77 lines
3.4 KiB
PHP
77 lines
3.4 KiB
PHP
|
|
@extends('layouts.business.pdf.pdf_layout')
|
||
|
|
|
||
|
|
@section('pdf_title')
|
||
|
|
<div class="table-header justify-content-center border-0 d-print-block text-center">
|
||
|
|
@include('business::print.header')
|
||
|
|
<h4 style="text-align: center; margin: 0; padding: 0; font-size: 16px;">
|
||
|
|
{{ __('Cash Balance List') }}
|
||
|
|
</h4>
|
||
|
|
@if ($filter_from_date && $filter_to_date)
|
||
|
|
<p style="text-align: center; margin: 0; padding: 0; font-weight: 400; font-size: 14px;" class="">{{ __('Duration:') }}
|
||
|
|
@if ($duration === 'today')
|
||
|
|
{{ Carbon\Carbon::parse($filter_from_date)->format('d-m-Y') }}
|
||
|
|
@elseif ($duration === 'yesterday')
|
||
|
|
{{ Carbon\Carbon::parse($filter_from_date)->format('d-m-Y') }}
|
||
|
|
@else
|
||
|
|
{{ Carbon\Carbon::parse($filter_from_date)->format('d-m-Y') }}
|
||
|
|
{{ __('to') }}
|
||
|
|
{{ Carbon\Carbon::parse($filter_to_date)->format('d-m-Y') }}
|
||
|
|
@endif
|
||
|
|
</p>
|
||
|
|
@endif
|
||
|
|
</div>
|
||
|
|
@endsection
|
||
|
|
|
||
|
|
@section('pdf_content')
|
||
|
|
|
||
|
|
<table width="100%" cellpadding="6" cellspacing="0"
|
||
|
|
style="border-collapse: collapse; border:1px solid gainsboro; font-size:12px;">
|
||
|
|
|
||
|
|
<thead>
|
||
|
|
<tr style="background-color: #C52127; color:white;">
|
||
|
|
<th style="font-size:12px; border:1px solid gainsboro; color: white">
|
||
|
|
{{ __('Date') }}
|
||
|
|
</th>
|
||
|
|
<th style="font-size:12px; border:1px solid gainsboro; color: white">
|
||
|
|
{{ __('Type') }}
|
||
|
|
</th>
|
||
|
|
<th style="font-size:12px; border:1px solid gainsboro; color: white">
|
||
|
|
{{ __('Payment') }}
|
||
|
|
</th>
|
||
|
|
<th style="font-size:12px; border:1px solid gainsboro; color: white">
|
||
|
|
{{ __('Name') }}
|
||
|
|
</th>
|
||
|
|
<th style="font-size:12px; border:1px solid gainsboro; color: white">
|
||
|
|
{{ __('Amount') }}
|
||
|
|
</th>
|
||
|
|
</tr>
|
||
|
|
</thead>
|
||
|
|
|
||
|
|
<tbody>
|
||
|
|
@foreach($cashes as $cash)
|
||
|
|
<tr style="background-color: {{ $loop->even ? '#F5F5F5' : '#FFFFFF' }};">
|
||
|
|
<td style="border:1px solid gainsboro; text-align:center;">
|
||
|
|
{{ formatted_date($cash->date) }}
|
||
|
|
</td>
|
||
|
|
<td style="border:1px solid gainsboro; text-align:center;">
|
||
|
|
{{ ucwords(str_replace('_', ' ', $cash->platform)) }}
|
||
|
|
</td>
|
||
|
|
<td style="border:1px solid gainsboro; text-align:center;">
|
||
|
|
{{ ucwords(str_replace('_', ' ', $cash->transaction_type)) }}
|
||
|
|
</td>
|
||
|
|
<td style="border:1px solid gainsboro; text-align:center;">
|
||
|
|
{{ $cash->user->name ?? '' }}
|
||
|
|
</td>
|
||
|
|
<td style="border:1px solid gainsboro; text-align:center;">
|
||
|
|
@if ($cash->type == 'credit' || $cash->transaction_type == 'bank_to_cash')
|
||
|
|
{{ currency_format($cash->amount, currency: business_currency()) }}
|
||
|
|
@elseif ($cash->type == 'debit' || $cash->transaction_type == 'cash_to_bank')
|
||
|
|
{{ currency_format(-$cash->amount, currency: business_currency()) }}
|
||
|
|
@endif
|
||
|
|
</td>
|
||
|
|
</tr>
|
||
|
|
@endforeach
|
||
|
|
</tbody>
|
||
|
|
</table>
|
||
|
|
@endsection
|