added multi approval field

This commit is contained in:
Jagad R R
2024-12-26 17:43:27 +07:00
parent 9b4e372de1
commit 19ef6b91bb
5 changed files with 45 additions and 15 deletions
@@ -78,7 +78,7 @@
<div class="dataTables_wrapper dt-bootstrap4 mt-2"> <div class="dataTables_wrapper dt-bootstrap4 mt-2">
@include('backend.layouts.partials.messages') @include('backend.layouts.partials.messages')
<table id="dataTable" <table id="dataTable"
class="table table-bordered table-striped table-head-fixed dataTable dtr-inline" class="table table-bordered table-striped table-head-fixed table-responsive dataTable dtr-inline"
style="width:100%"> style="width:100%">
<thead class="bg-light text-capitalize"> <thead class="bg-light text-capitalize">
<tr> <tr>
@@ -94,9 +94,12 @@
<th>Bukti 3</th> <th>Bukti 3</th>
<th>Account Number</th> <th>Account Number</th>
<th>Status</th> <th>Status</th>
@if (auth()->user()->can('approval.approve') || auth()->user()->can('final_approval.approve')) @if (auth()->user()->can('approval.approve'))
<th>Approval</th> <th>Approval</th>
@endif @endif
@if (auth()->user()->can('final_approval.approve'))
<th>Final Approval</th>
@endif
<th>Aksi</th> <th>Aksi</th>
</tr> </tr>
</thead> </thead>
@@ -179,7 +182,8 @@
@endif @endif
@endif @endif
</td> </td>
@elseif(auth()->user()->can('final_approval.approve')) @endif
@if(auth()->user()->can('final_approval.approve'))
<td> <td>
{{-- approve / reject button --}} {{-- approve / reject button --}}
@if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at) @if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at)
@@ -199,6 +203,8 @@
Open Open
</button> </button>
</form> </form>
@elseif ($item->final_approved_at)
{{ \Carbon\Carbon::parse($item->approved_at)->locale('id')->isoFormat('D MMMM Y') }}
@else @else
- -
@endif @endif
@@ -78,7 +78,7 @@
<div class="dataTables_wrapper dt-bootstrap4 mt-2"> <div class="dataTables_wrapper dt-bootstrap4 mt-2">
@include('backend.layouts.partials.messages') @include('backend.layouts.partials.messages')
<table id="dataTable" <table id="dataTable"
class="table table-bordered table-striped table-head-fixed dataTable dtr-inline" class="table table-bordered table-striped table-responsive table-head-fixed dataTable dtr-inline"
style="width:100%"> style="width:100%">
<thead class="bg-light text-capitalize"> <thead class="bg-light text-capitalize">
<tr> <tr>
@@ -94,9 +94,12 @@
<th>Bukti 3</th> <th>Bukti 3</th>
<th>Account Number</th> <th>Account Number</th>
<th>Status</th> <th>Status</th>
@if (auth()->user()->can('approval.approve') || auth()->user()->can('final_approval.approve')) @if (auth()->user()->can('approval.approve'))
<th>Approval</th> <th>Approval</th>
@endif @endif
@if (auth()->user()->can('final_approval.approve'))
<th>Final Approval</th>
@endif
<th>Aksi</th> <th>Aksi</th>
</tr> </tr>
</thead> </thead>
@@ -179,7 +182,8 @@
@endif @endif
@endif @endif
</td> </td>
@elseif(auth()->user()->can('final_approval.approve')) @endif
@if(auth()->user()->can('final_approval.approve'))
<td> <td>
{{-- approve / reject button --}} {{-- approve / reject button --}}
@if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at) @if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at)
@@ -199,6 +203,8 @@
Open Open
</button> </button>
</form> </form>
@elseif ($item->final_approved_at)
{{ \Carbon\Carbon::parse($item->approved_at)->locale('id')->isoFormat('D MMMM Y') }}
@else @else
- -
@endif @endif
@@ -78,7 +78,7 @@
<div class="dataTables_wrapper dt-bootstrap4 mt-2"> <div class="dataTables_wrapper dt-bootstrap4 mt-2">
@include('backend.layouts.partials.messages') @include('backend.layouts.partials.messages')
<table id="dataTable" <table id="dataTable"
class="table table-bordered table-striped table-head-fixed dataTable dtr-inline" class="table table-bordered table-striped table-responsive table-head-fixed dataTable dtr-inline"
style="width:100%"> style="width:100%">
<thead class="bg-light text-capitalize"> <thead class="bg-light text-capitalize">
<tr> <tr>
@@ -93,9 +93,12 @@
<th>Bukti 3</th> <th>Bukti 3</th>
<th>Account Number</th> <th>Account Number</th>
<th>Status</th> <th>Status</th>
@if (auth()->user()->can('approval.approve') || auth()->user()->can('final_approval.approve')) @if (auth()->user()->can('approval.approve'))
<th>Approval</th> <th>Approval</th>
@endif @endif
@if (auth()->user()->can('final_approval.approve'))
<th>Final Approval</th>
@endif
<th>Aksi</th> <th>Aksi</th>
</tr> </tr>
</thead> </thead>
@@ -177,7 +180,8 @@
@endif @endif
@endif @endif
</td> </td>
@elseif(auth()->user()->can('final_approval.approve')) @endif
@if(auth()->user()->can('final_approval.approve'))
<td> <td>
{{-- approve / reject button --}} {{-- approve / reject button --}}
@if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at) @if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at)
@@ -197,6 +201,8 @@
Open Open
</button> </button>
</form> </form>
@elseif ($item->final_approved_at)
{{ \Carbon\Carbon::parse($item->approved_at)->locale('id')->isoFormat('D MMMM Y') }}
@else @else
- -
@endif @endif
@@ -78,7 +78,7 @@
<div class="dataTables_wrapper dt-bootstrap4 mt-2"> <div class="dataTables_wrapper dt-bootstrap4 mt-2">
@include('backend.layouts.partials.messages') @include('backend.layouts.partials.messages')
<table id="dataTable" <table id="dataTable"
class="table table-bordered table-striped table-head-fixed dataTable dtr-inline" class="table table-bordered table-striped table-responsive table-head-fixed dataTable dtr-inline"
style="width:100%"> style="width:100%">
<thead class="bg-light text-capitalize"> <thead class="bg-light text-capitalize">
<tr> <tr>
@@ -94,9 +94,12 @@
<th>Bukti 3</th> <th>Bukti 3</th>
<th>Account Number</th> <th>Account Number</th>
<th>Status</th> <th>Status</th>
@if (auth()->user()->can('approval.approve') || auth()->user()->can('final_approval.approve')) @if (auth()->user()->can('approval.approve'))
<th>Approval</th> <th>Approval</th>
@endif @endif
@if (auth()->user()->can('final_approval.approve'))
<th>Final Approval</th>
@endif
<th>Aksi</th> <th>Aksi</th>
</tr> </tr>
</thead> </thead>
@@ -179,7 +182,8 @@
@endif @endif
@endif @endif
</td> </td>
@elseif(auth()->user()->can('final_approval.approve')) @endif
@if(auth()->user()->can('final_approval.approve'))
<td> <td>
{{-- approve / reject button --}} {{-- approve / reject button --}}
@if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at) @if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at)
@@ -199,6 +203,8 @@
Open Open
</button> </button>
</form> </form>
@elseif ($item->final_approved_at)
{{ \Carbon\Carbon::parse($item->approved_at)->locale('id')->isoFormat('D MMMM Y') }}
@else @else
- -
@endif @endif
@@ -78,7 +78,7 @@
<div class="dataTables_wrapper dt-bootstrap4 mt-2"> <div class="dataTables_wrapper dt-bootstrap4 mt-2">
@include('backend.layouts.partials.messages') @include('backend.layouts.partials.messages')
<table id="dataTable" <table id="dataTable"
class="table table-bordered table-striped table-head-fixed dataTable dtr-inline" class="table table-bordered table-striped table-responsive table-head-fixed dataTable dtr-inline"
style="width:100%"> style="width:100%">
<thead class="bg-light text-capitalize"> <thead class="bg-light text-capitalize">
<tr> <tr>
@@ -95,9 +95,12 @@
<th>Bukti 3</th> <th>Bukti 3</th>
<th>Account Number</th> <th>Account Number</th>
<th>Status</th> <th>Status</th>
@if (auth()->user()->can('approval.approve') || auth()->user()->can('final_approval.approve')) @if (auth()->user()->can('approval.approve'))
<th>Approval</th> <th>Approval</th>
@endif @endif
@if (auth()->user()->can('final_approval.approve'))
<th>Final Approval</th>
@endif
<th>Aksi</th> <th>Aksi</th>
</tr> </tr>
</thead> </thead>
@@ -181,7 +184,8 @@
@endif @endif
@endif @endif
</td> </td>
@elseif(auth()->user()->can('final_approval.approve')) @endif
@if(auth()->user()->can('final_approval.approve'))
<td> <td>
{{-- approve / reject button --}} {{-- approve / reject button --}}
@if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at) @if ($item->status == 'Approved' && $item->approved_at && !$item->final_approved_at)
@@ -201,6 +205,8 @@
Open Open
</button> </button>
</form> </form>
@elseif ($item->final_approved_at)
{{ \Carbon\Carbon::parse($item->approved_at)->locale('id')->isoFormat('D MMMM Y') }}
@else @else
- -
@endif @endif