瀏覽代碼

Merge branch 'baiyanting1' of http://124.70.43.205:3000/xieshengjie/jn_sis_zhfx into new-power

baiyanting 9 月之前
父節點
當前提交
a37e2e295c
共有 1 個文件被更改,包括 8 次插入2 次删除
  1. 8 2
      src/views/economicsOperation/photovoltaicAnalyse/prAnalyse/index.vue

+ 8 - 2
src/views/economicsOperation/photovoltaicAnalyse/prAnalyse/index.vue

@@ -226,8 +226,14 @@ export default {
           this.tableData = res.data.map((i) => {
             return {
               ...i,
-              prhbzzl: i.prhbzzl ? i.prhbzzl.toFixed(2) : i.prhbzzl,
-              prtbzzl: i.prtbzzl ? i.prtbzzl.toFixed(2) : i.prtbzzl,
+              prhbzzl:
+                i.prhbzzl && typeof i.prhbzzl == "number"
+                  ? i.prhbzzl.toFixed(2)
+                  : i.prhbzzl,
+              prtbzzl:
+                i.prtbzzl && typeof i.prtbzzl == "number"
+                  ? i.prtbzzl.toFixed(2)
+                  : i.prtbzzl,
             };
           });
         }