Commit 06e544caeed945dde31bc83e51e0c3d0e2bcca4a

Authored by Luciano Prestes
1 parent c791e21b

Remove manage_software feature from plugin

Signed-off-by: Arthur Del Esposte <arthurmde@gmail.com>
Signed-off-by: Luciano Prestes <lucianopcbr@gmail.com>
controllers/mpog_software_plugin_controller.rb
... ... @@ -2,29 +2,6 @@ require &#39;csv&#39;
2 2 class MpogSoftwarePluginController < ApplicationController
3 3 include InstitutionHelper
4 4  
5   - def archive_software
6   - per_page = 10
7   - scope = SoftwareInfo
8   - @q = params[:q]
9   - @collection = find_by_contents(:community, scope, @q, {:per_page => per_page, :page => params[:npage]})[:results]
10   - end
11   -
12   - def deactivate
13   - community = SoftwareInfo.find(params[:id]).community_id
14   - Community.find(community).deactivate
15   - if params[:from_profile]
16   - redirect_to :back
17   - else
18   - redirect_to :action => 'archive_software'
19   - end
20   - end
21   -
22   - def activate
23   - community = SoftwareInfo.find(params[:id]).community_id
24   - Community.find(community).activate
25   - redirect_to :action => 'archive_software'
26   - end
27   -
28 5 def check_reactivate_account
29 6 if request.xhr? and params[:email]
30 7 result = ""
... ...
views/mpog_software_plugin/archive_software.html.erb
... ... @@ -1,13 +0,0 @@
1   -<h1><%= _('Manage softwares') %></h1>
2   -
3   -<%= form_tag( { :action => 'archive_software' }, :method => 'get', :class => 'users-search' ) do %>
4   -
5   -<div id="search-softwares">
6   - <%= render :partial => 'softwares_search_form' %>
7   -</div>
8   -<div id="softwares-list">
9   - <%= render :partial => 'software_list' %>
10   -</div>
11   -<% end %>
12   -
13   -<%= render :partial => 'index_buttons' %>
14 0 \ No newline at end of file
views/profile/_software_tab.html.erb
... ... @@ -97,10 +97,4 @@
97 97 </td>
98 98 </tr>
99 99 </tr>
100   -</table>
101   -
102   -<% if profile.admins.include? current_person %>
103   - <%= label_tag _("Deactivate Software: ") %>
104   - <%= button_without_text :'deactivate-user', _('Deactivate software'), {:controller => "mpog_software_plugin", :action => 'deactivate', :id => profile.software_info.id, :q => @q, :from_profile => true}, :filter => @filter, :confirm => _("Do you want to deactivate this software?") %>
105   -<% end %>
106   -
  100 +</table>
107 101 \ No newline at end of file
... ...