@php use App\Models\Setting; use App\Support\AddressFormatter; use App\Support\AmountInWords; $company = [ 'name' => Setting::get('company_name', config('app.name')), 'address' => Setting::get('company_address', ''), 'owner' => Setting::get('company_owner', ''), 'pincode' => Setting::get('company_pincode', ''), 'phone' => Setting::get('company_phone', ''), 'email' => Setting::get('company_email', ''), 'gstin' => Setting::get('company_gstin', ''), 'state' => Setting::get('company_state', ''), 'state_code' => Setting::get('company_state_code', ''), ]; $companyAddress = collect([ $company['owner'] ? "({$company['owner']})" : null, AddressFormatter::flow($company['address']), ])->filter()->implode(', '); if ($company['pincode']) { $companyAddress = trim($companyAddress.' - '.$company['pincode'], ' -'); } $customerAddress = AddressFormatter::flow($saleReturn->customer->address); $sale = $saleReturn->sale; $declaration = Setting::get('credit_note_declaration', 'This credit note is issued against the invoice referenced above and reduces the amount payable by that invoice accordingly.'); $interState = $saleReturn->isInterState(); $summary = $saleReturn->taxSummary(); $cgstTotal = collect($summary)->sum('cgst'); $sgstTotal = collect($summary)->sum('sgst'); $igstTotal = collect($summary)->sum('igst'); @endphp
|
Buyer {{ $saleReturn->customer->name }} @if ($saleReturn->customer->contact_person){{ $saleReturn->customer->contact_person }} @endif @if ($customerAddress){{ $customerAddress }} @endif {{ collect([$saleReturn->customer->city, $saleReturn->customer->state, $saleReturn->customer->pincode])->filter()->implode(', ') }} @if ($saleReturn->customer->gstin)GSTIN/UIN: {{ $saleReturn->customer->gstin }}@endif |
Credit Note Details Credit Note No.: {{ $saleReturn->return_number }} Dated: {{ $saleReturn->return_date->format('d-M-Y') }} Against Invoice No.: {{ $sale->invoice_number }}, dated {{ $sale->sale_date->format('d-M-Y') }} Supply: {{ $interState ? 'Inter-State (IGST)' : 'Intra-State (CGST + SGST)' }} Returned to: {{ $saleReturn->warehouse->name }} |
| Sl No. |
Description of Goods | HSN | GST Rate |
Quantity | Rate | per | Amount |
|---|---|---|---|---|---|---|---|
| {{ $loop->iteration }} | {{ $item->product?->name ?? "Deleted product (#{$item->product_id})" }} | {{ $item->product?->hsn_code ?: '—' }} | {{ rtrim(rtrim(number_format((float) $item->tax_rate, 2), '0'), '.') }} % | {{ $item->quantity }} {{ $item->product?->unit ?: 'PCS' }} | {{ number_format((float) $item->unit_price, 2) }} | {{ $item->product?->unit ?: 'PCS' }} | {{ number_format((float) $item->line_total, 2) }} |
| Total | {{ $saleReturn->items->sum('quantity') }} PCS | {{ number_format((float) $saleReturn->subtotal, 2) }} | |||||
| IGST | {{ number_format($igstTotal, 2) }} | ||||||
| CGST | {{ number_format($cgstTotal, 2) }} | ||||||
| SGST | {{ number_format($sgstTotal, 2) }} | ||||||
| Total Credit | ₹ {{ number_format((float) $saleReturn->total, 2) }} | ||||||
Amount (in words): {{ AmountInWords::rupees((float) $saleReturn->total) }} E. & O.E
| GST Rate | Taxable Value | @if ($interState)IGST Rate | IGST Amt | @elseCGST Rate | CGST Amt | SGST Rate | SGST Amt | @endifTotal Tax |
|---|---|---|---|---|---|---|---|---|
| {{ rtrim(rtrim(number_format($bucket['rate'], 2), '0'), '.') }}% | {{ number_format($bucket['taxable'], 2) }} | @if ($interState){{ rtrim(rtrim(number_format($bucket['rate'], 2), '0'), '.') }}% | {{ number_format($bucket['igst'], 2) }} | @else{{ rtrim(rtrim(number_format($bucket['rate'] / 2, 2), '0'), '.') }}% | {{ number_format($bucket['cgst'], 2) }} | {{ rtrim(rtrim(number_format($bucket['rate'] / 2, 2), '0'), '.') }}% | {{ number_format($bucket['sgst'], 2) }} | @endif{{ number_format($tax, 2) }} |
| Total | {{ number_format((float) $saleReturn->subtotal, 2) }} | @if ($interState){{ number_format($igstTotal, 2) }} | @else{{ number_format($cgstTotal, 2) }} | {{ number_format($sgstTotal, 2) }} | @endif{{ number_format((float) $saleReturn->tax_total, 2) }} |
Reason for return: {{ $saleReturn->notes }}
@endif|
for {{ $company['name'] }} Authorised Signatory |
This is a Computer Generated Credit Note