Refactor menu registration to add top menu item for calendar and remove project menu entry for customer calendar

This commit is contained in:
ricky committed 2026-09-06 21:21:45 -04:00
1 parent 97ed852068
commit 8448c06b10
1 file changed
+3 -8
+3 -8
View File
@@ -46,20 +46,15 @@ Redmine::Plugin.register :redmine_qbo_calendar do
}
end
menu :project_menu,
:customer_calendar,
{ controller: 'events',
action: 'index' },
caption: 'Customer Calendar',
after: :calendar,
param: :project_id
# Global Permissions
permission :view_customer_appointments, { customer_appointments: [:index, :show] }, global: true
permission :add_customer_appointments, { customer_appointments: [:new, :create] }, global: true
permission :edit_customer_appointments, { customer_appointments: [:edit, :update] }, global: true
permission :delete_customer_appointments, { customer_appointments: [:destroy] }, global: true
# Register top menu items
menu :top_menu, :calendar, { controller: :calendars, action: :show }, caption: :label_calendar, if: Proc.new {User.current.logged?}
end
Rails.configuration.to_prepare do