fix: remove duplicate updatePrices function

Co-authored-by: aider (openai/DeepSeek-V3.2-Thinking) <aider@aider.chat>
This commit is contained in:
dxc
2026-02-27 16:06:18 +08:00
parent 657c916703
commit fbff519ac9

View File

@ -1057,18 +1057,6 @@ watch(() => [form.in_quantity, form.unit_price], () => {
form.post_tax_unit_price = Number((form.unit_price * taxMultiplier).toFixed(4));
})
const updatePrices = (source) => {
const taxMultiplier = 1 + (form.tax_rate || 0) / 100;
if (source === 'pre') {
form.post_tax_unit_price = Number((form.unit_price * taxMultiplier).toFixed(4));
} else if (source === 'post') {
form.unit_price = Number((form.post_tax_unit_price / taxMultiplier).toFixed(4));
} else if (source === 'tax') {
form.post_tax_unit_price = Number((form.unit_price * taxMultiplier).toFixed(4));
}
form.total_price = Number((form.in_quantity * form.unit_price).toFixed(4));
}
const fetchData = async () => {
loading.value = true
try {