@@ -59,31 +59,31 @@ discard block |
||
59 | 59 | public function register(Container $app) |
60 | 60 | { |
61 | 61 | // Service |
62 | - $app['eccube.service.system'] = function () use ($app) { |
|
62 | + $app['eccube.service.system'] = function() use ($app) { |
|
63 | 63 | return new \Eccube\Service\SystemService($app); |
64 | 64 | }; |
65 | - $app['view'] = function () use ($app) { |
|
65 | + $app['view'] = function() use ($app) { |
|
66 | 66 | return $app['twig']; |
67 | 67 | }; |
68 | - $app['eccube.service.cart'] = function () use ($app) { |
|
68 | + $app['eccube.service.cart'] = function() use ($app) { |
|
69 | 69 | return new \Eccube\Service\CartService($app['session'], $app['orm.em']); |
70 | 70 | }; |
71 | - $app['eccube.service.order'] = function () use ($app) { |
|
71 | + $app['eccube.service.order'] = function() use ($app) { |
|
72 | 72 | return new \Eccube\Service\OrderService($app); |
73 | 73 | }; |
74 | - $app['eccube.service.tax_rule'] = function () use ($app) { |
|
74 | + $app['eccube.service.tax_rule'] = function() use ($app) { |
|
75 | 75 | return new \Eccube\Service\TaxRuleService($app['eccube.repository.tax_rule']); |
76 | 76 | }; |
77 | - $app['eccube.service.plugin'] = function () use ($app) { |
|
77 | + $app['eccube.service.plugin'] = function() use ($app) { |
|
78 | 78 | return new \Eccube\Service\PluginService($app); |
79 | 79 | }; |
80 | - $app['eccube.service.mail'] = function () use ($app) { |
|
80 | + $app['eccube.service.mail'] = function() use ($app) { |
|
81 | 81 | return new \Eccube\Service\MailService($app); |
82 | 82 | }; |
83 | - $app['eccube.calculate.context'] = function () use ($app) { |
|
83 | + $app['eccube.calculate.context'] = function() use ($app) { |
|
84 | 84 | return new \Eccube\Service\Calculator\CalculateContext(); |
85 | 85 | }; |
86 | - $app['eccube.service.calculate'] = $app->protect(function ($Order, $Customer) use ($app) { |
|
86 | + $app['eccube.service.calculate'] = $app->protect(function($Order, $Customer) use ($app) { |
|
87 | 87 | $Service = new \Eccube\Service\CalculateService($Order, $Customer); |
88 | 88 | $Context = $app['eccube.calculate.context']; |
89 | 89 | $app['eccube.calculate.strategies']->setOrder($Order); |
@@ -93,13 +93,13 @@ discard block |
||
93 | 93 | return $Service; |
94 | 94 | }); |
95 | 95 | |
96 | - $app['eccube.service.payment'] = $app->protect(function ($clazz) use ($app) { |
|
96 | + $app['eccube.service.payment'] = $app->protect(function($clazz) use ($app) { |
|
97 | 97 | $Service = new $clazz; |
98 | 98 | $Service->setApplication($app); |
99 | 99 | return $Service; |
100 | 100 | }); |
101 | 101 | |
102 | - $app['eccube.calculate.strategies'] = function () use ($app) { |
|
102 | + $app['eccube.calculate.strategies'] = function() use ($app) { |
|
103 | 103 | $Collection = new \Eccube\Service\Calculator\CalculateStrategyCollection(); |
104 | 104 | $Collection->setApplication($app); |
105 | 105 | //$Collection->setOrder($Order); |
@@ -112,47 +112,47 @@ discard block |
||
112 | 112 | $Collection->add($app['eccube.calculate.strategy.calculate_total']); |
113 | 113 | return $Collection; |
114 | 114 | }; |
115 | - $app['eccube.calculate.strategy.shipping'] = function () use ($app) { |
|
115 | + $app['eccube.calculate.strategy.shipping'] = function() use ($app) { |
|
116 | 116 | $Strategy = new \Eccube\Service\Calculator\Strategy\ShippingStrategy(); |
117 | 117 | $Strategy->setApplication($app); |
118 | 118 | return $Strategy; |
119 | 119 | }; |
120 | - $app['eccube.calculate.strategy.charge'] = function () use ($app) { |
|
120 | + $app['eccube.calculate.strategy.charge'] = function() use ($app) { |
|
121 | 121 | $Strategy = new \Eccube\Service\Calculator\Strategy\ChargeStrategy(); |
122 | 122 | $Strategy->setApplication($app); |
123 | 123 | return $Strategy; |
124 | 124 | }; |
125 | 125 | |
126 | - $app['eccube.calculate.strategy.tax'] = function () use ($app) { |
|
126 | + $app['eccube.calculate.strategy.tax'] = function() use ($app) { |
|
127 | 127 | $Strategy = new \Eccube\Service\Calculator\Strategy\TaxStrategy(); |
128 | 128 | $Strategy->setApplication($app); |
129 | 129 | return $Strategy; |
130 | 130 | }; |
131 | 131 | |
132 | - $app['eccube.calculate.strategy.calculate_delivery_fee'] = function () use ($app) { |
|
132 | + $app['eccube.calculate.strategy.calculate_delivery_fee'] = function() use ($app) { |
|
133 | 133 | $Strategy = new \Eccube\Service\Calculator\Strategy\CalculateDeliveryFeeStrategy(); |
134 | 134 | $Strategy->setApplication($app); |
135 | 135 | return $Strategy; |
136 | 136 | }; |
137 | - $app['eccube.calculate.strategy.calculate_charge'] = function () use ($app) { |
|
137 | + $app['eccube.calculate.strategy.calculate_charge'] = function() use ($app) { |
|
138 | 138 | $Strategy = new \Eccube\Service\Calculator\Strategy\CalculateChargeStrategy(); |
139 | 139 | $Strategy->setApplication($app); |
140 | 140 | return $Strategy; |
141 | 141 | }; |
142 | - $app['eccube.calculate.strategy.calculate_total'] = function () use ($app) { |
|
142 | + $app['eccube.calculate.strategy.calculate_total'] = function() use ($app) { |
|
143 | 143 | $Strategy = new \Eccube\Service\Calculator\Strategy\CalculateTotalStrategy(); |
144 | 144 | $Strategy->setApplication($app); |
145 | 145 | return $Strategy; |
146 | 146 | }; |
147 | 147 | |
148 | - $app['payment.method'] = $app->protect(function ($clazz, $form) use ($app) { |
|
148 | + $app['payment.method'] = $app->protect(function($clazz, $form) use ($app) { |
|
149 | 149 | $PaymentMethod = new $clazz; |
150 | 150 | $PaymentMethod->setApplication($app); |
151 | 151 | $PaymentMethod->setFormType($form); |
152 | 152 | return $PaymentMethod; |
153 | 153 | }); |
154 | 154 | |
155 | - $app['payment.method.request'] = $app->protect(function ($clazz, $form, $request) use ($app) { |
|
155 | + $app['payment.method.request'] = $app->protect(function($clazz, $form, $request) use ($app) { |
|
156 | 156 | $PaymentMethod = new $clazz; |
157 | 157 | $PaymentMethod->setApplication($app); |
158 | 158 | $PaymentMethod->setFormType($form); |
@@ -160,11 +160,11 @@ discard block |
||
160 | 160 | return $PaymentMethod; |
161 | 161 | }); |
162 | 162 | |
163 | - $app['eccube.helper.order'] = function ($app) { |
|
163 | + $app['eccube.helper.order'] = function($app) { |
|
164 | 164 | return new OrderHelper($app); |
165 | 165 | }; |
166 | 166 | |
167 | - $app['eccube.service.csv.export'] = function () use ($app) { |
|
167 | + $app['eccube.service.csv.export'] = function() use ($app) { |
|
168 | 168 | $csvService = new \Eccube\Service\CsvExportService(); |
169 | 169 | $csvService->setEntityManager($app['orm.em']); |
170 | 170 | $csvService->setConfig($app['config']); |
@@ -176,206 +176,206 @@ discard block |
||
176 | 176 | |
177 | 177 | return $csvService; |
178 | 178 | }; |
179 | - $app['eccube.service.shopping'] = function () use ($app) { |
|
179 | + $app['eccube.service.shopping'] = function() use ($app) { |
|
180 | 180 | return new \Eccube\Service\ShoppingService($app, $app['eccube.service.cart'], $app['eccube.service.order']); |
181 | 181 | }; |
182 | 182 | |
183 | 183 | // Repository |
184 | - $app['eccube.repository.master.authority'] = function () use ($app) { |
|
184 | + $app['eccube.repository.master.authority'] = function() use ($app) { |
|
185 | 185 | return $app['orm.em']->getRepository('Eccube\Entity\Master\Authority'); |
186 | 186 | }; |
187 | - $app['eccube.repository.master.tag'] = function () use ($app) { |
|
187 | + $app['eccube.repository.master.tag'] = function() use ($app) { |
|
188 | 188 | return $app['orm.em']->getRepository('Eccube\Entity\Master\Tag'); |
189 | 189 | }; |
190 | - $app['eccube.repository.master.pref'] = function () use ($app) { |
|
190 | + $app['eccube.repository.master.pref'] = function() use ($app) { |
|
191 | 191 | return $app['orm.em']->getRepository('Eccube\Entity\Master\Pref'); |
192 | 192 | }; |
193 | - $app['eccube.repository.master.sex'] = function () use ($app) { |
|
193 | + $app['eccube.repository.master.sex'] = function() use ($app) { |
|
194 | 194 | return $app['orm.em']->getRepository('Eccube\Entity\Master\Sex'); |
195 | 195 | }; |
196 | - $app['eccube.repository.master.disp'] = function () use ($app) { |
|
196 | + $app['eccube.repository.master.disp'] = function() use ($app) { |
|
197 | 197 | return $app['orm.em']->getRepository('Eccube\Entity\Master\Disp'); |
198 | 198 | }; |
199 | - $app['eccube.repository.master.product_type'] = function () use ($app) { |
|
199 | + $app['eccube.repository.master.product_type'] = function() use ($app) { |
|
200 | 200 | return $app['orm.em']->getRepository('Eccube\Entity\Master\ProductType'); |
201 | 201 | }; |
202 | - $app['eccube.repository.master.page_max'] = function () use ($app) { |
|
202 | + $app['eccube.repository.master.page_max'] = function() use ($app) { |
|
203 | 203 | return $app['orm.em']->getRepository('Eccube\Entity\Master\PageMax'); |
204 | 204 | }; |
205 | - $app['eccube.repository.master.order_status'] = function () use ($app) { |
|
205 | + $app['eccube.repository.master.order_status'] = function() use ($app) { |
|
206 | 206 | }; |
207 | - $app['eccube.repository.master.product_list_max'] = function () use ($app) { |
|
207 | + $app['eccube.repository.master.product_list_max'] = function() use ($app) { |
|
208 | 208 | return $app['orm.em']->getRepository('Eccube\Entity\Master\ProductListMax'); |
209 | 209 | }; |
210 | - $app['eccube.repository.master.product_list_order_by'] = function () use ($app) { |
|
210 | + $app['eccube.repository.master.product_list_order_by'] = function() use ($app) { |
|
211 | 211 | return $app['orm.em']->getRepository('Eccube\Entity\Master\ProductListOrderBy'); |
212 | 212 | }; |
213 | - $app['eccube.repository.master.order_status'] = function () use ($app) { |
|
213 | + $app['eccube.repository.master.order_status'] = function() use ($app) { |
|
214 | 214 | return $app['orm.em']->getRepository('Eccube\Entity\Master\OrderStatus'); |
215 | 215 | }; |
216 | - $app['eccube.repository.master.device_type'] = function () use ($app) { |
|
216 | + $app['eccube.repository.master.device_type'] = function() use ($app) { |
|
217 | 217 | return $app['orm.em']->getRepository('Eccube\Entity\Master\DeviceType'); |
218 | 218 | }; |
219 | - $app['eccube.repository.master.csv_type'] = function () use ($app) { |
|
219 | + $app['eccube.repository.master.csv_type'] = function() use ($app) { |
|
220 | 220 | return $app['orm.em']->getRepository('Eccube\Entity\Master\CsvType'); |
221 | 221 | }; |
222 | - $app['eccube.repository.master.order_item_type'] = function () use ($app) { |
|
222 | + $app['eccube.repository.master.order_item_type'] = function() use ($app) { |
|
223 | 223 | return $app['orm.em']->getRepository('Eccube\Entity\Master\OrderItemType'); |
224 | 224 | }; |
225 | 225 | |
226 | - $app['eccube.repository.delivery'] = function () use ($app) { |
|
226 | + $app['eccube.repository.delivery'] = function() use ($app) { |
|
227 | 227 | return $app['orm.em']->getRepository('Eccube\Entity\Delivery'); |
228 | 228 | }; |
229 | - $app['eccube.repository.delivery_date'] = function () use ($app) { |
|
229 | + $app['eccube.repository.delivery_date'] = function() use ($app) { |
|
230 | 230 | return $app['orm.em']->getRepository('Eccube\Entity\DeliveryDate'); |
231 | 231 | }; |
232 | - $app['eccube.repository.delivery_fee'] = function () use ($app) { |
|
232 | + $app['eccube.repository.delivery_fee'] = function() use ($app) { |
|
233 | 233 | return $app['orm.em']->getRepository('Eccube\Entity\DeliveryFee'); |
234 | 234 | }; |
235 | - $app['eccube.repository.delivery_time'] = function () use ($app) { |
|
235 | + $app['eccube.repository.delivery_time'] = function() use ($app) { |
|
236 | 236 | return $app['orm.em']->getRepository('Eccube\Entity\DeliveryTime'); |
237 | 237 | }; |
238 | - $app['eccube.repository.payment'] = function () use ($app) { |
|
238 | + $app['eccube.repository.payment'] = function() use ($app) { |
|
239 | 239 | return $app['orm.em']->getRepository('Eccube\Entity\Payment'); |
240 | 240 | }; |
241 | - $app['eccube.repository.payment_option'] = function () use ($app) { |
|
241 | + $app['eccube.repository.payment_option'] = function() use ($app) { |
|
242 | 242 | return $app['orm.em']->getRepository('Eccube\Entity\PaymentOption'); |
243 | 243 | }; |
244 | - $app['eccube.repository.category'] = function () use ($app) { |
|
244 | + $app['eccube.repository.category'] = function() use ($app) { |
|
245 | 245 | $CategoryRepository = $app['orm.em']->getRepository('Eccube\Entity\Category'); |
246 | 246 | $CategoryRepository->setApplication($app); |
247 | 247 | |
248 | 248 | return $CategoryRepository; |
249 | 249 | }; |
250 | - $app['eccube.repository.customer'] = function () use ($app) { |
|
250 | + $app['eccube.repository.customer'] = function() use ($app) { |
|
251 | 251 | $customerRepository = $app['orm.em']->getRepository('Eccube\Entity\Customer'); |
252 | 252 | $customerRepository->setApplication($app); |
253 | 253 | return $customerRepository; |
254 | 254 | }; |
255 | - $app['eccube.repository.news'] = function () use ($app) { |
|
255 | + $app['eccube.repository.news'] = function() use ($app) { |
|
256 | 256 | return $app['orm.em']->getRepository('Eccube\Entity\News'); |
257 | 257 | }; |
258 | - $app['eccube.repository.mail_history'] = function () use ($app) { |
|
258 | + $app['eccube.repository.mail_history'] = function() use ($app) { |
|
259 | 259 | return $app['orm.em']->getRepository('Eccube\Entity\MailHistory'); |
260 | 260 | }; |
261 | - $app['eccube.repository.member'] = function () use ($app) { |
|
261 | + $app['eccube.repository.member'] = function() use ($app) { |
|
262 | 262 | $memberRepository = $app['orm.em']->getRepository('Eccube\Entity\Member'); |
263 | 263 | $memberRepository->setEncoderFactorty($app['security.encoder_factory']); |
264 | 264 | return $memberRepository; |
265 | 265 | }; |
266 | - $app['eccube.repository.order'] = function () use ($app) { |
|
266 | + $app['eccube.repository.order'] = function() use ($app) { |
|
267 | 267 | return $app['orm.em']->getRepository('Eccube\Entity\Order'); |
268 | 268 | }; |
269 | - $app['eccube.repository.product'] = function () use ($app) { |
|
269 | + $app['eccube.repository.product'] = function() use ($app) { |
|
270 | 270 | $productRepository = $app['orm.em']->getRepository('Eccube\Entity\Product'); |
271 | 271 | $productRepository->setApplication($app); |
272 | 272 | |
273 | 273 | return $productRepository; |
274 | 274 | }; |
275 | - $app['eccube.repository.product_image'] = function () use ($app) { |
|
275 | + $app['eccube.repository.product_image'] = function() use ($app) { |
|
276 | 276 | return $app['orm.em']->getRepository('Eccube\Entity\ProductImage'); |
277 | 277 | }; |
278 | - $app['eccube.repository.product_class'] = function () use ($app) { |
|
278 | + $app['eccube.repository.product_class'] = function() use ($app) { |
|
279 | 279 | return $app['orm.em']->getRepository('Eccube\Entity\ProductClass'); |
280 | 280 | }; |
281 | - $app['eccube.repository.product_stock'] = function () use ($app) { |
|
281 | + $app['eccube.repository.product_stock'] = function() use ($app) { |
|
282 | 282 | return $app['orm.em']->getRepository('Eccube\Entity\ProductStock'); |
283 | 283 | }; |
284 | - $app['eccube.repository.product_tag'] = function () use ($app) { |
|
284 | + $app['eccube.repository.product_tag'] = function() use ($app) { |
|
285 | 285 | return $app['orm.em']->getRepository('Eccube\Entity\ProductTag'); |
286 | 286 | }; |
287 | - $app['eccube.repository.class_name'] = function () use ($app) { |
|
287 | + $app['eccube.repository.class_name'] = function() use ($app) { |
|
288 | 288 | return $app['orm.em']->getRepository('Eccube\Entity\ClassName'); |
289 | 289 | }; |
290 | - $app['eccube.repository.class_category'] = function () use ($app) { |
|
290 | + $app['eccube.repository.class_category'] = function() use ($app) { |
|
291 | 291 | return $app['orm.em']->getRepository('Eccube\Entity\ClassCategory'); |
292 | 292 | }; |
293 | - $app['eccube.repository.customer_favorite_product'] = function () use ($app) { |
|
293 | + $app['eccube.repository.customer_favorite_product'] = function() use ($app) { |
|
294 | 294 | return $app['orm.em']->getRepository('Eccube\Entity\CustomerFavoriteProduct'); |
295 | 295 | }; |
296 | - $app['eccube.repository.base_info'] = function () use ($app) { |
|
296 | + $app['eccube.repository.base_info'] = function() use ($app) { |
|
297 | 297 | $BaseInfoRepository = $app['orm.em']->getRepository('Eccube\Entity\BaseInfo'); |
298 | 298 | $BaseInfoRepository->setApplication($app); |
299 | 299 | |
300 | 300 | return $BaseInfoRepository; |
301 | 301 | }; |
302 | - $app['eccube.repository.tax_rule'] = function () use ($app) { |
|
302 | + $app['eccube.repository.tax_rule'] = function() use ($app) { |
|
303 | 303 | $taxRuleRepository = $app['orm.em']->getRepository('Eccube\Entity\TaxRule'); |
304 | 304 | $taxRuleRepository->setApplication($app); |
305 | 305 | |
306 | 306 | return $taxRuleRepository; |
307 | 307 | }; |
308 | - $app['eccube.repository.page_layout'] = function () use ($app) { |
|
308 | + $app['eccube.repository.page_layout'] = function() use ($app) { |
|
309 | 309 | $pageLayoutRepository = $app['orm.em']->getRepository('Eccube\Entity\PageLayout'); |
310 | 310 | $pageLayoutRepository->setApplication($app); |
311 | 311 | |
312 | 312 | return $pageLayoutRepository; |
313 | 313 | }; |
314 | - $app['eccube.repository.block'] = function () use ($app) { |
|
314 | + $app['eccube.repository.block'] = function() use ($app) { |
|
315 | 315 | $blockRepository = $app['orm.em']->getRepository('Eccube\Entity\Block'); |
316 | 316 | $blockRepository->setApplication($app); |
317 | 317 | |
318 | 318 | return $blockRepository; |
319 | 319 | }; |
320 | - $app['eccube.repository.order'] = function () use ($app) { |
|
320 | + $app['eccube.repository.order'] = function() use ($app) { |
|
321 | 321 | $orderRepository = $app['orm.em']->getRepository('Eccube\Entity\Order'); |
322 | 322 | $orderRepository->setApplication($app); |
323 | 323 | |
324 | 324 | return $orderRepository; |
325 | 325 | }; |
326 | - $app['eccube.repository.customer_address'] = function () use ($app) { |
|
326 | + $app['eccube.repository.customer_address'] = function() use ($app) { |
|
327 | 327 | return $app['orm.em']->getRepository('Eccube\Entity\CustomerAddress'); |
328 | 328 | }; |
329 | - $app['eccube.repository.shipping'] = function () use ($app) { |
|
329 | + $app['eccube.repository.shipping'] = function() use ($app) { |
|
330 | 330 | return $app['orm.em']->getRepository('Eccube\Entity\Shipping'); |
331 | 331 | }; |
332 | - $app['eccube.repository.shipment_item'] = function () use ($app) { |
|
332 | + $app['eccube.repository.shipment_item'] = function() use ($app) { |
|
333 | 333 | return $app['orm.em']->getRepository('Eccube\Entity\ShipmentItem'); |
334 | 334 | }; |
335 | - $app['eccube.repository.customer_status'] = function () use ($app) { |
|
335 | + $app['eccube.repository.customer_status'] = function() use ($app) { |
|
336 | 336 | return $app['orm.em']->getRepository('Eccube\Entity\Master\CustomerStatus'); |
337 | 337 | }; |
338 | - $app['eccube.repository.order_status'] = function () use ($app) { |
|
338 | + $app['eccube.repository.order_status'] = function() use ($app) { |
|
339 | 339 | return $app['orm.em']->getRepository('Eccube\Entity\Master\OrderStatus'); |
340 | 340 | }; |
341 | - $app['eccube.repository.mail_template'] = function () use ($app) { |
|
341 | + $app['eccube.repository.mail_template'] = function() use ($app) { |
|
342 | 342 | return $app['orm.em']->getRepository('Eccube\Entity\MailTemplate'); |
343 | 343 | }; |
344 | - $app['eccube.repository.csv'] = function () use ($app) { |
|
344 | + $app['eccube.repository.csv'] = function() use ($app) { |
|
345 | 345 | return $app['orm.em']->getRepository('Eccube\Entity\Csv'); |
346 | 346 | }; |
347 | - $app['eccube.repository.template'] = function () use ($app) { |
|
347 | + $app['eccube.repository.template'] = function() use ($app) { |
|
348 | 348 | return $app['orm.em']->getRepository('Eccube\Entity\Template'); |
349 | 349 | }; |
350 | - $app['eccube.repository.authority_role'] = function () use ($app) { |
|
350 | + $app['eccube.repository.authority_role'] = function() use ($app) { |
|
351 | 351 | return $app['orm.em']->getRepository('Eccube\Entity\AuthorityRole'); |
352 | 352 | }; |
353 | 353 | |
354 | - $app['paginator'] = $app->protect(function () { |
|
354 | + $app['paginator'] = $app->protect(function() { |
|
355 | 355 | $paginator = new \Knp\Component\Pager\Paginator(); |
356 | 356 | $paginator->subscribe(new \Eccube\EventListener\PaginatorListener()); |
357 | 357 | |
358 | 358 | return $paginator; |
359 | 359 | }); |
360 | 360 | |
361 | - $app['eccube.repository.help'] = function () use ($app) { |
|
361 | + $app['eccube.repository.help'] = function() use ($app) { |
|
362 | 362 | return $app['orm.em']->getRepository('Eccube\Entity\Help'); |
363 | 363 | }; |
364 | - $app['eccube.repository.plugin'] = function () use ($app) { |
|
364 | + $app['eccube.repository.plugin'] = function() use ($app) { |
|
365 | 365 | return $app['orm.em']->getRepository('Eccube\Entity\Plugin'); |
366 | 366 | }; |
367 | - $app['eccube.repository.plugin_event_handler'] = function () use ($app) { |
|
367 | + $app['eccube.repository.plugin_event_handler'] = function() use ($app) { |
|
368 | 368 | return $app['orm.em']->getRepository('Eccube\Entity\PluginEventHandler'); |
369 | 369 | }; |
370 | - $app['eccube.repository.layout'] = function () use ($app) { |
|
370 | + $app['eccube.repository.layout'] = function() use ($app) { |
|
371 | 371 | return $app['orm.em']->getRepository('Eccube\Entity\Layout'); |
372 | 372 | }; |
373 | 373 | |
374 | - $app['request_scope'] = function () { |
|
374 | + $app['request_scope'] = function() { |
|
375 | 375 | return new ParameterBag(); |
376 | 376 | }; |
377 | 377 | // TODO 使用するか検討 |
378 | - $app['eccube.twig.node.hello'] = $app->protect(function ($node, $compiler) { |
|
378 | + $app['eccube.twig.node.hello'] = $app->protect(function($node, $compiler) { |
|
379 | 379 | $compiler |
380 | 380 | ->addDebugInfo($node) |
381 | 381 | ->write("echo 'Helloooooo ' . ") |
@@ -385,7 +385,7 @@ discard block |
||
385 | 385 | |
386 | 386 | }); |
387 | 387 | // TODO 使用するか検討 |
388 | - $app['eccube.twig.node.jiro'] = $app->protect(function ($node, $compiler) { |
|
388 | + $app['eccube.twig.node.jiro'] = $app->protect(function($node, $compiler) { |
|
389 | 389 | $compiler |
390 | 390 | ->addDebugInfo($node) |
391 | 391 | ->write("echo 'jirooooooo ' . ") |
@@ -396,7 +396,7 @@ discard block |
||
396 | 396 | }); |
397 | 397 | |
398 | 398 | // TODO 使用するか検討 |
399 | - $app['eccube.twig.generic_node_names'] = function () use ($app) { |
|
399 | + $app['eccube.twig.generic_node_names'] = function() use ($app) { |
|
400 | 400 | return [ |
401 | 401 | 'hello', |
402 | 402 | 'jiro', |
@@ -405,7 +405,7 @@ discard block |
||
405 | 405 | }; |
406 | 406 | |
407 | 407 | // TODO 使用するか検討 |
408 | - $app['twig_parsers'] = function () use ($app) { |
|
408 | + $app['twig_parsers'] = function() use ($app) { |
|
409 | 409 | $GenericTokenParsers = []; |
410 | 410 | foreach ($app['eccube.twig.generic_node_names'] as $tagName) { |
411 | 411 | $GenericTokenParsers[] = new \Eccube\Twig\Extension\GenericTokenParser($app, $tagName); |
@@ -413,7 +413,7 @@ discard block |
||
413 | 413 | return $GenericTokenParsers; |
414 | 414 | }; |
415 | 415 | |
416 | - $app['eccube.twig.block.templates'] = function () { |
|
416 | + $app['eccube.twig.block.templates'] = function() { |
|
417 | 417 | $templates = new ArrayCollection(); |
418 | 418 | $templates[] = 'render_block.twig'; |
419 | 419 | |
@@ -421,13 +421,13 @@ discard block |
||
421 | 421 | }; |
422 | 422 | |
423 | 423 | // Form\Type |
424 | - $app->extend('form.type.extensions', function ($extensions) use ($app) { |
|
424 | + $app->extend('form.type.extensions', function($extensions) use ($app) { |
|
425 | 425 | $extensions[] = new \Eccube\Form\Extension\HelpTypeExtension(); |
426 | 426 | $extensions[] = new \Eccube\Form\Extension\FreezeTypeExtension(); |
427 | 427 | $extensions[] = new \Eccube\Form\Extension\DoctrineOrmExtension($app['orm.em']); |
428 | 428 | return $extensions; |
429 | 429 | }); |
430 | - $app->extend('form.types', function ($types) use ($app) { |
|
430 | + $app->extend('form.types', function($types) use ($app) { |
|
431 | 431 | $types[] = new \Eccube\Form\Type\NameType($app['config']); |
432 | 432 | $types[] = new \Eccube\Form\Type\KanaType($app['config']); |
433 | 433 | $types[] = new \Eccube\Form\Type\TelType($app['config']); |
@@ -531,13 +531,13 @@ discard block |
||
531 | 531 | return $types; |
532 | 532 | }); |
533 | 533 | $app['eccube.entity.event.dispatcher']->addEventListener(new \Acme\Entity\SoldOutEventListener()); |
534 | - $app['eccube.queries'] = function () { |
|
534 | + $app['eccube.queries'] = function() { |
|
535 | 535 | return new \Eccube\Doctrine\Query\Queries(); |
536 | 536 | }; |
537 | 537 | // TODO QueryCustomizerの追加方法は要検討 |
538 | 538 | $app['eccube.queries']->addCustomizer(new \Acme\Entity\AdminProductListCustomizer()); |
539 | 539 | |
540 | - $app['eccube.purchase.flow.cart.item_processors'] = function ($app) { |
|
540 | + $app['eccube.purchase.flow.cart.item_processors'] = function($app) { |
|
541 | 541 | $processors = new ArrayCollection(); |
542 | 542 | $processors->add(new DeletedProductValidator()); |
543 | 543 | $processors->add(new DisplayStatusValidator()); |
@@ -547,7 +547,7 @@ discard block |
||
547 | 547 | return $processors; |
548 | 548 | }; |
549 | 549 | |
550 | - $app['eccube.purchase.flow.cart.holder_processors'] = function ($app) { |
|
550 | + $app['eccube.purchase.flow.cart.holder_processors'] = function($app) { |
|
551 | 551 | $processors = new ArrayCollection(); |
552 | 552 | $processors->add(new PaymentProcessor($app)); |
553 | 553 | $processors->add(new PaymentTotalLimitValidator($app['config']['max_total_fee'])); |
@@ -558,14 +558,14 @@ discard block |
||
558 | 558 | }; |
559 | 559 | |
560 | 560 | // example |
561 | - $app->extend('eccube.purchase.flow.cart.item_processors', function ($processors, $app) { |
|
561 | + $app->extend('eccube.purchase.flow.cart.item_processors', function($processors, $app) { |
|
562 | 562 | |
563 | 563 | $processors->add(new StockValidator()); |
564 | 564 | |
565 | 565 | return $processors; |
566 | 566 | }); |
567 | 567 | |
568 | - $app['eccube.purchase.flow.cart'] = function ($app) { |
|
568 | + $app['eccube.purchase.flow.cart'] = function($app) { |
|
569 | 569 | $flow = new PurchaseFlow(); |
570 | 570 | $flow->setItemProcessors($app['eccube.purchase.flow.cart.item_processors']); |
571 | 571 | $flow->setItemHolderProcessors($app['eccube.purchase.flow.cart.holder_processors']); |
@@ -573,7 +573,7 @@ discard block |
||
573 | 573 | return $flow; |
574 | 574 | }; |
575 | 575 | |
576 | - $app['eccube.purchase.flow.shopping'] = function () use ($app) { |
|
576 | + $app['eccube.purchase.flow.shopping'] = function() use ($app) { |
|
577 | 577 | $flow = new PurchaseFlow(); |
578 | 578 | $flow->addItemProcessor(new StockValidator()); |
579 | 579 | $flow->addItemProcessor(new DisplayStatusValidator()); |
@@ -583,7 +583,7 @@ discard block |
||
583 | 583 | return $flow; |
584 | 584 | }; |
585 | 585 | |
586 | - $app['eccube.purchase.flow.order'] = function () use ($app) { |
|
586 | + $app['eccube.purchase.flow.order'] = function() use ($app) { |
|
587 | 587 | $flow = new PurchaseFlow(); |
588 | 588 | $flow->addItemProcessor(new StockValidator()); |
589 | 589 | $flow->addItemHolderProcessor(new PaymentTotalLimitValidator($app['config']['max_total_fee'])); |