2011-12-16 00:41:46 +02:00
|
|
|
- allow_admin = can? current_user, :admin_project, @project
|
2011-10-21 15:56:37 +03:00
|
|
|
- user = @team_member.user
|
2012-02-18 14:12:48 +02:00
|
|
|
|
2012-04-02 21:13:44 +03:00
|
|
|
.team_member_show
|
2012-07-29 01:40:21 +03:00
|
|
|
- if can? current_user, :admin_project, @project
|
2012-09-05 08:56:59 +03:00
|
|
|
= link_to 'Remove from team', project_team_member_path(project_id: @project, id: @team_member.id), confirm: 'Are you sure?', method: :delete, class: "right btn danger"
|
2012-04-02 21:13:44 +03:00
|
|
|
.profile_avatar_holder
|
2012-08-10 18:07:50 -04:00
|
|
|
= image_tag gravatar_icon(user.email, 60), class: "borders"
|
2012-12-13 21:44:55 +02:00
|
|
|
%h3.page_title
|
2012-04-02 21:13:44 +03:00
|
|
|
= user.name
|
|
|
|
%small
|
|
|
|
= user.email
|
2012-07-29 01:40:21 +03:00
|
|
|
|
2012-04-02 21:13:44 +03:00
|
|
|
%hr
|
|
|
|
.back_link
|
2012-03-24 01:01:36 +02:00
|
|
|
%br
|
2012-09-16 09:21:20 -04:00
|
|
|
= link_to project_team_index_path(@project), class: "" do
|
2012-04-02 21:13:44 +03:00
|
|
|
← To team list
|
|
|
|
%br
|
|
|
|
.row
|
2012-04-10 08:51:08 +03:00
|
|
|
.span6
|
2012-09-03 21:53:16 +03:00
|
|
|
%table.lite
|
2012-04-02 21:13:44 +03:00
|
|
|
%tr
|
|
|
|
%td Email
|
|
|
|
%td= mail_to user.email
|
|
|
|
%tr
|
|
|
|
%td Skype
|
|
|
|
%td= user.skype
|
|
|
|
- unless user.linkedin.blank?
|
|
|
|
%tr
|
|
|
|
%td LinkedIn
|
|
|
|
%td= user.linkedin
|
|
|
|
- unless user.twitter.blank?
|
|
|
|
%tr
|
|
|
|
%td Twitter
|
|
|
|
%td= user.twitter
|
|
|
|
- unless user.bio.blank?
|
|
|
|
%tr
|
|
|
|
%td Bio
|
|
|
|
%td= user.bio
|
2012-04-10 08:51:08 +03:00
|
|
|
.span6
|
2012-09-03 21:53:16 +03:00
|
|
|
%table.lite
|
2012-04-02 21:13:44 +03:00
|
|
|
%tr
|
|
|
|
%td Member since
|
|
|
|
%td= @team_member.created_at.stamp("Aug 21, 2011")
|
|
|
|
%tr
|
|
|
|
%td
|
|
|
|
Project Access:
|
2012-08-10 18:07:50 -04:00
|
|
|
%small (#{link_to "read more", help_permissions_path, class: "vlink"})
|
2012-04-02 21:13:44 +03:00
|
|
|
%td
|
2012-08-10 18:07:50 -04:00
|
|
|
= form_for(@team_member, as: :team_member, url: project_team_member_path(@project, @team_member)) do |f|
|
|
|
|
= f.select :project_access, options_for_select(Project.access_options, @team_member.project_access), {}, class: "project-access-select", disabled: !allow_admin
|
2012-04-02 21:13:44 +03:00
|
|
|
%hr
|
2012-08-21 08:20:11 +03:00
|
|
|
= render @events
|
2011-12-16 00:41:46 +02:00
|
|
|
:javascript
|
|
|
|
$(function(){
|
2012-06-04 01:37:27 +03:00
|
|
|
$('.repo-access-select, .project-access-select').live("change", function() {
|
2011-12-16 00:41:46 +02:00
|
|
|
$(this.form).submit();
|
|
|
|
});
|
|
|
|
})
|
2011-10-21 15:56:37 +03:00
|
|
|
|