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