add auto tax field
This commit is contained in:
parent
e28ccf3e46
commit
2ba5e53b3e
@ -493,9 +493,7 @@ const app = new Vue({
|
|||||||
this.taxes[tax_id].push(item.id);
|
this.taxes[tax_id].push(item.id);
|
||||||
} else {
|
} else {
|
||||||
this.taxes.push(tax_id);
|
this.taxes.push(tax_id);
|
||||||
|
|
||||||
this.taxes[tax_id] = [];
|
this.taxes[tax_id] = [];
|
||||||
|
|
||||||
this.taxes[tax_id].push(item.id);
|
this.taxes[tax_id].push(item.id);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -523,7 +521,7 @@ const app = new Vue({
|
|||||||
description: item.description,
|
description: item.description,
|
||||||
quantity: 1,
|
quantity: 1,
|
||||||
price: item.price,
|
price: item.price,
|
||||||
add_tax: (item_taxes.length) ? true : false,
|
add_tax: true,
|
||||||
tax_ids: item_taxes,
|
tax_ids: item_taxes,
|
||||||
add_discount: false,
|
add_discount: false,
|
||||||
discount: 0,
|
discount: 0,
|
||||||
@ -558,7 +556,6 @@ const app = new Vue({
|
|||||||
this.taxes[this.tax_id].push(this.items[item_index].item_id);
|
this.taxes[this.tax_id].push(this.items[item_index].item_id);
|
||||||
} else {
|
} else {
|
||||||
this.taxes[this.tax_id] = [];
|
this.taxes[this.tax_id] = [];
|
||||||
|
|
||||||
this.taxes[this.tax_id].push(this.items[item_index].item_id);
|
this.taxes[this.tax_id].push(this.items[item_index].item_id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -165,6 +165,7 @@
|
|||||||
<td colspan="1" style="border: 0;" class="w-1">
|
<td colspan="1" style="border: 0;" class="w-1">
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<tr v-if="row.add_discount">
|
<tr v-if="row.add_discount">
|
||||||
<td colspan="3" style="border: 0;"></td>
|
<td colspan="3" style="border: 0;"></td>
|
||||||
<td colspan="2" style="border: 0;">
|
<td colspan="2" style="border: 0;">
|
||||||
@ -207,6 +208,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<tr v-if="row.add_tax" v-for="(row_tax, row_tax_index) in row.tax_ids"
|
<tr v-if="row.add_tax" v-for="(row_tax, row_tax_index) in row.tax_ids"
|
||||||
:index="row_tax_index">
|
:index="row_tax_index">
|
||||||
@else
|
@else
|
||||||
@ -252,6 +254,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<tr v-if="row.add_tax">
|
<tr v-if="row.add_tax">
|
||||||
<td class="pb-0" colspan="2" style="border: 0;">
|
<td class="pb-0" colspan="2" style="border: 0;">
|
||||||
</td>
|
</td>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user