diff --git a/app/models/module_app.rb b/app/models/module_app.rb index 282840537..740d0d18b 100644 --- a/app/models/module_app.rb +++ b/app/models/module_app.rb @@ -185,18 +185,18 @@ class ModuleApp user_ids = self.auth_approvals.inject([]) do |users, auth| users += auth.authorized_users.map{|user| user.id} end - update_attribute(:auth_approval_users, user_ids.uniq) + self.update_attribute(:auth_approval_users, user_ids.uniq) end def update_auth_manager_users - update_attribute(:auth_manager_users, self.auth_manager_authorized_users.map{|user| user.id}) + self.update_attribute(:auth_manager_users, self.auth_manager_authorized_users.map{|user| user.id}) end def update_auth_sub_manager_users user_ids = self.auth_sub_managers.inject([]) do |users, auth| users += auth.authorized_users.map{|user| user.id} end - update_attribute(:auth_sub_manager_users, user_ids.uniq) + self.update_attribute(:auth_sub_manager_users, user_ids.uniq) end def managers diff --git a/app/views/admin/categories/_category.html.erb b/app/views/admin/categories/_category.html.erb index ad98735bd..de09e970d 100644 --- a/app/views/admin/categories/_category.html.erb +++ b/app/views/admin/categories/_category.html.erb @@ -10,7 +10,7 @@
  • <%= link_to show_toggle_archive_btn(category) , toggle_admin_module_app_category_path(@module_app_id, category), method: :post, remote: true, class: "archive_toggle" %>
  • <% end %> <% if is_manager? || is_admin? %> -
  • <%= link_to t(:category_auth), admin_authorizations_path(@module_app.key, 'category', category.id) %>
  • +
  • <%= link_to t(:category_auth), admin_authorizations_path(@module_app.key, 'category_authorization', category.id) %>
  • <% end %>