⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.19
Server IP:
178.33.27.10
Server:
Linux cpanel.dev-unit.com 3.10.0-1160.108.1.el7.x86_64 #1 SMP Thu Jan 25 16:17:31 UTC 2024 x86_64
Server Software:
Apache/2.4.57 (Unix) OpenSSL/1.0.2k-fips
PHP Version:
8.2.11
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
home
/
id
/
erp.dev-unit.com
/
storage
/
framework
/
views
/
View File Name :
4e449c2d595f742109e716381c601a82.php
<?php $__env->startSection('page-title'); ?> <?php echo e(__('Create Bill')); ?> <?php $__env->stopSection(); ?> <?php $__env->startSection('page-breadcrumb'); ?> <?php echo e(__('Bill')); ?> <?php $__env->stopSection(); ?> <?php $type = request()->query('type'); $projectsid = request()->query('project_id'); ?> <?php $__env->startPush('scripts'); ?> <script src="<?php echo e(asset('js/jquery-ui.min.js')); ?>"></script> <script src="<?php echo e(asset('js/jquery.repeater.min.js')); ?>"></script> <script> $(document).ready(function() { var vendorId = '<?php echo e($vendorId); ?>'; if (vendorId > 0) { $('#vendor').val(vendorId).change(); } }); $(document).on('change', '#vendor', function() { $('#vendor_detail').removeClass('d-none'); $('#vendor_detail').addClass('d-block'); $('#vendor-box').removeClass('d-block'); $('#vendor-box').addClass('d-none'); var id = $(this).val(); var url = $(this).data('url'); $.ajax({ url: url, type: 'POST', headers: { 'X-CSRF-TOKEN': jQuery('#token').val() }, data: { 'id': id }, cache: false, success: function(data) { if (data != '') { $('#vendor_detail').html(data); } else { $('#vendor-box').removeClass('d-none'); $('#vendor_detail').removeClass('d-block'); $('#vendor_detail').addClass('d-none'); } }, }); }); $(document).on('click', '#remove', function() { $('#vendor-box').removeClass('d-none'); $('#vendor_detail').removeClass('d-block'); $('#vendor_detail').addClass('d-none'); }) </script> <script> $(document).on('keyup', '.quantity', function() { var quntityTotalTaxPrice = 0; var el = $(this).parent().parent().parent().parent(); var quantity = $(this).val(); var price = $(el.find('.price')).val(); var discount = $(el.find('.discount')).val(); if (discount.length <= 0) { discount = 0; } var totalItemPrice = (quantity * price) - discount; var amount = (totalItemPrice); var totalItemTaxRate = $(el.find('.itemTaxRate')).val(); var itemTaxPrice = parseFloat((totalItemTaxRate / 100) * (totalItemPrice)); $(el.find('.itemTaxPrice')).val(itemTaxPrice.toFixed(2)); $(el.find('.amount')).html(parseFloat(itemTaxPrice) + parseFloat(amount)); var totalItemTaxPrice = 0; var itemTaxPriceInput = $('.itemTaxPrice'); for (var j = 0; j < itemTaxPriceInput.length; j++) { totalItemTaxPrice += parseFloat(itemTaxPriceInput[j].value); } var totalItemPrice = 0; var inputs_quantity = $(".quantity"); var priceInput = $('.price'); for (var j = 0; j < priceInput.length; j++) { totalItemPrice += (parseFloat(priceInput[j].value) * parseFloat(inputs_quantity[j].value)); } var inputs = $(".amount"); var subTotal = 0; for (var i = 0; i < inputs.length; i++) { subTotal = parseFloat(subTotal) + parseFloat($(inputs[i]).html()); } var sumAmount = totalItemPrice ; $('.subTotal').html((sumAmount).toFixed(2)); $('.totalTax').html(totalItemTaxPrice.toFixed(2)); $('.totalAmount').html((parseFloat(subTotal)).toFixed(2)); }) $(document).on('keyup change', '.price', function() { var el = $(this).parent().parent().parent().parent(); var price = $(this).val(); var quantity = $(el.find('.quantity')).val(); if (quantity.length <= 0) { quantity = 1; } var discount = $(el.find('.discount')).val(); if (discount.length <= 0) { discount = 0; } var totalItemPrice = (quantity * price) - discount; var amount = (totalItemPrice); var totalItemTaxRate = $(el.find('.itemTaxRate')).val(); var itemTaxPrice = parseFloat((totalItemTaxRate / 100) * (totalItemPrice)); $(el.find('.itemTaxPrice')).val(itemTaxPrice.toFixed(2)); $(el.find('.amount')).html(parseFloat(itemTaxPrice) + parseFloat(amount)); var totalItemTaxPrice = 0; var itemTaxPriceInput = $('.itemTaxPrice'); for (var j = 0; j < itemTaxPriceInput.length; j++) { totalItemTaxPrice += parseFloat(itemTaxPriceInput[j].value); } var totalItemPrice = 0; var inputs_quantity = $(".quantity"); var priceInput = $('.price'); for (var j = 0; j < priceInput.length; j++) { if (inputs_quantity[j].value <= 0) { inputs_quantity[j].value = 1; } totalItemPrice += (parseFloat(priceInput[j].value) * parseFloat(inputs_quantity[j].value)); } var inputs = $(".amount"); var subTotal = 0; for (var i = 0; i < inputs.length; i++) { subTotal = parseFloat(subTotal) + parseFloat($(inputs[i]).html()); } $('.subTotal').html((totalItemPrice).toFixed(2)); $('.totalTax').html(totalItemTaxPrice.toFixed(2)); $('.totalAmount').html((parseFloat(subTotal)).toFixed(2)); }) $(document).on('keyup change', '.discount', function() { var el = $(this).parent().parent().parent(); var discount = $(this).val(); if (discount.length <= 0) { discount = 0; } var price = $(el.find('.price')).val(); var quantity = $(el.find('.quantity')).val(); var totalItemPrice = (quantity * price) - discount; var amount = (totalItemPrice); var totalItemTaxRate = $(el.find('.itemTaxRate')).val(); var itemTaxPrice = parseFloat((totalItemTaxRate / 100) * (totalItemPrice)); $(el.find('.itemTaxPrice')).val(itemTaxPrice.toFixed(2)); $(el.find('.amount')).html(parseFloat(itemTaxPrice) + parseFloat(amount)); var totalItemTaxPrice = 0; var itemTaxPriceInput = $('.itemTaxPrice'); for (var j = 0; j < itemTaxPriceInput.length; j++) { totalItemTaxPrice += parseFloat(itemTaxPriceInput[j].value); } var totalItemPrice = 0; var inputs_quantity = $(".quantity"); var priceInput = $('.price'); for (var j = 0; j < priceInput.length; j++) { totalItemPrice += (parseFloat(priceInput[j].value) * parseFloat(inputs_quantity[j].value)); } var inputs = $(".amount"); var subTotal = 0; for (var i = 0; i < inputs.length; i++) { subTotal = parseFloat(subTotal) + parseFloat($(inputs[i]).html()); } var totalItemDiscountPrice = 0; var itemDiscountPriceInput = $('.discount'); for (var k = 0; k < itemDiscountPriceInput.length; k++) { if (itemDiscountPriceInput[k].value == '') { itemDiscountPriceInput[k].value = parseFloat(0); } totalItemDiscountPrice += parseFloat(itemDiscountPriceInput[k].value); } $('.subTotal').html((totalItemPrice).toFixed(2)); $('.totalTax').html(totalItemTaxPrice.toFixed(2)); $('.totalAmount').html((parseFloat(subTotal)).toFixed(2)); $('.totalDiscount').html(totalItemDiscountPrice.toFixed(2)); }) </script> <?php if(module_is_active('Account')): ?> <script> $(document).on('change', '.item', function() { items($(this)); }); function items(data) { var in_type = $('#bill_type').val(); if (in_type == 'product') { var iteams_id = data.val(); var url = data.data('url'); var el = data; $.ajax({ url: url, type: 'POST', headers: { 'X-CSRF-TOKEN': jQuery('#token').val() }, data: { 'product_id': iteams_id }, cache: false, success: function(data) { var item = JSON.parse(data); $(el.parent().parent().find('.quantity')).val(1); if (item.product != null) { $(el.parent().parent().find('.price')).val(item.product.purchase_price); $(el.parent().parent().parent().find('.pro_description')).val(item.product .description); } else { $(el.parent().parent().find('.price')).val(0); $(el.parent().parent().parent().find('.pro_description')).val(''); } var taxes = ''; var tax = []; var totalItemTaxRate = 0; if (item.taxes == 0) { taxes += '-'; } else { for (var i = 0; i < item.taxes.length; i++) { taxes += '<span class="p-2 px-3 mt-1 mr-1 badge bg-primary me-1">' + item.taxes[i].name + ' ' + '(' + item.taxes[i].rate + '%)' + '</span>'; tax.push(item.taxes[i].id); totalItemTaxRate += parseFloat(item.taxes[i].rate); } } var itemTaxPrice = 0; if (item.product != null) { var itemTaxPrice = parseFloat((totalItemTaxRate / 100) * (item.product.sale_price * 1)); } $(el.parent().parent().find('.itemTaxPrice')).val(itemTaxPrice.toFixed(2)); $(el.parent().parent().find('.itemTaxRate')).val(totalItemTaxRate.toFixed(2)); $(el.parent().parent().find('.taxes')).html(taxes); $(el.parent().parent().find('.tax')).val(tax); $(el.parent().parent().find('.unit')).html(item.unit); $(el.parent().parent().find('.discount')).val(0); $(el.parent().parent().find('.amount')).html(item.totalAmount); var inputs = $(".amount"); var subTotal = 0; for (var i = 0; i < inputs.length; i++) { subTotal = parseFloat(subTotal) + parseFloat($(inputs[i]).html()); } var totalItemPrice = 0; var priceInput = $('.price'); for (var j = 0; j < priceInput.length; j++) { totalItemPrice += parseFloat(priceInput[j].value); } var totalItemTaxPrice = 0; var itemTaxPriceInput = $('.itemTaxPrice'); for (var j = 0; j < itemTaxPriceInput.length; j++) { totalItemTaxPrice += parseFloat(itemTaxPriceInput[j].value); if (item.product != null) { $(el.parent().parent().find('.amount')).html(parseFloat(item.totalAmount) + parseFloat(itemTaxPriceInput[j].value)); } } var totalItemDiscountPrice = 0; var itemDiscountPriceInput = $('.discount'); for (var k = 0; k < itemDiscountPriceInput.length; k++) { totalItemDiscountPrice += parseFloat(itemDiscountPriceInput[k].value); } $('.subTotal').html(totalItemPrice.toFixed(2)); $('.totalTax').html(totalItemTaxPrice.toFixed(2)); $('.totalAmount').html((parseFloat(totalItemPrice) - parseFloat( totalItemDiscountPrice) + parseFloat(totalItemTaxPrice)).toFixed(2)); }, }); } } </script> <?php endif; ?> <?php if(module_is_active('Taskly')): ?> <script> $(document).on('change', '.item', function() { var iteams_id = $(this).val(); var el = $(this); $(el.parent().parent().find('.price')).val(0); $(el.parent().parent().find('.amount')).html(0); $(el.parent().parent().find('.taxes')).val(0); var proposal_type = $("#proposal_type").val(); if (proposal_type == 'project') { $("#tax_project").change(); } }); $(document).on('change', '#tax_project', function() { var tax_id = $(this).val(); if (tax_id.length != 0) { $.ajax({ type: 'post', url: "<?php echo e(route('get.taxes')); ?>", data: { _token: "<?php echo e(csrf_token()); ?>", tax_id: tax_id, }, beforeSend: function() { $("#loader").removeClass('d-none'); }, success: function(response) { var response = jQuery.parseJSON(response); if (response != null) { $("#loader").addClass('d-none'); var TaxRate = 0; if (response.length > 0) { $.each(response, function(i) { TaxRate = parseInt(response[i]['rate']) + TaxRate; }); } $(".itemTaxRate").val(TaxRate); $(".price").change(); } else { $(".itemTaxRate").val(0); $(".price").change(); $('.section_div').html(''); toastrs('Error', 'Something went wrong please try again !', 'error'); } }, }); } else { $(".itemTaxRate").val(0); $('.taxes').html(""); $(".price").change(); $("#loader").addClass('d-none'); } }); </script> <?php endif; ?> <?php if(module_is_active('Account')): ?> <script> $(document).ready(function() { SectionGet('product'); }); </script> <?php elseif(module_is_active('Taskly')): ?> <script> $(document).ready(function() { SectionGet('project'); }); </script> <?php endif; ?> <script> $(document).on('click', '[data-repeater-delete]', function() { $(".price").change(); $(".discount").change(); }); </script> <script> $(document).on('change', "[name='bill_type_radio']", function() { var val = $(this).val(); $(".bill_div").empty(); if (val == 'product') { $(".discount_apply_div").removeClass('d-none'); $(".tax_project_div").addClass('d-none'); $(".discount_project_div").addClass('d-none'); var label = `<?php echo e(Form::label('category_id', __('Category'), ['class' => 'form-label'])); ?> <?php echo e(Form::select('category_id', $category, null, ['class' => 'form-control', 'required' => 'required'])); ?>`; $(".bill_div").append(label); $("#bill_type").val('product'); SectionGet(val); } else if (val == 'project') { $(".discount_apply_div").addClass('d-none'); $(".tax_project_div").removeClass('d-none'); $(".discount_project_div").removeClass('d-none'); var label = ` <?php echo e(Form::label('project', __('Project'), ['class' => 'form-label'])); ?> <?php echo e(Form::select('project', $projects, $projectsid, ['class' => 'form-control', 'required' => 'required'])); ?>` $(".bill_div").append(label); $("#bill_type").val('project'); var project_id = $("#project").val(); SectionGet(val, project_id); } choices(); }); function SectionGet(type = 'product', project_id = "0", title = 'Project') { $.ajax({ type: 'post', url: "<?php echo e(route('bill.section.type')); ?>", data: { _token: "<?php echo e(csrf_token()); ?>", type: type, project_id: project_id, acction: 'create', }, beforeSend: function() { $("#loader").removeClass('d-none'); }, success: function(response) { if (response != false) { $('.section_div').html(response.html); $("#loader").addClass('d-none'); $('.pro_name').text(title) // for item SearchBox ( this function is custom Js ) JsSearchBox(); } else { $('.section_div').html(''); toastrs('Error', 'Something went wrong please try again !', 'error'); } }, }); } $(document).on('change', "#project", function() { var title = $(this).find('option:selected').text(); var project_id = $(this).val(); SectionGet('project', project_id, title); }); </script> <?php $__env->stopPush(); ?> <?php $__env->startSection('content'); ?> <div class="row"> <?php echo e(Form::open(['url' => 'bill', 'class' => 'w-100 needs-validation', 'novalidate', 'enctype' => 'multipart/form-data'])); ?> <input type="hidden" name="_token" id="token" value="<?php echo e(csrf_token()); ?>"> <input type="hidden" name="redirect_route" value="<?php echo e(isset($_GET['redirect_route']) ? $_GET['redirect_route'] : null); ?>"> <?php if(module_is_active('Account')): ?> <input type="hidden" name="bill_type" id="bill_type" value="product"> <?php elseif(module_is_active('Taskly')): ?> <input type="hidden" name="bill_type" id="bill_type" value="project"> <?php endif; ?> <div class="col-12"> <div class="card"> <div class="card-body"> <div class="row"> <div class="col-xs-12 col-sm-12 col-md-6 col-lg-6"> <div class="row" id="vendor-box"> <div class="form-group col-md-6" id="account-box"> <label class="reqire form-label"><?php echo e(__('Account Type')); ?></label><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <select class="form-control account_type <?php echo e(!empty($errors->first('account_type')) ? 'is-invalid' : ''); ?>" name="account_type" required id="account_type"> <option value=""><?php echo e(__('Select Account Type')); ?></option> <?php if(module_is_active('Account')): ?> <option value="Accounting"><?php echo e(__('Accounting')); ?></option> <?php endif; ?> <?php if(module_is_active('Taskly')): ?> <option value="Projects" <?php if($type == 'project'): ?> selected <?php endif; ?>><?php echo e(__('Projects')); ?></option> <?php endif; ?> </select> </div> <div class="form-group col-md-6"> <?php if(module_is_active('Account')): ?> <div class="form-group"> <?php echo e(Form::label('vendor_id', __('Vendor'), ['class' => 'form-label'])); ?><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php echo e(Form::select('vendor_id', $vendors, $vendorId, ['class' => 'form-control ', 'id' => 'vendor', 'data-url' => route('bill.vendor'), 'required' => 'required', 'placeholder' => 'Select vendor'])); ?> <?php if(empty($vendors->count())): ?> <div class="text-xs "> <?php echo e(__('Please create vendor/Client first.')); ?> <a <?php if(module_is_active('Account')): ?> href="<?php echo e(route('vendors.index')); ?>" <?php else: ?> href="<?php echo e(route('users.index')); ?>" <?php endif; ?>><b><?php echo e(__('Create vendor/Client')); ?></b></a> </div> <?php endif; ?> </div> <?php else: ?> <div class="form-group"> <?php echo e(Form::label('vender_name', __('Vendor'), ['class' => 'form-label'])); ?><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php echo e(Form::text('vender_name', null, ['class' => 'form-control ', 'placeholder' => 'Enter vender name', 'required' => 'required'])); ?> </div> <?php endif; ?> </div> </div> <div id="vendor_detail" class="d-none"> </div> </div> <div class="col-xs-12 col-sm-12 col-md-6 col-lg-6"> <div class="row"> <div class="col-md-12"> <div class="form-group"> <div class="form-group col-md-6"> <label class="require form-label"><?php echo e(__('Billing Type')); ?></label> <select class="form-control <?php echo e(!empty($errors->first('Billing Type')) ? 'is-invalid' : ''); ?>" name="bill_type_radio" required="" id="billing_type"> <option value=""><?php echo e(__('Select Billing Type')); ?></option> <option value="product" id="product" class="d-none"><?php echo e(__('Item Wise')); ?></option> <option value="project" id="project1" class="d-none"><?php echo e(__('Project Wise')); ?> </option> </select> <div class="invalid-feedback"> <?php echo e($errors->first('billing_type')); ?> </div> </div> </div> </div> <div class="col-md-6"> <div class="form-group"> <?php echo e(Form::label('bill_date', __('Bill Date'), ['class' => 'form-label'])); ?><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <div class="form-icon-user"> <?php echo e(Form::date('bill_date', date('Y-m-d'), ['class' => 'form-control ', 'required' => 'required', 'placeholder' => 'Select Issue Date'])); ?> </div> </div> </div> <div class="col-md-6"> <div class="form-group"> <?php echo e(Form::label('due_date', __('Due Date'), ['class' => 'form-label'])); ?><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <div class="form-icon-user"> <?php echo e(Form::date('due_date', date('Y-m-d'), ['class' => 'form-control ', 'required' => 'required', 'placeholder' => 'Select Due Date'])); ?> </div> </div> </div> <div class="col-md-6"> <div class="form-group"> <?php echo e(Form::label('bill_number', __('Bill Number'), ['class' => 'form-label'])); ?> <div class="form-icon-user"> <input type="text" class="form-control" value="<?php echo e($bill_number); ?>" readonly> </div> </div> </div> <div class="col-md-6"> <div class="form-group bill_div"> <?php if(module_is_active('Account')): ?> <?php echo e(Form::label('category_id', __('Category'), ['class' => 'form-label'])); ?><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php echo e(Form::select('category_id', $category, null, ['class' => 'form-control ', 'required' => 'required', 'placeholder' => 'Select Category'])); ?> <?php if(empty($category->count())): ?> <div class="text-xs "> <?php echo e(__('Please add constant category. ')); ?><a href="<?php echo e(route('category.index')); ?>"><b><?php echo e(__('Add Category')); ?></b></a> </div> <?php endif; ?> <?php elseif(module_is_active('Taskly')): ?> <?php echo e(Form::label('project', __('Project'), ['class' => 'form-label'])); ?><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php echo e(Form::select('project', $projects, null, ['class' => 'form-control ', 'required' => 'required'])); ?> <?php endif; ?> </div> </div> <div class="col-md-6"> <div class="form-group"> <?php echo e(Form::label('order_number', __('Order Number'), ['class' => 'form-label'])); ?><?php if (isset($component)) { $__componentOriginaleab1765d328ab3f8835fc5d78676a070 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginaleab1765d328ab3f8835fc5d78676a070 = $attributes; } ?> <?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.required','data' => []] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?> <?php $component->withName('required'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?> <?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $attributes = $__attributesOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__attributesOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <?php if (isset($__componentOriginaleab1765d328ab3f8835fc5d78676a070)): ?> <?php $component = $__componentOriginaleab1765d328ab3f8835fc5d78676a070; ?> <?php unset($__componentOriginaleab1765d328ab3f8835fc5d78676a070); ?> <?php endif; ?> <div class="form-icon-user"> <?php echo e(Form::number('order_number', null, ['class' => 'form-control', 'required' => 'required'])); ?> </div> </div> </div> <?php if(module_is_active('Taskly')): ?> <div class="col-md-6 tax_project_div <?php echo e(module_is_active('Account') ? 'd-none' : ''); ?>"> <div class="form-group"> <?php echo e(Form::label('tax_project', __('Tax'), ['class' => 'form-label'])); ?> <?php echo e(Form::select('tax_project[]', $taxs, null, ['class' => 'form-control get_tax multi-select choices', 'data-toggle' => 'select2', 'multiple' => 'multiple', 'id' => 'tax_project', 'data-placeholder' => 'Select Tax'])); ?> </div> </div> <?php endif; ?> <?php if(module_is_active('CustomField') && !$customFields->isEmpty()): ?> <div class="col-md-12"> <div class="tab-pane fade show" id="tab-2" role="tabpanel"> <?php echo $__env->make('custom-field::formBuilder', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> </div> </div> <?php endif; ?> <?php echo $__env->yieldPushContent('recurring_div'); ?> </div> </div> </div> </div> </div> </div> <div id="loader" class="card card-flush"> <div class="card-body"> <div class="row"> <img class="loader" src="<?php echo e(asset('public/images/loader.gif')); ?>" alt=""> </div> </div> </div> <div class="col-12 section_div"> </div> <div class="modal-footer"> <input type="button" value="<?php echo e(__('Cancel')); ?>" onclick="location.href = '<?php echo e(route('bill.index')); ?>';" class="btn btn-light me-2"> <input type="submit" value="<?php echo e(__('Create')); ?>" class="btn btn-primary" id="submit"> </div> <?php echo e(Form::close()); ?> </div> <?php $__env->stopSection(); ?> <?php $__env->startPush('scripts'); ?> <script src="<?php echo e(asset('js/jquery-searchbox.js')); ?>"></script> <script> $(document).ready(function() { $('#account_type').on('change', function() { if ($(this).val() === 'Accounting') { $('#product').removeClass('d-none').show(); $('#project1').addClass('d-none').hide(); } else { $('#product').addClass('d-none').hide(); $('#project1').removeClass('d-none').show(); } }); var type = '<?php echo e($type); ?>'; if(type == 'project'){ $('#account_type').trigger('change'); } }); </script> <script> $("#submit").click(function() { var skill = $('.account_type').val(); if (skill == '') { $('#account_validation').removeClass('d-none') toastrs('Error', 'Account Type field is required!', 'error'); return false; } else { $('#account_validation').addClass('d-none') } }); </script> <?php $__env->stopPush(); ?> <?php echo $__env->make('layouts.main', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/id/erp.dev-unit.com/packages/workdo/Account/src/Providers/../Resources/views/bill/create.blade.php ENDPATH**/ ?>