_add_member.rhtml
1.42 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<h2><%= _('New member') %></h2>
<%= link_to( profile_image(task.requestor, :minor, :border => 0), task.requestor.public_profile_url ) %>
<%= _('%s wants to be a member of %s.') %
[content_tag('strong', link_to( task.requestor.name, task.requestor.public_profile_url ) ),
content_tag('strong', link_to( task.target.name, task.target.public_profile_url ) )] %>
<% form_for('task', task, :url => { :action => 'close', :id => task.id } ) do |f| %>
<div>
<%= radio_button_tag(:decision, 'finish', true,
:id => "decision-finish-#{task.id}",
:onclick => "Element.show('group-for-friend-#{task.id}')") %>
<label for="<%= "decision-finish-#{task.id}" %>"><b><%= _('Accept') %></b></label>
<%= radio_button_tag(:decision, 'cancel', false,
:id => "decision-cancel-#{task.id}",
:onclick => "Element.hide('group-for-friend-#{task.id}')") %>
<label for="<%= "decision-cancel-#{task.id}" %>"><b><%= _('Ignore') %></b></label>
<p class="member-classify-suggestions">
<%= _('Roles:') %> <br>
<%
@roles = Role.find(:all).select{ |r| r.has_kind?('Profile') }
%>
<% @roles.each do |r| %>
<%= labelled_check_box(r.name, 'task[roles][]', r.id, ( task.target.members.empty? ? true : ( r.id == Profile::Roles.member.id ) ) ) %><br/>
<% end %>
</p>
</div>
<% button_bar do %>
<%= submit_button(:ok, _('Ok!')) %>
<% end %>
<% end %>