2014-01-21 04:51:49 +00:00
|
|
|
|
-set_meta_tags title: [title_object(@project), t('layout.projects.members')]
|
2012-05-02 10:18:07 +01:00
|
|
|
|
= render 'sidebar'
|
|
|
|
|
= render 'submenu'
|
2012-04-09 18:11:39 +01:00
|
|
|
|
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%a{name: 'users'}
|
2012-04-09 18:11:39 +01:00
|
|
|
|
%h3= t("layout.users.list_header")
|
|
|
|
|
|
2013-08-07 19:54:42 +01:00
|
|
|
|
#collaborators{'ng-controller' => 'CollaboratorsController'}
|
2013-08-07 17:27:24 +01:00
|
|
|
|
= hidden_field_tag :owner_name, @project.try(:owner).try(:uname)
|
|
|
|
|
= hidden_field_tag :project_name, @project.try(:name)
|
|
|
|
|
|
|
|
|
|
#add_collaborator_form
|
|
|
|
|
.admin-search.withimage
|
|
|
|
|
.img
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%img{alt: 'avatar', 'ng-src' => '{{new_collaborator.avatar}}', 'ng-show' => 'new_collaborator.avatar'}
|
2013-08-07 19:54:42 +01:00
|
|
|
|
= text_field_tag :collaborator_name, nil, 'ng-model' => 'new_collaborator.term', 'ng-keyup' => 'search()'
|
2013-08-07 17:27:24 +01:00
|
|
|
|
|
2013-08-08 11:41:54 +01:00
|
|
|
|
.admin-role
|
|
|
|
|
.lineForm
|
|
|
|
|
= select_tag 'role', options_for_collaborators_roles_select, 'ng-model' => 'new_collaborator.collaborator.role'
|
|
|
|
|
.admin-add
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%a.button{rel: 'nofollow', href: '', 'ng-click' => 'add()'}
|
2013-08-08 11:41:54 +01:00
|
|
|
|
= t('layout.add')
|
|
|
|
|
.both
|
|
|
|
|
|
2013-08-07 17:27:24 +01:00
|
|
|
|
.users-search-popup
|
|
|
|
|
.header
|
|
|
|
|
.title= t('layout.issues.search_user')
|
|
|
|
|
%span.icon-remove-circle
|
|
|
|
|
.list
|
|
|
|
|
.people{'ng-repeat' => 'c in new_collaborators', 'ng-click' => 'select(c)'}
|
|
|
|
|
.avatar
|
|
|
|
|
%img{width: '16px', 'ng-src' => '{{c.avatar}}', alt: 'avatar'}
|
|
|
|
|
.name {{c.actor_name}}
|
|
|
|
|
.both
|
2014-01-21 04:51:49 +00:00
|
|
|
|
|
2013-08-07 17:27:24 +01:00
|
|
|
|
.nothing{'ng-hide' => 'new_collaborators.length > 0'}= t('layout.issues.nothing_to_show')
|
|
|
|
|
.both
|
2012-04-12 22:44:53 +01:00
|
|
|
|
.both
|
2013-08-07 17:27:24 +01:00
|
|
|
|
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%table.tablesorter{cellpadding: "0", cellspacing: "0"}
|
2013-08-07 17:27:24 +01:00
|
|
|
|
%thead
|
|
|
|
|
%tr
|
|
|
|
|
%th.centered
|
|
|
|
|
%span.delete{'ng-click' => 'deleteCollaborators()'}
|
|
|
|
|
%th
|
|
|
|
|
= t("layout.collaborators.members")
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%th{colspan: "3"}
|
2013-08-07 17:27:24 +01:00
|
|
|
|
= t("layout.collaborators.roles")
|
|
|
|
|
%tr.search
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%th{colspan: "5"}
|
|
|
|
|
%input{type: "text", placeholder: "#{t('layout.filter_by_name')}", 'ng-model' => 'query.actor_name'}
|
2013-08-07 17:27:24 +01:00
|
|
|
|
|
|
|
|
|
%tbody
|
|
|
|
|
%tr{'ng-repeat' => 'c in collaborators | filter:query'}
|
|
|
|
|
%td
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%input{type: 'checkbox', 'ng-model' => 'c.removed' }
|
2013-08-07 17:27:24 +01:00
|
|
|
|
%td
|
|
|
|
|
.img
|
|
|
|
|
%img{'ng-src' => '{{c.avatar}}', alt: 'avatar' }
|
|
|
|
|
.forimg
|
|
|
|
|
%a{'ng-href' => '{{c.actor_path}}'} {{c.actor_name}}
|
|
|
|
|
|
|
|
|
|
- Relation::ROLES.each do |role|
|
|
|
|
|
%td
|
|
|
|
|
.radio
|
2014-01-21 04:51:49 +00:00
|
|
|
|
%input{type: 'radio', 'ng-model' => 'c.collaborator.role', value: role, 'ng-click' => 'update(c)'}
|
2013-08-07 17:27:24 +01:00
|
|
|
|
.forradio
|
|
|
|
|
%label= t("layout.collaborators.role_names.#{role}")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%br
|
|
|
|
|
|
|
|
|
|
.both
|