瀏覽代碼

no message

linwenxin 9 月之前
父節點
當前提交
191ea09b9d

+ 8 - 5
src/views/workOrder/workOrderPool/detailModule/workOrderInfo/mixins/hs_productColumns.js

@@ -425,12 +425,15 @@ export default {
       }
       this.orderInfo.orderProducts.splice(index, 1, {
         ...row,
-        estimatePrice: estimatePrice,
-        serviceAmount: serviceAmount
+        estimatePrice: Number(estimatePrice.toFixed(2)),
+        serviceAmount: Number(serviceAmount.toFixed(2))
       })
-      this.orderInfo.serviceAmount = this.orderInfo.orderProducts
-        .map(item => item.serviceAmount || 0)
-        .reduce((a, b) => a + b, 0)
+      this.orderInfo.serviceAmount = Number(
+        this.orderInfo.orderProducts
+          .map(item => item.serviceAmount || 0)
+          .reduce((a, b) => a + b, 0)
+          .toFixed(2)
+      )
     },
     getVfyKey_hs(index, bool = true) {
       return [