fixes
This commit is contained in:
@@ -18,7 +18,7 @@ class BasketController extends Controller
|
|||||||
$offer_id = $request->input('offer_id');
|
$offer_id = $request->input('offer_id');
|
||||||
$quantity = $request->input('quantity');
|
$quantity = $request->input('quantity');
|
||||||
$price = Offers::getPrice($offer_id, $quantity)->price_taxed;
|
$price = Offers::getPrice($offer_id, $quantity)->price_taxed;
|
||||||
return $quantity * $price;
|
return number_format($quantity * $price, 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function addBasket(Request $request)
|
public function addBasket(Request $request)
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ class Offers
|
|||||||
{
|
{
|
||||||
$sale_channel_id = $sale_channel_id ? $sale_channel_id : SaleChannels::getDefaultID();
|
$sale_channel_id = $sale_channel_id ? $sale_channel_id : SaleChannels::getDefaultID();
|
||||||
$offer = Offer::withPriceBySaleChannelByQuantity($sale_channel_id, $quantity)->find($id);
|
$offer = Offer::withPriceBySaleChannelByQuantity($sale_channel_id, $quantity)->find($id);
|
||||||
return $offer->price_lists->first()->price_list_values->first();
|
return number_format($offer->price_lists->first()->price_list_values->first(),2);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function getBasket()
|
public static function getBasket()
|
||||||
|
|||||||
@@ -34,6 +34,7 @@
|
|||||||
Tarif appliqué
|
Tarif appliqué
|
||||||
</div>
|
</div>
|
||||||
<div class="col-6">
|
<div class="col-6">
|
||||||
|
{{ $sale_channel['name'] ?? '' }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row m-3">
|
<div class="row m-3">
|
||||||
@@ -61,6 +62,11 @@
|
|||||||
<span id="basket-total-shipped"></span> €
|
<span id="basket-total-shipped"></span> €
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="row m-3">
|
||||||
|
<div class="col-12 text-center">
|
||||||
|
<a href="" class="btn btn-green-dark">COMMANDER</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
@endcomponent
|
@endcomponent
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -27,10 +27,13 @@
|
|||||||
</section>
|
</section>
|
||||||
</aside>
|
</aside>
|
||||||
|
|
||||||
|
@include('load.layout.chevron')
|
||||||
|
|
||||||
@push('js')
|
@push('js')
|
||||||
<script>
|
<script>
|
||||||
$('#filters').click(function() {
|
$('#filters').click(function() {
|
||||||
$('#sidebar').toggleClass('d-none');
|
$('#sidebar').toggleClass('d-none');
|
||||||
})
|
})
|
||||||
|
initChevron();
|
||||||
</script>
|
</script>
|
||||||
@endpush
|
@endpush
|
||||||
@@ -16,7 +16,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col mb-4">
|
<div class="col mb-4">
|
||||||
@for ($i = round(count($category['children']) / 3); $i < round(2 * count($category['children']) / 3); $i++)
|
@for ($i = round(count($category['children']) / 3); $i < round(2 * count($category['children']) / 3); $i++)
|
||||||
<strong>{{ $category['children'][$i]['name'] }}</strong><br>
|
<strong>
|
||||||
|
<a class="green-dark" href="{{ route('Shop.Categories.show', ['id' => $category['children'][$i]['id']]) }}">
|
||||||
|
{{ $category['children'][$i]['name'] }}
|
||||||
|
</a>
|
||||||
|
</strong><br>
|
||||||
@foreach ($category['children'][$i]['children'] ?? [] as $leaf)
|
@foreach ($category['children'][$i]['children'] ?? [] as $leaf)
|
||||||
<a class="green-dark" href="{{ route('Shop.Categories.show', ['id' => $leaf['id']]) }}">
|
<a class="green-dark" href="{{ route('Shop.Categories.show', ['id' => $leaf['id']]) }}">
|
||||||
{{ $leaf['name'] }}
|
{{ $leaf['name'] }}
|
||||||
@@ -26,7 +30,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col mb-4">
|
<div class="col mb-4">
|
||||||
@for ($i = round(2 * count($category['children']) / 3); $i < count($category['children']); $i++)
|
@for ($i = round(2 * count($category['children']) / 3); $i < count($category['children']); $i++)
|
||||||
<strong>{{ $category['children'][$i]['name'] }}</strong><br>
|
<strong>
|
||||||
|
<a class="green-dark" href="{{ route('Shop.Categories.show', ['id' => $category['children'][$i]['id']]) }}">
|
||||||
|
{{ $category['children'][$i]['name'] }}
|
||||||
|
</a>
|
||||||
|
</strong><br>
|
||||||
@foreach ($category['children'][$i]['children'] ?? [] as $leaf)
|
@foreach ($category['children'][$i]['children'] ?? [] as $leaf)
|
||||||
<a class="green-dark" href="{{ route('Shop.Categories.show', ['id' => $leaf['id']]) }}">
|
<a class="green-dark" href="{{ route('Shop.Categories.show', ['id' => $leaf['id']]) }}">
|
||||||
{{ $leaf['name'] }}
|
{{ $leaf['name'] }}
|
||||||
|
|||||||
Reference in New Issue
Block a user