@extends('layouts.print') @section('title', 'Cetak Laporan Penjualan') @section('doc-title', 'Laporan Penjualan') @section('doc-subtitle', 'Periode: ' . \Carbon\Carbon::parse($from)->locale('id')->isoFormat('D MMMM Y') . ' – ' . \Carbon\Carbon::parse($to)->locale('id')->isoFormat('D MMMM Y') ) @section('content') {{-- Summary Cards --}}
| # | Produk | Total Qty Terjual | Total Nilai | % Kontribusi |
|---|---|---|---|---|
| {{ $i + 1 }} | {{ $r['barang'] }} | {{ number_format($r['total_qty']) }} | Rp {{ number_format($r['total_nilai'], 0, ',', '.') }} | {{ $total > 0 ? number_format(($r['total_nilai'] / $total) * 100, 1) : 0 }}% |
| # | Tanggal | Produk | Pembeli | Qty | Harga/Satuan | Total |
|---|---|---|---|---|---|---|
| {{ $i + 1 }} | {{ $p->tanggal->format('d M Y') }} | {{ $p->barang->name ?? '-' }} | {{ $p->pembeli ?? '—' }} | {{ $p->qty }} | Rp {{ number_format($p->harga_satuan, 0, ',', '.') }} | Rp {{ number_format($p->total_harga, 0, ',', '.') }} |
| Tidak ada data penjualan pada periode ini. | ||||||
| TOTAL PENDAPATAN | Rp {{ number_format($total, 0, ',', '.') }} | |||||