From 68ed31fc392b42c2901077409c060d8fd847b111 Mon Sep 17 00:00:00 2001 From: soufiane Date: Tue, 11 Jul 2023 11:53:50 +0200 Subject: [PATCH] wip #6121 @1:00 --- .../{OrderSaved.php => OrderOperation.php} | 2 +- app/Http/Controllers/AjaxController.php | 2 +- app/Models/Order.php | 5 ++- resources/styles/components/products.styl | 20 +++++++++--- .../views/partials/product-link.blade.php | 32 +++++++++++-------- 5 files changed, 38 insertions(+), 23 deletions(-) rename app/Events/{OrderSaved.php => OrderOperation.php} (96%) diff --git a/app/Events/OrderSaved.php b/app/Events/OrderOperation.php similarity index 96% rename from app/Events/OrderSaved.php rename to app/Events/OrderOperation.php index a377159..beb17d7 100644 --- a/app/Events/OrderSaved.php +++ b/app/Events/OrderOperation.php @@ -6,7 +6,7 @@ use Illuminate\Queue\SerializesModels; use App\Models\Order; use App\Models\Client; -class OrderSaved +class OrderOperation { use SerializesModels; public function __construct(Order $order) diff --git a/app/Http/Controllers/AjaxController.php b/app/Http/Controllers/AjaxController.php index c483585..6c1c7e7 100644 --- a/app/Http/Controllers/AjaxController.php +++ b/app/Http/Controllers/AjaxController.php @@ -402,7 +402,7 @@ class AjaxController extends CubistFrontController /** * - * The following block of code format address data with good format of database [{'...','...'}] + * The following block of code format address data with good format in database [{'...','...'}] * to make it same in the database, readable and editable later in front * */ diff --git a/app/Models/Order.php b/app/Models/Order.php index dfd156d..28dee92 100644 --- a/app/Models/Order.php +++ b/app/Models/Order.php @@ -1,8 +1,7 @@ OrderSaved::class + 'saving' => OrderOperation::class ]; public function setFields() diff --git a/resources/styles/components/products.styl b/resources/styles/components/products.styl index bb16191..b18c90d 100644 --- a/resources/styles/components/products.styl +++ b/resources/styles/components/products.styl @@ -4,7 +4,7 @@ &-grid &-switch - +below(960px) + +below(1200px) display: none; margin-left: 1rem; @@ -40,11 +40,11 @@ // On the smaller screens, 270px min-width is sometimes too wide // when including the content padding so reduce it when getting close. - +below(960px) + +below(1200px) grid-template-columns: repeat(auto-fill, minmax(225px, 1fr)) &.products-grid-aslist - +above(960px) + +above(1200px) grid-gap 20px grid-template-columns: repeat(auto-fill, minmax(100%, 1fr)) @@ -94,7 +94,7 @@ white-space nowrap height auto overflow hidden - width: calc(100% - 300px) + width: calc(100% - 100px) text-overflow ellipsis .links @@ -110,6 +110,18 @@ h3 margin-bottom: 0.25em; + .product-container + display: flex + + .product-description-container + width: 40% + + .product-price-info p + margin: 0 !important + +above(1400px) + .product-description-container + width: 50% !important + .btn width 100%; padding-top 0.7rem diff --git a/resources/views/partials/product-link.blade.php b/resources/views/partials/product-link.blade.php index 8e522b5..a58550d 100644 --- a/resources/views/partials/product-link.blade.php +++ b/resources/views/partials/product-link.blade.php @@ -24,20 +24,24 @@ There shoulln't be any space between closing of a and opening of div {{-- Product details --}} -->
-

{{ $product->get('reference') }} -

-
- {{$product->get('name')}} -
-
- @if($product->basic_selling_price && $product->json) - @php($options = true) -

{{ __('Produit configurable') }}

-

{{ __('A partir de :').' '. $price }}€ HT

- @elseif($product->basic_selling_price && !$product->json) -

{{ __('Prix catalogue :').' '.$product->basic_selling_price }}€ HT

-

{{ __('Votre prix :').' '. $price }}€ HT

- @endif +
+
+

{{ $product->get('reference') }} +

+
+ {{$product->get('name')}} +
+
+
+ @if($product->basic_selling_price && $product->json) + @php($options = true) +

{{ __('Produit configurable') }}

+

{{ __('A partir de :').' '. $price }}€ HT

+ @elseif($product->basic_selling_price && !$product->json) +

{{ __('Prix catalogue :').' '.$product->basic_selling_price }}€ HT

+

{{ __('Votre prix :').' '. $price }}€ HT

+ @endif +
@if(config('features.quote')) -- 2.39.5