fix layout

This commit is contained in:
Ludovic CANDELLIER
2022-12-21 18:33:15 +01:00
parent 9895266798
commit ae39681cb0
16 changed files with 164 additions and 135 deletions

View File

@@ -0,0 +1,9 @@
<h1 style="font-size: 1.5em;">
@foreach($breadcrumb ?? [] as $parent)
<a href="{{ route('Shop.Categories.show', ['id' => $parent['id']]) }}" style="text-decoration: none; color: inherit;">{{ $parent['name'] }}</a> /
@endforeach
<span style="font-size: 1.4em;">
{{ $category['name'] }}
</span>
</h1>
<h3 style="font-size: 1.2em;">{!! $category['description'] !!}</h3>

View File

@@ -1,31 +1,15 @@
<div class="row">
<div class="col-12 text-right">
@if ($display_by_rows ?? false)
@include('components.form.button', [
'id' => 'by_cards',
'icon' => 'fa-th',
'class' => 'btn-secondary',
'title' => 'Vue par vignettes',
])
@else
@include('components.form.button', [
'id' => 'by_rows',
'icon' => 'fa-list',
'class' => 'btn-secondary',
'title' => 'Vue par lignes',
])
@endif
@include('components.form.button', [
'data_id' => 'botanic',
'data_id' => 'semences',
'icon' => 'fa-leaf',
'class' => 'products bg-yellow yellow-dark',
'class' => 'products bg-yellow yellow-dark' . (($article_nature == 'semences') ? ' d-none' : ''),
'title' => 'Par semences',
])
@include('components.form.button', [
'data_id' => 'merchandise',
'data_id' => 'plants',
'icon' => 'fa-seedling',
'class' => 'products bg-green text-white',
'class' => 'products bg-green text-white' . (($article_nature == 'plants') ? ' d-none' : ''),
'title' => 'Par plants',
])
@@ -43,7 +27,7 @@
$('#category-form').submit();
});
$('.products').click(function() {
$('#product_type').val($(this).data('id'));
$('#article_nature').val($(this).data('id'));
$('#category-form').submit();
});
</script>

View File

@@ -2,9 +2,9 @@
@if ($articles ?? false)
@foreach ($articles as $product_name => $article)
@if ((($product_type == 'botanic') && (($article['semences'] ?? false) || ($article['plants'] ?? false))) || (($product_type == 'merchandise') &&($article['mercchandises'] ?? false)))
<div class="col-3 mb-3">
@include('Shop.Articles.partials.article')
</div>
<div class="col-3 mb-3">
@include('Shop.Articles.partials.article')
</div>
@endif
@endforeach
@endif