Commit b9826c1e4c93d830ecc6415f491709f82860dab8

Authored by Leandro Santos
1 parent d627c51d
Exists in master

see only by environment admin

controllers/myprofile/dialoga_plugin_myprofile_controller.rb
1 1 class DialogaPluginMyprofileController < MyProfileController
2 2  
3   - protect 'perform_task', :profile
  3 + before_filter :is_admin
4 4  
5 5 def send_report
6 6 path = File.join(Rails.root,'plugins','dialoga','script')
... ... @@ -13,4 +13,10 @@ class DialogaPluginMyprofileController &lt; MyProfileController
13 13 redirect_to :back
14 14 end
15 15  
  16 + protected
  17 + def is_admin
  18 + render_access_denied unless current_person.is_admin?
  19 + end
  20 +
  21 +
16 22 end
... ...