Файловый менеджер - Редактировать - /home/clickysoft/public_html/calvary-p2.clickysoft.net/storage/framework/views/f8e7e5bc5e711861b01f1511adb83089.php
Назад
<?php $__env->startSection('title', 'Lunch Program'); ?> <?php $__env->startPush('front-styles'); ?> <style> .nxt-btn:hover { color: #fff } </style> <?php $__env->stopPush(); ?> <?php $__env->startSection('content'); ?> <?php $user_cart = \Illuminate\Support\Facades\Session::get('user_cart'); ?> <?php if(empty($hotLunch)): ?> <section class="lunch-program-sec"> <div class="container"> <div class="row"> <div class="col-md-12"> <div class="lps-head"> <h3>No Lunch Program Available</h3> </div> </div> </div> </div> </section> <?php else: ?> <section class="lunch-program-sec"> <div class="container"> <div class="row"> <div class="col-md-12"> <div class="lps-head"> <h3>Lunch Program</h3> <?php echo $hotLunch->description; ?> </div> </div> </div> <div class="row justify-content-center pt-5"> <div class="col-md-12 col-lg-9"> <div class="row add-child-row"> <?php $__currentLoopData = $children; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $child): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <div class="col-md-6 col-lg-4 col-sm-12 col-12"> <div class="<?php echo \Illuminate\Support\Arr::toCssClasses([ 'position-relative', 'chd-card', 'active' => isset($user_cart['siblings'][$child->id]), ]); ?>" data-id="<?php echo e($child->id); ?>" data-grade="<?php echo e($child->grade->title); ?>"> <input type="hidden" name="child_grade" value="<?php echo e($child->grade->title); ?>"> <label class="child-card" for="chd<?php echo e($child->id); ?>"> <h4 class="child-boxx"><?php echo e($child->name); ?></h4> </label> <p>Grade : <span> <?php echo e($child->grade->school->title . ' ' . $child->grade->title); ?></span> </p> <p>Assigned teacher : <span><?php echo e($child?->teacher?->full_name ?? 'NA'); ?></span></p> </div> <div class="ed-del"> <button type="button" class="edit-btnn btn btn-outline-primary " data-id="<?php echo e($child->id); ?>"> Edit </button> <button type="button" class="remove btn btn-outline-danger" data-id="<?php echo e($child->id); ?>"> Delete </button> </div> </div> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> </div> </div> </div> <div class="text-center mt-5"> <?php if(auth()->guard()->check()): ?> <a class="nxt-btn text-decoration-none" href="<?php echo e(route('child.add', ['lunch_program' => true])); ?>">Add a new child</a> <?php else: ?> <a class="nxt-btn text-decoration-none" href="javascript:void(0)" onclick="LoginFirst()">Add a new child</a> </div> </div> <?php endif; ?> <div class="modal fade" id="delModal" tabindex="-1" aria-labelledby="delModal" aria-modal="true" role="dialog"> <div class="modal-dialog modal-dialog-slideout modal-dialog-centered dm-max"> <div class=" modal-content rmd-content"> <div class="modal-header rmd-header absol-right"> <button type="button" class="md-close" data-bs-dismiss="modal" aria-label="Close"> <img src="<?php echo e(asset('assets/front/images/btn-close.svg')); ?>" alt="" class="img-fluid"> </button> </div> <div class="modal-body rmd-body"> <div class="row justify-content-center"> <div class="col-md-12 col-sm-12 col-12"> <div class="lps-head dl-md-head"> <h3>Delete</h3> <p>Are you sure you want to remove this child?</p> </div> <div class="crm-cancel"> <button data-bs-dismiss="modal" class="dl-cancel">Cancel</button> <button class="dl-confirm" data-id="0">Confirm</button> </div> </div> </div> </div> </div> </div> </div> </section> <?php endif; ?> <?php $__env->stopSection(); ?> <?php $__env->startPush('front-scripts'); ?> <script src="<?php echo e(asset('assets/front/js/global.js')); ?>"></script> <script src="<?php echo e(asset('assets/admin/js/axios.min.js')); ?>"></script> <script src="<?php echo e(asset('assets/admin/js/sweetalert.min.js')); ?>"></script> <script> function LoginFirst() { swal({ title: "You have to login first.", icon: "error", dangerMode: true, closeOnClickOutside: false }).then((btn) => { window.location.href = '<?php echo e(route('login')); ?>'; }); } function payAnnualDue() { window.location.href = '<?php echo e(route('annual.due')); ?>'; } $('.edit-btnn').on('click', function() { const id = $(this).attr('data-id') window.location = `<?php echo e(\Illuminate\Support\Facades\URL::to('/edit-child')); ?>/${id}?lunch_program=1` }) $('.remove').click(function() { const id = $(this).attr('data-id') $('.dl-confirm').attr('data-id', id) $('#delModal').modal('show') }) $('.dl-confirm').click(function() { const id = $(this).attr('data-id') const token = `<?php echo e(csrf_token()); ?>` $.ajax({ url: `<?php echo e(\Illuminate\Support\Facades\URL::to('/delete-child')); ?>/${id}`, type: 'DELETE', dataType: 'json', headers: { 'X-CSRF-TOKEN': token }, success: function(data) { swal({ title: "Child deleted successfully", icon: "success", closeOnClickOutside: false }).then((btn) => { window.location.reload(); }); }, error: function() { swal({ title: "Could not delete child.", icon: "error", dangerMode: true, closeOnClickOutside: false }); } }); }) $('.chd-card').click(function() { const childId = $(this).attr('data-id') const childGrade = $(this).attr('data-grade') const token = `<?php echo e(csrf_token()); ?>` $.ajax({ url: `<?php echo e(route('add.sibling')); ?>`, type: 'POST', dataType: 'json', headers: { 'X-CSRF-TOKEN': token }, data: { child_id: childId, grade: childGrade }, success: function(data) { if (data.ps2) { window.location = `<?php echo e(\Illuminate\Support\Facades\URL::to('/display-selected-items')); ?>/${data.url_name}` } else if (data.success) { window.location = `<?php echo e(\Illuminate\Support\Facades\URL::to('/lunch-items-selection')); ?>/${data.url_name}` } else { window.location = `<?php echo e(route('not.available.for.child')); ?>` } }, error: function(error) {} }); }) </script> <?php $__env->stopPush(); ?> <?php echo $__env->make('front.layouts.master', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/clickysoft/public_html/calvary-p2.clickysoft.net/resources/views/front/lunch-program/index.blade.php ENDPATH**/ ?>
| ver. 1.4 |
Github
|
.
| PHP 8.1.29 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка