Browse Source

fix: 修复统计问题

sy-water-data-board-ui
panyuyi 1 month ago
parent
commit
e8e2143080
  1. 18
      src/views/dike/runManage/patrolMaintenance/statisticsAnalysis/index.vue
  2. 3
      vue.config.js

18
src/views/dike/runManage/patrolMaintenance/statisticsAnalysis/index.vue

@ -356,13 +356,10 @@ export default {
this.requestFunc({ group: "C_15" }).then((res) => { this.requestFunc({ group: "C_15" }).then((res) => {
if (res.data) { if (res.data) {
if (res.data?.yaxis?.length) { if (res.data?.yaxis?.length) {
let newArr = res.data.yaxis.flatMap((v) => v.series); this.flawSum = res.data.yaxis
this.flawSum = Number( .flatMap((v) => v.series)
newArr.find((v) => v.code === "DF_QX_SUM")?.sum ?? null .map((v) => Number(v.sum ?? null))
); .reduce((acc, cur) => acc + cur, 0);
this.yhSum = Number(
newArr.find((v) => v.code === "DF_YH_SUM")?.sum ?? null
);
} }
this.$nextTick(() => { this.$nextTick(() => {
// //
@ -550,6 +547,13 @@ export default {
// //
this.requestFunc({ group: "C_17" }).then((res) => { this.requestFunc({ group: "C_17" }).then((res) => {
if (res.data) { if (res.data) {
if (res.data.yaxis?.length) {
this.yhSum = Number(
res.data.yaxis
.flatMap((v) => v.series)
?.find((v) => v.code === "DF_BD_YH_SUM")?.sum ?? null
);
}
this.$nextTick(() => { this.$nextTick(() => {
// //
if (this.yhCompareRefBarInstance) { if (this.yhCompareRefBarInstance) {

3
vue.config.js

@ -80,7 +80,8 @@ module.exports = {
changeOrigin: true, changeOrigin: true,
}, },
[process.env.VUE_APP_BASE_API]: { [process.env.VUE_APP_BASE_API]: {
target: "http://shuili.product.dev.com:30115/", // target: "http://shuili.product.dev.com:30115/",
target: "http://172.16.34.80:18082/",
// target: "http://192.168.31.26:18082/", // target: "http://192.168.31.26:18082/",
// target: 'http://172.16.32.62:18888/', // target: 'http://172.16.32.62:18888/',
// target: "http://172.16.34.27:18082", // target: "http://172.16.34.27:18082",

Loading…
Cancel
Save