Skip to content

Commit

Permalink
feature: rbac
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul-Bob committed Dec 3, 2024
1 parent e25597b commit 7f132b0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/avo.rb
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ def mount_engines
mount Avo::Dashboards::Engine, at: "/dashboards" if defined?(Avo::Dashboards::Engine)
mount Avo::Pro::Engine, at: "/avo-pro" if defined?(Avo::Pro::Engine)
mount Avo::Kanban::Engine, at: "/boards" if defined?(Avo::Kanban::Engine)
mount Avo::Permissions::Engine, at: "/permissions" if defined?(Avo::Permissions::Engine)
}
end

Expand Down
3 changes: 2 additions & 1 deletion lib/avo/resources/resource_manager.rb
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,8 @@ def get_available_resources(user = nil)
resource.model_class,
Avo.configuration.authorization_methods.stringify_keys["index"],
policy_class: resource.authorization_policy,
raise_exception: false
raise_exception: false,
resource_class: resource.to_s
)
end
.sort_by { |r| r.name }
Expand Down

0 comments on commit 7f132b0

Please sign in to comment.