mirror of
https://github.com/grocy/grocy.git
synced 2025-04-29 17:45:39 +00:00
Disable opening of tare weight handling enabled products also on the stock entries page (same as for the stock overview page, references #988)
This commit is contained in:
parent
80cf68aeaa
commit
196d304de6
@ -54,7 +54,9 @@
|
|||||||
<tbody class="d-none">
|
<tbody class="d-none">
|
||||||
@foreach($stockEntries as $stockEntry)
|
@foreach($stockEntries as $stockEntry)
|
||||||
<tr id="stock-{{ $stockEntry->id }}-row"
|
<tr id="stock-{{ $stockEntry->id }}-row"
|
||||||
class="@if(GROCY_FEATURE_FLAG_STOCK_BEST_BEFORE_DATE_TRACKING && $stockEntry->best_before_date < date('Y-m-d 23:59:59', strtotime('-1 days')) && $stockEntry->amount > 0) table-danger @elseif(GROCY_FEATURE_FLAG_STOCK_BEST_BEFORE_DATE_TRACKING && $stockEntry->best_before_date < date('Y-m-d 23:59:59', strtotime("+$nextXDays days"))
|
class="@if(GROCY_FEATURE_FLAG_STOCK_BEST_BEFORE_DATE_TRACKING && $stockEntry->best_before_date < date('Y-m-d 23:59:59', strtotime('-1 days')) && $stockEntry->amount > 0) table-danger @elseif(GROCY_FEATURE_FLAG_STOCK_BEST_BEFORE_DATE_TRACKING && $stockEntry->best_before_date < date('Y-m-d 23:59:59', strtotime("
|
||||||
|
+$nextXDays
|
||||||
|
days"))
|
||||||
&&
|
&&
|
||||||
$stockEntry->amount > 0) table-warning @endif">
|
$stockEntry->amount > 0) table-warning @endif">
|
||||||
<td class="fit-content border-right">
|
<td class="fit-content border-right">
|
||||||
@ -73,7 +75,7 @@
|
|||||||
<i class="fas fa-utensils"></i>
|
<i class="fas fa-utensils"></i>
|
||||||
</a>
|
</a>
|
||||||
@if(GROCY_FEATURE_FLAG_STOCK_PRODUCT_OPENED_TRACKING)
|
@if(GROCY_FEATURE_FLAG_STOCK_PRODUCT_OPENED_TRACKING)
|
||||||
<a class="btn btn-success btn-sm product-open-button @if($stockEntry->open == 1) disabled @endif"
|
<a class="btn btn-success btn-sm product-open-button @if($stockEntry->open == 1 || FindObjectInArrayByPropertyValue($products, 'id', $stockEntry->product_id)->enable_tare_weight_handling == 1) disabled @endif"
|
||||||
href="#"
|
href="#"
|
||||||
data-toggle="tooltip"
|
data-toggle="tooltip"
|
||||||
data-placement="left"
|
data-placement="left"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user