Passed
Push — master ( 54235f...041fe5 )
by Matthijs
31:29 queued 24:13
created
app/Http/Controllers/Backend/NewsController.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -31,20 +31,20 @@  discard block
 block discarded – undo
31 31
             ->with(array('newsGroup'))        ->leftJoin(NewsService::getGroupModel()->getTable(), NewsService::getGroupModel()->getTable().'.id', '=', 'news_group_id');
32 32
             
33 33
             $datatables = Datatables::of($query)
34
-            ->filterColumn('title', function ($query, $keyword) {
34
+            ->filterColumn('title', function($query, $keyword) {
35 35
 
36 36
                 $query->where(
37
-                    function ($query) use ($keyword) {
37
+                    function($query) use ($keyword) {
38 38
                         $query->whereRaw("news.title like ?", ["%{$keyword}%"]);
39 39
                         ;
40 40
                     }
41 41
                 );
42 42
             })
43
-            ->addColumn('newsgroup', function ($query) {
43
+            ->addColumn('newsgroup', function($query) {
44 44
                 return $query->newstitle;
45 45
             })
46 46
 
47
-            ->addColumn('action', function ($query) {
47
+            ->addColumn('action', function($query) {
48 48
                 $deleteLink = Form::deleteajax(url()->route('news.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
49 49
                 $links = '<a href="'.url()->route('news.edit', $query->id).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a>  '.$deleteLink;
50 50
             
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
 
66 66
     public function store(Request $request)
67 67
     {
68
-        $result  = NewsService::create($request->all());
68
+        $result = NewsService::create($request->all());
69 69
         return NewsService::notificationRedirect('news.index', $result, 'The news item was inserted.');
70 70
     }
71 71
 
@@ -90,13 +90,13 @@  discard block
 block discarded – undo
90 90
     
91 91
     public function update(Request $request, $newsId)
92 92
     {
93
-        $result  = NewsService::updateById($request->all(), $newsId);
93
+        $result = NewsService::updateById($request->all(), $newsId);
94 94
         return NewsService::notificationRedirect('news.index', $result, 'The news item was inserted.');
95 95
     }
96 96
 
97 97
     public function destroy($newsId)
98 98
     {
99
-        $result  = NewsService::destroy($newsId);
99
+        $result = NewsService::destroy($newsId);
100 100
 
101 101
         if ($result) {
102 102
             Notification::success('The news was deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/HtmlBlockController.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -30,18 +30,18 @@  discard block
 block discarded – undo
30 30
             
31 31
             $datatables = Datatables::of($query)
32 32
 
33
-            ->addColumn('active', function ($query) {
33
+            ->addColumn('active', function($query) {
34 34
                 if ($query->active) {
35 35
                     return '<a href="#" class="change-active" data-url="/admin/html-block/change-active/'.$query->id.'"><span class="glyphicon glyphicon-ok icon-green"></span></a>';
36 36
                 }
37 37
                 return '<a href="#" class="change-active" data-url="/admin/html-block/change-active/'.$query->id.'"><span class="glyphicon glyphicon-remove icon-red"></span></a>';
38 38
             })
39
-            ->addColumn('image', function ($query) {
39
+            ->addColumn('image', function($query) {
40 40
                 if ($query->image_file_name) {
41 41
                     return '<img src="'.config('hideyo.public_path').'/html_block/'.$query->id.'/'.$query->image_file_name.'" width="200px" />';
42 42
                 }
43 43
             })
44
-            ->addColumn('action', function ($query) {
44
+            ->addColumn('action', function($query) {
45 45
                 $deleteLink = Form::deleteajax(url()->route('html-block.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
46 46
                 $copy = '<a href="/admin/html-block/'.$query->id.'/copy" class="btn btn-default btn-sm btn-info"><i class="entypo-pencil"></i>Copy</a>';
47 47
                 $links = '<a href="'.url()->route('html-block.edit', $query->id).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a> '.$copy.' '.$deleteLink;
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
 
62 62
     public function store(Request $request)
63 63
     {
64
-        $result  = HtmlBlockService::create($request->all());
64
+        $result = HtmlBlockService::create($request->all());
65 65
         return HtmlBlockService::notificationRedirect('html-block.index', $result, 'The html block was inserted.');     
66 66
     }
67 67
 
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
 
79 79
     public function update(Request $request, $htmlBlockId)
80 80
     {
81
-        $result  = HtmlBlockService::updateById($request->all(), $htmlBlockId);
81
+        $result = HtmlBlockService::updateById($request->all(), $htmlBlockId);
82 82
             return HtmlBlockService::notificationRedirect('html-block.index', $result, 'The html block was updated.');     
83 83
     }
84 84
 
@@ -97,8 +97,8 @@  discard block
 block discarded – undo
97 97
     {
98 98
         $htmlBlock = HtmlBlockService::find($htmlBlockId);
99 99
 
100
-        if($htmlBlock) {
101
-            $result  = HtmlBlockService::createCopy($request->all(), $htmlBlockId);
100
+        if ($htmlBlock) {
101
+            $result = HtmlBlockService::createCopy($request->all(), $htmlBlockId);
102 102
             return HtmlBlockService::notificationRedirect('html-block.index', $result, 'The html block was inserted.');      
103 103
         }
104 104
 
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
 
108 108
     public function destroy($htmlBlockId)
109 109
     {
110
-        $result  = HtmlBlockService::destroy($htmlBlockId);
110
+        $result = HtmlBlockService::destroy($htmlBlockId);
111 111
 
112 112
         if ($result) {
113 113
             Notification::success('The html block was deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/PaymentMethodController.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -35,22 +35,22 @@  discard block
 block discarded – undo
35 35
             
36 36
             $datatables = Datatables::of($query)
37 37
 
38
-            ->addColumn('orderconfirmed', function ($query) {
38
+            ->addColumn('orderconfirmed', function($query) {
39 39
                 if ($query->orderConfirmedOrderStatus) {
40 40
                     return $query->orderConfirmedOrderStatus->title;
41 41
                 }
42 42
             })
43
-            ->addColumn('paymentcompleted', function ($query) {
43
+            ->addColumn('paymentcompleted', function($query) {
44 44
                 if ($query->orderPaymentCompletedOrderStatus) {
45 45
                     return $query->orderPaymentCompletedOrderStatus->title;
46 46
                 }
47 47
             })
48
-            ->addColumn('paymentfailed', function ($query) {
48
+            ->addColumn('paymentfailed', function($query) {
49 49
                 if ($query->orderPaymentFailedOrderStatus) {
50 50
                     return $query->orderPaymentFailedOrderStatus->title;
51 51
                 }
52 52
             })
53
-            ->addColumn('action', function ($query) {
53
+            ->addColumn('action', function($query) {
54 54
                 $deleteLink = Form::deleteajax(url()->route('payment-method.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-sm btn-danger'));
55 55
                 $links = '<a href="'.url()->route('payment-method.edit', $query->id).'" class="btn btn-sm btn-success"><i class="fi-pencil"></i>Edit</a>  '.$deleteLink;
56 56
                 return $links;
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 
76 76
     public function store(Request $request)
77 77
     {
78
-        $result  = PaymentMethodService::create($request->all());
78
+        $result = PaymentMethodService::create($request->all());
79 79
         return PaymentMethodService::notificationRedirect('payment-method.index', $result, 'The payment method was inserted.');
80 80
     }
81 81
 
@@ -92,13 +92,13 @@  discard block
 block discarded – undo
92 92
 
93 93
     public function update(Request $request, $paymentMethodId)
94 94
     {
95
-        $result  = PaymentMethodService::updateById($request->all(), $paymentMethodId);
95
+        $result = PaymentMethodService::updateById($request->all(), $paymentMethodId);
96 96
         return PaymentMethodService::notificationRedirect('payment-method.index', $result, 'The payment method was updated.');
97 97
     }
98 98
 
99 99
     public function destroy($paymentMethodId)
100 100
     {
101
-        $result  = PaymentMethodService::destroy($paymentMethodId);
101
+        $result = PaymentMethodService::destroy($paymentMethodId);
102 102
 
103 103
         if ($result) {
104 104
             Notification::success('The payment method was deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/OrderStatusEmailTemplateController.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -27,8 +27,8 @@  discard block
 block discarded – undo
27 27
             )->where('shop_id', '=', auth('hideyobackend')->user()->selected_shop_id);
28 28
             
29 29
             $datatables = Datatables::of($query)
30
-            ->addColumn('action', function ($query) {
31
-                $deleteLink = Form::deleteajax('/admin/order-status-email-template/'. $query->id, 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
30
+            ->addColumn('action', function($query) {
31
+                $deleteLink = Form::deleteajax('/admin/order-status-email-template/'.$query->id, 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
32 32
                 $links = '<a href="/admin/order-status-email-template/'.$query->id.'/edit" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a>  '.$deleteLink;
33 33
             
34 34
                 return $links;
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 
48 48
     public function store(Request $request)
49 49
     {
50
-        $result  = OrderStatusEmailTemplateService::create($request->all());
50
+        $result = OrderStatusEmailTemplateService::create($request->all());
51 51
         return OrderStatusEmailTemplateService::notificationRedirect('order-status-email-template.index', $result, 'The template was inserted.');
52 52
     }
53 53
 
@@ -63,13 +63,13 @@  discard block
 block discarded – undo
63 63
 
64 64
     public function update(Request $request, $templateId)
65 65
     {
66
-        $result  = OrderStatusEmailTemplateService::updateById($request->all(), $templateId);
66
+        $result = OrderStatusEmailTemplateService::updateById($request->all(), $templateId);
67 67
         return OrderStatusEmailTemplateService::notificationRedirect('order-status-email-template.index', $result, 'The template was updated.');
68 68
     }
69 69
 
70 70
     public function destroy($templateId)
71 71
     {
72
-        $result  = OrderStatusEmailTemplateService::destroy($templateId);
72
+        $result = OrderStatusEmailTemplateService::destroy($templateId);
73 73
 
74 74
         if ($result) {
75 75
             Notification::success('template was deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/SendingMethodCountryPriceController.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
                 'name']
31 31
             )->where('sending_method_id', '=', $sendingMethodId);
32 32
             
33
-            $datatables = \Datatables::of($users)->addColumn('action', function ($users) use ($sendingMethodId) {
33
+            $datatables = \Datatables::of($users)->addColumn('action', function($users) use ($sendingMethodId) {
34 34
                 $delete = \Form::deleteajax(url()->route('sending-method.country-prices.destroy', array('sendingMethodId' => $sendingMethodId, 'id' => $users->id)), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
35 35
                 $link = '<a href="'.url()->route('sending-method.country-prices.edit', array('sendingMethodId' => $sendingMethodId, 'id' => $users->id)).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a>  '.$delete;
36 36
             
@@ -65,8 +65,8 @@  discard block
 block discarded – undo
65 65
         $countries = \Excel::load($file, function($reader) {
66 66
         })->get();
67 67
 
68
-        if($countries) {
69
-            $result  = SendingMethodService::importCountries($countries, $request->get('tax_rate_id'), $sendingMethodId);
68
+        if ($countries) {
69
+            $result = SendingMethodService::importCountries($countries, $request->get('tax_rate_id'), $sendingMethodId);
70 70
             Notification::success('The countries are inserted.');
71 71
             return redirect()->route('sending-method.country-prices.index', $sendingMethodId);
72 72
         }         
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
 
75 75
     public function store(Request $request, $sendingMethodId)
76 76
     {
77
-        $result  = SendingMethodService::createCountry($request->all(), $sendingMethodId);
77
+        $result = SendingMethodService::createCountry($request->all(), $sendingMethodId);
78 78
         return SendingMethodService::notificationRedirect(array('sending-method.country-prices.index', $sendingMethodId), $result, 'The country was inserted.');
79 79
     }
80 80
 
@@ -89,13 +89,13 @@  discard block
 block discarded – undo
89 89
 
90 90
     public function update(Request $request, $sendingMethodId, $id)
91 91
     {
92
-        $result  = SendingMethodService::updateCountryById($request->all(), $id);
92
+        $result = SendingMethodService::updateCountryById($request->all(), $id);
93 93
         return SendingMethodService::notificationRedirect(array('sending-method.country-prices.index', $sendingMethodId), $result, 'The country was updated.');
94 94
     }
95 95
 
96 96
     public function destroy($sendingMethodId, $id)
97 97
     {
98
-        $result  = SendingMethodService::destroyCountry($id);
98
+        $result = SendingMethodService::destroyCountry($id);
99 99
 
100 100
         if ($result) {
101 101
             Notification::success('The country price was deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/ProductImageController.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
 {
19 19
     public function index(Request $request, $productId)
20 20
     {
21
-           $product = ProductService::find($productId);
21
+            $product = ProductService::find($productId);
22 22
         if ($request->wantsJson()) {
23 23
 
24 24
             $query = ProductService::getImageModel()->where('product_id', '=', $productId);
@@ -96,8 +96,8 @@  discard block
 block discarded – undo
96 96
                 foreach ($newProductAttributes as $key => $productAttribute) {
97 97
                     $newArray = array();
98 98
                     foreach ($productAttribute as $keyNew => $valueNew) {
99
-                         $newArray[] = $keyNew.': '.$valueNew['value'];
100
-                         $attributesList[$valueNew['id']] = $valueNew['value'];
99
+                            $newArray[] = $keyNew.': '.$valueNew['value'];
100
+                            $attributesList[$valueNew['id']] = $valueNew['value'];
101 101
                     }
102 102
                     $productAttributesList[$key] = implode(', ', $newArray);
103 103
                 }
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -24,11 +24,11 @@  discard block
 block discarded – undo
24 24
             $query = ProductService::getImageModel()->where('product_id', '=', $productId);
25 25
             
26 26
             $datatables = \Datatables::of($query)
27
-            ->addColumn('thumb', function ($query) use ($productId) {
27
+            ->addColumn('thumb', function($query) use ($productId) {
28 28
                 return '<img src="/files/product/100x100/'.$query->product_id.'/'.$query->file.'"  />';
29 29
             })
30 30
 
31
-            ->addColumn('action', function ($query) use ($productId) {
31
+            ->addColumn('action', function($query) use ($productId) {
32 32
                 $deleteLink = \Form::deleteajax(url()->route('product.images.destroy', array('productId' => $productId, 'id' => $query->id)), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
33 33
                 $links = '<a href="'.url()->route('product.images.edit', array('productId' => $productId, 'id' => $query->id)).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a>  '.$deleteLink;
34 34
             
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
 
51 51
     public function store(Request $request, $productId)
52 52
     {
53
-        $result  = ProductService::createImage($request->all(), $productId);
53
+        $result = ProductService::createImage($request->all(), $productId);
54 54
         return ProductService::notificationRedirect(array('product.images.index', $productId), $result, 'The product image was inserted.');
55 55
     }
56 56
 
@@ -64,13 +64,13 @@  discard block
 block discarded – undo
64 64
 
65 65
         if ($productImage->relatedProductAttributes->count()) {
66 66
             foreach ($productImage->relatedProductAttributes as $row) {
67
-                $selectedProductAttributes[] =  $row->pivot->product_attribute_id;
67
+                $selectedProductAttributes[] = $row->pivot->product_attribute_id;
68 68
             }
69 69
         }
70 70
 
71 71
         if ($productImage->relatedAttributes->count()) {
72 72
             foreach ($productImage->relatedAttributes as $row) {
73
-                $selectedAttributes[] =  $row->pivot->attribute_id;
73
+                $selectedAttributes[] = $row->pivot->attribute_id;
74 74
             }
75 75
         }
76 76
 
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 
80 80
     public function generateAttributeLists($product)
81 81
     {
82
-        $productAttributes =         $product->attributes;
82
+        $productAttributes = $product->attributes;
83 83
         $newProductAttributes = array();
84 84
         $attributesList = array();
85 85
         $productAttributesList = array();
@@ -109,13 +109,13 @@  discard block
 block discarded – undo
109 109
 
110 110
     public function update(Request $request, $productId, $productImageId)
111 111
     {
112
-        $result  = ProductService::updateImageById($request->all(), $productId, $productImageId);
112
+        $result = ProductService::updateImageById($request->all(), $productId, $productImageId);
113 113
         return ProductService::notificationRedirect(array('product.images.index', $productId), $result, 'The product image was update.');
114 114
     }
115 115
 
116 116
     public function destroy($productId, $productImageId)
117 117
     {
118
-        $result  = ProductService::destroyImage($productImageId);
118
+        $result = ProductService::destroyImage($productImageId);
119 119
 
120 120
         if ($result) {
121 121
             Notification::success('The product image is deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/ProductRelatedProductController.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -27,13 +27,13 @@  discard block
 block discarded – undo
27 27
             $query = ProductRelatedProductService::getModel()->where('product_id', '=', $productId);
28 28
             
29 29
             $datatables = \Datatables::of($query)
30
-                ->addColumn('related', function ($query) use ($productId) {
30
+                ->addColumn('related', function($query) use ($productId) {
31 31
                     return $query->RelatedProduct->title;
32 32
                 })
33
-                ->addColumn('product', function ($query) use ($productId) {
33
+                ->addColumn('product', function($query) use ($productId) {
34 34
                     return $query->Product->title;
35 35
                 })
36
-                ->addColumn('action', function ($query) use ($productId) {
36
+                ->addColumn('action', function($query) use ($productId) {
37 37
                     $deleteLink = \Form::deleteajax(url()->route('product.related-product.destroy', array('productId' => $productId, 'id' => $query->id)), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
38 38
                     
39 39
                     return $deleteLink;
@@ -55,13 +55,13 @@  discard block
 block discarded – undo
55 55
     
56 56
     public function store(Request $request, $productId)
57 57
     {
58
-        $result  = ProductRelatedProductService::create($request->all(), $productId);
58
+        $result = ProductRelatedProductService::create($request->all(), $productId);
59 59
         return redirect()->route('product.related-product.index', $productId);
60 60
     }
61 61
 
62 62
     public function destroy($productId, $productRelatedProductId)
63 63
     {
64
-        $result  = ProductRelatedProductService::destroy($productRelatedProductId);
64
+        $result = ProductRelatedProductService::destroy($productRelatedProductId);
65 65
 
66 66
         if ($result) {
67 67
             Notification::success('The related product is deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/SendingMethodController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 
28 28
             ->where('shop_id', '=', auth('hideyobackend')->user()->selected_shop_id);
29 29
 
30
-            $datatables = Datatables::of($query)->addColumn('action', function ($query) {
30
+            $datatables = Datatables::of($query)->addColumn('action', function($query) {
31 31
                 $deleteLink = Form::deleteajax(url()->route('sending-method.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-sm btn-danger'), $query->title);
32 32
                 $links = '<a href="'.url()->route('sending-method.country-prices.index', $query->id).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Country prices ('.$query->countryPrices()->count().')</a>  <a href="/admin/sending-method/'.$query->id.'/edit" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a>  '.$deleteLink;
33 33
             
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 
52 52
     public function store(Request $request)
53 53
     {
54
-        $result  = SendingMethodService::create($request->all());
54
+        $result = SendingMethodService::create($request->all());
55 55
         return SendingMethodService::notificationRedirect('sending-method.index', $result, 'The sending method was inserted.');
56 56
     }
57 57
 
@@ -68,13 +68,13 @@  discard block
 block discarded – undo
68 68
 
69 69
     public function update(Request $request, $sendingMethodId)
70 70
     {
71
-        $result  = SendingMethodService::updateById($request->all(), $sendingMethodId);
71
+        $result = SendingMethodService::updateById($request->all(), $sendingMethodId);
72 72
         return SendingMethodService::notificationRedirect('sending-method.index', $result, 'The sending method was updated.');
73 73
     }
74 74
 
75 75
     public function destroy($sendingMethodId)
76 76
     {
77
-        $result  = SendingMethodService::destroy($sendingMethodId);
77
+        $result = SendingMethodService::destroy($sendingMethodId);
78 78
 
79 79
         if ($result) {
80 80
             Notification::success('The sending method was deleted.');
Please login to merge, or discard this patch.
app/Http/Controllers/Backend/ProductCombinationController.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
     {
27 27
         $product = ProductService::find($productId);
28 28
 
29
-        if($product) {
29
+        if ($product) {
30 30
             if ($request->wantsJson()) {
31 31
 
32 32
                 $query = ProductCombinationService::getModel()->select(
@@ -34,18 +34,18 @@  discard block
 block discarded – undo
34 34
                     'default_on']
35 35
                 )->where('product_id', '=', $productId);
36 36
 
37
-                $datatables = \Datatables::of($query)->addColumn('action', function ($query) use ($productId) {
37
+                $datatables = \Datatables::of($query)->addColumn('action', function($query) use ($productId) {
38 38
                     $deleteLink = \Form::deleteajax(url()->route('product-combination.destroy', array('productId' => $productId, 'id' => $query->id)), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'));
39 39
                     $links = '<a href="'.url()->route('product-combination.edit', array('productId' => $productId, 'id' => $query->id)).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a>  '.$deleteLink;
40 40
                 
41 41
                     return $links;
42 42
                 })
43 43
 
44
-                ->addColumn('amount', function ($query) {
44
+                ->addColumn('amount', function($query) {
45 45
                     return '<input type="text" class="change-amount-product-attribute" value="'.$query->amount.'" data-url="/admin/product/'.$query->product_id.'/product-combination/change-amount-attribute/'.$query->id.'">';
46 46
                 })
47 47
 
48
-                ->addColumn('price', function ($query) {
48
+                ->addColumn('price', function($query) {
49 49
                     $result = 0;
50 50
                     if ($query->price) {
51 51
 
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
                             'amount' => $query->amount
95 95
                             );
96 96
 
97
-                        $result =  '&euro; '.$output['orginal_price_ex_tax_number_format'].' / &euro; '.$output['orginal_price_inc_tax_number_format'];
97
+                        $result = '&euro; '.$output['orginal_price_ex_tax_number_format'].' / &euro; '.$output['orginal_price_inc_tax_number_format'];
98 98
 
99 99
 
100 100
                         if ($query->discount_value) {
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
                     return $result;
106 106
                 })
107 107
 
108
-                ->addColumn('combinations', function ($query) use ($productId) {
108
+                ->addColumn('combinations', function($query) use ($productId) {
109 109
                     $items = array();
110 110
                     foreach ($query->combinations as $row) {
111 111
                         $items[] = $row->attribute->attributeGroup->title.': '.$row->attribute->value;
@@ -150,8 +150,8 @@  discard block
 block discarded – undo
150 150
 
151 151
     public function store(Request $request, $productId)
152 152
     {
153
-        $result  = ProductCombinationService::create($request->all(), $productId);
154
-        if($result) {
153
+        $result = ProductCombinationService::create($request->all(), $productId);
154
+        if ($result) {
155 155
             return ProductCombinationService::notificationRedirect(array('product-combination.index', $productId), $result, 'The product extra fields are updated.');
156 156
 
157 157
         }
@@ -188,14 +188,14 @@  discard block
 block discarded – undo
188 188
     public function update(Request $request, $productId, $id)
189 189
     {
190 190
 
191
-        $result  = ProductCombinationService::updateById($request->all(), $productId, $id);
191
+        $result = ProductCombinationService::updateById($request->all(), $productId, $id);
192 192
         return ProductCombinationService::notificationRedirect(array('product-combination.index', $productId), $result, 'The product combinations are updated.');
193 193
 
194 194
     }
195 195
 
196 196
     public function destroy($productId, $id)
197 197
     {
198
-        $result  = ProductCombinationService::destroy($id);
198
+        $result = ProductCombinationService::destroy($id);
199 199
 
200 200
         if ($result) {
201 201
             Notification::success('The product combination is deleted.');
Please login to merge, or discard this patch.