Skip to content

Commit

Permalink
[FIX] Attributes.
Browse files Browse the repository at this point in the history
  • Loading branch information
Seiger committed Nov 21, 2024
1 parent c38ada2 commit 3107ed8
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 7 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@ of Evolution CMS for seamless and efficient **online commerce**.
- [ ] Automated Email Marketing.
- [x] Plugin events.
- [x] sCommerceManagerAddTabEvent.
- [x] sCommerceFormFieldRender.
- [x] sCommerceAfterProductSave.
- [x] sCommerceAfterProductContentSave.
- [x] sCommerceAfterProductDuplicate.
- [x] Multi-currency Support (ISO 4217).
- [ ] Integration with Payment Systems.
Expand Down
2 changes: 2 additions & 0 deletions docs/pages/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@ of Evolution CMS for seamless and efficient **online commerce**.
- [ ] Automated Email Marketing.
- [x] Plugin events.
- [x] sCommerceManagerAddTabEvent.
- [x] sCommerceFormFieldRender.
- [x] sCommerceAfterProductSave.
- [x] sCommerceAfterProductContentSave.
- [x] sCommerceAfterProductDuplicate.
- [x] Multi-currency Support (ISO 4217).
- [ ] Integration with Payment Systems.
Expand Down
2 changes: 1 addition & 1 deletion views/attrvaluesTab.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
@push('scripts.bot')
<div id="actions">
<div class="btn-group">
<a id="Button5" class="btn btn-secondary" href="{!!$moduleUrl!!}">
<a id="Button5" class="btn btn-secondary" href="{!!$moduleUrl!!}&get=attributes">
<i class="fa fa-times-circle"></i><span>@lang('sCommerce::global.to_list_attributes')</span>
</a>
<a id="Button2" class="btn btn-primary" href="javascript:void(0);" onclick="addItem();">
Expand Down
2 changes: 1 addition & 1 deletion views/partials/attributeMultiselect.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<input type="hidden" name="{{$prefix}}{{$attribute->id}}" value="">
<div class="input-group-prepend"><span class="input-group-text"><small>@lang('sCommerce::global.type_attr_multiselect')</small></span></div>
<select id="{{$prefix}}{{$attribute->id}}" class="form-control select2" name="{{$prefix}}{{$attribute->id}}[]" multiple onchange="documentDirty=true;">
@foreach($options as $option)
@foreach(($options ?? []) as $option)
<option value="{{$option}}" @if(in_array($option, $value)) selected @endif>{{$option}}</option>
@endforeach
</select>
Expand Down
4 changes: 2 additions & 2 deletions views/productTab.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
</div>
</div>
</div>
@if(sCommerce::config('product.show_field_availability', 1) == 1)
@if(sCommerce::config('product.show_field_availability', 1))
<div class="row-col col-lg-3 col-md-6 col-12">
<div class="row form-row">
<div class="col-auto col-title">
Expand Down Expand Up @@ -136,7 +136,7 @@
</div>
</div>
@endif
@if(sCommerce::config('product.quantity_on', 1) == 2)&emsp;
@if(sCommerce::config('product.quantity_on', 1) == 2)
<div class="row-col col-lg-3 col-md-6 col-12">
<div class="row form-row">
<div class="col-auto col-title">
Expand Down
7 changes: 4 additions & 3 deletions views/productsTab.blade.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
@php
use Seiger\sCommerce\Models\sProduct;
$order = request()->has('order') ? request()->input('order') : 'id';
if (evo()->getConfig('check_sMultisite', false)) {
$domains = \Seiger\sMultisite\Models\sMultisite::all();
Expand Down Expand Up @@ -78,7 +79,7 @@ class="form-control rounded-left scom-input seiger__search"
<button class="seiger-sort-btn" style="padding:0;displai: inline;border: none;background: transparent;">@lang('sCommerce::global.quantity') <i class="fas fa-sort" style="color: #036efe;"></i></button>
</th>
@endif
@if (sCommerce::config('products.show_field_availability', 1) == 1)
@if (sCommerce::config('products.show_field_availability', 1) && sCommerce::config('product.show_field_availability', 1))
<th class="sorting @if($order == 'availability') sorted @endif" data-order="availability">
<button class="seiger-sort-btn" style="padding:0;displai: inline;border: none;background: transparent;">@lang('sCommerce::global.availability') <i class="fas fa-sort" style="color: #036efe;"></i></button>
</th>
Expand Down Expand Up @@ -158,8 +159,8 @@ class="form-control rounded-left scom-input seiger__search"
@if (sCommerce::config('products.show_field_quantity', 1) && sCommerce::config('product.quantity_on', 1))
<td>{{$item->quantity}}</td>
@endif
@if (sCommerce::config('products.show_field_availability', 1) == 1)
<td>{{$item->availability}}</td>
@if (sCommerce::config('products.show_field_availability', 1) && sCommerce::config('product.show_field_availability', 1))
<td>{{sProduct::listAvailability()[$item->availability]}}</td>
@endif
@if (sCommerce::config('products.show_field_category', 1) == 1)
<td>
Expand Down

0 comments on commit 3107ed8

Please sign in to comment.