Tanggal : {{$tanggal}}
@php $faktur = $data->original; $jsonencode = json_encode($faktur); @endphp @if(count($faktur) > 0) @php for ($i=0; $i < count($faktur[0]->transaction_details); $i++) { $details = $faktur[0]->transaction_details[$i]; $itemlist [] = $faktur[0]->transaction_details[$i]->item; } $tanggal = date('d/m/Y',strtotime($faktur[0]->created_at)); @endphp @php $jenis = $faktur[0]->is_paid; $total = $faktur[0]->total; $discount = $faktur[0]->discount; if ($discount > 100) { $discountshow =number_format($discount,0,',','.'); $totalall = $total - $discount; }else { $discountshow = $discount . " %"; $totalall = $total - ($total * $discount/100); } $hasil_rupiah =number_format($totalall,0,',','.'); if ($jenis) { $trans = "Cash"; }else { $trans = "Credit"; } $hargabarang = $details->custom_price; $qty = $details->qty; $discountitem = $details->discount; if ($discountitem > 100) { $discountitemshow =number_format($discountitem,0,',','.'); $hargatotal = ($hargabarang * $qty) - $discountitem; }else { $discountitemshow = $discountitem . " % "; $hargatotal = ($hargabarang * $qty) - ($hargabarang * $discountitem/100); } $hasil_rupiahshow =number_format($hargatotal,0,',','.'); $totalshow =number_format($total,0,',','.'); @endphp|
No Faktur : {{$id}}
Sales : {{$faktur[0]->salesman->name}} Tanggal Penjualan : {{$tanggal}} Pelanggan : {{$faktur[0]->customer->name}} |
Tipe Pembayaran : {{$faktur[0]->ispaid ? "Cash" : "Credit"}} |
|||||
| No | Barcode | Nama Barang | Harga Barang | Qty | Total | |
|---|---|---|---|---|---|---|
| {{$i}} | {{$item->code}} | {{$item->name}} | {{number_format($item->price,0,',','.')}} | {{$details->qty}} | {{$hasil_rupiahshow}} | |
| Grand Total : | {{$hasil_rupiah}} | |||||
Kosong
@endifDicetak Pada : {{date('d/m/Y')}}