index.rhtml 1.63 KB
<h2><%= _('My profile') %></h2>

<%= link_to (@profile.image ? image_tag( @profile.image.public_filename) : _('Put image')), :action => 'change_image'  %>

<%= display_profile_info(profile) %>


<% file_manager do %>

  <%= file_manager_button(_('Edit Profile'), 'icons-app/edit-profile.png', :controller => 'profile_editor', :action => 'edit') %>

  <%= file_manager_button(_('Edit Visual Design'), 'icons-app/design-editor.png', :controller => 'profile_editor', :action => 'design_editor') %>

  <%= 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 Members'), 'icons-app/members.png', :controller => 'profile_members') if profile.organization?  %>

  <%= file_manager_button(_('Consumed Products'), 'icons-app/consumed_product.png', :controller => 'consumed_products')  %>

  <%= file_manager_button(_('Manage Products'), 'icons-app/products.png', :controller => 'manage_products') if profile.enterprise? %>

<% end %>

<% if @profile.person? %>
  <h2><%= _('My organizations') %></h2>
  
  <% file_manager do %>

    <% @profile.enterprise_memberships.each do |em| %>
      <%= file_manager_button(em.name, em.image ? em.image.public_filename(:minor) : 'icons-app/organization.png', :profile => em.identifier, :controller => 'profile_editor' ) %>
    <% end %>

    <%= file_manager_button(_('Register a new Enterprise'), 'icons-app/enterprise-registration.png', :controller => 'enterprise_registration') %>

  <% end %>

<% end %>