Update Module Permohonan
- Update Automaticly get branch id by user login - change static status permohonan to dynamic and database base - update create permohonan, update selection debiture to table base
This commit is contained in:
@@ -50,33 +50,6 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Branch
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select class="input tomselect w-full @error('branch_id') border-danger @enderror" name="branch_id" id="branch_id">
|
||||
<option value="">Pilih Branch</option>
|
||||
@if(isset($branches))
|
||||
@foreach($branches as $row)
|
||||
@if(isset($permohonan))
|
||||
<option value="{{ $row->id }}" {{ isset($permohonan->branch_id) && $permohonan->branch_id == $row->id?'selected' : '' }}>
|
||||
{{ $row->name }}
|
||||
</option>
|
||||
@else
|
||||
<option value="{{ $row->id }}">
|
||||
{{ $row->name }}
|
||||
</option>
|
||||
@endif
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
@error('branch_id')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Tujuan Penilaian
|
||||
@@ -112,14 +85,14 @@
|
||||
<select class="input tomselect w-full @error('branch_id') border-danger @enderror" name="status" id="status">
|
||||
<option value="">Pilih Status Permohonan</option>
|
||||
@if(isset($status))
|
||||
@foreach($status as $key => $row)
|
||||
@foreach($status as $row)
|
||||
@if(isset($permohonan))
|
||||
<option value="{{ $key }}" {{ isset($permohonan->status) && $permohonan->status == $key ?'selected' : '' }}>
|
||||
{{ $row }}
|
||||
<option value="{{ $row->slug }}" {{ isset($permohonan->status) && $permohonan->status == $row->slug ?'selected' : '' }}>
|
||||
{{ $row->name }}
|
||||
</option>
|
||||
@else
|
||||
<option value="{{ $key }}">
|
||||
{{ $row }}
|
||||
<option value="{{ $row->slug }}">
|
||||
{{ $row->name }}
|
||||
</option>
|
||||
@endif
|
||||
@endforeach
|
||||
|
||||
Reference in New Issue
Block a user