Completed
Push — master ( 9b7f47...c035fa )
by Yangsin
42:09
created
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/Form/Type/Admin/SearchProductType.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,6 @@
 block discarded – undo
27 27
 use Symfony\Component\Form\AbstractType;
28 28
 use Symfony\Component\Form\Extension\Core\Type;
29 29
 use Symfony\Component\Form\FormBuilderInterface;
30
-use Symfony\Component\Validator\Constraints as Assert;
31 30
 
32 31
 class SearchProductType extends AbstractType
33 32
 {
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/ChangePasswordType.php 2 patches
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -25,8 +25,6 @@
 block discarded – undo
25 25
 
26 26
 use Symfony\Component\Form\AbstractType;
27 27
 use Symfony\Component\Form\FormBuilderInterface;
28
-use Symfony\Component\Form\FormError;
29
-use Symfony\Component\Form\FormEvents;
30 28
 use Symfony\Component\OptionsResolver\OptionsResolverInterface;
31 29
 use Symfony\Component\Security\Core\Validator\Constraints\UserPassword;
32 30
 use Symfony\Component\Validator\Constraints as Assert;
Please login to merge, or discard this patch.
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -35,6 +35,9 @@
 block discarded – undo
35 35
 {
36 36
     private $app;
37 37
 
38
+    /**
39
+     * @param \Silex\Application $app
40
+     */
38 41
     public function __construct($app)
39 42
     {
40 43
         $this->app = $app;
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.
src/Eccube/Controller/Admin/AdminController.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -65,12 +65,12 @@  discard block
 block discarded – undo
65 65
     {
66 66
         // install.phpのチェック.
67 67
         if (isset($app['config']['eccube_install']) && $app['config']['eccube_install'] == 1) {
68
-            $file = $app['config']['root_dir'] . '/html/install.php';
68
+            $file = $app['config']['root_dir'].'/html/install.php';
69 69
             if (file_exists($file)) {
70 70
                 $message = $app->trans('admin.install.warning', array('installphpPath' => 'html/install.php'));
71 71
                 $app->addWarning($message, 'admin');
72 72
             }
73
-            $fileOnRoot = $app['config']['root_dir'] . '/install.php';
73
+            $fileOnRoot = $app['config']['root_dir'].'/install.php';
74 74
             if (file_exists($fileOnRoot)) {
75 75
                 $message = $app->trans('admin.install.warning', array('installphpPath' => 'install.php'));
76 76
                 $app->addWarning($message, 'admin');
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
                     t1.status
312 312
                 ORDER BY
313 313
                     t1.status';
314
-        $rsm = new ResultSetMapping();;
314
+        $rsm = new ResultSetMapping(); ;
315 315
         $rsm->addScalarResult('status', 'status');
316 316
         $rsm->addScalarResult('count', 'count');
317 317
         $query = $em->createNativeQuery($sql, $rsm);
Please login to merge, or discard this patch.
src/Eccube/Form/Type/Admin/ShipmentItemType.php 1 patch
Spacing   +5 added lines, -9 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
                 )));
98 98
 
99 99
         $app = $this->app;
100
-        $builder->addEventListener(FormEvents::PRE_SUBMIT, function (FormEvent $event) use ($app) {
100
+        $builder->addEventListener(FormEvents::PRE_SUBMIT, function(FormEvent $event) use ($app) {
101 101
             // モーダルからのPOST時に、金額等をセットする.
102 102
             if ('modal' === $app['request']->get('modal')) {
103 103
                 $data = $event->getData();
@@ -112,17 +112,13 @@  discard block
 block discarded – undo
112 112
                     $data['product_name'] = $Product->getName();
113 113
                     $data['product_code'] = $ProductClass->getCode();
114 114
                     $data['class_name1'] = $ProductClass->hasClassCategory1() ?
115
-                        $ProductClass->getClassCategory1()->getClassName() :
116
-                        null;
115
+                        $ProductClass->getClassCategory1()->getClassName() : null;
117 116
                     $data['class_name2'] = $ProductClass->hasClassCategory2() ?
118
-                        $ProductClass->getClassCategory2()->getClassName() :
119
-                        null;
117
+                        $ProductClass->getClassCategory2()->getClassName() : null;
120 118
                     $data['class_category_name1'] = $ProductClass->hasClassCategory1() ?
121
-                        $ProductClass->getClassCategory1()->getName() :
122
-                        null;
119
+                        $ProductClass->getClassCategory1()->getName() : null;
123 120
                     $data['class_category_name2'] = $ProductClass->hasClassCategory2() ?
124
-                        $ProductClass->getClassCategory2()->getName() :
125
-                        null;
121
+                        $ProductClass->getClassCategory2()->getName() : null;
126 122
                     $data['price'] = $ProductClass->getPrice02();
127 123
                     $data['quantity'] = empty($data['quantity']) ? 1 : $data['quantity'];
128 124
                     $event->setData($data);
Please login to merge, or discard this patch.