diff --git a/src/views/supermarketerp/purchaseManagement/smErpCgBack/form.vue b/src/views/supermarketerp/purchaseManagement/smErpCgBack/form.vue index 4be8bfa..10d28a5 100644 --- a/src/views/supermarketerp/purchaseManagement/smErpCgBack/form.vue +++ b/src/views/supermarketerp/purchaseManagement/smErpCgBack/form.vue @@ -73,7 +73,7 @@ { seq: '合计', quantity: total.quantity, - retailPrice: total.retailPrice, + retailPrice: `${total.retailPrice}元`, purchasePrice: total.purchasePrice, realPrice: `${total.realPrice}元`, totalAmount: total.totalAmount, @@ -130,9 +130,12 @@ - + + @@ -257,9 +260,7 @@ const validRules = ref>({ // 合计总金额 const total = computed(() => { const quantity = vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.quantity || 0), 0).toFixed(2) - const retailPrice = displayPrice( - vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.selectedUnitObj?.retailPrice || 0), 0).toFixed(2), - ) + const retailPrice = vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.selectedUnitObj?.retailPrice || 0), 0).toFixed(2) const purchasePrice = displayPrice( vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.selectedUnitObj?.purchasePrice || 0), 0), ) @@ -293,6 +294,7 @@ const getInitData = async () => { selectedUnitObj: { ...selectedUnitObj, realPrice: Number(displayPrice(item?.realPrice, "")) || 0, + retailPrice: Number(displayPrice(selectedUnitObj.retailPrice, "")) || 0, totalAmount: Number(displayPrice(item?.totalAmount, "")), }, } @@ -332,6 +334,7 @@ const getSelectedRows = (selectionRows: any) => { selectedUnitObj: { ...firstUnit, realPrice: Number(displayPrice(firstUnit.purchasePrice, "")), + retailPrice: Number(displayPrice(firstUnit.retailPrice, "")), totalAmount: 1 * Number(displayPrice(firstUnit.purchasePrice, "")), }, unitId: firstUnit.id, @@ -388,6 +391,7 @@ const settledTableItems = computed(() => { productNature: item.productNature, unitPrice: selectedUnitObj.purchasePrice ? Number(selectedUnitObj?.purchasePrice) : 0, realPrice: selectedUnitObj.realPrice ? storePrice(selectedUnitObj?.realPrice) : 0, + retailPrice: selectedUnitObj.retailPrice ? storePrice(selectedUnitObj?.retailPrice) : 0, totalAmount: storePrice(Number(selectedUnitObj?.totalAmount || 0)), remark: item.remark, unitId: selectedUnitObj.id, diff --git a/src/views/supermarketerp/purchaseManagement/smErpCgBack/index.vue b/src/views/supermarketerp/purchaseManagement/smErpCgBack/index.vue index 8f50b7d..e5be61e 100644 --- a/src/views/supermarketerp/purchaseManagement/smErpCgBack/index.vue +++ b/src/views/supermarketerp/purchaseManagement/smErpCgBack/index.vue @@ -15,9 +15,9 @@ value-format="YYYY-MM-DD" /> - + + + 查询 重置 diff --git a/src/views/supermarketerp/purchaseManagement/smErpCgInventory/form.vue b/src/views/supermarketerp/purchaseManagement/smErpCgInventory/form.vue index 9b48c55..cb31019 100644 --- a/src/views/supermarketerp/purchaseManagement/smErpCgInventory/form.vue +++ b/src/views/supermarketerp/purchaseManagement/smErpCgInventory/form.vue @@ -101,7 +101,7 @@ { seq: '合计', quantity: total.quantity, - retailPrice: total.retailPrice, + retailPrice: `${total.retailPrice}元`, purchasePrice: total.purchasePrice, realPrice: `${total.realPrice}元`, totalAmount: total.totalAmount, @@ -158,9 +158,12 @@ - + + @@ -285,9 +288,7 @@ const validRules = ref>({ // 合计总金额 const total = computed(() => { const quantity = vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.quantity || 0), 0).toFixed(2) - const retailPrice = displayPrice( - vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.selectedUnitObj?.retailPrice || 0), 0).toFixed(2), - ) + const retailPrice = vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.selectedUnitObj?.retailPrice || 0), 0).toFixed(2) const purchasePrice = displayPrice( vxeTableData.value.reduce((sum: any, row: any) => sum + Number(row.selectedUnitObj?.purchasePrice || 0), 0), ) @@ -321,6 +322,7 @@ const getInitData = async () => { selectedUnitObj: { ...selectedUnitObj, realPrice: Number(displayPrice(item?.realPrice, "")) || 0, + retailPrice: Number(displayPrice(selectedUnitObj.retailPrice, "")) || 0, totalAmount: Number(displayPrice(item?.totalAmount, "")), }, } @@ -360,6 +362,7 @@ const getSelectedRows = (selectionRows: any[]) => { selectedUnitObj: { ...firstUnit, realPrice: Number(displayPrice(firstUnit.purchasePrice, "")), + retailPrice: Number(displayPrice(firstUnit.retailPrice, "")), totalAmount: 1 * Number(displayPrice(firstUnit.purchasePrice, "")), }, unitId: firstUnit.id, @@ -415,6 +418,7 @@ const settledTableItems = computed(() => { productNature: item.productNature, unitPrice: selectedUnitObj.purchasePrice ? Number(selectedUnitObj?.purchasePrice) : 0, realPrice: selectedUnitObj.realPrice ? storePrice(selectedUnitObj?.realPrice) : 0, + retailPrice: selectedUnitObj.retailPrice ? storePrice(selectedUnitObj?.retailPrice) : 0, totalAmount: storePrice(Number(selectedUnitObj?.totalAmount || 0)), remark: item.remark, unitId: selectedUnitObj.id, diff --git a/src/views/supermarketerp/purchaseManagement/smErpCgInventory/index.vue b/src/views/supermarketerp/purchaseManagement/smErpCgInventory/index.vue index e61d958..397f07d 100644 --- a/src/views/supermarketerp/purchaseManagement/smErpCgInventory/index.vue +++ b/src/views/supermarketerp/purchaseManagement/smErpCgInventory/index.vue @@ -15,9 +15,9 @@ value-format="YYYY-MM-DD" /> - + + + 查询 重置