@extends('layouts.app') @section('content')

Close Register

Review sales and finalize your session for {{ auth()->user()->name }}

Opening Cash
MWK {{ number_format($register->opening_cash, 2) }}
Started at {{ $register->opened_at->format('H:i') }}
Total Sales
MWK {{ number_format($totals['total_sales'], 2) }}
{{ $counts['count_total_sales'] ?? 0 }} Transactions
Time Open
{{ (int)$register->opened_at->diffInHours(now()) }}h {{ (int)($register->opened_at->diffInMinutes(now()) % 60) }}m
{{ $register->opened_at->format('d M Y') }}
Sales Breakdown
@php $methods = [ ['key' => 'cash', 'label' => 'Cash', 'icon' => 'bi-cash-stack', 'color' => 'text-success'], ['key' => 'card', 'label' => 'Card', 'icon' => 'bi-credit-card', 'color' => 'text-primary'], ['key' => 'airtel_money', 'label' => 'Airtel Money', 'icon' => 'bi-phone', 'color' => 'text-danger'], ['key' => 'mpamba', 'label' => 'TNM Mpamba', 'icon' => 'bi-phone-fill', 'color' => 'text-success'], ['key' => 'bank_transfer', 'label' => 'Bank Transfer', 'icon' => 'bi-bank', 'color' => 'text-info'], ['key' => 'standard_bank', 'label' => 'Standard Bank', 'icon' => 'bi-building', 'color' => 'text-primary'], ['key' => 'national_bank', 'label' => 'National Bank', 'icon' => 'bi-building-fill', 'color' => 'text-primary'], ['key' => 'cheques', 'label' => 'Cheques', 'icon' => 'bi-file-earmark-check', 'color' => 'text-secondary'], ['key' => 'advance', 'label' => 'Advance', 'icon' => 'bi-hourglass-split', 'color' => 'text-warning'], ['key' => 'cash_and_card', 'label' => 'Split Payment', 'icon' => 'bi-intersect', 'color' => 'text-dark'], ]; @endphp @foreach($methods as $method) @if(($counts['count_'.$method['key']] ?? 0) > 0) @endif @endforeach @if(($counts['count_total_sales'] ?? 0) == 0) @endif
Method Count Total
{{ $method['label'] }}
{{ $counts['count_'.$method['key']] }} MWK {{ number_format($totals['total_'.$method['key']], 2) }}
No sales recorded for this session.
Expected Balance
Opening Cash MWK {{ number_format($register->opening_cash, 2) }}
Cash Sales Only MWK {{ number_format($totals['total_cash'] ?? 0, 2) }}
Expected in Drawer MWK {{ number_format(($totals['total_cash'] ?? 0) + $register->opening_cash, 2) }}
Confirm the amount in your drawer matches the expected total before closing.
Back to POS
@if(isset($settings['logo'])) @endif

{{ $settings['system_name'] ?? 'REGISTER SUMMARY' }}

Z-REPORT
Cashier: {{ auth()->user()->name ?? 'Unknown' }}
Register ID: #{{ $register->id }}
Time Opened:
{{ $register->opened_at->format('d M Y, H:i') }}
Time Closed:
{{ now()->format('d M Y, H:i') }}
OPENING CASH: MWK {{ number_format($register->opening_cash, 2) }}
PAYMENT METHODS USED
@foreach($methods as $method) @if(($counts['count_'.$method['key']] ?? 0) > 0) @endif @endforeach @if(($counts['count_total_sales'] ?? 0) == 0) @endif
Method Count Total
{{ $method['label'] }} {{ $counts['count_'.$method['key']] }} {{ number_format($totals['total_'.$method['key']], 2) }}
No sales recorded
TOTAL SALES: MWK {{ number_format($totals['total_sales'], 2) }}
TOTAL IN DRAWER: MWK {{ number_format(($totals['total_cash'] ?? 0) + $register->opening_cash, 2) }}
(Opening Cash + Cash Sales)

*** END OF REPORT ***

@endsection