From 3977e13d8dce8644398e0d8166a746483b647238 Mon Sep 17 00:00:00 2001
From: Eric Bremner <ebremner@uwaterloo.ca>
Date: Thu, 20 Feb 2025 13:38:20 -0500
Subject: [PATCH] ISTWCMS-7252: Using permission for accessing custom form
 users page

---
 uw_custom_forms.permissions.yml | 3 +++
 uw_custom_forms.routing.yml     | 2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)
 create mode 100644 uw_custom_forms.permissions.yml

diff --git a/uw_custom_forms.permissions.yml b/uw_custom_forms.permissions.yml
new file mode 100644
index 0000000..375ded3
--- /dev/null
+++ b/uw_custom_forms.permissions.yml
@@ -0,0 +1,3 @@
+access uw custom forms user settings:
+  title: 'Access UW custom forms user settings'
+  description: 'Access the list of users per uw custom forms.'
diff --git a/uw_custom_forms.routing.yml b/uw_custom_forms.routing.yml
index c5ad3d9..97a6c8e 100644
--- a/uw_custom_forms.routing.yml
+++ b/uw_custom_forms.routing.yml
@@ -11,7 +11,7 @@ admission_requirements_form.users:
     _form: '\Drupal\uw_custom_forms\Form\AdmissionRequirementsFormUsers'
     _title: 'Admission requirements user settings'
   requirements:
-    _custom_access: '\Drupal\uw_custom_forms\Form\AdmissionRequirementsFormUsers::access'
+    _permission: 'access uw custom forms user settings'
 admission_requirements_form.settings:
   path: '/admin/config/admission-requirements-form/settings'
   defaults:
-- 
GitLab