/
home
/
sjslayjy
/
public_html
/
olddevlok
/
storage
/
framework
/
views
/
Upload File
HOME
<?php $__env->startSection('title','Generate Loading Slip Invoice'); ?> <?php $__env->startSection('content'); ?> <div class="main-content"> <div class="main-content-inner"> <div class="breadcrumbs ace-save-state" id="breadcrumbs"> <ul class="breadcrumb"> <li> <i class="ace-icon fa fa-home home-icon"></i> <a href="#"><?php echo e(__('messages.Home')); ?></a> </li> <li><a href="<?php echo e('/user/generated-invoices'); ?>"><?php echo e(__('messages.GeneratedInvoices')); ?></a></li> <li class="active"><?php echo e(__('messages.GenerateLoadingSlipInvoice')); ?></li> </ul> </div> <div class="page-content"> <div class="page-header"> <h1> <?php echo e(__('messages.GenerateLoadingSlipInvoice')); ?> </h1> </div><!-- /.page-header --> <div class="container"> <div class="row"> <div class="panel panel-primary"> <div class="panel-heading"> <h3 class="panel-title"><?php echo e(__('messages.InvoiceGenerationForm')); ?></h3> </div> <div class="panel-body"> <div class="col-md-4"> <div class="form-group"> <label for="qr_data"><?php echo e(__('messages.LoadingSlip')); ?></label> <input type="text" class="form-control" name="qr_data" id="qr_data" onchange="getLoadingSlipDetails(this.value)"> </div> </div> <div class="clearfix"></div> <form action="<?php echo e(url('/user/generate-loading-slip-invoice')); ?>" method="post" role="form" id="generateInvoiceForm" onsubmit="return validateForm()"> <?php echo e(csrf_field()); ?> <div id="details"></div> </div> </div> </div> </div> </form> </div> </div><!-- /.page-content --> </div><!-- /.main-content --> <?php $__env->startSection('script'); ?> <?php echo e(Html::script("assets/js/ace-elements.min.js")); ?> <?php echo e(Html::script("assets/js/ace.min.js")); ?> <?php echo e(Html::script("assets/js/bootstrap-datepicker.min.js")); ?> <script type="text/javascript"> $(document).ready(function() { $('#qr_data').focus(); $('.date-picker').datepicker({ format: 'dd/mm/yyyy', endDate: '+0d', autoclose: true }); }); function submitForm(){ $('#generateInvoiceForm').submit(); } function validateForm(){ if($('#breakInvoice').prop('checked')){ var total_quantity = $('#total_quantity').val(); debugger; var entered_quantity = 0; debugger; $(".quantity_validator").each(function() { entered_quantity = parseInt(entered_quantity) + parseInt($(this).val()); }); debugger; if(entered_quantity > total_quantity){ swal('Error','Entered Quantity Should not be greater than total Quantity ('+total_quantity+')','error'); return false; }else if(entered_quantity < total_quantity){ swal('Error','Entered Quantity Should not be less than total Quantity ('+total_quantity+')','error'); return false; }else{ return true; } }else{ var total_amount = parseInt($('#total_amount').val()); if($('#qr_data').val() == ""){ swal('Error','Please Select Loading Slip','error'); return false; }else if($('#invoice_type_id').val() == ""){ swal('Error','Please Select Invoice Type','error'); return false; }else if($('#invoice_date').val() == ""){ swal('Error','Please Enter Invoice Date','error'); return false; }else if(total_amount >= 50000 && $('#eway_bill_no').val() == ""){ swal('Error','Please Enter Eway Bill','error'); return false; }else{ return true; } } } function getLoadingSlipDetails(qr_data){ if(qr_data != ""){ $(".loading-bg").show(); var url ="<?php echo e(url('/user/loading-slip-details')); ?>"; $.ajax({ url: url+"/"+qr_data, type: 'GET', success:function(data){ $(".loading-bg").hide(); $('#details').html(data); } }); } $('.date-picker').datepicker({ format: 'dd/mm/yyyy', endDate: '+0d', autoclose: true }); } </script> <?php $__env->stopSection(); ?> <?php $__env->stopSection(); ?> <?php echo $__env->make('dashboard.layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/pmmsanvp/public_html/srt/resources/views/dashboard/invoice/generate-loading-slip-invoice.blade.php ENDPATH**/ ?>