-
Notifications
You must be signed in to change notification settings - Fork 13
/
apigee_m10n.routing.yml
executable file
·317 lines (290 loc) · 10.4 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
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
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
# This route is required for field UI routes to be attached to.
apigee_m10n.settings.rate_plan_x:
path: /admin/config/apigee-monetization/rate-plan-x
defaults:
_form: \Drupal\apigee_m10n\Form\RatePlanXConfigForm
_title: Rate Plans X
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.xproduct:
path: /admin/config/apigee-monetization/xproduct
defaults:
_controller: \Drupal\system\Controller\SystemController::systemAdminMenuBlockPage
_title: Product X 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.entity_view_display.purchased_plan.default:
path: admin/config/apigee-monetization/purchased-plan-settings/display
defaults:
_title: Rate plan purchases
requirements:
_permission: administer apigee monetization
options:
_apigee_monetization_route: TRUE
apigee_m10n.settings.purchased_product:
path: /admin/config/apigee-monetization/purchased-product-settings
defaults:
_controller: \Drupal\system\Controller\SystemController::systemAdminMenuBlockPage
_title: ApigeeX product 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
entity.xproduct.collection:
path: /admin/config/apigee-monetization/xproduct/list
defaults:
_entity_list: xproduct
_title: Product X
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.xbilling:
path: /user/{user}/monetization/xbilling
defaults:
_controller: \Drupal\apigee_m10n\Controller\PrepaidBalanceXController::prepaidBalancePage
_title: Prepaid balance
requirements:
user: '^[1-9]+[0-9]*$'
_custom_access: \Drupal\apigee_m10n\Controller\PrepaidBalanceXController::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.xplans:
path: /user/{user}/xplans
defaults:
_controller: \Drupal\apigee_m10n\Controller\BuyApiController::xcatalogPage
_title: "Buy APIs"
requirements:
_custom_access: \Drupal\apigee_m10n\Controller\BuyApiController::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.xprofile:
path: /user/{user}/monetization/xbilling-details
defaults:
_controller: \Drupal\apigee_m10n\Controller\BillingTypeController::myBillingType
_title: Billing Details
requirements:
user: '^[1-9]+[0-9]*$'
_custom_access: \Drupal\apigee_m10n\Controller\BillingTypeController::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.purchased_product.developer_product_collection:
path: /user/{user}/monetization/purchased-product
defaults:
_controller: \Drupal\apigee_m10n\Entity\ListBuilder\PurchasedProductListBuilderForDeveloper::render
_title_callback: \Drupal\apigee_m10n\Entity\ListBuilder\PurchasedProductListBuilderForDeveloper::getPageTitle
requirements:
user: '^[1-9]+[0-9]*$'
_custom_access: \Drupal\apigee_m10n\Entity\ListBuilder\PurchasedProductListBuilderForDeveloper::access
options:
_apigee_monetization_route: TRUE
no_cache: '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.xrate_plan.canonical:
path: /user/{user}/monetization/xproduct/{xproduct}/plan/{xrate_plan}
defaults:
_entity_view: xrate_plan.full
_title_callback: \Drupal\Core\Entity\Controller\EntityController::title
requirements:
user: '^[1-9]+[0-9]*$'
_entity_developer_access: xrate_plan.view
options:
_apigee_monetization_route: TRUE
parameters:
user:
type: entity:user
xrate_plan:
type: entity:xrate_plan
converter: paramconverter.entity.xrate_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.xrate_plan.purchase:
path: /user/{user}/monetization/xproduct/{xproduct}/plan/{xrate_plan}/purchase
defaults:
_controller: \Drupal\apigee_m10n\Entity\Controller\PurchaseRatePlanXController::purchaseForm
_title_callback: \Drupal\apigee_m10n\Entity\Controller\PurchaseRatePlanXController::title
requirements:
user: '^[1-9]+[0-9]*$'
_entity_developer_access: xrate_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
entity.purchased_product.developer_cancel_form:
path: /user/{user}/monetization/purchased-product/{purchased_product}/cancel
defaults:
_entity_form: purchased_product.cancel
_title_callback: \Drupal\Core\Entity\Controller\EntityController::title
requirements:
user: '^[1-9]+[0-9]*$'
_entity_access: purchased_product.update
options:
_apigee_monetization_route: TRUE
parameters:
user:
type: entity:user
purchased_product:
type: entity:purchased_product
converter: paramconverter.entity.purchased_product