@extends('layouts.app') @section('content') @php($base = array_merge(['type'=>'profit'], request()->query()))

{{ __('app.profit_report') }}

{{ __('app.profit_report_hint') }}

CSVExcel{{ __('app.print') }}
{{ __('app.income') }}{{ number_format($summary['income'],2) }}
{{ __('app.cost') }}{{ number_format($summary['cost'],2) }}
{{ __('app.gross_profit') }}{{ number_format($summary['gross_profit'],2) }}
{{ __('app.expenses') }}{{ number_format($summary['expenses'],2) }}
{{ __('app.net_profit') }}{{ number_format($summary['net_profit'],2) }}
@forelse($rows as $r)@empty@endforelse
{{ __('app.invoice') }}{{ __('app.date') }}{{ __('app.mobile') }}IMEI{{ __('app.cost') }}{{ __('app.sale_price') }}{{ __('app.profit') }}
{{ $r->invoice_no }}{{ \Illuminate\Support\Carbon::parse($r->sale_date)->format('Y-m-d') }}{{ $r->brand }} {{ $r->model }}{{ $r->imei_1 }}{{ number_format($r->total_cost,2) }}{{ number_format($r->sale_total,2) }}{{ number_format($r->profit,2) }}
{{ __('app.no_records') }}
{{ $rows->links() }} @endsection