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