{{-- Company Logo --}}
@php
$companyGst = $invoice->companyGst;
$customerGstin = $invoice->customerGstin;
@endphp
{{ strtoupper($invoice->company->company_name ?? 'Company Name') }}
@if($companyGst)
{{ $companyGst->address_line1 ?? '' }}@if($companyGst->address_line2), {{ $companyGst->address_line2 }}@endif
{{ $companyGst->city ?? '' }}@if($companyGst->state), {{ $companyGst->state->name ?? '' }}@endif {{ $companyGst->pincode ?? '' }} @else Company address not configured @endif
GSTIN: {{ $companyGst->gstin_number ?? '-' }}
State Name: {{ $companyGst && $companyGst->state ? ($companyGst->state->name ?? '-') : '-' }},
Code: {{ $companyGst && $companyGst->state ? ($companyGst->state->state_code ?? '-') : '-' }}
Contact: {{ $companyGst->email ?? ($invoice->company->email ?? '-') }}
@if(!empty($companyGst?->phone) || !empty($invoice->company?->phone))
, {{ $companyGst->phone ?? $invoice->company->phone }}
@endif
{{-- IRN and Ack Details (for e-invoice) --}}
@if(!empty($invoice->irn))
IRN: {{ $invoice->irn }}
Ack No.: {{ $invoice->ack_no ?? 'N/A' }}
@endif
Ack Date: {{ $invoice->ack_date ? \Carbon\Carbon::parse($invoice->ack_date)->format('d-M-y') : 'N/A' }} |
{{-- QR Code (for e-invoice) --}}
@if(!empty($invoice->irn))
QR CODE
@endif
Tax Invoice
@php
$firstIssue = $stockIssues->first();
$refNo = $firstIssue->reference_number ?? null;
$refDate = $firstIssue->reference_date ?? null;
if (!$refNo && isset($salesOrder) && $salesOrder) {
$refNo = $salesOrder->so_number ?? null;
$refDate = $salesOrder->so_date ?? null;
}
$deliveryNoteNos = $stockIssues->pluck('document_number')->filter()->implode(', ');
$deliveryNoteDates = $stockIssues->pluck('posting_date')->filter()->map(function ($d) {
try {
return \Carbon\Carbon::parse($d)->format('d-M-y');
} catch (\Throwable $e) {
return $d;
}
})->unique()->implode(', ');
$buyerOrderNo = isset($salesOrder) && $salesOrder ? ($salesOrder->customer_po_number ?? null) : null;
if (empty($buyerOrderNo)) {
$buyerOrderNo = 'Direct';
}
$termsOfDelivery = isset($salesOrder) && $salesOrder ? ($salesOrder->delivery_terms ?? null) : null;
if (empty($termsOfDelivery)) {
$termsOfDelivery = '-';
}
$destination = '-';
if (!empty($shippingAddress)) {
$destination = trim(implode(', ', array_filter([
$shippingAddress->city ?? null,
$shippingAddress->state ?? null,
]))) ?: '-';
} elseif (!empty($invoice->shipping_address)) {
$destination = $invoice->shipping_address;
}
@endphp
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Buyer (Bill to)
{{ strtoupper($invoice->customer->customer_name ?? 'Customer Name') }}
@if($billingAddress)
{{ $billingAddress->address_line1 ?? '' }}@if($billingAddress->address_line2), {{ $billingAddress->address_line2 }}@endif
{{ $billingAddress->city ?? '' }}, {{ $billingAddress->state ?? '' }} {{ $billingAddress->pincode ?? '' }} @else Customer Address @endif
GSTIN/UIN: {{ $customerGstin->gstin_number ?? 'N/A' }}
State Name: {{ $customerGstin && $customerGstin->state ? ($customerGstin->state->name ?? 'State') : 'State' }},
Code: {{ $customerGstin->state_code ?? 'XX' }}
|
Consignee (Ship to)
{{ strtoupper($invoice->customer->customer_name ?? 'Customer Name') }}
@if($shippingAddress)
{{ $shippingAddress->address_line1 ?? '' }}@if($shippingAddress->address_line2), {{ $shippingAddress->address_line2 }}@endif
{{ $shippingAddress->city ?? '' }}, {{ $shippingAddress->state ?? '' }} {{ $shippingAddress->pincode ?? '' }} @else Shipping Address @endif
GSTIN/UIN: {{ $customerGstin->gstin_number ?? 'N/A' }}
State Name: {{ $customerGstin && $customerGstin->state ? ($customerGstin->state->name ?? 'State') : 'State' }},
Code: {{ $customerGstin->state_code ?? 'XX' }}
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Taxable Amount
₹ {{ \App\Helpers\NumberHelper::formatIndianNumber($invoice->taxable_amount, 2) }}
@if($invoice->tax_type === 'INTRASTATE')
CGST
₹ {{ \App\Helpers\NumberHelper::formatIndianNumber($invoice->cgst_amount, 2) }}
SGST
₹ {{ \App\Helpers\NumberHelper::formatIndianNumber($invoice->sgst_amount, 2) }}
@else
IGST
₹ {{ \App\Helpers\NumberHelper::formatIndianNumber($invoice->igst_amount, 2) }}
@endif
Total
₹ {{ \App\Helpers\NumberHelper::formatIndianNumber($invoice->total_amount, 2) }}
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Amount Chargeable (in words)
INR {{ \App\Helpers\NumberHelper::amountToWords($invoice->total_amount) }}
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Tax Amount (in words):
INR {{ \App\Helpers\NumberHelper::amountToWords($invoice->cgst_amount + $invoice->sgst_amount + $invoice->igst_amount) }}
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
A/c Holder's Name: {{ $invoice->company->company_name ?? 'Company Name' }}
Bank Name: {{ $invoice->company->bank_name ?? 'ICICI BANK' }} A/c No.: {{ $invoice->company->bank_account_number ?? 'XXXXXXXXXXXX' }} Branch & IFS Code: {{ $invoice->company->bank_branch ?? 'Branch' }} & {{ $invoice->company->bank_ifsc ?? 'ICICXXXXXX' }}
Declaration
@if(!empty($invoice->company->msme_number))
We declare that this invoice shows the actual price of the goods described and that all particulars are true and correct.
* Our entity is an MSME Registration with holding Udyog Aadhaar Registration Certificate Number {{ $invoice->company->msme_number }} under the Provisions of (MSMED) Act, S.W.&F Act & F.W.F.E Act, as per that (MSMED) act, if the payment is not made within 45 days from the date of billing, Interest will be charged at 3 times of Bank Rate notified by RBI.
@endif
|
for {{ strtoupper($invoice->company->company_name ?? 'Company Name') }}
Authorised Signatory
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||