gitlabhq/app/views/admin/users/show.html.haml

128 lines
2.8 KiB
Text
Raw Normal View History

%h3.page_title
User: #{@admin_user.name}
- if @admin_user.blocked
%small Blocked
- if @admin_user.admin
%small Administrator
= link_to edit_admin_user_path(@admin_user), class: "btn right" do
%i.icon-edit
Edit
2011-10-08 23:36:38 +02:00
%br
2012-02-11 18:56:18 +01:00
2012-09-03 20:53:16 +02:00
%table.zebra-striped
%thead
%tr
%th Profile
%th
2011-11-18 21:55:13 +01:00
%tr
%td
%b
Email:
%td
= @admin_user.email
2012-11-28 04:14:05 +01:00
%tr
%td
%b
Username:
%td
= @admin_user.username
2011-11-18 21:55:13 +01:00
%tr
%td
%b
Admin:
%td= check_box_tag "admin", 1, @admin_user.admin, disabled: :disabled
2012-04-13 07:12:34 +02:00
%tr
%td
%b
Blocked:
%td= check_box_tag "blocked", 1, @admin_user.blocked, disabled: :disabled
%tr
%td
%b
Created at:
%td
= @admin_user.created_at.stamp("March 1, 1999")
2011-11-18 21:55:13 +01:00
%tr
%td
%b
Projects limit:
%td
= @admin_user.projects_limit
- unless @admin_user.skype.empty?
%tr
%td
%b
Skype:
%td
= @admin_user.skype
- unless @admin_user.linkedin.empty?
%tr
%td
%b
Linkedin:
%td
= @admin_user.linkedin
- unless @admin_user.twitter.empty?
%tr
%td
%b
Twitter:
%td
= @admin_user.twitter
2011-10-08 23:36:38 +02:00
%br
2012-12-10 04:14:05 +01:00
%h5 Add User to Projects
%br
= form_tag team_update_admin_user_path(@admin_user), class: "bulk_import", method: :put do
2012-09-03 20:53:16 +02:00
%table
2012-02-11 18:56:18 +01:00
%thead
2011-10-08 23:36:38 +02:00
%tr
2012-02-11 18:56:18 +01:00
%th Projects
%th Project Access:
%tr
%td= select_tag :project_ids, options_from_collection_for_select(@projects , :id, :name_with_namespace), multiple: true, data: {placeholder: 'Select projects'}, class: 'chosen span5'
%td= select_tag :project_access, options_for_select(Project.access_options), class: "project-access-select chosen span3"
2012-02-11 18:56:18 +01:00
%tr
%td= submit_tag 'Add', class: "btn primary"
%td
Read more about project permissions
%strong= link_to "here", help_permissions_path, class: "vlink"
%br
2012-12-10 04:14:05 +01:00
- if @admin_user.groups.present?
%h5 Owner of groups:
%br
%table.zebra-striped
%thead
%tr
%th Name
- @admin_user.groups.each do |group|
%tr
%td= link_to group.name, admin_group_path(group)
- if @admin_user.projects.present?
2012-12-10 04:14:05 +01:00
%h5 Projects:
%br
2012-02-11 18:56:18 +01:00
2012-09-03 20:53:16 +02:00
%table.zebra-striped
%thead
%tr
%th Name
%th Project Access
%th
%th
- @admin_user.users_projects.each do |tm|
- project = tm.project
%tr
%td= link_to project.name_with_namespace, admin_project_path(project)
%td= tm.project_access_human
%td= link_to 'Edit Access', edit_admin_team_member_path(tm), class: "btn small"
%td= link_to 'Remove from team', admin_team_member_path(tm), confirm: 'Are you sure?', method: :delete, class: "btn small danger"