Remove switch organizations tab from settings and clear Rails cache for PUT /admin/organizations (#3045)
* Remove switch organization functionality * Touch profile_updated_at when updating org
This commit is contained in:
parent
df44cbd254
commit
982658d3ab
3 changed files with 8 additions and 7 deletions
|
|
@ -8,6 +8,11 @@ module Admin
|
|||
# @resources = Organization.all.paginate(10, params[:page])
|
||||
# end
|
||||
|
||||
def update
|
||||
super
|
||||
@requested_resource.touch(:profile_updated_at)
|
||||
end
|
||||
|
||||
# Define a custom finder by overriding the `find_resource` method:
|
||||
# def find_resource(param)
|
||||
# Organization.find_by!(slug: param)
|
||||
|
|
|
|||
|
|
@ -404,16 +404,16 @@ class User < ApplicationRecord
|
|||
end
|
||||
|
||||
def settings_tab_list
|
||||
tab_list = %w[
|
||||
%w[
|
||||
Profile
|
||||
Integrations
|
||||
Notifications
|
||||
Publishing\ from\ RSS
|
||||
Organization
|
||||
Billing
|
||||
Account
|
||||
Misc
|
||||
]
|
||||
tab_list << "Switch Organizations" if has_role?(:switch_between_orgs)
|
||||
tab_list.push("Account", "Misc")
|
||||
end
|
||||
|
||||
def profile_image_90
|
||||
|
|
|
|||
|
|
@ -1,4 +0,0 @@
|
|||
<% if @user.has_role?(:switch_between_orgs) %>
|
||||
<h1 style="color:#00cc44">Hey Mary 👋</h1>
|
||||
<%= render "users/org_non_member" %>
|
||||
<% end %>
|
||||
Loading…
Add table
Reference in a new issue