@extends('layouts.layout-horizontal') @section('title', 'View Customer') @section('css') @endsection @section('content')
{{ $customer->name }}
Edit Back
Mobile
{{ $customer->mobile }}
GST
{{ $customer->gst_number ?: '-' }}
Billing Address
{{ $customer->billing_address ?: '-' }}
State / Pincode
{{ $customer->state }} / {{ $customer->pincode }}
Transportation
{{ $customer->transportation_name ?: '-' }}
VPP (COD)
{{ $customer->vpp_cod ? 'Yes' : 'No' }}
Party / Mode
{{ ucfirst($customer->party_type) }} / {{ ucfirst($customer->mode_type) }}
Payment
{{ ucfirst($customer->payment_type) }} @if ($customer->payment_type === 'cash' && $customer->cash_option) ({{ strtoupper($customer->cash_option) }}) @endif
Shipping Addresses
{{ $customer->shippingAddresses->count() }}
@forelse($customer->shippingAddresses as $addr)
{{ $addr->address }}
@if (!$loop->last)
@endif @empty No shipping addresses @endforelse
Opening Balances
@php $cashModeActive = app(\App\Support\CashMode::class)->active(); $visibleCompanies = $cashModeActive ? $companies : $companies->where('mode', '!=', 'cash'); @endphp {{-- Company Tabs --}} {{-- Tab Content --}}
@foreach($visibleCompanies as $company) @php $companyBalances = $customer->openingBalances->where('company_id', $company->id); @endphp
{{-- Add Form --}}
@csrf
{{-- Existing Balances Table --}}
@forelse($companyBalances as $ob) @empty @endforelse
Date Fiscal Year Direction Amount
{{ \Illuminate\Support\Carbon::parse($ob->as_of_date)->format('d M Y') }} {{ $ob->fiscal_year ?: '-' }} {{ $ob->direction }} {{ indian_number($ob->amount, 2) }}
@csrf @method('DELETE')
No opening balances for {{ $company->name }}.
@endforeach
{{-- SEZ LUT Section (only for SEZ customers) --}} @if($customer->is_sez)
SEZ LUT Numbers
SEZ Customer
{{-- Add LUT Form --}}
@csrf
@error('lut_number')
{{ $message }}
@enderror
@error('valid_from')
{{ $message }}
@enderror
@error('valid_to')
{{ $message }}
@enderror
{{-- LUT Table --}}
@forelse($customer->sezLuts as $lut) @empty @endforelse
# LUT Number Valid From Valid To Status Action
{{ $loop->iteration }} {{ $lut->lut_number }} {{ $lut->valid_from->format('d-M-Y') }} {{ $lut->valid_to->format('d-M-Y') }} @if(now()->between($lut->valid_from, $lut->valid_to)) Active @elseif(now()->lt($lut->valid_from)) Upcoming @else Expired @endif
@csrf @method('DELETE')
No LUTs added yet.
@endif @endsection @push('scripts') @endpush