2024-07-25 04:08:26 +00:00
|
|
|
@use(App\Models\Charge)
|
|
|
|
|
2021-10-01 04:59:04 +00:00
|
|
|
@extends('adminlte::layouts.app')
|
|
|
|
|
|
|
|
@section('htmlheader_title')
|
|
|
|
Unprocessed Charges
|
|
|
|
@endsection
|
|
|
|
@section('page_title')
|
|
|
|
Unprocessed
|
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section('contentheader_title')
|
|
|
|
Unprocessed Charges
|
|
|
|
@endsection
|
|
|
|
@section('contentheader_description')
|
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section('main-content')
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-9">
|
|
|
|
<div class="card">
|
|
|
|
<div class="card-body">
|
|
|
|
<table class="table table-striped table-hover" id="unprocessed_charges">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>ID</th>
|
|
|
|
<th>Date Created</th>
|
|
|
|
<th>Date Charge</th>
|
|
|
|
<th>Account</th>
|
|
|
|
<th>Service</th>
|
|
|
|
<th>Description</th>
|
|
|
|
<th class="text-right">Total</th>
|
2024-07-31 12:36:28 +00:00
|
|
|
<th> </th>
|
2021-10-01 04:59:04 +00:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
|
|
|
|
<tbody>
|
2024-07-25 04:08:26 +00:00
|
|
|
@forelse(Charge::pending()->with(['account.user','service'])->get() as $o)
|
2021-10-01 04:59:04 +00:00
|
|
|
<tr>
|
2024-07-25 04:08:26 +00:00
|
|
|
<td>{{ $o->id }}</td>
|
2022-07-25 13:59:28 +00:00
|
|
|
<td>{{ $o->charge_at->format('Y-m-d') }}</td>
|
|
|
|
<td>{{ $o->created_at->format('Y-m-d') }}</td>
|
2021-10-01 04:59:04 +00:00
|
|
|
<td>{{ $o->account->name }}</td>
|
2024-07-25 04:08:26 +00:00
|
|
|
<td><a href="{{ url('u/service',$o->service_id) }}">{{ $o->service->name_short }}</a></td>
|
2021-10-01 04:59:04 +00:00
|
|
|
<td>{{ $o->description }}</td>
|
2024-07-31 12:36:28 +00:00
|
|
|
<td class="text-right">{{ number_format($o->total,2) }}</td>
|
|
|
|
<td><a class="charge_delete text-dark" data-id="{{ $o->id }}" href="{{ url('/r/charge/delete',$o->id) }}"><i class="fas fa-fw fa-ban"></i></a></td>
|
2021-10-01 04:59:04 +00:00
|
|
|
</tr>
|
2024-07-25 04:08:26 +00:00
|
|
|
@empty
|
|
|
|
<tr>
|
|
|
|
<td colspan="7">Not charges unprocessed</td>
|
|
|
|
</tr>
|
|
|
|
@endforelse
|
2021-10-01 04:59:04 +00:00
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2024-07-31 12:36:28 +00:00
|
|
|
|
|
|
|
<x-leenooks::modal.delete hide="row" trigger="charge_delete"/>
|
2021-10-01 04:59:04 +00:00
|
|
|
@endsection
|
|
|
|
|
2024-07-31 12:36:28 +00:00
|
|
|
@pa(datatables,rowgroup|conditionalpaging)
|
2021-10-01 04:59:04 +00:00
|
|
|
|
2024-07-31 12:36:28 +00:00
|
|
|
@section('page-scripts')
|
2021-10-01 04:59:04 +00:00
|
|
|
<script type="text/javascript">
|
|
|
|
$(document).ready(function() {
|
2024-07-31 12:36:28 +00:00
|
|
|
$('#unprocessed_charges').DataTable({
|
|
|
|
conditionalPaging: true,
|
|
|
|
order: [[3,'desc'],[1,'desc']],
|
|
|
|
rowGroup: {
|
|
|
|
dataSrc: [3],
|
|
|
|
},
|
2021-10-01 04:59:04 +00:00
|
|
|
});
|
|
|
|
});
|
|
|
|
</script>
|
|
|
|
@append
|