Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kazuhiko Shiozaki
gitlab-ce
Commits
a8557183
Commit
a8557183
authored
Apr 19, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Redesign team.members pages
parent
d6cebe34
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
44 deletions
+41
-44
app/views/teams/members/_show.html.haml
app/views/teams/members/_show.html.haml
+19
-18
app/views/teams/members/new.html.haml
app/views/teams/members/new.html.haml
+22
-26
No files found.
app/views/teams/members/_show.html.haml
View file @
a8557183
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
-
allow_admin
=
can?
current_user
,
:manage_user_team
,
@team
-
allow_admin
=
can?
current_user
,
:manage_user_team
,
@team
%li
{
id:
dom_id
(
member
),
class:
"team_member_row user_#{user.id}"
}
%li
{
id:
dom_id
(
member
),
class:
"team_member_row user_#{user.id}"
}
.row
.row
.span
5
.span
4
=
link_to
user_path
(
user
.
username
),
title:
user
.
name
,
class:
"dark"
do
=
link_to
user_path
(
user
.
username
),
title:
user
.
name
,
class:
"dark"
do
=
image_tag
gravatar_icon
(
user
.
email
,
40
),
class:
"avatar s32"
=
image_tag
gravatar_icon
(
user
.
email
,
40
),
class:
"avatar s32"
=
link_to
user_path
(
user
.
username
),
title:
user
.
name
,
class:
"dark"
do
=
link_to
user_path
(
user
.
username
),
title:
user
.
name
,
class:
"dark"
do
...
@@ -10,14 +10,15 @@
...
@@ -10,14 +10,15 @@
%br
%br
%small
.cgray
=
user
.
username
%small
.cgray
=
user
.
username
.span
4
.span
7.pull-right
-
if
allow_admin
-
if
allow_admin
.pull-left
=
form_for
(
member
,
as: :team_member
,
url:
team_member_path
(
@team
,
user
))
do
|
f
|
=
form_for
(
member
,
as: :team_member
,
url:
team_member_path
(
@team
,
user
))
do
|
f
|
=
f
.
select
:permission
,
options_for_select
(
UsersProject
.
access_roles
,
@team
.
default_projects_access
(
user
)),
{},
class:
"medium trigger-submit"
%br
=
label_tag
do
=
label_tag
do
=
f
.
check_box
:group_admin
,
class:
'trigger-submit'
=
f
.
check_box
:group_admin
,
class:
'trigger-submit'
%span
Admin access
%span
Admin access
=
f
.
select
:permission
,
options_for_select
(
UsersProject
.
access_roles
,
@team
.
default_projects_access
(
user
)),
{},
class:
"medium trigger-submit"
.pull-right
.pull-right
-
if
current_user
==
user
-
if
current_user
==
user
%span
.btn.disabled
This is you!
%span
.btn.disabled
This is you!
...
...
app/views/teams/members/new.html.haml
View file @
a8557183
%h3
.page_title
%h3
.page_title
Team:
#{
@team
.
name
}
Team:
#{
@team
.
name
}
%fieldset
%hr
%legend
Members (
#{
@team
.
members
.
count
}
)
=
form_tag
team_members_path
(
@team
),
id:
"team_members"
,
class:
"bulk_import"
,
method: :post
do
=
form_tag
team_members_path
(
@team
),
id:
"team_members"
,
class:
"bulk_import"
,
method: :post
do
%table
#members_list
%h6
1. Choose people you want in the team
%thead
.clearfix
%tr
=
label_tag
:user_ids
,
"People"
%th
User name
.input
%th
Default project access
%th
Team access
%th
-
@team
.
members
.
each
do
|
member
|
%tr
.member
%td
=
member
.
name
%small
=
"(
#{
member
.
username
}
)"
%td
=
@team
.
human_default_projects_access
(
member
)
%td
=
@team
.
admin?
(
member
)
?
"Admin"
:
"Member"
%td
%tr
%td
=
users_select_tag
(
:user_ids
,
multiple:
true
)
=
users_select_tag
(
:user_ids
,
multiple:
true
)
%td
=
select_tag
:default_project_access
,
options_for_select
(
Project
.
access_options
),
{
class:
"project-access-select chosen span3"
}
%td
%h6
2. Set access level for them
%span
=
check_box_tag
:group_admin
.clearfix
%span
Admin?
=
label_tag
:project_access
,
"Project Access"
%td
=
submit_tag
'Add User'
,
class:
"btn btn-create"
,
id: :add_members_to_team
.input
=
select_tag
:default_project_access
,
options_for_select
(
Project
.
access_options
),
class:
"project-access-select chosen"
.clearfix
=
label_tag
:group_admin
do
%span
Team Admin?
.input
=
check_box_tag
:group_admin
.actions
=
submit_tag
'Add users'
,
class:
"btn btn-create"
,
id: :add_members_to_team
=
link_to
"Cancel"
,
team_members_path
(
@team
),
class:
"btn btn-cancel"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment