-
Notifications
You must be signed in to change notification settings - Fork 16
/
og.routing.yml
45 lines (41 loc) · 1.34 KB
/
og.routing.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Routes for Organic groups.
og.subscribe:
path: 'group/{entity_type_id}/{group}/subscribe/{membership_type}'
defaults:
_controller: '\Drupal\og\Controller\SubscriptionController::subscribe'
_title: 'Join Group'
membership_type: default
requirements:
# Only authenticated users can subscribe to group, but we do allow anonymous
# users to reach this route. They will be redirect to login page or be given
# the correct page by the controller.
_access: 'TRUE'
options:
parameters:
group:
type: entity:{entity_type_id}
membership_type:
type: entity:og_membership_type
og.unsubscribe:
path: 'group/{entity_type_id}/{group}/unsubscribe'
defaults:
_controller: '\Drupal\og\Controller\SubscriptionController::unsubscribe'
_title: 'Leave Group'
requirements:
_user_is_logged_in: 'TRUE'
options:
parameters:
group:
type: entity:{entity_type_id}
og.add_multiple_roles_confirm:
path: '/group/roles/add'
defaults:
_form: '\Drupal\og\Form\OgAddMultipleRolesForm'
requirements:
_custom_access: '\Drupal\og\Form\OgAddMultipleRolesForm::access'
og.remove_multiple_roles_confirm:
path: '/group/roles/remove'
defaults:
_form: '\Drupal\og\Form\OgRemoveMultipleRolesForm'
requirements:
_custom_access: '\Drupal\og\Form\OgRemoveMultipleRolesForm::access'