@extends('layouts.app') @section('content') @php $changeAmount = (float) ($order->change_amount ?? 0); /* * Kadang kembalian muncul Rp 1 karena pembulatan/perhitungan decimal. * Untuk kasus transaksi percetakan, selisih 0-1 rupiah dianggap 0. */ if ($changeAmount <= 1) { $changeAmount = 0; } $invoicePrintRouteExists = \Illuminate\Support\Facades\Route::has('orders.invoice-print'); $printNotaRouteExists = \Illuminate\Support\Facades\Route::has('print.nota'); $printFakturRouteExists = \Illuminate\Support\Facades\Route::has('print.faktur'); @endphp @if(session('success'))
{{ session('success') }}
@endif @if(session('error'))
{{ session('error') }}
@endif

Pembayaran Berhasil

Transaksi berhasil diproses. Silakan cetak nota sesuai ukuran yang dibutuhkan.

LUNAS
No. Invoice
{{ $order->invoice_number }}
Pelanggan
{{ $order->customer_name }}
File
{{ $order->file_name ?: '-' }}
@if(($order->use_ppn ?? false) || (($order->ppn_amount ?? 0) > 0))
Subtotal
Rp {{ number_format($order->subtotal_before_ppn ?: (($order->total_price ?? 0) - ($order->ppn_amount ?? 0)), 0, ',', '.') }}
PPN {{ rtrim(rtrim(number_format((float) ($order->ppn_rate ?? 0), 2, ',', '.'), '0'), ',') }}%
Rp {{ number_format($order->ppn_amount ?? 0, 0, ',', '.') }}
@endif
Total
Rp {{ number_format($order->total_price, 0, ',', '.') }}
Dibayar
Rp {{ number_format($order->paid_amount, 0, ',', '.') }}
Kembalian
Rp {{ number_format($changeAmount, 0, ',', '.') }}

Kasir
{{ $order->cashier->name ?? '-' }}
Waktu
{{ optional($order->paid_at)->format('d M Y H:i') ?: now()->format('d M Y H:i') }}

Cetak Nota / Invoice

Pilih ukuran cetak sesuai kebutuhan pelanggan.

@if($printNotaRouteExists) Cetak POS 80mm @endif @if($invoicePrintRouteExists) Cetak A4 Cetak A5 Cetak 21,5 × 16,5 @else @if($printFakturRouteExists) Cetak Faktur A5 @endif @endif
@endsection