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