index.rhtml
2.57 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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
<div id="profile-editor-index">
<h1 class="block-title"><%= _('My profile') %></h1>
<%= render :partial => 'pending_tasks' %>
<% file_manager do %>
<%= file_manager_button(_('Edit Profile'), 'icons-app/edit-profile.png', :controller => 'profile_editor', :action => 'edit') %>
<%= file_manager_button(_('Mail settings'), 'icons-app/mail.png', :controller => 'mailconf') if profile.person? && MailConf.enabled? %>
<%= file_manager_button(_('Pending tasks'), 'icons-app/todo.png', :controller => 'tasks', :action => 'index') %>
<%= file_manager_button(_('Edit Visual Design'), 'icons-app/design-editor.png', :controller => 'profile_design', :action => 'index') %>
<%= file_manager_button(_('Manage Content'), 'icons-app/cms.png', :controller => 'cms') %>
<%= file_manager_button(_('Change Password'), 'icons-app/change-password.png', :controller => 'account', :action => 'change_password') if profile.person? %>
<%= file_manager_button(_('Manage friends'), 'icons-app/friends.png', :controller => 'friends', :action => 'index') if profile.person? %>
<%= file_manager_button(_('Manage Members'), 'icons-app/members.png', :controller => 'profile_members') if profile.organization? && user.has_permission?(:manage_memberships, profile) %>
<%= file_manager_button(_('Manage Products and Services'), 'icons-app/products.png', :controller => 'manage_products') if profile.enterprise? %>
<%= file_manager_button(_('Enterprise Validation'), 'icons-app/validation.png', :controller => 'enterprise_validation') if profile.is_validation_entity? %>
<%= file_manager_button(_('Favorite Enterprises'), 'icons-app/favorites.png', :controller => 'favorite_enterprises') if profile.person? %>
<% if profile.enterprise? %>
<% if profile.enabled? %>
<%= file_manager_button(_('Disable Enterprise'), 'icons-app/disable.png', :action => 'disable') %>
<% else %>
<%= file_manager_button(_('Enable Enterprise'), 'icons-app/enable.png', :action => 'enable') %>
<% end %>
<% end %>
<% end %>
<% if @profile.person? %>
<h2><%= _('Manage my groups') %></h2>
<% button_bar do %>
<%= button(:add, _('Create a new community'), :controller => 'memberships', :action => 'new_community') %>
<%= button(:add, _('Register a new Enterprise'), :controller => 'enterprise_registration') %>
<% end %>
<% file_manager do %>
<% @profile.memberships.each do |group| %>
<%= file_manager_button(group.name, profile_icon(group) , :profile => group.identifier, :controller => 'profile_editor' ) %>
<% end %>
<% end %>
<% end %>
</div><!-- end id="profile-editor-index" -->