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