@extends('backend.layouts_backend.master2') @section('title') All Products @endsection @section('content') {{-- header --}}

All Products

@if (Auth::user()->can('product-create')) @endif @if (Auth::user()->can('view-inactive-products')) @endif
{{-- end header --}}
{{-- alert add item --}} @if (session('messagesave')) {{--
{{ session('message')}}
--}} @endif {{-- alert delete item --}} @if (session('messagedelete')) {{--
{{ session('messagedelete')}}
--}} @endif {{-- alert update item --}} @if (session('messageupdate')) @endif
{{-- --}} @if (is_array($product_create_form_fields_values)) @if (in_array(4, $product_create_form_fields_values ?? '')) @endif @endif @if (is_array($product_create_form_fields_values)) @if (in_array(2, $product_create_form_fields_values ?? '')) @endif @endif @if (is_array($product_create_form_fields_values)) @if (in_array(6, $product_create_form_fields_values ?? '')) @endif @endif @foreach ($products as $key => $product) {{-- --}} @php $product_image_decoded = isset($product->product_image) ? json_decode($product->product_image) : null; $product_gallery_decoded = isset($product->product_image_gallery) ? json_decode($product->product_image_gallery) : null; @endphp @if (is_array($product_create_form_fields_values)) @if (in_array(4, $product_create_form_fields_values ?? '')) @endif @endif {{-- --}} {{-- --}} {{-- --}} {{-- --}} @if (is_array($product_create_form_fields_values)) @if (in_array(2, $product_create_form_fields_values ?? '')) @endif @endif @if (is_array($product_create_form_fields_values)) @if (in_array(6, $product_create_form_fields_values ?? '')) @endif @endif {{-- view details modal --}} {{-- end of view modal --}} @endforeach
#Id Product Code NameCategoryBranchImage StatusProduct StockStock AlertCreated By Action
{{ $key + 1 ?? 'N/A' }} {{ $product->product_code ?? 'N/A' }} {{ $product->product_name ?? 'N/A' }}{{ $product->product_category->product_category_name ?? 'N/A' }}{{ $product->branch->branch_name ?? 'N/A' }} preview {{ $product->product_image ?? 'N/A' }}{{ $product->product_image_gallery ?? 'N/A' }}{{ $product->product_cost_price ?? 'N/A' }}{{ $product->product_selling_price ?? 'N/A' }} @if ($product->product_status == '1') Active @else In Active @endif {{ $product->product_stock_quantity ?? 'N/A' }}{{ $product->product_stock_alert ?? 'N/A' }} {{ get_user_fullname_temporary($product->created_by) ?? 'N/A' }}
@if (Auth::user()->can('product-show')) @endif @if (Auth::user()->can('product-edit')) @endif @if (Auth::user()->can('product-delete'))
@csrf @method('DELETE')
@endif

@endsection