CHANGE_jobcard_discount_calculation:ss
This commit is contained in:
parent
2c9289f309
commit
2248bd425f
@ -400,6 +400,10 @@ class Jobcard extends BaseController
|
||||
'billing_city' => $this->request->getPost('city'),
|
||||
'billing_state' => $this->request->getPost('state'),
|
||||
'billing_postal_code' => $this->request->getPost('postalcode'),
|
||||
'fuel_qty'=> $this->request->getPost('fuel_qty'),
|
||||
'meter'=> $this->request->getPost('meter'),
|
||||
'delivery_date'=> $this->request->getPost('delivery_date'),
|
||||
'note'=> $this->request->getPost('note'),
|
||||
'status'=> $this->request->getPost('status'),
|
||||
'assigned_to'=> json_encode($this->request->getPost('assigned_to')),
|
||||
// 'store_item_issued'=> $this->request->getPost('store_item_issued'),
|
||||
|
||||
@ -8,7 +8,8 @@ class JobcardModel extends Model
|
||||
protected $allowedFields = ['job_card_id','inv_no','vehicle_id','branch_id',
|
||||
'order_number','client_mobile_no','client_name',
|
||||
'billing_address','billing_city','billing_state','billing_country',
|
||||
'billing_postal_code','status','assigned_to', 'store_item_issued','subtotal','tax', 'discount','total','isactive'];
|
||||
'billing_postal_code','fuel_qty', 'meter', 'delivery_date', 'note',
|
||||
'status','assigned_to', 'store_item_issued','subtotal','tax', 'discount','total','isactive'];
|
||||
|
||||
|
||||
|
||||
|
||||
@ -80,6 +80,25 @@
|
||||
<input type="text" class="form-control" name="postalcode" placeholder="PIN Code"value="<?= isset($jobs['billing_postal_code']) ? $jobs['billing_postal_code'] : '' ?>" maxlength="6" minlength="6" >
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<div class="form-row">
|
||||
<div class="form-group col-md-3">
|
||||
<label for="inputPassword4" class="col-form-label">Fuel Qty<span class="text-danger"></span></label>
|
||||
<input type="text" class="form-control" name="fuel_qty" placeholder="Fuel Qty"value="<?= isset($jobs['fuel_qty']) ? $jobs['fuel_qty'] : '' ?>" >
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="inputPassword4" class="col-form-label">Meter Reading<span class="text-danger"></span></label>
|
||||
<input type="text" class="form-control" name="meter" placeholder="Meter Reading"value="<?= isset($jobs['meter']) ? $jobs['meter'] : '' ?>" >
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="inputPassword4" class="col-form-label">Delivery Date<span class="text-danger"></span></label>
|
||||
<input type="date" class="form-control" name="delivery_date" placeholder="Delivery Date" value="<?= isset($jobs['delivery_date']) ? $jobs['delivery_date'] : '' ?>">
|
||||
</div>
|
||||
<div class="form-group col-md-3">
|
||||
<label for="inputPassword4" class="col-form-label">Note<span class="text-danger"></span></label>
|
||||
<input type="text" class="form-control" name="note" placeholder="Note"value="<?= isset($jobs['note']) ? $jobs['note'] : '' ?>" >
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-row">
|
||||
<div class="form-group col-md-3">
|
||||
<label for="inputPassword4" class="col-form-label">Status<span class="text-danger">*</span>(<?php echo isset($jobs['status']) ? $jobs['status'] : '' ?>)</label>
|
||||
@ -316,7 +335,7 @@ $(document).ready(async function() {
|
||||
for (const value of edit_service_data) {
|
||||
servicearray = <?php echo isset($service_1) ? json_encode($service_1) : json_encode($service) ?>;
|
||||
// console.log(servicearray);
|
||||
var newRow = `<tr class="service_class"><td hidden style="width:10%;">
|
||||
var newRow = `<tr class="service_class"><td hidden>
|
||||
<input type="number" class="form-control labour_cost" name="labour_cost" value="${value.labour_cost}"></td>
|
||||
<td><select class="form-control book-select SelExample service" name="service_details[]" required data-toggle="select2" style="width: 249px !important;">`;
|
||||
|
||||
@ -330,19 +349,19 @@ $(document).ready(async function() {
|
||||
|
||||
|
||||
newRow += '</select></td>' +
|
||||
'<td style="width:10%;"><input hidden type="text" class="form-control rate-d-only" value="'+value.amount+'" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input hidden type="text" class="form-control item-rate1" value="'+value.amount+'" name="unit-price[]" readonly /></td>' +
|
||||
'<td style="width:10%;"><input hidden type="number" class="form-control item-quantity" min="0" value="'+value.qty+'" name="quantity[]" readonly/></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control item-tax" value="'+value.tax+'" name="item-tax[]" readonly /></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td style="width:12%;"><input hidden type="text" class="form-control item-amount1" value="'+value.amount+'" name="amount[]"/></td>' +
|
||||
'<td><input hidden type="text" class="form-control rate-d-only" value="'+value.amount+'" readonly /></td>' +
|
||||
'<td hidden><input hidden type="text" class="form-control item-rate1" value="'+value.amount+'" name="unit-price[]" readonly /></td>' +
|
||||
'<td><input hidden type="number" class="form-control item-quantity" min="0" value="'+value.qty+'" name="quantity[]" readonly/></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-tax" value="'+value.tax+'" name="item-tax[]" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-amount1" value="'+value.amount+'" name="amount[]"/></td>' +
|
||||
'<td><center><i class="fa fa-trash remove-item"></i></center><input value="service" name="item_type" hidden></td>' +
|
||||
'<td hidden><input name="id" value="'+value.job_card_service_id+'"></td>' +
|
||||
'</tr>';
|
||||
|
||||
// console.log(value);
|
||||
tr = $('#productItemTable tbody').append(newRow);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
/** APPEND CHILD PRODUCT */
|
||||
await edit_product_data(value.product);
|
||||
editlabourcost(value,'service_lb');
|
||||
@ -355,7 +374,7 @@ $(document).ready(async function() {
|
||||
for (const value of edit_complaint_data) {
|
||||
complaint = <?php echo json_encode($complaint) ?>;
|
||||
// console.log(productarray);
|
||||
var newRow = '<tr class="complaint_class"><td hidden style="width:10%;"> <input type="number" class="form-control labour_cost" name="labour_cost" value="'+value.labour_cost+'"></td><td><select class="form-control book-select SelExample complaint" id="complaint_detail" name="complaint_details[]" required data-toggle="select2" style="width: 249px !important;">';
|
||||
var newRow = '<tr class="complaint_class"><td hidden> <input type="number" class="form-control labour_cost" name="labour_cost" value="'+value.labour_cost+'"></td><td><select class="form-control book-select SelExample complaint" id="complaint_detail" name="complaint_details[]" required data-toggle="select2" style="width: 249px !important;">';
|
||||
|
||||
for (var i = 0; i < complaint.length; i++)
|
||||
{
|
||||
@ -365,12 +384,12 @@ $(document).ready(async function() {
|
||||
}
|
||||
|
||||
newRow += '</select></td>' +
|
||||
'<td style="width:10%;"><input hidden type="text" class="form-control rate-d-only" value="'+value.amount+'" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input hidden type="text" class="form-control item-rate1" value="'+value.amount+'" name="unit-price[]" readonly /></td>' +
|
||||
'<td style="width:10%;"><input hidden type="number" class="form-control item-quantity" min="0" value="'+value.qty+'" name="quantity[]" readonly/></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control item-tax" value="'+value.tax+'" name="item-tax[]" readonly /></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td style="width:12%;"><input hidden type="text" class="form-control item-amount1" value="'+value.amount+'" name="amount[]"/></td>' +
|
||||
'<td><input hidden type="text" class="form-control rate-d-only" value="'+value.amount+'" readonly /></td>' +
|
||||
'<td hidden><input hidden type="text" class="form-control item-rate1" value="'+value.amount+'" name="unit-price[]" readonly /></td>' +
|
||||
'<td><input hidden type="number" class="form-control item-quantity" min="0" value="'+value.qty+'" name="quantity[]" readonly/></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-tax" value="'+value.tax+'" name="item-tax[]" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-amount1" value="'+value.amount+'" name="amount[]"/></td>' +
|
||||
'<td><div style="display: inline-block;">'+
|
||||
'<center><i class="fa fa-trash remove-item"></i></center>'+
|
||||
'</div>'+
|
||||
@ -386,7 +405,7 @@ $(document).ready(async function() {
|
||||
|
||||
|
||||
$('#productItemTable tbody').append(newRow);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
/** APPEND CHILD PRODUCT */
|
||||
await edit_product_data(value.product);
|
||||
editlabourcost(value,'complaint_lb')
|
||||
@ -397,13 +416,13 @@ $(document).ready(async function() {
|
||||
var edit_ccomplaint_data = <?php echo isset($editccomplaintdata) ? json_encode($editccomplaintdata) : 0 ?>;
|
||||
if(edit_ccomplaint_data.length > 0) {
|
||||
for (const value of edit_ccomplaint_data) {
|
||||
var newRow = '<tr class="custom_complaint_class"><td hidden style="width:10%;"> <input type="number" class="form-control labour_cost" name="labour_cost" value="'+value.labour_cost+'"></td><td><textarea class="form-control custom-comp" id="custom_complaint_detail" rows="5">'+value.name+'</textarea></td>' +
|
||||
'<td style="width:10%;"><input hidden type="text" class="form-control rate-d-only" value="'+value.amount+'" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input hidden type="text" class="form-control item-rate1" value="'+value.amount+'" name="unit-price[]" /></td>' +
|
||||
'<td style="width:10%;"><input hidden type="number" class="form-control item-quantity" min="0" value="'+value.qty+'" name="quantity[]" readonly/></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control item-tax" value="'+value.tax+'" name="item-tax[]" /></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td style="width:12%;"><input hidden type="text" class="form-control item-amount1" value="'+value.amount+'" name="amount[]"/></td>' +
|
||||
var newRow = '<tr class="custom_complaint_class"><td hidden> <input type="number" class="form-control labour_cost" name="labour_cost" value="'+value.labour_cost+'"></td><td><textarea class="form-control custom-comp" id="custom_complaint_detail" rows="5">'+value.name+'</textarea></td>' +
|
||||
'<td><input hidden type="text" class="form-control rate-d-only" value="'+value.amount+'" readonly /></td>' +
|
||||
'<td hidden><input hidden type="text" class="form-control item-rate1" value="'+value.amount+'" name="unit-price[]" /></td>' +
|
||||
'<td><input hidden type="number" class="form-control item-quantity" min="0" value="'+value.qty+'" name="quantity[]" readonly/></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-tax" value="'+value.tax+'" name="item-tax[]" /></td>' +
|
||||
'<td><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-amount1" value="'+value.amount+'" name="amount[]"/></td>' +
|
||||
'<td><div style="display: inline-block;">'+
|
||||
'<center><i class="fa fa-trash remove-item"></i></center>'+
|
||||
'</div>'+
|
||||
@ -419,7 +438,7 @@ $(document).ready(async function() {
|
||||
|
||||
|
||||
$('#productItemTable tbody').append(newRow);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
/** APPEND CHILD PRODUCT */
|
||||
await edit_product_data(value.product);
|
||||
editlabourcost(value,'custom_complaint_lb')
|
||||
@ -429,20 +448,20 @@ $(document).ready(async function() {
|
||||
function editlabourcost(data,cls) {
|
||||
total_wih_tax = parseInt(data.labour_cost) + (parseInt(data.labour_cost) * (data.tax / 100));
|
||||
total_tax_amt = total_wih_tax - parseInt(data.labour_cost);
|
||||
var newRow = '<tr class="'+cls+'"><td hidden style="width:10%;"><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fas fa-user-alt" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><input type="text" class="form-control labour_cost" readonly value="Labour Cost"></td>' +
|
||||
'<td style="width:10%;"><input type="text" class="form-control rate-d-only" value="'+data.labour_cost+'" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input hidden type="text" class="form-control item-rate" name="unit-price[]" value="'+data.labour_cost +'" /></td>' +
|
||||
'<td style="width:10%;"><input type="number" class="form-control item-quantity-'+cls+' item-quantity" min="0" name="quantity[]" value="1" readonly /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="'+data.tax+'" readonly /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control total-tax-amount" value="'+Math.round(total_tax_amt)+'" readonly /></td>' +
|
||||
'<td style="width:12%;"><input type="text" class="form-control item-amount lab_amt" name="amount[]" value="' + Math.round(total_wih_tax) + '" /></td>' +
|
||||
var newRow = '<tr class="'+cls+'"><td hidden><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fas fa-user-alt" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><input type="text" class="form-control labour_cost" readonly value="Labour Cost"></td>' +
|
||||
'<td><input type="text" class="form-control rate-d-only" value="'+data.labour_cost+'" readonly /></td>' +
|
||||
'<td hidden><input hidden type="text" class="form-control item-rate" name="unit-price[]" value="'+data.labour_cost +'" /></td>' +
|
||||
'<td><input type="number" class="form-control item-quantity-'+cls+' item-quantity" min="0" name="quantity[]" value="1" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="'+data.tax+'" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control total-tax-amount" value="'+Math.round(total_tax_amt)+'" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control item-amount lab_amt" name="amount[]" value="' + Math.round(total_wih_tax) + '" /></td>' +
|
||||
'<td hidden></td>' +
|
||||
'<td hidden></td>' +
|
||||
'</tr>';
|
||||
|
||||
$('#productItemTable tbody').append(newRow);
|
||||
// $(newRow).insertAfter(tr);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
}
|
||||
|
||||
function edit_product_data(products) {
|
||||
@ -460,18 +479,18 @@ $(document).ready(async function() {
|
||||
{
|
||||
action = '<center><i class="fa fa-trash remove-item" id="remove-item"></i></center>';
|
||||
}
|
||||
var newRow = `<tr class="product"><td hidden style="width:10%;"><input type="number" class="form-control labour_cost" name="labour_cost"></td>
|
||||
var newRow = `<tr class="product"><td hidden><input type="number" class="form-control labour_cost" name="labour_cost"></td>
|
||||
<td style="padding-left: 40px !important;"><i class="fa fa-wrench" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i>
|
||||
<select class="form-control book-select SelExample product" name="item_details[]" required data-toggle="select2" style="width: 249px !important;">`;
|
||||
|
||||
newRow += '<option value="' + product.product_id + '" selected>' + product.pname + '</option>';
|
||||
newRow += '</select></td>' +
|
||||
'<td style="width:10%;"><input type="text" class="form-control rate-d-only" value="'+product.amount+'" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input hidden type="text" class="form-control item-rate" name="unit-price[]" value="' + product.amount * product.qty + '" readonly /></td>' +
|
||||
'<td style="width:10%;"><input type="number" class="form-control item-quantity" min="0" max="'+Number(product.qty_stock)+'" value="' + product.qty + '" name="quantity[]"/></td>' +
|
||||
'<td style="width:8%;"> <input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="' + product.tax + '" readonly /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control total-tax-amount" value="'+total_tax_amt+'" readonly /></td>' +
|
||||
'<td style="width:12%;"><input type="text" class="form-control item-amount" name="amount[]" value="' + total_wih_tax + '" readonly/></center></td>' +
|
||||
'<td><input type="text" class="form-control rate-d-only" value="'+product.amount+'" readonly /></td>' +
|
||||
'<td hidden><input hidden type="text" class="form-control item-rate" name="unit-price[]" value="' + product.amount * product.qty + '" readonly /></td>' +
|
||||
'<td><input type="number" class="form-control item-quantity" min="0" max="'+Number(product.qty_stock)+'" value="' + product.qty + '" name="quantity[]"/></td>' +
|
||||
'<td> <input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="' + product.tax + '" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control total-tax-amount" value="'+total_tax_amt+'" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control item-amount" name="amount[]" value="' + total_wih_tax + '" readonly/></center></td>' +
|
||||
'<td>'+
|
||||
action+
|
||||
'<input value="product" name="item_type" hidden>'+
|
||||
@ -482,7 +501,7 @@ $(document).ready(async function() {
|
||||
|
||||
$('#productItemTable tbody').append(newRow);
|
||||
// $(newRow).insertAfter(tr);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
}
|
||||
|
||||
}
|
||||
@ -694,15 +713,16 @@ $(window).on('load', function() {
|
||||
}
|
||||
|
||||
var tableData;
|
||||
var initial = 0;
|
||||
// var initial = 0;
|
||||
// Update item amounts on change of discount
|
||||
$('#applyDiscountBtn').on('click', function() {
|
||||
|
||||
if($('#dt_amount').val() != '' && $('#dt_amount').val() > 0 && $('#grandtotal').val() > 0) {
|
||||
if(initial == 0) {
|
||||
tableData = $('#productItemTable tbody').html();;
|
||||
initial++;
|
||||
}
|
||||
// if(initial == 0) {
|
||||
tableData = $('#productItemTable tbody').html();
|
||||
console.log(tableData);
|
||||
// initial++;
|
||||
// }
|
||||
|
||||
var discount = parseFloat($('#dt_amount').val());
|
||||
|
||||
@ -715,8 +735,8 @@ $(window).on('load', function() {
|
||||
|
||||
$('#refreshDiscountBtn').prop('disabled', true);
|
||||
$('#refreshDiscountBtn').on('click', function() {
|
||||
$('#productItemTable tbody').empty();
|
||||
$('#productItemTable tbody').append(tableData);
|
||||
$('#productItemTable tbody').html('');
|
||||
$('#productItemTable tbody').html(tableData);
|
||||
|
||||
$('#refreshDiscountBtn').prop('disabled', true);
|
||||
$('#dt_amount').val(0);
|
||||
@ -1065,19 +1085,19 @@ $(window).on('load', function() {
|
||||
const labourcost = async (cost,tax,tr,cls) => {
|
||||
total_wih_tax = parseInt(cost) + (parseInt(cost) * (tax / 100));
|
||||
total_tax_amt = total_wih_tax - parseInt(cost);
|
||||
var newRow = '<tr class="'+cls+'"><td hidden style="width:10%;"><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fas fa-user-alt" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><input type="text" class="form-control labour_cost" readonly value="Labour Cost"></td>' +
|
||||
'<td style="width:10%;"><input type="text" class="form-control rate-d-only" value="'+cost+'" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input type="text" class="form-control item-rate" name="unit-price[]" value="'+cost+'" /></td>' +
|
||||
'<td style="width:10%;"><input type="number" class="form-control item-quantity-'+cls+' item-quantity" min="0" name="quantity[]" value="'+1+'" /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="'+tax+'" /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control total-tax-amount" value="'+total_tax_amt+'" readonly /></td>' +
|
||||
'<td style="width:12%;"><input type="text" class="form-control item-amount lab_amt" name="amount[]" value="' + total_wih_tax + '"/></td>' +
|
||||
var newRow = '<tr class="'+cls+'"><td hidden><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fas fa-user-alt" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><input type="text" class="form-control labour_cost" readonly value="Labour Cost"></td>' +
|
||||
'<td><input type="text" class="form-control rate-d-only" value="'+cost+'" readonly /></td>' +
|
||||
'<td hidden><input type="text" class="form-control item-rate" name="unit-price[]" value="'+cost+'" /></td>' +
|
||||
'<td><input type="number" class="form-control item-quantity-'+cls+' item-quantity" min="0" name="quantity[]" value="'+1+'" /></td>' +
|
||||
'<td><input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="'+tax+'" /></td>' +
|
||||
'<td><input type="text" class="form-control total-tax-amount" value="'+total_tax_amt+'" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control item-amount lab_amt" name="amount[]" value="' + total_wih_tax + '"/></td>' +
|
||||
'<td hidden></td>' +
|
||||
'<td hidden></td>' +
|
||||
'</tr>';
|
||||
|
||||
$(newRow).insertAfter(tr);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
}
|
||||
|
||||
const service_child_products = async (data,tr) => {
|
||||
@ -1094,15 +1114,15 @@ $(window).on('load', function() {
|
||||
var tax = cgst + sgst;
|
||||
total_wih_tax = parseInt(product.unit_price) + (parseInt(product.unit_price) * (tax / 100));
|
||||
total_tax_amt = total_wih_tax - parseInt(product.unit_price);
|
||||
var newRow = '<tr class="product"><td hidden style="width:10%;"><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fa fa-wrench" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><select class="form-control book-select SelExample product" name="item_details[]" required data-toggle="select2" style="width: 249px !important;">';
|
||||
var newRow = '<tr class="product"><td hidden><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fa fa-wrench" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><select class="form-control book-select SelExample product" name="item_details[]" required data-toggle="select2" style="width: 249px !important;">';
|
||||
newRow += '<option value="' + product.product_id + '">' + product.product_name + '</option>';
|
||||
newRow += '</select></td>' +
|
||||
'<td style="width:10%;"><input type="text" class="form-control rate-d-only" value="'+ product.unit_price +'" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input type="text" class="form-control item-rate" name="unit-price[]" value="' + product.unit_price + '" readonly /></td>' +
|
||||
'<td style="width:10%;"><input type="number" class="form-control item-quantity" min="0" max="'+Number(product.qty_stock)+'" value="1" name="quantity[]"/></td>' +
|
||||
'<td style="width:8%;"> <input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="' + tax + '" readonly /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control total-tax-amount" value="'+total_tax_amt+'" readonly /></td>' +
|
||||
'<td style="width:12%;"><input type="text" class="form-control item-amount" name="amount1[]" value="' + total_wih_tax + '" readonly/></td>' +
|
||||
'<td><input type="text" class="form-control rate-d-only" value="'+ product.unit_price +'" readonly /></td>' +
|
||||
'<td hidden><input type="text" class="form-control item-rate" name="unit-price[]" value="' + product.unit_price + '" readonly /></td>' +
|
||||
'<td><input type="number" class="form-control item-quantity" min="0" max="'+Number(product.qty_stock)+'" value="1" name="quantity[]"/></td>' +
|
||||
'<td> <input type="text" class="form-control taxable-value item-tax" name="item-tax[]" value="' + tax + '" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control total-tax-amount" value="'+total_tax_amt+'" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control item-amount" name="amount1[]" value="' + total_wih_tax + '" readonly/></td>' +
|
||||
'<td><center><i class="fa fa-trash remove-item"></i></center><input value="product" name="item_type" hidden></td>' +
|
||||
'<td hidden><input type="hidden" name="id" value=""></td>' +
|
||||
'</tr>';
|
||||
@ -1110,7 +1130,7 @@ $(window).on('load', function() {
|
||||
|
||||
// $('#productItemTable tbody').append(newRow);
|
||||
$(newRow).insertAfter(tr);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
|
||||
});
|
||||
}
|
||||
@ -1222,7 +1242,7 @@ $(window).on('load', function() {
|
||||
selected_pr.push(rowProductid);
|
||||
});
|
||||
|
||||
var newRow = '<tr class="product"><td hidden style="width:10%;"><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fa fa-wrench" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><select class="form-control book-select SelExample product" name="item_details[]" required data-toggle="select2" style="width: 249px !important;"><option value="">Select a Product</option>';
|
||||
var newRow = '<tr class="product"><td hidden><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fa fa-wrench" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><select class="form-control book-select SelExample product" name="item_details[]" required data-toggle="select2" style="width: 249px !important;"><option value="">Select a Product</option>';
|
||||
for (var i = 0; i < productarray.length; i++)
|
||||
{
|
||||
var product = productarray[i];
|
||||
@ -1233,19 +1253,19 @@ $(window).on('load', function() {
|
||||
}
|
||||
|
||||
newRow += '</select></td>' +
|
||||
'<td style="width:10%;"><input type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input type="text" class="form-control item-rate" name="unit-price[]" readonly /></td>' +
|
||||
'<td style="width:10%;"><input type="number" class="form-control item-quantity" min="0" name="quantity[]"/></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control item-tax" name="item-tax[]" readonly /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control total-tax-amount" value="" readonly /></td>' +
|
||||
'<td style="width:12%;"><input type="text" class="form-control item-amount" name="amount[]"/></td>' +
|
||||
'<td><input type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td hidden><input type="text" class="form-control item-rate" name="unit-price[]" readonly /></td>' +
|
||||
'<td><input type="number" class="form-control item-quantity" min="0" name="quantity[]"/></td>' +
|
||||
'<td><input type="text" class="form-control item-tax" name="item-tax[]" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control total-tax-amount" value="" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control item-amount" name="amount[]"/></td>' +
|
||||
'<td><center><i class="fa fa-trash remove-item"></i></center><input value="product" name="item_type" hidden></td>' +
|
||||
'<td hidden><input type="hidden" name="id"></td>' +
|
||||
'</tr>';
|
||||
|
||||
// $('#productItemTable tbody').append(newRow);
|
||||
$(newRow).insertAfter($(this).closest('tr'));
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
});
|
||||
|
||||
$('#addService').click(function() {
|
||||
@ -1263,7 +1283,7 @@ $(window).on('load', function() {
|
||||
servicearray = <?php echo isset($service_1) ? json_encode($service_1) : json_encode($service) ?>;
|
||||
}
|
||||
console.log(servicearray);
|
||||
var newRow = '<tr class="service_class"><td hidden style="width:10%;"> <input type="number" class="form-control labour_cost" name="labour_cost"></td><td><select class="form-control book-select SelExample service" name="service_details[]" required data-toggle="select2" style="width: 249px !important;"><option value="">Select a Service</option>';
|
||||
var newRow = '<tr class="service_class"><td hidden> <input type="number" class="form-control labour_cost" name="labour_cost"></td><td><select class="form-control book-select SelExample service" name="service_details[]" required data-toggle="select2" style="width: 249px !important;"><option value="">Select a Service</option>';
|
||||
|
||||
for (var i = 0; i < servicearray.length; i++)
|
||||
{
|
||||
@ -1275,19 +1295,19 @@ $(window).on('load', function() {
|
||||
}
|
||||
|
||||
newRow += '</select></td>' +
|
||||
'<td style="width:10%;"><input hidden type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input type="text" class="form-control item-rate1" name="unit-price[]" readonly /></td>' +
|
||||
'<td style="width:10%;"><input hidden type="number" class="form-control item-quantity" min="0" name="quantity[]" readonly/></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control item-tax" name="item-tax[]" readonly /></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td style="width:12%;"><input hidden type="text" class="form-control item-amount1" name="amount[]"/></td>' +
|
||||
'<td><input hidden type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td hidden><input type="text" class="form-control item-rate1" name="unit-price[]" readonly /></td>' +
|
||||
'<td><input hidden type="number" class="form-control item-quantity" min="0" name="quantity[]" readonly/></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-tax" name="item-tax[]" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-amount1" name="amount[]"/></td>' +
|
||||
'<td><center><i class="fa fa-trash remove-item" id="remove-item"></i></center><input value="service" name="item_type" hidden></td>' +
|
||||
'<td hidden><input type="hidden" name="id"></td>' +
|
||||
'</tr>';
|
||||
|
||||
|
||||
$('#productItemTable tbody').append(newRow);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
}else{
|
||||
toastr.warning("First Select Vehicle!");
|
||||
}
|
||||
@ -1314,7 +1334,7 @@ $(window).on('load', function() {
|
||||
});
|
||||
|
||||
complaint = <?php echo json_encode($complaint) ?>;
|
||||
var newRow = '<tr class="complaint_class"><td hidden style="width:10%;"> <input type="number" class="form-control labour_cost" name="labour_cost"></td><td><select class="form-control book-select SelExample complaint" id="complaint_detail" name="complaint_details[]" required data-toggle="select2" style="width: 249px !important;"><option value="">Select a Complaint</option>';
|
||||
var newRow = '<tr class="complaint_class"><td hidden> <input type="number" class="form-control labour_cost" name="labour_cost"></td><td><select class="form-control book-select SelExample complaint" id="complaint_detail" name="complaint_details[]" required data-toggle="select2" style="width: 249px !important;"><option value="">Select a Complaint</option>';
|
||||
|
||||
for (var i = 0; i < complaint.length; i++)
|
||||
{
|
||||
@ -1326,12 +1346,12 @@ $(window).on('load', function() {
|
||||
}
|
||||
|
||||
newRow += '</select></td>' +
|
||||
'<td style="width:10%;"><input hidden type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input type="text" class="form-control item-rate1" name="unit-price[]" readonly /></td>' +
|
||||
'<td style="width:10%;"><input hidden type="number" class="form-control item-quantity" min="0" name="quantity[]" readonly/></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control item-tax" name="item-tax[]" readonly /></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td style="width:12%;"><input hidden type="text" class="form-control item-amount1" name="amount[]"/></td>' +
|
||||
'<td><input hidden type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td hidden><input type="text" class="form-control item-rate1" name="unit-price[]" readonly /></td>' +
|
||||
'<td><input hidden type="number" class="form-control item-quantity" min="0" name="quantity[]" readonly/></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-tax" name="item-tax[]" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-amount1" name="amount[]"/></td>' +
|
||||
'<td><div style="display: inline-block;">'+
|
||||
'<center><i class="fa fa-trash remove-item"></i></center>'+
|
||||
'</div>'+
|
||||
@ -1345,7 +1365,7 @@ $(window).on('load', function() {
|
||||
'<td hidden><input type="hidden" name="id"></td>' +
|
||||
'</tr>';
|
||||
$('#productItemTable tbody').append(newRow);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
});
|
||||
/** To achieve this functionality where entering a value in one input field automatically populates another input field
|
||||
* ONLY APPLICABLE IN COMPLAINT ONLY
|
||||
@ -1362,13 +1382,13 @@ $(window).on('load', function() {
|
||||
|
||||
$('#addCustomComplaint').click(function() {
|
||||
complaint = <?php echo json_encode($complaint) ?>;
|
||||
var newRow = '<tr class="custom_complaint_class"><td hidden style="width:10%;"> <input type="number" class="form-control labour_cost" name="labour_cost"></td><td><textarea class="form-control custom-comp" id="custom_complaint_detail" required rows="5"></textarea></td>' +
|
||||
'<td style="width:10%;"><input hidden type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td style="width:10%;" hidden><input type="text" class="form-control item-rate1" name="unit-price[]" readonly /></td>' +
|
||||
'<td style="width:10%;"><input hidden type="number" class="form-control item-quantity" min="0" value="1" name="quantity[]" readonly/></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control item-tax" name="item-tax[]" value="18" readonly /></td>' +
|
||||
'<td style="width:12%;"><input hidden type="text" class="form-control item-amount1" name="amount[]" required/></td>' +
|
||||
'<td style="width:8%;"><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
var newRow = '<tr class="custom_complaint_class"><td hidden> <input type="number" class="form-control labour_cost" name="labour_cost"></td><td><textarea class="form-control custom-comp" id="custom_complaint_detail" required rows="5"></textarea></td>' +
|
||||
'<td><input hidden type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td hidden><input type="text" class="form-control item-rate1" name="unit-price[]" readonly /></td>' +
|
||||
'<td><input hidden type="number" class="form-control item-quantity" min="0" value="1" name="quantity[]" readonly/></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-tax" name="item-tax[]" value="18" readonly /></td>' +
|
||||
'<td><input hidden type="text" class="form-control item-amount1" name="amount[]" required/></td>' +
|
||||
'<td><input hidden type="text" class="form-control total-tax-amount" readonly /></td>' +
|
||||
'<td hidden><input type="hidden"></td>' +
|
||||
'<td><div style="display: inline-block;">'+
|
||||
'<center><i class="fa fa-trash remove-item"></i></center>'+
|
||||
@ -1383,19 +1403,19 @@ $(window).on('load', function() {
|
||||
'<td hidden><input type="hidden" name="id" value=""></td>' +
|
||||
'</tr>';
|
||||
|
||||
newRow += '<tr class="custom_complaint_lb"><td hidden style="width:10%;"><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fas fa-user-alt" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><input type="text" class="form-control labour_cost" value="Labour Cost"></td>' +
|
||||
'<td style="width:10%;" hidden><input type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td style="width:10%;"><input type="text" class="form-control item-rate item-rate_cc" name="unit-price[]" value="" readonly/></td>' +
|
||||
'<td style="width:10%;"><input type="number" class="form-control item-quantity" min="0" name="quantity[]" value="'+1+'" readonly /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control taxable-value item-tax item-tax_cc" name="item-tax[]" value="'+18+'" readonly /></td>' +
|
||||
'<td style="width:8%;"><input type="text" class="form-control total-tax-amount" value="" readonly /></td>' +
|
||||
'<td style="width:12%;"><input type="text" class="form-control item-amount lab_amt item-amount_cc" name="amount1[]" value="" required /></td>' +
|
||||
newRow += '<tr class="custom_complaint_lb"><td hidden><input type="number" class="form-control labour_cost" name="labour_cost"></td><td style="padding-left: 40px !important;"><i class="fas fa-user-alt" style="font-size: 13px;margin-top: 8px;position: absolute;margin-left: -18px;" aria-hidden="true"></i><input type="text" class="form-control labour_cost" value="Labour Cost"></td>' +
|
||||
'<td hidden><input type="text" class="form-control rate-d-only" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control item-rate item-rate_cc" name="unit-price[]" value="" readonly/></td>' +
|
||||
'<td><input type="number" class="form-control item-quantity" min="0" name="quantity[]" value="'+1+'" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control taxable-value item-tax item-tax_cc" name="item-tax[]" value="'+18+'" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control total-tax-amount" value="" readonly /></td>' +
|
||||
'<td><input type="text" class="form-control item-amount lab_amt item-amount_cc" name="amount1[]" value="" required /></td>' +
|
||||
'<td hidden></td>' +
|
||||
'<td hidden></td>' +
|
||||
'</tr>';
|
||||
|
||||
$('#productItemTable tbody').append(newRow);
|
||||
initializeSelect2();
|
||||
// initializeSelect2();
|
||||
});
|
||||
|
||||
/** To achieve this functionality where entering a value in one input field automatically populates another input field
|
||||
|
||||
@ -167,65 +167,42 @@ p {
|
||||
<td style="padding:20px;"><h3><b>JOB CARD</b></h3></td>
|
||||
<td style="padding:20px;"><b>JOB NO: </b><?= $vehicle[0]['order_number'] ?></td>
|
||||
</tr></table>
|
||||
<hr style="margin-top: 10px; margin-bottom: 10px;">
|
||||
<br>
|
||||
<!-- <hr style="margin-top: 10px; margin-bottom: 10px;"> -->
|
||||
<!-- <br> -->
|
||||
<table class="list" style="width:100%">
|
||||
<tr>
|
||||
<td style="width: 33.33%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:95%;float:left;">
|
||||
<td style="width: 100%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:100%;margin:0 auto;">
|
||||
<tbody>
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;" colspan="2"><center>CUSTOMER INFO</center></th>
|
||||
</tr>
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;">NAME</th>
|
||||
<th style="border: 0.5px solid black;">MOBILE</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="border: 1px solid black;"><?= $job_card[0]['client_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;"><?= $job_card[0]['client_mobile_no'] ?></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td style="width: 33.33%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:95%;margin:0 auto;">
|
||||
<tbody>
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;" colspan="4"><center>VEHICLE INFO</center></th>
|
||||
</tr>
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;">MAKE</th>
|
||||
<th style="border: 0.5px solid black;">MODEL</th>
|
||||
<th style="border: 0.5px solid black;">COLOR</th>
|
||||
<th style="border: 0.5px solid black;">REG NO</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="border: 1px solid black;"><?= $vehicle[0]['bike_company'] ?></td>
|
||||
<td style="border: 0.5px solid black;"><?= $vehicle[0]['bike_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;"><?= $vehicle[0]['colour'] ?></td>
|
||||
<td style="border: 0.5px solid black;"><?= $vehicle[0]['reg_no'] ?></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td style="width: 33.33%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:95%;float:right;">
|
||||
<tbody>
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;" colspan="3"><center>DELIVERY INFO</center></th>
|
||||
</tr>
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;">DATE</th>
|
||||
<th style="border: 0.5px solid black;">FUEL QTY</th>
|
||||
<th style="border: 0.5px solid black;">METER</th>
|
||||
<th style="border: 0.5px solid black;">COLOR</th>
|
||||
<td style="border: 0.5px solid black;"><?= $vehicle[0]['colour'] ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="border: 1px solid black;">04/06/2024</td>
|
||||
<td style="border: 0.5px solid black;">25%</td>
|
||||
<td style="border: 0.5px solid black;">14556</td>
|
||||
<th style="border: 0.5px solid black;">MOBILE</th>
|
||||
<td style="border: 0.5px solid black;"><?= $job_card[0]['client_mobile_no'] ?></td>
|
||||
|
||||
<th style="border: 0.5px solid black;">MODEL</th>
|
||||
<td style="border: 0.5px solid black;"><?= $vehicle[0]['bike_name'] ?></td>
|
||||
|
||||
<th style="border: 0.5px solid black;">FUEL</th>
|
||||
<td style="border: 0.5px solid black;"><?= $job_card[0]['fuel_qty'] ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th style="border: 0.5px solid black;">DELIVERY</th>
|
||||
<td style="border: 1px solid black;"><?= date('d/m/Y', strtotime($job_card[0]['delivery_date'])) ?></td>
|
||||
|
||||
<th style="border: 0.5px solid black;">REG</th>
|
||||
<td style="border: 0.5px solid black;"><?= $vehicle[0]['reg_no'] ?></td>
|
||||
|
||||
<th style="border: 0.5px solid black;">METER</th>
|
||||
<td style="border: 0.5px solid black;"><?= $job_card[0]['meter'] ?></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
@ -238,44 +215,46 @@ p {
|
||||
|
||||
<table class="list" style="width:100%; table-layout: fixed;">
|
||||
<tr>
|
||||
<td style="width: 50%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:95%; float:left;">
|
||||
<td style="width: 100%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:100%;">
|
||||
<tbody>
|
||||
<tr style="border: 1px solid black;">
|
||||
<!-- <tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;" colspan="2"><center>TYPE OF SERVICES</center></th>
|
||||
</tr>
|
||||
</tr> -->
|
||||
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;">Services List</th>
|
||||
<th style="border: 0.5px solid black;">Action</th>
|
||||
<th style="border: 0.5px solid black;width:70%;">Services List</th>
|
||||
<th style="border: 0.5px solid black;width:30%;">Note</th>
|
||||
</tr>
|
||||
|
||||
<?php foreach ($service as $key => $item) : ?>
|
||||
<tr>
|
||||
<td style="border: 0.5px solid black;"><?= $item['product_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;"></td>
|
||||
<td style="border: 0.5px solid black;width:70%;"><?= $item['product_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;width:30%;"></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td style="width: 50%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:95%; float:right;">
|
||||
</tr>
|
||||
<br>
|
||||
<tr>
|
||||
<td style="width: 100%; vertical-align: top;">
|
||||
<table class="invoice-related-table1" style="width:100%;">
|
||||
<thead>
|
||||
<tr style="border: 1px solid black;">
|
||||
<!-- <tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;" colspan="2"><center>OTHER WORKS</center></th>
|
||||
</tr>
|
||||
</tr> -->
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;">Complaint List</th>
|
||||
<th style="border: 0.5px solid black;">Action</th>
|
||||
<th style="border: 0.5px solid black;width:70%;">Complaint List</th>
|
||||
<th style="border: 0.5px solid black;width:30%;">Note</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($complaint as $key => $item) : ?>
|
||||
<tr>
|
||||
<td style="border: 0.5px solid black;"><?= $item['product_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;"></td>
|
||||
<td style="border: 0.5px solid black;width:70%;"><?= $item['product_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;width:30%;"></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
@ -289,31 +268,31 @@ p {
|
||||
|
||||
<table class="invoice-related-table">
|
||||
<tbody>
|
||||
<tr style="border: 1px solid black;">
|
||||
<!-- <tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;" colspan="5"><center>PRODUCT DETAILS</center></th>
|
||||
</tr>
|
||||
</tr> -->
|
||||
<tr style="border: 1px solid black;">
|
||||
<th style="border: 0.5px solid black;">S no</th>
|
||||
<th style="border: 0.5px solid black;">Description Of Goods</th>
|
||||
<th style="border: 0.5px solid black;">Quantity</th>
|
||||
<th style="border: 0.5px solid black;">Per</th>
|
||||
<th style="border: 0.5px solid black;">Action</th>
|
||||
<th style="border: 0.5px solid black;width:10%;">No</th>
|
||||
<th style="border: 0.5px solid black;width:50%;">Description Of Goods</th>
|
||||
<th style="border: 0.5px solid black;width:10%;">Qty</th>
|
||||
<th style="border: 0.5px solid black;width:10%;">Unit</th>
|
||||
<th style="border: 0.5px solid black;width:20%;">Note</th>
|
||||
</tr>
|
||||
|
||||
<?php foreach ($job_card_products as $key => $item) : ?>
|
||||
<tr>
|
||||
|
||||
<td style="border: 1px solid black;"><?= $key+1; ?></td>
|
||||
<td style="border: 0.5px solid black;"><?= $item['product_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;"><?= $item['qty'] ?></td>
|
||||
<td style="border: 0.5px solid black;"><?= $item['per'] ?></td>
|
||||
<td style="border: 0.5px solid black;"></td>
|
||||
<td style="border: 1px solid black;width:10%;"><?= $key+1; ?></td>
|
||||
<td style="border: 0.5px solid black;width:50%;"><?= $item['product_name'] ?></td>
|
||||
<td style="border: 0.5px solid black;width:10%;"><?= $item['qty'] ?></td>
|
||||
<td style="border: 0.5px solid black;width:10%;"><?= $item['per'] ?></td>
|
||||
<td style="border: 0.5px solid black;width:20%;"></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
<br>
|
||||
|
||||
<table class="invoice-related-table">
|
||||
<thead>
|
||||
@ -323,7 +302,7 @@ p {
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td style="border: 0.5px solid black;">bike's right indicator is broken, and the tank is scratched.</td>
|
||||
<td style="border: 0.5px solid black;"><?= $job_card[0]['note'] ?></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
@ -59,9 +59,9 @@
|
||||
<td><?= $value['total']; ?></td>
|
||||
<td><?= $value['status']; ?></td>
|
||||
<td>
|
||||
<a href="<?= "new_jobcard/" . $value['job_card_id']; ?>" class="edit-button" title="Edit"><i class="ri-pencil-line"></i></a>
|
||||
<a href="<?= "new_jobcard/" . $value['job_card_id']; ?>" class="edit-button" title="Edit"><i class="ri-pencil-line" style="font-size: 20px;"></i></a>
|
||||
|
||||
<a href="<?= "download_jobcard_invoice/" . $value['job_card_id']; ?>" class="edit-button" title="Download"><i class="ri-file-download-line"></i></a>
|
||||
<a href="<?= "download_jobcard_invoice/" . $value['job_card_id']; ?>" class="edit-button" title="Download"><i class="ri-file-download-line" style="font-size: 20px;"></i></a>
|
||||
|
||||
</td>
|
||||
<?php endif?>
|
||||
|
||||
@ -64,12 +64,12 @@
|
||||
<td>
|
||||
<input class="form-control form-control-sm" type="text" id="searchUnitPrice" placeholder="Search Unit Price">
|
||||
</td>
|
||||
<td>
|
||||
<!-- <td>
|
||||
<input class="form-control form-control-sm" type="text" id="searchQtyStock" placeholder="Search Qty in Stock">
|
||||
</td>
|
||||
<td>
|
||||
<input class="form-control form-control-sm" type="text" id="searchRackNo" placeholder="Search Rack No">
|
||||
</td>
|
||||
</td> -->
|
||||
</tr>
|
||||
<tr>
|
||||
<th>SKU Id</th>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user