Completed
Pull Request — experimental/3.1 (#1985)
by Kentaro
132:51 queued 123:28
created
src/Eccube/Controller/Mypage/WithdrawController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@
 block discarded – undo
60 60
                     // 会員削除
61 61
                     $email = $Customer->getEmail();
62 62
                     // メールアドレスにダミーをセット
63
-                    $Customer->setEmail(Str::random(60) . '@dummy.dummy');
63
+                    $Customer->setEmail(Str::random(60).'@dummy.dummy');
64 64
                     $Customer->setDelFlg(Constant::ENABLED);
65 65
 
66 66
                     $app['orm.em']->flush();
Please login to merge, or discard this patch.
src/Eccube/Service/CsvExportService.php 3 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -307,7 +307,7 @@  discard block
 block discarded – undo
307 307
     {
308 308
         $config = $this->config;
309 309
 
310
-        return function ($value) use ($config) {
310
+        return function($value) use ($config) {
311 311
             return mb_convert_encoding(
312 312
                 (string) $value, $config['csv_export_encoding'], 'UTF-8'
313 313
             );
@@ -431,7 +431,7 @@  discard block
 block discarded – undo
431 431
             if ($Conditions instanceof ArrayCollection) {
432 432
                 $Conditions = new ArrayCollection(
433 433
                     array_map(
434
-                        function ($Entity) use ($em) {
434
+                        function($Entity) use ($em) {
435 435
                             return $em->getRepository(get_class($Entity))->find($Entity->getId());
436 436
                         }, $Conditions->toArray()
437 437
                     )
Please login to merge, or discard this patch.
Doc Comments   -2 removed lines patch added patch discarded remove patch
@@ -325,7 +325,6 @@  discard block
 block discarded – undo
325 325
 
326 326
     /**
327 327
      * @param $row
328
-     * @param null $callback
329 328
      */
330 329
     public function fputcsv($row)
331 330
     {
@@ -424,7 +423,6 @@  discard block
 block discarded – undo
424 423
      * XXX self::setExportQueryBuilder() をコールする前に EntityManager を取得したいので、引数で渡している
425 424
      *
426 425
      * @param array $searchData セッションから取得した検索条件の配列
427
-     * @param EntityManager $em
428 426
      */
429 427
     protected function findDeserializeObjects(array &$searchData)
430 428
     {
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,6 @@
 block discarded – undo
27 27
 use Doctrine\Common\Collections\ArrayCollection;
28 28
 use Eccube\Common\Constant;
29 29
 use Eccube\Util\EntityUtil;
30
-use Symfony\Component\Form\FormFactory;
31 30
 use Symfony\Component\HttpFoundation\Request;
32 31
 
33 32
 class CsvExportService
Please login to merge, or discard this patch.
src/Eccube/Controller/ProductController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@
 block discarded – undo
106 106
             ));
107 107
             $addCartForm = $builder->getForm();
108 108
 
109
-            if ($request->getMethod() === 'POST' && (string)$Product->getId() === $request->get('product_id')) {
109
+            if ($request->getMethod() === 'POST' && (string) $Product->getId() === $request->get('product_id')) {
110 110
                 $addCartForm->handleRequest($request);
111 111
 
112 112
                 if ($addCartForm->isValid()) {
Please login to merge, or discard this patch.
src/Eccube/Controller/Admin/Customer/CustomerEditController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
                         ->setCompanyName($Customer->getCompanyName())
89 89
                         ->setZip01($Customer->getZip01())
90 90
                         ->setZip02($Customer->getZip02())
91
-                        ->setZipcode($Customer->getZip01() . $Customer->getZip02())
91
+                        ->setZipcode($Customer->getZip01().$Customer->getZip02())
92 92
                         ->setPref($Customer->getPref())
93 93
                         ->setAddr01($Customer->getAddr01())
94 94
                         ->setAddr02($Customer->getAddr02())
Please login to merge, or discard this patch.
src/Eccube/Controller/Admin/Product/ProductClassController.php 3 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -138,7 +138,7 @@
 block discarded – undo
138 138
                                 'allow_add' => true,
139 139
                                 'allow_delete' => true,
140 140
                                 'data' => $ProductClasses,
141
-                             ));
141
+                                ));
142 142
 
143 143
                         $event = new EventArgs(
144 144
                             array(
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@
 block discarded – undo
106 106
                     $class2Valied = $this->isValiedCategory($ClassName2);
107 107
 
108 108
                     // 規格が選択されていないか、選択された状態で分類が保有されていれば、画面表示
109
-                    if($class1Valied && $class2Valied){
109
+                    if ($class1Valied && $class2Valied) {
110 110
                         $hasClassCategoryFlg = true;
111 111
                     }
112 112
 
Please login to merge, or discard this patch.
Doc Comments   +5 added lines patch added patch discarded remove patch
@@ -529,6 +529,9 @@  discard block
 block discarded – undo
529 529
     /**
530 530
      * 登録、更新時のエラー画面表示
531 531
      *
532
+     * @param Application $app
533
+     * @param boolean $not_product_class
534
+     * @param \Symfony\Component\Form\FormInterface $classForm
532 535
      */
533 536
     protected function render($app, $Product, $ProductClass, $not_product_class, $classForm, $error = null)
534 537
     {
@@ -580,6 +583,7 @@  discard block
 block discarded – undo
580 583
 
581 584
     /**
582 585
      * 規格1と規格2を組み合わせた商品規格を作成
586
+     * @param Application $app
583 587
      */
584 588
     private function createProductClasses($app, Product $Product, ClassName $ClassName1 = null, ClassName $ClassName2 = null)
585 589
     {
@@ -667,6 +671,7 @@  discard block
 block discarded – undo
667 671
      *
668 672
      * @param $productClassDest コピー先となる商品規格
669 673
      * @param $productClassOrig コピー元となる商品規格
674
+     * @param Application $app
670 675
      */
671 676
     private function setDefualtProductClass($app, $productClassDest, $productClassOrig) {
672 677
         $productClassDest->setDeliveryDate($productClassOrig->getDeliveryDate());
Please login to merge, or discard this patch.
src/Eccube/Controller/Admin/Setting/System/SecurityController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -102,7 +102,7 @@
 block discarded – undo
102 102
             if (count($allowHost) > 0) {
103 103
                 $form->get('admin_allow_host')->setData(Str::convertLineFeed(implode("\n", $allowHost)));
104 104
             }
105
-            $form->get('force_ssl')->setData((bool)$app['config']['force_ssl']);
105
+            $form->get('force_ssl')->setData((bool) $app['config']['force_ssl']);
106 106
         }
107 107
 
108 108
         return $app->render('Setting/System/security.twig', array(
Please login to merge, or discard this patch.
src/Eccube/Resource/doctrine/migration/Version20160413151321.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
 
22 22
         // path.ymlの更新
23 23
         $app = Application::getInstance();
24
-        $file = $app['config']['root_dir'] . '/app/config/eccube/path.yml';
24
+        $file = $app['config']['root_dir'].'/app/config/eccube/path.yml';
25 25
         $config = Yaml::parse(file_get_contents($file));
26 26
 
27 27
         if (!array_key_exists('public_path', $config)) {
Please login to merge, or discard this patch.
src/Eccube/Controller/Admin/Content/CacheController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -58,7 +58,7 @@
 block discarded – undo
58 58
                 }
59 59
                 if ($dir == 'doctrine') {
60 60
                     // doctrineが指定された場合は, cache driver経由で削除.
61
-                    $config =  $app['orm.em']->getConfiguration();
61
+                    $config = $app['orm.em']->getConfiguration();
62 62
                     $this->deleteDoctrineCache($config->getMetadataCacheImpl());
63 63
                     $this->deleteDoctrineCache($config->getQueryCacheImpl());
64 64
                     $this->deleteDoctrineCache($config->getResultCacheImpl());
Please login to merge, or discard this patch.
src/Eccube/Form/Type/Admin/OrderType.php 1 patch
Spacing   +8 added lines, -10 removed lines patch added patch discarded remove patch
@@ -234,13 +234,13 @@  discard block
 block discarded – undo
234 234
                     '\Eccube\Entity\Customer'
235 235
                 )));
236 236
 
237
-        $builder->addEventListener(FormEvents::PRE_SUBMIT, function (FormEvent $event) use ($BaseInfo) {
237
+        $builder->addEventListener(FormEvents::PRE_SUBMIT, function(FormEvent $event) use ($BaseInfo) {
238 238
 
239 239
             $data = $event->getData();
240 240
             $orderDetails = &$data['OrderDetails'];
241 241
 
242 242
             // 数量0フィルター
243
-            $quantityFilter = function ($v) {
243
+            $quantityFilter = function($v) {
244 244
                 return !(isset($v['quantity']) && preg_match('/^0+$/', trim($v['quantity'])));
245 245
             };
246 246
 
@@ -249,10 +249,9 @@  discard block
 block discarded – undo
249 249
                 $shippings = &$data['Shippings'];
250 250
 
251 251
                 // 数量を抽出
252
-                $getQuantity = function ($v) {
252
+                $getQuantity = function($v) {
253 253
                     return (isset($v['quantity']) && preg_match('/^\d+$/', trim($v['quantity']))) ?
254
-                        trim($v['quantity']) :
255
-                        0;
254
+                        trim($v['quantity']) : 0;
256 255
                 };
257 256
 
258 257
                 foreach ($shippings as &$shipping) {
@@ -268,7 +267,7 @@  discard block
 block discarded – undo
268 267
                         $orderDetail['quantity'] = 0;
269 268
 
270 269
                         // 受注詳細と同じ商品規格のみ抽出
271
-                        $productClassFilter = function ($v) use ($orderDetail) {
270
+                        $productClassFilter = function($v) use ($orderDetail) {
272 271
                             return $orderDetail['ProductClass'] === $v['ProductClass'];
273 272
                         };
274 273
 
@@ -277,10 +276,9 @@  discard block
 block discarded – undo
277 276
                             if (!empty($shipping['ShipmentItems'])) {
278 277
 
279 278
                                 // 同じ商品規格の受注詳細の価格を適用
280
-                                $applyPrice = function (&$v) use ($orderDetail) {
279
+                                $applyPrice = function(&$v) use ($orderDetail) {
281 280
                                     $v['price'] = ($v['ProductClass'] === $orderDetail['ProductClass']) ?
282
-                                        $orderDetail['price'] :
283
-                                        $v['price'];
281
+                                        $orderDetail['price'] : $v['price'];
284 282
                                 };
285 283
                                 array_walk($shipping['ShipmentItems'], $applyPrice);
286 284
 
@@ -300,7 +298,7 @@  discard block
 block discarded – undo
300 298
 
301 299
             $event->setData($data);
302 300
         });
303
-        $builder->addEventListener(FormEvents::POST_SUBMIT, function (FormEvent $event) {
301
+        $builder->addEventListener(FormEvents::POST_SUBMIT, function(FormEvent $event) {
304 302
             $form = $event->getForm();
305 303
             $orderDetails = $form['OrderDetails']->getData();
306 304
             if (empty($orderDetails) || count($orderDetails) < 1) {
Please login to merge, or discard this patch.