Implement global permissions for customer appointments and update views to check permissions before displaying actions

This commit is contained in:
ricky committed 2026-09-06 21:11:18 -04:00
1 parent 167e956457
commit 97ed852068
8 files changed
+70 -40

No files matched your search

@@ -5,8 +5,10 @@
<i class="fa-regular fa-calendar-days"></i> <%= l(:button_calendar) %>
<% end %>
<%= link_to new_customer_appointment_path do %>
<i class="fa-regular fa-pen-to-square"></i> <%= l(:button_add) %>
<% if User.current.allowed_to?(:add_customer_appointments, nil, global: true) %>
<%= link_to new_customer_appointment_path do %>
<i class="fa-regular fa-pen-to-square"></i> <%= l(:button_add) %>
<% end %>
<% end %>
</div>