Team 3 (Doctor Activities for Neb 1)
Specific Folder FTP Upload / ftp-deploy (push) Successful in 1m47s Details

This commit is contained in:
zeeshan 2026-09-11 17:22:24 +05:30
parent e93cefe521
commit 02f801da03
1 changed files with 26 additions and 2 deletions

View File

@ -72,6 +72,11 @@
plan_details="{{ json_encode($sub->formdata) }}">
<i class="mdi mdi-pencil"></i> Execute
</button>
<button type="button" class="btn btn-xs btn-info edit-plan"
plan_details="{{ json_encode($sub->formdata) }}">
<i class="mdi mdi-pencil"></i> Edit Plan
</button>
@endif
</td>
@ -220,7 +225,7 @@
<input type="hidden" name="form_id" value="{{$form_id}}">
@csrf
<input type="hidden" name="id" value="" id="execution-id">
<input type="hidden" name="execution_done" value="yes">
@foreach($questions as $question)
<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>
@ -323,11 +328,12 @@
})
$('.edit-btn').click(function(){
$('#execution-plan_date').attr('readonly',true);
$('#execution-plan_date,#execution-name_of_the_speaker,#execution-msl_code,#execution-tentative_attendees_count,#execution-budget_required').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'))
for(let k of Object.keys(selected)) {
if(selected[k] != '')
@ -337,6 +343,24 @@
$('#form-wrapper').hide()
$('#execution-form-wrapper').show()
$('#table-wrapper').hide()
$('#execution-form').append('<input type="hidden" name="execution_done" value="yes">');
})
$('.edit-plan').click(function(){
let selected = JSON.parse($(this).attr('plan_details'))
for(let k of Object.keys(selected)) {
if(selected[k] != '')
$('#execution-'+k).val(selected[k]);
}
$('#execution-id').val(selected['id'])
$('#form-wrapper').hide()
$('#execution-form-wrapper').show()
$('#table-wrapper').hide()
$('#execution-record_date,#execution-attendence').parent().hide();
$('#execution-record_date,#execution-attendence').attr('required',false);
})
jQuery(document).ready(function($){