canDo('parser.whatsapp.approve')) { return true; } return false; } /** * Determine if the given user can approve the given whatsapp. * * @param UserPolicyInterface $authUser * * @return bool */ public function submit(UserPolicyInterface $authUser, Whatsapp $whatsapp) { if ($authUser->canDo('parser.whatsapp.submit')) { return true; } return false; } /** * Determine if the given user can approve the given whatsapp. * * @param UserPolicyInterface $authUser * * @return bool */ public function publish(UserPolicyInterface $authUser, Whatsapp $whatsapp) { if ($authUser->canDo('parser.whatsapp.publish')) { return true; } return false; } /** * Determine if the given user can approve the given whatsapp. * * @param UserPolicyInterface $authUser * * @return bool */ public function unpublish(UserPolicyInterface $authUser, Whatsapp $whatsapp) { if ($authUser->canDo('parser.whatsapp.unpublish')) { return true; } return false; } /** * Determine if the given user can approve the given whatsapp. * * @param UserPolicyInterface $authUser * * @return bool */ public function archive(UserPolicyInterface $authUser, Whatsapp $whatsapp) { if ($authUser->canDo('parser.whatsapp.archive')) { return true; } return false; } /** * Determine if the given user can approve the given whatsapp. * * @param UserPolicyInterface $authUser * * @return bool */ public function unarchive(UserPolicyInterface $authUser, Whatsapp $whatsapp) { if ($authUser->canDo('parser.whatsapp.unarchive')) { return true; } return false; } /** * Determine if the given user can approve the given whatsapp. * * @param UserPolicyInterface $authUser * * @return bool */ public function reject(UserPolicyInterface $authUser, Whatsapp $whatsapp) { if ($authUser->canDo('parser.whatsapp.reject')) { return true; } return false; } }