Team 3 (Neb 1 Form)
This commit is contained in:
parent
7bb4afc7ab
commit
59c4d13736
|
|
@ -65,7 +65,15 @@
|
||||||
@endphp
|
@endphp
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<button type="button" class="btn btn-xs btn-info edit-btn" plan_details="{{json_encode($sub->formdata)}}"><i class="mdi mdi-pencil"></i> Edit</button>
|
@if(isset($sub->formdata->execution_done) && $sub->formdata->execution_done == 'yes') Executed
|
||||||
|
|
||||||
|
@else
|
||||||
|
<button type="button" class="btn btn-xs btn-info edit-btn"
|
||||||
|
plan_details="{{ json_encode($sub->formdata) }}">
|
||||||
|
<i class="mdi mdi-pencil"></i> Execute
|
||||||
|
</button>
|
||||||
|
@endif
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td>{{(isset($sub->formdata->record_date) && $sub->formdata->record_date > 0) ?'Yes':'No' }}</td>
|
<td>{{(isset($sub->formdata->record_date) && $sub->formdata->record_date > 0) ?'Yes':'No' }}</td>
|
||||||
<td>{{$sub->formdata->plan_date}}</td>
|
<td>{{$sub->formdata->plan_date}}</td>
|
||||||
|
|
@ -143,6 +151,7 @@
|
||||||
<input type="hidden" name="form_id" value="{{$form_id}}">
|
<input type="hidden" name="form_id" value="{{$form_id}}">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="id" value="" id="execution-id">
|
<input type="hidden" name="id" value="" id="execution-id">
|
||||||
|
<input type="hidden" name="execution_done" value="yes">
|
||||||
@foreach($questions as $question)
|
@foreach($questions as $question)
|
||||||
<div class="col-md-12 mb-2">
|
<div class="col-md-12 mb-2">
|
||||||
<label for="execution-{{$question->code}}" class="form-label">{{$question->question}} {!!$question->required == 'yes' ? '<span class="text-danger">*</span>':''!!} </label>
|
<label for="execution-{{$question->code}}" class="form-label">{{$question->question}} {!!$question->required == 'yes' ? '<span class="text-danger">*</span>':''!!} </label>
|
||||||
|
|
@ -245,6 +254,11 @@
|
||||||
})
|
})
|
||||||
|
|
||||||
$('.edit-btn').click(function(){
|
$('.edit-btn').click(function(){
|
||||||
|
$('#execution-plan_date').attr('readonly',true);
|
||||||
|
let contacts = document.getElementById('execution-type_of_meeting');
|
||||||
|
contacts.addEventListener('mousedown', function(e) {
|
||||||
|
e.preventDefault();
|
||||||
|
})
|
||||||
let selected = JSON.parse($(this).attr('plan_details'))
|
let selected = JSON.parse($(this).attr('plan_details'))
|
||||||
for(let k of Object.keys(selected)) {
|
for(let k of Object.keys(selected)) {
|
||||||
if(selected[k] != '')
|
if(selected[k] != '')
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue