Update check If user can assign project to team
This commit is contained in:
parent
6d713e84e1
commit
e52fec9cd9
|
@ -4,7 +4,7 @@ class Teams::ProjectsController < Teams::ApplicationController
|
||||||
|
|
||||||
def index
|
def index
|
||||||
@projects = user_team.projects
|
@projects = user_team.projects
|
||||||
@avaliable_projects = current_user.admin? ? Project.without_team(user_team) : (Project.personal(current_user) + current_user.projects).uniq
|
@avaliable_projects = current_user.admin? ? Project.without_team(user_team) : current_user.owned_projects.without_team(user_team)
|
||||||
end
|
end
|
||||||
|
|
||||||
def new
|
def new
|
||||||
|
|
Loading…
Reference in a new issue