@php
use Illuminate\Support\Facades\DB;
$monthWise = [];
$target_target_arr = [];
$netsale_target_arr = [];
$achvment_target_arr = [];
$gawt_target = 0;
$gdt_target = 0;
$gdt_cus_target = 0;
error_reporting(0);
@endphp
|
Per Capita Consumption Report
|
| Start Month: |
{{date('M-Y',strtotime($start_date))}} |
End Month: |
{{date('M-Y',strtotime($end_date))}} |
| City/Town |
Province Name |
City/Town Tier |
Population |
@foreach($months as $month)
{{date('M-Y',strtotime($month.'-01'))}} |
@endforeach
{{-- Overall | --}}
@foreach($months as $month)
| Net Sales (CTNs) |
Net Sales (PCs) |
Per Capita Cons. |
@endforeach
{{--
Per Capita Cons. |
Net Sales |
--}}
@foreach($cities as $city)
@php
$city_arr =collect($data)->where('city_id', $city->id)->all();
$row = collect($city_arr)->first();
@endphp
| {{$row->city_name}} |
{{$row->province_name}} |
{{$row->tier_name}} |
{{$row->population}} |
@foreach($months as $month)
@php
$month_wise =collect($city_arr)->where('date', $month)->first();
@endphp
{{$month_wise->net_sale}} |
{{$month_wise->total_pieces}} |
{{number_format($month_wise->per_capita,2)}} |
@endforeach
@endforeach