@@ -22,7 +22,7 @@ discard block |
||
| 22 | 22 | if ($request->wantsJson()) { |
| 23 | 23 | $brand = BrandService::getModel()->where('shop_id', '=', auth('hideyobackend')->user()->selected_shop_id); |
| 24 | 24 | |
| 25 | - $datatables = DataTables::of($brand)->addColumn('action', function ($query) { |
|
| 25 | + $datatables = DataTables::of($brand)->addColumn('action', function($query) { |
|
| 26 | 26 | $deleteLink = Form::deleteajax(url()->route('brand.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger'), $query->title); |
| 27 | 27 | $links = '<a href="'.url()->route('brand.edit', $query->id).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a> '.$deleteLink; |
| 28 | 28 | |
@@ -42,7 +42,7 @@ discard block |
||
| 42 | 42 | |
| 43 | 43 | public function store(Request $request) |
| 44 | 44 | { |
| 45 | - $result = BrandService::create($request->all()); |
|
| 45 | + $result = BrandService::create($request->all()); |
|
| 46 | 46 | return BrandService::notificationRedirect('brand.index', $result, 'The brand was inserted.'); |
| 47 | 47 | } |
| 48 | 48 | |
@@ -53,13 +53,13 @@ discard block |
||
| 53 | 53 | |
| 54 | 54 | public function update(Request $request, $brandId) |
| 55 | 55 | { |
| 56 | - $result = BrandService::updateById($request->all(), $brandId); |
|
| 56 | + $result = BrandService::updateById($request->all(), $brandId); |
|
| 57 | 57 | return BrandService::notificationRedirect('brand.index', $result, 'The brand was updated.'); |
| 58 | 58 | } |
| 59 | 59 | |
| 60 | 60 | public function destroy($brandId) |
| 61 | 61 | { |
| 62 | - $result = BrandService::destroy($brandId); |
|
| 62 | + $result = BrandService::destroy($brandId); |
|
| 63 | 63 | if ($result) { |
| 64 | 64 | Notification::error('The brand was deleted.'); |
| 65 | 65 | return redirect()->route('brand.index'); |
@@ -25,13 +25,13 @@ discard block |
||
| 25 | 25 | $query = ProductRelatedProductService::getModel()->where('product_id', '=', $productId); |
| 26 | 26 | |
| 27 | 27 | $datatables = \DataTables::of($query) |
| 28 | - ->addColumn('related', function ($query) use ($productId) { |
|
| 28 | + ->addColumn('related', function($query) use ($productId) { |
|
| 29 | 29 | return $query->RelatedProduct->title; |
| 30 | 30 | }) |
| 31 | - ->addColumn('product', function ($query) use ($productId) { |
|
| 31 | + ->addColumn('product', function($query) use ($productId) { |
|
| 32 | 32 | return $query->Product->title; |
| 33 | 33 | }) |
| 34 | - ->addColumn('action', function ($query) use ($productId) { |
|
| 34 | + ->addColumn('action', function($query) use ($productId) { |
|
| 35 | 35 | $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')); |
| 36 | 36 | |
| 37 | 37 | return $deleteLink; |
@@ -52,13 +52,13 @@ discard block |
||
| 52 | 52 | |
| 53 | 53 | public function store(Request $request, $productId) |
| 54 | 54 | { |
| 55 | - $result = ProductRelatedProductService::create($request->all(), $productId); |
|
| 55 | + $result = ProductRelatedProductService::create($request->all(), $productId); |
|
| 56 | 56 | return redirect()->route('product.related-product.index', $productId); |
| 57 | 57 | } |
| 58 | 58 | |
| 59 | 59 | public function destroy($productId, $productRelatedProductId) |
| 60 | 60 | { |
| 61 | - $result = ProductRelatedProductService::destroy($productRelatedProductId); |
|
| 61 | + $result = ProductRelatedProductService::destroy($productRelatedProductId); |
|
| 62 | 62 | |
| 63 | 63 | if ($result) { |
| 64 | 64 | Notification::success('The related product is deleted.'); |
@@ -34,10 +34,10 @@ discard block |
||
| 34 | 34 | ->where('faq_item.shop_id', '=', auth('hideyobackend')->user()->selected_shop_id); |
| 35 | 35 | |
| 36 | 36 | $datatables = DataTables::of($query) |
| 37 | - ->addColumn('faqitemgroup', function ($query) { |
|
| 37 | + ->addColumn('faqitemgroup', function($query) { |
|
| 38 | 38 | return $query->grouptitle; |
| 39 | 39 | }) |
| 40 | - ->addColumn('action', function ($query) { |
|
| 40 | + ->addColumn('action', function($query) { |
|
| 41 | 41 | $deleteLink = Form::deleteajax(url()->route('faq.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger')); |
| 42 | 42 | $links = '<a href="'.url()->route('faq.edit', $query->id).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a> '.$deleteLink; |
| 43 | 43 | |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | |
| 59 | 59 | public function store(Request $request) |
| 60 | 60 | { |
| 61 | - $result = FaqService::create($request->all()); |
|
| 61 | + $result = FaqService::create($request->all()); |
|
| 62 | 62 | return FaqService::notificationRedirect('faq.index', $result, 'FaqItem was inserted.'); |
| 63 | 63 | } |
| 64 | 64 | |
@@ -70,13 +70,13 @@ discard block |
||
| 70 | 70 | |
| 71 | 71 | public function update(Request $request, $faqId) |
| 72 | 72 | { |
| 73 | - $result = FaqService::updateById($request->all(), $faqId); |
|
| 73 | + $result = FaqService::updateById($request->all(), $faqId); |
|
| 74 | 74 | return FaqService::notificationRedirect('faq.index', $result, 'FaqItem was updated.'); |
| 75 | 75 | } |
| 76 | 76 | |
| 77 | 77 | public function destroy($faqItemId) |
| 78 | 78 | { |
| 79 | - $result = FaqService::destroy($faqItemId); |
|
| 79 | + $result = FaqService::destroy($faqItemId); |
|
| 80 | 80 | |
| 81 | 81 | if ($result) { |
| 82 | 82 | Notification::success('The faq was deleted.'); |
@@ -27,22 +27,22 @@ discard block |
||
| 27 | 27 | |
| 28 | 28 | $datatables = DataTables::of($query) |
| 29 | 29 | |
| 30 | - ->addColumn('orderconfirmed', function ($query) { |
|
| 30 | + ->addColumn('orderconfirmed', function($query) { |
|
| 31 | 31 | if ($query->orderConfirmedOrderStatus) { |
| 32 | 32 | return $query->orderConfirmedOrderStatus->title; |
| 33 | 33 | } |
| 34 | 34 | }) |
| 35 | - ->addColumn('paymentcompleted', function ($query) { |
|
| 35 | + ->addColumn('paymentcompleted', function($query) { |
|
| 36 | 36 | if ($query->orderPaymentCompletedOrderStatus) { |
| 37 | 37 | return $query->orderPaymentCompletedOrderStatus->title; |
| 38 | 38 | } |
| 39 | 39 | }) |
| 40 | - ->addColumn('paymentfailed', function ($query) { |
|
| 40 | + ->addColumn('paymentfailed', function($query) { |
|
| 41 | 41 | if ($query->orderPaymentFailedOrderStatus) { |
| 42 | 42 | return $query->orderPaymentFailedOrderStatus->title; |
| 43 | 43 | } |
| 44 | 44 | }) |
| 45 | - ->addColumn('action', function ($query) { |
|
| 45 | + ->addColumn('action', function($query) { |
|
| 46 | 46 | $deleteLink = Form::deleteajax(url()->route('payment-method.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-sm btn-danger')); |
| 47 | 47 | $links = '<a href="'.url()->route('payment-method.edit', $query->id).'" class="btn btn-sm btn-success"><i class="fi-pencil"></i>Edit</a> '.$deleteLink; |
| 48 | 48 | return $links; |
@@ -67,7 +67,7 @@ discard block |
||
| 67 | 67 | |
| 68 | 68 | public function store(Request $request) |
| 69 | 69 | { |
| 70 | - $result = PaymentMethodService::create($request->all()); |
|
| 70 | + $result = PaymentMethodService::create($request->all()); |
|
| 71 | 71 | return PaymentMethodService::notificationRedirect('payment-method.index', $result, 'The payment method was inserted.'); |
| 72 | 72 | } |
| 73 | 73 | |
@@ -84,13 +84,13 @@ discard block |
||
| 84 | 84 | |
| 85 | 85 | public function update(Request $request, $paymentMethodId) |
| 86 | 86 | { |
| 87 | - $result = PaymentMethodService::updateById($request->all(), $paymentMethodId); |
|
| 87 | + $result = PaymentMethodService::updateById($request->all(), $paymentMethodId); |
|
| 88 | 88 | return PaymentMethodService::notificationRedirect('payment-method.index', $result, 'The payment method was updated.'); |
| 89 | 89 | } |
| 90 | 90 | |
| 91 | 91 | public function destroy($paymentMethodId) |
| 92 | 92 | { |
| 93 | - $result = PaymentMethodService::destroy($paymentMethodId); |
|
| 93 | + $result = PaymentMethodService::destroy($paymentMethodId); |
|
| 94 | 94 | |
| 95 | 95 | if ($result) { |
| 96 | 96 | Notification::success('The payment method was deleted.'); |
@@ -35,7 +35,7 @@ |
||
| 35 | 35 | Notification::error($validator->errors()->all()); |
| 36 | 36 | } |
| 37 | 37 | |
| 38 | - Mail::send('frontend.email.contact', ['data' => $input], function ($m) use ($input) { |
|
| 38 | + Mail::send('frontend.email.contact', ['data' => $input], function($m) use ($input) { |
|
| 39 | 39 | $m->from('[email protected]', 'Dutchbridge'); |
| 40 | 40 | $m->replyTo($input['email'], $input['name']); |
| 41 | 41 | $m->to('[email protected]')->subject(': thnx for your contact!'); |
@@ -10,7 +10,7 @@ discard block |
||
| 10 | 10 | public function getItem(Request $request, $newsGroupSlug, $slug) |
| 11 | 11 | { |
| 12 | 12 | $news = NewsService::selectOneBySlug(config()->get('app.shop_id'), $slug); |
| 13 | - $newsGroups = NewsService::selectAllActiveGroupsByShopId(config()->get('app.shop_id')); |
|
| 13 | + $newsGroups = NewsService::selectAllActiveGroupsByShopId(config()->get('app.shop_id')); |
|
| 14 | 14 | |
| 15 | 15 | if ($news) { |
| 16 | 16 | if ($news->slug != $slug or $news->newsGroup->slug != $newsGroupSlug) { |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | $page = $request->get('page', 1); |
| 29 | 29 | $news = NewsService::selectByGroupAndByShopIdAndPaginate(config()->get('app.shop_id'), $newsGroupSlug, 25); |
| 30 | 30 | $newsGroup = NewsService::selectOneGroupByShopIdAndSlug(config()->get('app.shop_id'), $newsGroupSlug); |
| 31 | - $newsGroups = NewsService::selectAllActiveGroupsByShopId(config()->get('app.shop_id')); |
|
| 31 | + $newsGroups = NewsService::selectAllActiveGroupsByShopId(config()->get('app.shop_id')); |
|
| 32 | 32 | |
| 33 | 33 | if ($newsGroup) { |
| 34 | 34 | return view('frontend.news.group')->with(array('selectedPage' => $page, 'news' => $news, 'newsGroups' => $newsGroups, 'newsGroup' => $newsGroup)); |
@@ -41,7 +41,7 @@ discard block |
||
| 41 | 41 | { |
| 42 | 42 | $page = $request->get('page', 1); |
| 43 | 43 | $news = NewsService::selectAllByShopIdAndPaginate(config()->get('app.shop_id'), 25); |
| 44 | - $newsGroups = NewsService::selectAllActiveGroupsByShopId(config()->get('app.shop_id')); |
|
| 44 | + $newsGroups = NewsService::selectAllActiveGroupsByShopId(config()->get('app.shop_id')); |
|
| 45 | 45 | if ($news) { |
| 46 | 46 | return view('frontend.news.index')->with(array('selectedPage' => $page, 'news' => $news, 'newsGroups' => $newsGroups)); |
| 47 | 47 | } |
@@ -22,7 +22,7 @@ discard block |
||
| 22 | 22 | if ($request->wantsJson()) { |
| 23 | 23 | $query = ProductTagGroupService::getModel()->where('shop_id', '=', auth('hideyobackend')->user()->selected_shop_id); |
| 24 | 24 | |
| 25 | - $datatables = \DataTables::of($query)->addColumn('action', function ($query) { |
|
| 25 | + $datatables = \DataTables::of($query)->addColumn('action', function($query) { |
|
| 26 | 26 | $deleteLink = \Form::deleteajax(url()->route('product-tag-group.destroy', $query->id), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger')); |
| 27 | 27 | $links = '<a href="'.url()->route('product-tag-group.edit', $query->id).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a> '.$deleteLink; |
| 28 | 28 | |
@@ -44,7 +44,7 @@ discard block |
||
| 44 | 44 | |
| 45 | 45 | public function store(Request $request) |
| 46 | 46 | { |
| 47 | - $result = ProductTagGroupService::create($request->all()); |
|
| 47 | + $result = ProductTagGroupService::create($request->all()); |
|
| 48 | 48 | return ProductTagGroupService::notificationRedirect('product-tag-group.index', $result, 'The product group tag was inserted.'); |
| 49 | 49 | } |
| 50 | 50 | |
@@ -60,13 +60,13 @@ discard block |
||
| 60 | 60 | |
| 61 | 61 | public function update(Request $request, $productTagGroupId) |
| 62 | 62 | { |
| 63 | - $result = ProductTagGroupService::updateById($request->all(), $productTagGroupId); |
|
| 63 | + $result = ProductTagGroupService::updateById($request->all(), $productTagGroupId); |
|
| 64 | 64 | return ProductTagGroupService::notificationRedirect('product-tag-group.index', $result, 'The product group tag was updated.'); |
| 65 | 65 | } |
| 66 | 66 | |
| 67 | 67 | public function destroy($productTagGroupId) |
| 68 | 68 | { |
| 69 | - $result = ProductTagGroupService::destroy($productTagGroupId); |
|
| 69 | + $result = ProductTagGroupService::destroy($productTagGroupId); |
|
| 70 | 70 | |
| 71 | 71 | if ($result) { |
| 72 | 72 | Notification::success('The product group tag was deleted.'); |
@@ -24,10 +24,10 @@ discard block |
||
| 24 | 24 | $image = BrandService::getModelImage()->where('brand_id', '=', $brandId); |
| 25 | 25 | |
| 26 | 26 | $datatables = DataTables::of($image) |
| 27 | - ->addColumn('thumb', function ($image) { |
|
| 27 | + ->addColumn('thumb', function($image) { |
|
| 28 | 28 | return '<img src="'.config('hideyo.public_path').'/brand/100x100/'.$image->brand_id.'/'.$image->file.'" />'; |
| 29 | 29 | }) |
| 30 | - ->addColumn('action', function ($image) use ($brandId) { |
|
| 30 | + ->addColumn('action', function($image) use ($brandId) { |
|
| 31 | 31 | $deleteLink = Form::deleteajax(url()->route('brand.images.destroy', array('brandId' => $brandId, 'id' => $image->id)), 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger')); |
| 32 | 32 | $links = '<a href="'.url()->route('brand.images.edit', array('brandId' => $brandId, 'id' => $image->id)).'" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a> '.$deleteLink; |
| 33 | 33 | return $links; |
@@ -36,7 +36,7 @@ discard block |
||
| 36 | 36 | return $datatables->make(true); |
| 37 | 37 | } |
| 38 | 38 | |
| 39 | - return view('backend.brand_image.index')->with(array( 'brand' => $brand)); |
|
| 39 | + return view('backend.brand_image.index')->with(array('brand' => $brand)); |
|
| 40 | 40 | } |
| 41 | 41 | |
| 42 | 42 | public function create($brandId) |
@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | |
| 48 | 48 | public function store(Request $request, $brandId) |
| 49 | 49 | { |
| 50 | - $result = BrandService::createImage($request->all(), $brandId); |
|
| 50 | + $result = BrandService::createImage($request->all(), $brandId); |
|
| 51 | 51 | return BrandService::notificationRedirect(array('brand.images.index', $brandId), $result, 'The brand image was inserted.'); |
| 52 | 52 | } |
| 53 | 53 | |
@@ -59,13 +59,13 @@ discard block |
||
| 59 | 59 | |
| 60 | 60 | public function update(Request $request, $brandId, $brandImageId) |
| 61 | 61 | { |
| 62 | - $result = BrandService::updateImageById($request->all(), $brandId, $brandImageId); |
|
| 62 | + $result = BrandService::updateImageById($request->all(), $brandId, $brandImageId); |
|
| 63 | 63 | return BrandService::notificationRedirect(array('brand.images.index', $brandId), $result, 'The brand image was updated.'); |
| 64 | 64 | } |
| 65 | 65 | |
| 66 | 66 | public function destroy($brandId, $brandImageId) |
| 67 | 67 | { |
| 68 | - $result = BrandService::destroyImage($brandImageId); |
|
| 68 | + $result = BrandService::destroyImage($brandImageId); |
|
| 69 | 69 | |
| 70 | 70 | if ($result) { |
| 71 | 71 | Notification::success('The file was deleted.'); |
@@ -24,7 +24,7 @@ discard block |
||
| 24 | 24 | $query = OrderStatusService::getModel()->where('shop_id', '=', auth('hideyobackend')->user()->selected_shop_id); |
| 25 | 25 | |
| 26 | 26 | $datatables = \DataTables::of($query) |
| 27 | - ->addColumn('title', function ($query) { |
|
| 27 | + ->addColumn('title', function($query) { |
|
| 28 | 28 | |
| 29 | 29 | if ($query->color) { |
| 30 | 30 | return '<span style="background-color:'.$query->color.'; padding: 10px; line-height:30px; text-align:center; color:white;">'.$query->title.'</span>'; |
@@ -32,8 +32,8 @@ discard block |
||
| 32 | 32 | |
| 33 | 33 | return $query->title; |
| 34 | 34 | }) |
| 35 | - ->addColumn('action', function ($query) { |
|
| 36 | - $deleteLink = Form::deleteajax('/admin/order-status/'. $query->id, 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger')); |
|
| 35 | + ->addColumn('action', function($query) { |
|
| 36 | + $deleteLink = Form::deleteajax('/admin/order-status/'.$query->id, 'Delete', '', array('class'=>'btn btn-default btn-sm btn-danger')); |
|
| 37 | 37 | $links = '<a href="/admin/order-status/'.$query->id.'/edit" class="btn btn-default btn-sm btn-success"><i class="entypo-pencil"></i>Edit</a> '.$deleteLink; |
| 38 | 38 | |
| 39 | 39 | return $links; |
@@ -52,7 +52,7 @@ discard block |
||
| 52 | 52 | |
| 53 | 53 | public function store(Request $request) |
| 54 | 54 | { |
| 55 | - $result = OrderStatusService::create($request->all()); |
|
| 55 | + $result = OrderStatusService::create($request->all()); |
|
| 56 | 56 | return OrderStatusService::notificationRedirect('order-status.index', $result, 'The order status was inserted.'); |
| 57 | 57 | } |
| 58 | 58 | |
@@ -73,13 +73,13 @@ discard block |
||
| 73 | 73 | |
| 74 | 74 | public function update(Request $request, $orderStatusId) |
| 75 | 75 | { |
| 76 | - $result = OrderStatusService::updateById($request->all(), $orderStatusId); |
|
| 76 | + $result = OrderStatusService::updateById($request->all(), $orderStatusId); |
|
| 77 | 77 | return OrderStatusService::notificationRedirect('order-status.index', $result, 'The order status was updated.'); |
| 78 | 78 | } |
| 79 | 79 | |
| 80 | 80 | public function destroy($orderStatusId) |
| 81 | 81 | { |
| 82 | - $result = OrderStatusService::destroy($orderStatusId); |
|
| 82 | + $result = OrderStatusService::destroy($orderStatusId); |
|
| 83 | 83 | |
| 84 | 84 | if ($result) { |
| 85 | 85 | Notification::success('The order status was deleted.'); |