fix: type error
This commit is contained in:
parent
c1fe4428ba
commit
a43d21ac1d
1 changed files with 12 additions and 10 deletions
|
|
@ -159,16 +159,18 @@ onMounted(async () => {
|
||||||
|
|
||||||
data.value = JSON.parse(sessionStorage.getItem('quotation-preview') || '{}');
|
data.value = JSON.parse(sessionStorage.getItem('quotation-preview') || '{}');
|
||||||
|
|
||||||
|
if (data.value) {
|
||||||
productList.value = data.value?.productServiceList.map((v) => ({
|
productList.value = data.value?.productServiceList.map((v) => ({
|
||||||
id: v.product.id,
|
id: v.product.id,
|
||||||
code: v.product.code,
|
code: v.product.code,
|
||||||
detail: v.product.detail,
|
detail: v.product.detail,
|
||||||
amount: v.amount,
|
amount: v.amount,
|
||||||
priceUnit: v.pricePerUnit,
|
priceUnit: v.pricePerUnit || 0,
|
||||||
discount: v.discount,
|
discount: v.discount || 0,
|
||||||
vat: v.vat,
|
vat: v.vat || 0,
|
||||||
value: 0,
|
value: 0,
|
||||||
}));
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
summaryPrice.value = obj.productServiceList.reduce(
|
summaryPrice.value = obj.productServiceList.reduce(
|
||||||
(a, c) => {
|
(a, c) => {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue