lilei 1 week ago
parent
commit
2ac54279c3
1 changed files with 2 additions and 3 deletions
  1. 2 3
      src/views/salesManagement/salesQueryNew/vaildPriceModal.vue

+ 2 - 3
src/views/salesManagement/salesQueryNew/vaildPriceModal.vue

@@ -70,7 +70,7 @@ export default {
     dataList () {
       const list = this.dataObj && this.dataObj.data || []
       list.map(item => {
-        item.totalKsAmount = item.totalShowCost - item.totalAmount
+        item.totalKsAmount = Number(item.totalShowCost - item.totalAmount).toFixed(2)
       })
       return list
     },
@@ -98,7 +98,7 @@ export default {
           { title: '单位', dataIndex: 'productEntity.unit', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
           { title: '售价小计', dataIndex: 'totalAmount', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
           { title: '参考成本价小计', dataIndex: 'totalShowCost', width: '15%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
-          { title: '亏损金额', dataIndex: 'totalKsAmount', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } }
+          { title: '亏损金额', dataIndex: 'totalKsAmount', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
         ]
       }
       return []
@@ -107,7 +107,6 @@ export default {
   methods: {
     // 保存
     handleSubmit (type) {
-      console.log(type, this.modalType)
       this.spinning = true
       this.$emit('ok', type)
     },