관리-도구
편집 파일: 48d428bc4795679c36d5d4b53729f8ce.php
<?php $__env->startSection('content'); ?> <script src="https://code.jquery.com/jquery-3.4.1.slim.min.js" integrity="sha384-J6qa4849blE2+poT4WnyKhv5vZF5SrPo0iEjwBvKU7imGFAV0wwj1yYfoRSJoZ+n" crossorigin="anonymous"></script> <link href="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote-lite.min.css" rel="stylesheet"> <script src="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote-lite.min.js"></script> <!-- partial --> <div class="main-panel"> <div class="content-wrapper"> <style> .description-cell { max-width: 200px; /* Adjust the value as needed */ white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } </style> <div class="row"> <div class="col-lg-12 grid-margin stretch-card"> <div class="card"> <div class="card-body"> <div class="d-flex justify-content-between"> <h3 class="text-center"><b>Project Category</b></h3> <button class="btn btn-success" data-toggle="modal" data-target="#addService">Add new Category +</button> </div> <hr> <div class="table-responsive"> <table class="table table-hover"> <thead> <tr> <th>#</th> <th>Project Category</th> <th>Location</th> <th>Image</th> <th class="text-center">Action</th> </tr> </thead> <tbody> <?php $__currentLoopData = $pjtcat; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $service): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <tr> <td><?php echo e($loop->iteration); ?></td> <td><?php echo e($service->projectcategory); ?></td> <td><?php echo e($service->location); ?></td> <td><img src="<?php echo e(asset('storage/' . $service->image)); ?>" alt=""></td> <td class="text-center"> <button class="btn btn-primary my-2" data-toggle="modal" data-target="#updateService<?php echo e($service->id); ?>"><i class="fa fa-pen"></i></button> <form method="post" action="<?php echo e(route('admin-projectcategory.destroy', $service->id)); ?>"> <?php echo csrf_field(); ?> <?php echo method_field('DELETE'); ?> <button class="btn btn-danger my-2"><i class="fa fa-trash"></i></button> </form> </td> </tr> <!--update Service Modal --> <div class="modal fade" id="updateService<?php echo e($service->id); ?>" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true"> <div class="modal-dialog modal-dialog-centered" role="document"> <div class="modal-content"> <div class="modal-header"> <h5 class="modal-title" id="exampleModalLongTitle">Update Project Category</h5> <button type="button" class="close" data-dismiss="modal" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> <div class="modal-body"> <div class="card"> <div class="card-body"> <form method="post" action="<?php echo e(route('admin-projectcategory.update', $service->id)); ?>"> <?php echo csrf_field(); ?> <?php echo method_field('PUT'); ?> <div class="form-group"> <label for="exampleInputImage">Image</label> <input type="file" name="image" class="form-control" id="exampleInputImage" placeholder="Upload service image"> <?php if($service->image): ?> <div> <img src="<?php echo e(asset('storage/' . $service->image)); ?>" alt="Selected Image" style="max-width: 100px; max-height: 100px;"> </div> <?php endif; ?> </div> <div class="form-group"> <label for="title">Product Category</label> <input type="text" name="projectcategory" value="<?php echo e(old('service', $service->projectcategory)); ?>" class="form-control" id="title" placeholder="Enter Projectcategory"> </div> <div class="form-group"> <label for="title">Location</label> <input type="text" name="location" value="<?php echo e(old('service', $service->location)); ?>" class="form-control" id="title" placeholder="Enter Location"> </div> <div class="text-center"> <button type="submit" class="btn btn-primary w-50">Submit</button> </div> </form> </div> </div> </div> </div> </div> </div> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> </tbody> </table> </div> </div> </div> </div> </div> </div> <!-- content-wrapper ends --> <!--Add Service Modal --> <div class="modal fade" id="addService" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true"> <div class="modal-dialog modal-dialog-centered" role="document"> <div class="modal-content"> <div class="modal-header"> <h5 class="modal-title" id="exampleModalLongTitle">Add new Project Category</h5> <button type="button" class="close" data-dismiss="modal" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> <div class="modal-body"> <div class="card"> <div class="card-body"> <form method="post" action="<?php echo e(route('admin-projectcategory.store')); ?>" enctype="multipart/form-data"> <?php echo csrf_field(); ?> <div class="form-group"> <label for="exampleInputImage">Image</label> <input type="file" name="image" class="form-control" id="exampleInputImage"> <?php $__errorArgs = ['image']; $__bag = $errors->getBag($__errorArgs[1] ?? 'default'); if ($__bag->has($__errorArgs[0])) : if (isset($message)) { $__messageOriginal = $message; } $message = $__bag->first($__errorArgs[0]); ?> <div class="alert alert-danger"><?php echo e($message); ?></div> <?php unset($message); if (isset($__messageOriginal)) { $message = $__messageOriginal; } endif; unset($__errorArgs, $__bag); ?> </div> <div class="form-group"> <label for="serviceTitle">Project Category</label> <input type="text" name="projectcategory" class="form-control" id="serviceTitle" placeholder="Enter Projectcategory" required> </div> <div class="form-group"> <label for="serviceTitle">Location</label> <input type="text" name="location" class="form-control" id="serviceTitle" placeholder="Enter Location" required> </div> <div class="text-center"> <button type="submit" class="btn btn-primary w-50">Submit</button> </div> </form> </div> </div> </div> </div> </div> </div> <script> $('#summernote').summernote({ placeholder: 'Description', tabsize: 2, height: 120, toolbar: [ ['style', ['style']], ['font', ['bold', 'underline', 'clear']], ['color', ['color']], ['para', ['ul', 'ol', 'paragraph']], ['table', ['table']], ['insert', ['link', 'picture', 'video']], ['view', ['fullscreen', 'codeview', 'help']] ] }); </script> <script> $('#summernotes').summernote({ placeholder: 'Description', tabsize: 2, height: 120, toolbar: [ ['style', ['style']], ['font', ['bold', 'underline', 'clear']], ['color', ['color']], ['para', ['ul', 'ol', 'paragraph']], ['table', ['table']], ['insert', ['link', 'picture', 'video']], ['view', ['fullscreen', 'codeview', 'help']] ] }); </script> <?php $__env->stopSection(); ?> <?php echo $__env->make('layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/u539723576/domains/ictglobaltech.com/public_html/roomgeardesigns/resources/views/admin/projectcategory.blade.php ENDPATH**/ ?>