@php $whatsappGatewayDisabled = \App\Models\WhatsappGateway\WhatsappGatewayGeneral::first()->disabled; $paymentGateway = \App\Models\PaymentGateway::where('is_active', true)->first(); @endphp
{{ __('Billing') }}
Options @if (!$whatsappGatewayDisabled) {{ __('billing.button.send-notification') }} @endif {!! trans('billing.button.create') !!} {!! trans('billing.button.reset-next-bill') !!} @if (count($invoices)) {!! trans('billing.button.invoice') !!} {!! trans('billing.button.billing') !!} @endif {{ __('Setting') }}
@if ($paymentGateway && $paymentGateway->value === 'tripay' && env('TRIPAY_MODE') === 'development') Payment Gateway The payment gateway is in developer mode, so don't conduct real transactions with customers. It's used solely for testing payments through the payment gateway. @endif
{{ trans('billing.status.unpayment') }} {{ trans('billing.status.pay-later') }} {{ trans('billing.status.overdue') }} {{ trans('billing.status.partial-paid') }} Failed {{ trans('billing.status.payment') }} {{ trans('billing.ph.all') }} @if($search_with_status === 'paylater' || $search_with_status === 'partially_paid' || $search_with_status === 'paid') {{ trans('billing.ph.search-teller') }} @foreach ($users as $user) {{ $user->full_name }} @endforeach @endif {{ __('billing.ph.all-year') }} @foreach (array_reverse(\Carbon\CarbonPeriod::create(now()->subYears(5), '1 year', now())->toArray()) as $date) {{ $date->format('Y') }} @endforeach {{ __('billing.ph.all-month') }} @foreach (array_reverse(\Carbon\CarbonPeriod::create(now()->addMonth(), '1 month', now()->addMonths(12))->toArray()) as $date) {{ $date->format('F') }} @endforeach
{{ __('Reset') }} {{ __('Advance Search') }}
{{ trans('billing.table.no') }} {{ trans('billing.table.customer-name') }} {{ trans('Billing Address') }} {{ trans('billing.table.customer-paket') }} {{ trans('billing.table.periode') }} {{ trans('billing.table.bill') }} @if($search_with_status != 'paid') Status {{ trans('billing.table.deadline') }} @endif @if($search_with_status === 'paid') {{ trans('billing.table.payment-time') }} @endif {{ trans('Note') }} {{ trans('billing.table.action') }} @forelse ($invoices as $key => $invoice)
{{ $invoice->full_name }}
@php $userInvoicesCount = $invoice->user->invoices()->where('invoices.status', '!=', 'paid')->count(); @endphp @if ($userInvoicesCount > 1 && $invoice->periode === $invoice->customer_paket->invoices()->where('status', '!=','paid')->oldest()->first()->periode) {{ $userInvoicesCount }} invoices @endif
@php $installationAddress = $invoice->customer_paket->customer_installation_address; $address = $installationAddress->address?$installationAddress->address.', ' : ''; $subdistrict = $installationAddress->subDistrict?$installationAddress->subDistrict.', ' : ''; $district = $installationAddress->district?$installationAddress->district.', ' : ''; $city = $installationAddress->city?$installationAddress->city.', ' : ''; $province = $installationAddress->province?$installationAddress->province.', ' : ''; $country = $installationAddress->country?$installationAddress->country.', ' : ''; $fullAddress = $address.$subdistrict.$district.$city.$province.$country; @endphp {{ $fullAddress }} {{ $invoice->customer_paket->paket->name.' - '.$invoice->customer_paket->internet_service->value }} {{ Str::apa($invoice->customer_paket->renewal_period) }} - @moneyIDR($invoice->total_amount) @if (!is_null($invoice->customer_paket->customer_billing_address->last_reminder_date)) Last Reminder {{ \Carbon\Carbon::parse($invoice->customer_paket->customer_billing_address->last_reminder_date)->format('d M Y, H:i') }} @endif @if ($invoice->customer_paket->update_mikrotik_status === 'failed') Update Mikrotik Failed @endif {{ \Carbon\Carbon::parse($invoice->start_periode)->format('d M y') }} {{ \Carbon\Carbon::parse($invoice->end_periode)->format('d M y') }} @if($search_with_status != 'paid')
{{ Str::apa(Str::replace('_', ' ', $invoice->status)) }}
@endif @if($search_with_status === 'paid') @endif {{ $invoice->notes }}
@if($invoice->customer_paket->status === 'pending') Activation @else @endif
@empty
{{ trans('billing.notfound') }}
@endforelse @if ($invoices->count())
@if (collect($selectedInvoice)->count()) @if($search_with_status === 'paid') {!! trans_choice('billing.button.bulk-unpayment', collect($selectedInvoice)->count(), [ 'count' => collect($selectedInvoice)->count(),]) !!} @else {!! trans_choice('billing.button.bulk-payment', collect($selectedInvoice)->count(), [ 'count' => collect($selectedInvoice)->count(),]) !!} {!! trans_choice('billing.button.bulk-delete-invoice', collect($selectedInvoice)->count(), [ 'count' => collect($selectedInvoice)->count(),]) !!} @endif @endif
@endif
@if ($invoices->hasPages())
{{ $invoices->links() }}
@endif