@extends('layouts.admin') @section('title', 'Item Report') @section('content-header', 'Item Report') @section('content')

{{$title}}


{{$datetitle}}

@php $i = 0; $totaloverall = 0; $totaloverallquantity = 0; $totaloveralltax = 0; $totaloverallmisc = 0; $totaloverallbranch = 0; @endphp @foreach ($oid as $branch) @php $k = 0; $b = 0; $totalmethod = 0 ; $totalcategory = 0; $totalmisc = 0; $totaltax = 0; $totaloverallitem = 0; $totalitemwithouttax = 0; $totalquantity = 0; @endphp @foreach ($method as $category) @php $rows = max($items[$i][$k]->count(), 1); $previousCno = null; $l = 0; $j = 0; $color = 'white'; @endphp @if (isset($items[$i][$k]) && count($items[$i][$k]) > 0) @foreach ($items[$i][$k] as $item) @if ($item['cno'] != $previousCno) @endif @if ($j == 0) @endif @if ($item['cno'] != $previousCno) @php $totalcategory += $categorycount[$i][$k][$l]['total']; $l++; @endphp @endif @if ($j == 0) @php $totalmethod += $overallmethod[$i][$k]['sold']; $j = 1; @endphp @endif @if ($b == 0) @php $totaloverallbranch += $overallbranch[$i]; $b = 1; @endphp @endif @php $previousCno = $item['cno']; $totalmisc += $item['misctotal']; $totaloverallitem += $item['sell_price']; $totaltax += $item['tax_amt']; $totalitemwithouttax += $item['sell_price'] - $item['misctotal'] - $item['tax_amt']; $totalquantity += $item['quantity']; @endphp @endforeach @else @endif @php $k++; @endphp @endforeach @php $i++; $totaloverall += $totalitemwithouttax; @endphp @php $totaloverallquantity += $totalquantity; $totaloveralltax += $totaltax; $totaloverallmisc += $totalmisc; @endphp @endforeach
Method Item Detail Gross Sale (RM) Total Percent by Method (%) Branch Gross Sale (RM)
Name SKUID Category Price (RM) Tax (RM) Quantity Total Item (RM) Total Tax (RM) Total Misc (RM) Overall Total Item (RM) Category Total
{{$branch['BID']}}
{{ $category }}{{ $item['sku_desc'] ?? 0 }} {{ $item['sku_id'] ?? 0 }} {{ $item['cno'] ?? 0 }} @if ($item['quantity'] != 0) {{number_format(($item['sell_price'] - $item['misctotal'] - $item['tax_amt']) / $item['quantity'],2) }} @else 0 @endif @if ($item['quantity'] != 0) {{number_format(($item['tax_amt']) / $item['quantity'],2) }} @else 0 @endif {{ $item['quantity'] ?? 0 }} {{ number_format($item['sell_price'] - $item['misctotal'] - $item['tax_amt'] ?? 0,2) }} {{ number_format($item['tax_amt'] ?? 0,2) }} {{ number_format($item['misctotal'] ?? 0,2) }} {{ number_format($item['sell_price'] ?? 0,2) }}{{number_format($categorycount[$i][$k][$l]['total'], 2)}}{{number_format($overallmethod[$i][$k]['sold'],2)}} @if ($overallbranch[$i] != 0) {{ number_format(100 * ($overallmethod[$i][$k]['sold'] / $overallbranch[$i]), 0) }} @else 0% @endif {{number_format($overallbranch[$i],2)}}
{{ $category }} - - - - - - - - - - - - -
Overall - - - - - {{$totalquantity}} {{number_format($totalitemwithouttax,2)}} {{number_format($totaltax,2)}} {{number_format($totalmisc,2)}} {{number_format($totaloverallitem,2)}} {{number_format($totalcategory,2)}} {{number_format($totalmethod,2)}} -
Overal Item (RM) {{number_format($totaloverall,2)}}
Overall Quantity {{$totaloverallquantity}}
Overall Tax (RM) {{number_format($totaloveralltax,2)}}
Overall Misc (RM) {{number_format($totaloverallmisc,2)}}
Overall Gross Sale (RM) {{number_format($totaloverallbranch,2)}}
@endsection @section('js') @endsection