forked from apigee/apigee-m10n-drupal
-
Notifications
You must be signed in to change notification settings - Fork 0
/
apigee_m10n.routing.yml
178 lines (163 loc) · 5.79 KB
/
apigee_m10n.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
apigee_m10n.settings:
path: /admin/config/apigee-monetization
defaults:
_controller: \Drupal\system\Controller\SystemController::systemAdminMenuBlockPage
_title: Monetization
requirements:
_permission: administer apigee monetization
options:
# This enables monetization check for this route.
_apigee_monetization_route: TRUE
# This route is required for field UI routes to be attached to.
apigee_m10n.settings.rate_plan:
path: /admin/config/apigee-monetization/rate-plan
defaults:
_form: \Drupal\apigee_m10n\Form\RatePlanConfigForm
_title: Rate Plans
requirements:
_permission: administer apigee monetization
options:
_apigee_monetization_route: TRUE
apigee_m10n.settings.product_bundle:
path: /admin/config/apigee-monetization/product-bundle
defaults:
_controller: \Drupal\system\Controller\SystemController::systemAdminMenuBlockPage
_title: Product bundle settings
requirements:
_permission: administer apigee monetization
options:
_apigee_monetization_route: TRUE
apigee_m10n.settings.prepaid_balance:
path: /admin/config/apigee-monetization/prepaid-balance
defaults:
_form: \Drupal\apigee_m10n\Form\PrepaidBalanceConfigForm
_title: Prepaid balance
requirements:
_permission: administer apigee monetization
options:
_apigee_monetization_route: TRUE
apigee_m10n.settings.purchased_plan:
path: /admin/config/apigee-monetization/purchased-plan-settings
defaults:
_controller: \Drupal\system\Controller\SystemController::systemAdminMenuBlockPage
_title: Rate plan purchase settings
requirements:
_permission: administer apigee monetization
options:
_apigee_monetization_route: TRUE
entity.product_bundle.collection:
path: /admin/config/apigee-monetization/product-bundle/list
defaults:
_entity_list: product_bundle
_title: Product bundles
requirements:
_permission: administer apigee monetization
options:
_apigee_monetization_route: TRUE
apigee_monetization.my_billing:
path: /monetization/billing
defaults:
_controller: \Drupal\apigee_m10n\Controller\PrepaidBalanceController::myRedirect
requirements:
_permission: view own prepaid balance
options:
_apigee_monetization_route: TRUE
apigee_monetization.billing:
path: /user/{user}/monetization/billing
defaults:
_controller: \Drupal\apigee_m10n\Controller\PrepaidBalanceController::prepaidBalancePage
_title: Prepaid balance
requirements:
user: '^[1-9]+[0-9]*$'
_custom_access: \Drupal\apigee_m10n\Controller\PrepaidBalanceController::access
options:
_apigee_monetization_route: TRUE
apigee_monetization.my_plans:
path: /plans
defaults:
_controller: \Drupal\apigee_m10n\Controller\PricingAndPlansController::myPlans
requirements:
_permission: view rate_plan
options:
_apigee_monetization_route: TRUE
apigee_monetization.plans:
path: /user/{user}/plans
defaults:
_controller: \Drupal\apigee_m10n\Controller\PricingAndPlansController::catalogPage
_title: "Pricing and Plans"
requirements:
_custom_access: \Drupal\apigee_m10n\Controller\PricingAndPlansController::access
options:
_apigee_monetization_route: TRUE
apigee_monetization.profile:
path: /user/{user}/monetization/billing-details
defaults:
_form: \Drupal\apigee_m10n\Form\BillingDetailsForm
_title: Billing Details
requirements:
user: '^[1-9]+[0-9]*$'
_custom_access: \Drupal\apigee_m10n\Form\BillingDetailsForm::access
options:
_apigee_monetization_route: TRUE
apigee_monetization.reports:
path: /user/{user}/monetization/reports
defaults:
_form: \Drupal\apigee_m10n\Form\ReportsDownloadForm
_title: Download Reports
requirements:
user: '^[1-9]+[0-9]*$'
_custom_access: \Drupal\apigee_m10n\Form\ReportsDownloadForm::access
options:
_apigee_monetization_route: TRUE
entity.purchased_plan.developer_collection:
path: /user/{user}/monetization/purchased-plans
defaults:
_controller: \Drupal\apigee_m10n\Entity\ListBuilder\PurchasedPlanListBuilderForDeveloper::render
_title_callback: \Drupal\apigee_m10n\Entity\ListBuilder\PurchasedPlanListBuilderForDeveloper::getPageTitle
requirements:
user: '^[1-9]+[0-9]*$'
_custom_access: \Drupal\apigee_m10n\Entity\ListBuilder\PurchasedPlanListBuilderForDeveloper::access
options:
_apigee_monetization_route: TRUE
entity.rate_plan.canonical:
path: /user/{user}/monetization/product-bundle/{product_bundle}/plan/{rate_plan}
defaults:
_entity_view: rate_plan.full
_title_callback: \Drupal\Core\Entity\Controller\EntityController::title
requirements:
user: '^[1-9]+[0-9]*$'
_entity_developer_access: rate_plan.view
options:
_apigee_monetization_route: TRUE
parameters:
user:
type: entity:user
rate_plan:
type: entity:rate_plan
converter: paramconverter.entity.rate_plan
entity.rate_plan.purchase:
path: /user/{user}/monetization/product-bundle/{product_bundle}/plan/{rate_plan}/purchase
defaults:
_controller: \Drupal\apigee_m10n\Entity\Controller\PurchaseRatePlanController::purchaseForm
_title_callback: \Drupal\apigee_m10n\Entity\Controller\PurchaseRatePlanController::title
requirements:
user: '^[1-9]+[0-9]*$'
_entity_developer_access: rate_plan.purchase
options:
_apigee_monetization_route: TRUE
entity.purchased_plan.developer_cancel_form:
path: /user/{user}/monetization/purchased-plan/{purchased_plan}/cancel
defaults:
_entity_form: purchased_plan.cancel
_title_callback: \Drupal\Core\Entity\Controller\EntityController::title
requirements:
user: '^[1-9]+[0-9]*$'
_entity_access: purchased_plan.update
options:
_apigee_monetization_route: TRUE
parameters:
user:
type: entity:user
purchased_plan:
type: entity:purchased_plan
converter: paramconverter.entity.purchased_plan