Commit a83d0e882ccd318e265eaac7a68af32cd747099d

Authored by Luciano Prestes
1 parent 484cf1f1

Removed unnecessary buttons in step 2 of the software creation

Signed-off-by: Fabio Teixeira <fabio1079@gmail.com>
Signed-off-by: Luciano Prestes <lucianopcbr@gmail.com>
views/profile_editor/edit_software_community.html.erb
  1 +
1 <%= render :partial => 'first_edit_software_community_extras', :locals => {:class_step_one => "another-step", :class_step_two => "current-step"} if @first_edit %> 2 <%= render :partial => 'first_edit_software_community_extras', :locals => {:class_step_one => "another-step", :class_step_two => "current-step"} if @first_edit %>
2 3
3 <h1><%= _('Configure Software Community') %></h1> 4 <h1><%= _('Configure Software Community') %></h1>
@@ -66,19 +67,20 @@ @@ -66,19 +67,20 @@
66 67
67 <% button_bar do %> 68 <% button_bar do %>
68 <%= submit_button('save', _('Save'), :cancel => {:action => 'index'}) %> 69 <%= submit_button('save', _('Save'), :cancel => {:action => 'index'}) %>
69 - <%= button(:back, _('Back to control panel'), :controller => 'profile_editor') %> 70 +
  71 + <% unless @first_edit %>
  72 + <%= button(:back, _('Back to control panel'), :controller => 'profile_editor') %>
  73 + <% end %>
70 <% end %> 74 <% end %>
71 75
72 - <% if user && user.has_permission?('destroy_profile', profile) %> 76 + <% if user && user.has_permission?('destroy_profile', profile) && !@first_edit %>
73 <% button_bar(:id => 'delete-profile') do %> 77 <% button_bar(:id => 'delete-profile') do %>
74 - <%= button(:remove, _('Delete profile'), {:action => :destroy_profile}) %>  
75 - 78 + <%= button(:remove, _('Delete software and community'), {:action => :destroy_profile}) %>
76 <% if environment.admins.include?(current_person) %> 79 <% if environment.admins.include?(current_person) %>
77 -  
78 <% if profile.visible? %> 80 <% if profile.visible? %>
79 - <%= button(:remove, _('Deactivate profile'), {:action => :deactivate_profile, :id=>profile.id}, :id=>'deactivate_profile_button', :data => {:confirm=>_("Are you sure you want to deactivate this profile?")}) %> 81 + <%= button(:remove, _('Deactivate software and community'), {:action => :deactivate_profile, :id=>profile.id}, :id=>'deactivate_profile_button', :data => {:confirm=>_("Are you sure you want to deactivate this profile?")}) %>
80 <% else %> 82 <% else %>
81 - <%= button(:add, _('Activate profile'), {:action => :activate_profile, :id=>profile.id}, :data => {:confirm=>_("Are you sure you want to deactivate this profile?")}) %> 83 + <%= button(:add, _('Activate software and community'), {:action => :activate_profile, :id=>profile.id}, :data => {:confirm=>_("Are you sure you want to deactivate this profile?")}) %>
82 <% end %> 84 <% end %>
83 <% end %> 85 <% end %>
84 <% end %> 86 <% end %>