We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 3d4d2db + 1dfe6da commit 9bbc2efCopy full SHA for 9bbc2ef
1 file changed
lib/solidus_reports/engine.rb
@@ -17,15 +17,9 @@ class Engine < Rails::Engine
17
end
18
19
initializer "solidus_reports.environment", before: :load_config_initializers do
20
- # rubocop:disable Lint/ConstantDefinitionInBlock
21
- # rubocop:disable Lint/OrAssignmentToConstant
22
- REPORT_TABS ||= [:reports].freeze
23
- # rubocop:enable Lint/ConstantDefinitionInBlock
24
- # rubocop:enable Lint/OrAssignmentToConstant
25
-
26
new_item = Spree::BackendConfiguration::MenuItem.new(
27
- REPORT_TABS,
28
- "file",
+ label: :reports,
+ icon: "file",
29
condition: -> { can?(:admin, :reports) }
30
)
31
Spree::Backend::Config.menu_items << new_item
0 commit comments