Manage team from groups page. Phase 1
This commit is contained in:
parent
08fded3fac
commit
aaa1c94239
5 changed files with 66 additions and 15 deletions
|
@ -47,7 +47,12 @@ class GroupsController < ApplicationController
|
|||
end
|
||||
|
||||
def people
|
||||
@users = group.users
|
||||
@project = group.projects.find(params[:project_id]) if params[:project_id]
|
||||
@users = @project ? @project.users : group.users
|
||||
|
||||
if @project
|
||||
@team_member = @project.users_projects.new
|
||||
end
|
||||
end
|
||||
|
||||
protected
|
||||
|
|
|
@ -21,7 +21,11 @@ class TeamMembersController < ProjectResourceController
|
|||
params[:project_access]
|
||||
)
|
||||
|
||||
redirect_to project_team_index_path(@project)
|
||||
if params[:redirect_to]
|
||||
redirect_to params[:redirect_to]
|
||||
else
|
||||
redirect_to project_team_index_path(@project)
|
||||
end
|
||||
end
|
||||
|
||||
def update
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue