add watermark on zoom, update display of article nature on shelve (change icon to text
This commit is contained in:
@@ -1,26 +1,41 @@
|
||||
@foreach ($article_natures as $nature)
|
||||
<div class="btn products" data-id="{{ $nature }}">
|
||||
@if ($article_nature == $nature)
|
||||
<img src="{{ App\Repositories\Shop\ArticleNatures::getIconBySlug($nature, 'normal', 'icon_selection') }}">
|
||||
@else
|
||||
<img src="{{ App\Repositories\Shop\ArticleNatures::getIconBySlug($nature, 'normal', 'icon') }}">
|
||||
@endif
|
||||
</div>
|
||||
<div class="btn products" data-id="{{ $nature }}">
|
||||
@if ($article_nature == $nature)
|
||||
@php
|
||||
$iconType = 'icon_selection';
|
||||
$iconClass = 'badge-success';
|
||||
@endphp
|
||||
@else
|
||||
@php
|
||||
$iconType = 'icon';
|
||||
$iconClass = 'badge-secondary';
|
||||
@endphp
|
||||
@endif
|
||||
|
||||
@php
|
||||
$icon = App\Repositories\Shop\ArticleNatures::getIconBySlug($nature, 'normal', $iconType);
|
||||
@endphp
|
||||
@if ($icon)
|
||||
<img src="{{ $icon }}" alt="{{ $nature }}">
|
||||
@else
|
||||
<span class="badge {{ $iconClass }}" style="font-size: 1.2em;">{{ $nature }}</span>
|
||||
@endif
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
@push('js')
|
||||
<script>
|
||||
$('#by_rows').click(function() {
|
||||
$('#display_by_rows').val(1);
|
||||
$('#category-form').submit();
|
||||
});
|
||||
$('#by_cards').click(function() {
|
||||
$('#display_by_rows').val(0);
|
||||
$('#category-form').submit();
|
||||
});
|
||||
$('.products').click(function() {
|
||||
$('#article_nature').val($(this).data('id'));
|
||||
$('#category-form').submit();
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
<script>
|
||||
$('#by_rows').click(function() {
|
||||
$('#display_by_rows').val(1);
|
||||
$('#category-form').submit();
|
||||
});
|
||||
$('#by_cards').click(function() {
|
||||
$('#display_by_rows').val(0);
|
||||
$('#category-form').submit();
|
||||
});
|
||||
$('.products').click(function() {
|
||||
$('#article_nature').val($(this).data('id'));
|
||||
$('#category-form').submit();
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@@ -1,20 +1,20 @@
|
||||
<div class="sp-loading"><img src="images/sp-loading.gif" alt=""><br>LOADING IMAGES</div>
|
||||
<div class="sp-wrap" style="width: 100%;">
|
||||
@if ($images)
|
||||
@foreach ($images as $image)
|
||||
<a href="{{ App\Repositories\Core\Images::getImageSrc($image) }}">
|
||||
<img src="{{ App\Repositories\Core\Images::getNormalSrc($image) }}" class="img-fluid">
|
||||
</a>
|
||||
@endforeach
|
||||
@else
|
||||
<img src="{{ $image }}" class="img-fluid">
|
||||
@endif
|
||||
@if ($images)
|
||||
@foreach ($images as $image)
|
||||
<a href="{{ App\Repositories\Shop\Articles::getZoomSrc($image) }}">
|
||||
<img src="{{ App\Repositories\Core\Images::getNormalSrc($image) }}" class="img-fluid">
|
||||
</a>
|
||||
@endforeach
|
||||
@else
|
||||
<img src="{{ $image }}" class="img-fluid">
|
||||
@endif
|
||||
</div>
|
||||
|
||||
@push('js')
|
||||
<script>
|
||||
$(window).load(function() {
|
||||
$('.sp-wrap').smoothproducts();
|
||||
});
|
||||
</script>
|
||||
<script>
|
||||
$(window).load(function() {
|
||||
$('.sp-wrap').smoothproducts();
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
Reference in New Issue
Block a user