@if(session()->has('success'))
{{ session()->get('success') }}
@endif
@if(session()->has('error'))
{{ session()->get('error') }}
@endif
{!! $sl=null !!}
@foreach($data AS $value)
| {!! ++$sl !!} |
{!! $value->name !!} |
{!! $value->code !!} |
{{ $value->brandObj ? $value->brandObj->title : '' }} |
@if(isset($value->category)){!! $value->category->name !!}@endif |
{{-- Warranty status fixed (Checking 1 instead of yes) --}}
@if($value->warranty_status == 1)
Yes
@else
No
@endif
|
{!! $value->product_cost !!} |
{!! $value->retail_price !!} |
{!! $value->wholesale_price !!} |
@php $totalQty = 0; @endphp
@if(isset($value->stock_qty))
@foreach($value->stock_qty as $qty)
@php $totalQty += $qty->quantity; @endphp
@endforeach
@endif
{{-- Stock Alert Logic --}}
{{ $totalQty }}
|
@if(auth()->user()->role_id == 1)
@endif
|
@endforeach