@foreach ($transaksis as $transaksi)
{{-- Logo --}}

JATIM HARDWARE

SURABAYA
Telepon: 08123423985

LAPORAN LABA(RUGI) CUSTOMER

{{-- @if ($nama_customer)

Customer {{ $nama_customer }}

@endif @if ($filter_type == 'tanggal')

Periode Tanggal {{ \Carbon\Carbon::parse($tanggal_awal)->translatedFormat('d F Y') . ' - ' . \Carbon\Carbon::parse($tanggal_akhir)->translatedFormat('d F Y') }}

@elseif($filter_type == 'bulan')

Bulan {{ \Carbon\Carbon::createFromFormat('!m', $bulan)->translatedFormat('F') }} Tahun {{ $tahun }}

@else

Tahun {{ $tahun }}

@endif --}}

No Faktur

: {{ $transaksi->no_faktur }}

Nama Pelanggan

: {{ $transaksi->customer->nama }}

Alamat Pelanggan

: {{ $transaksi->customer->alamat . ' - ' . $transaksi->customer->kota->nama }}

Tanggal

: {{ $transaksi->tanggal_faktur }}

Sales

: {{ $transaksi->customer->sales->nama }}
@php $total_harga_jual = 0; $total_hpp = 0; $total_margin = 0; $total_laba_rugi = 0; @endphp @foreach ($transaksi->barangTransaksis as $item) @php $margin = $item->harga_jual - $item->hpp; $sub_total = $margin * $item->jumlah; @endphp @php $total_harga_jual += $item->harga_jual * $item->jumlah; $total_hpp += $item->hpp * $item->jumlah; $total_margin += $margin * $item->jumlah; $total_laba_rugi += $sub_total; @endphp @endforeach
No Nama Barang Jumlah Harga Jual Harga Modal Margin L/R
{{ $loop->iteration }} {{ $item->barang->nama }} {{ $item->jumlah }} Rp {{ number_format($item->harga_jual, 0, ',', '.') }} Rp {{ number_format($item->hpp, 0, ',', '.') }} Rp {{ number_format($margin, 0, ',', '.') }}
Total Rp {{ number_format($total_harga_jual, 0, ',', '.') }} Rp {{ number_format($total_hpp, 0, ',', '.') }} Rp {{ number_format($total_laba_rugi, 0, ',', '.') }}
@if (!$loop->last)
@endif @endforeach

Surabaya, 19 Maret 2025
Penanggung Jawab

AAN HARYONO

{{-- Laporan Laba Rugi

Laporan Laba Rugi

@foreach ($transaksis as $tran)
No Faktur {{ $tran->no_faktur }} Tanggal {{ date('d-m-Y', strtotime($tran->tanggal_faktur)) }}
Customer {{ $tran->customer->nama ?? 'N/A' }} Total Margin Rp {{ number_format($tran->total_harga_margin, 0, ',', '.') }}
@foreach ($tran->barangTransaksis as $item) @endforeach
No Nama Barang Qty Harga Jual HPP Margin Total Margin
{{ $loop->iteration }} {{ $item->barang->nama }} {{ $item->jumlah }} Rp {{ number_format($item->harga_jual, 0, ',', '.') }} Rp {{ number_format($item->hpp, 0, ',', '.') }} Rp {{ number_format($item->harga_jual - $item->hpp, 0, ',', '.') }} Rp {{ number_format(($item->harga_jual - $item->hpp) * $item->jumlah, 0, ',', '.') }}
@if (!$loop->last)
@endif @endforeach

Dicetak pada:
{{ \Carbon\Carbon::now()->translatedFormat('d F Y H:i:s') }}

Hormat Kami,




CV. BIGTOOL SUKSES SEJAHTERA

--}}