fix: quotation => handle change pay type

This commit is contained in:
puriphatt 2024-12-23 11:56:06 +07:00
parent 89265882d5
commit 40d0f4f2dc

View file

@ -671,15 +671,12 @@ function triggerProductServiceDialog() {
}
function handleChangePayType(type: PayCondition) {
if (type === 'Full') {
quotationFormData.value.paySplitCount = 0;
}
if (
type === 'Split' &&
tempPaySplitCount.value !== undefined &&
tempPaySplit.value &&
tempTableProduct.value
type === 'Split' ||
(type === 'Full' &&
tempPaySplitCount.value !== undefined &&
tempPaySplit.value &&
tempTableProduct.value)
) {
quotationFormData.value.paySplitCount = tempPaySplitCount.value;
quotationFormData.value.paySplit = JSON.parse(