@ued_fpi/data-visual 1.2.28 → 1.2.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/dist/es/ipes/src/AnnualEventStatistics/index.vue.mjs +3 -3
  2. package/dist/es/ipes/src/BasicSecurityManagement/index.vue.mjs +1 -1
  3. package/dist/es/ipes/src/EmengercyPlan/index.vue.mjs +1 -1
  4. package/dist/es/ipes/src/EmergencyWatch/index.vue.mjs +13 -26
  5. package/dist/es/ipes/src/EventTracking/index.vue.mjs +2 -0
  6. package/dist/es/ipes/src/GasControl/index.vue.mjs +1 -1
  7. package/dist/es/ipes/src/GroundwaterMonitor/index.vue.mjs +46 -31
  8. package/dist/es/ipes/src/HazardousWasteManagement/index.vue.mjs +19 -4
  9. package/dist/es/ipes/src/HomeworkVolumeTrend/index.vue.mjs +6 -2
  10. package/dist/es/ipes/src/Level3AirDefense/components/PercentageItem.vue.mjs +3 -3
  11. package/dist/es/ipes/src/PerformanceWarrantyResponsibilities/images/performance-light.png.mjs +1 -1
  12. package/dist/es/ipes/src/PerformanceWarrantyResponsibilities/images/performance.png.mjs +1 -1
  13. package/dist/es/ipes/src/PerformanceWarrantyResponsibilities/index.vue.mjs +33 -39
  14. package/dist/es/ipes/src/RiskClassification/index.vue.mjs +3 -5
  15. package/dist/es/ipes/src/VehicleTrend/index.vue.mjs +1 -1
  16. package/dist/es/ipes/src/WasteGas/index.vue.mjs +3 -11
  17. package/dist/es/ipes/src/WasteWater/index.vue.mjs +3 -11
  18. package/dist/es/ipes/src/WastewaterTargetRate/index.vue.mjs +22 -4
  19. package/dist/es/ipes/src/WaterQualityStandard/index.vue.mjs +13 -11
  20. package/dist/es/style.css +1 -1
  21. package/dist/es/wgms/src/ChangeAlongRiver/index.vue.mjs +6 -3
  22. package/dist/es/wgms/src/DistributionOfWaterQualityLevels/index.vue.mjs +3 -3
  23. package/dist/es/wgms/src/DrinkingWaterComplianceRate/index.vue.mjs +5 -6
  24. package/dist/es/wgms/src/RegionalQualityAnalysis/index.vue.mjs +24 -13
  25. package/dist/es/wgms/src/UpstreamImpact/index.vue.mjs +7 -4
  26. package/dist/es/wgms/src/WaterQualityRainfall/index.vue.mjs +10 -8
  27. package/dist/es/wgms/src/WaterQualitySituation/index.vue.mjs +29 -22
  28. package/dist/es/wgms/src/WaterQualityStatesAnalysis/index.vue.mjs +11 -6
  29. package/dist/es/wgms/src/common/popup-table.vue.mjs +1 -1
  30. package/dist/es/wgms/utils/echarts/echartsOptions.mjs +2 -2
  31. package/dist/es/wgms/utils/tools.mjs +7 -1
  32. package/dist/lib/ipes/src/AnnualEventStatistics/index.vue.js +3 -3
  33. package/dist/lib/ipes/src/BasicSecurityManagement/index.vue.js +1 -1
  34. package/dist/lib/ipes/src/EmengercyPlan/index.vue.js +1 -1
  35. package/dist/lib/ipes/src/EmergencyWatch/index.vue.js +12 -25
  36. package/dist/lib/ipes/src/EventTracking/index.vue.js +2 -0
  37. package/dist/lib/ipes/src/GasControl/index.vue.js +1 -1
  38. package/dist/lib/ipes/src/GroundwaterMonitor/index.vue.js +45 -30
  39. package/dist/lib/ipes/src/HazardousWasteManagement/index.vue.js +18 -3
  40. package/dist/lib/ipes/src/HomeworkVolumeTrend/index.vue.js +6 -2
  41. package/dist/lib/ipes/src/Level3AirDefense/components/PercentageItem.vue.js +3 -3
  42. package/dist/lib/ipes/src/PerformanceWarrantyResponsibilities/images/performance-light.png.js +1 -1
  43. package/dist/lib/ipes/src/PerformanceWarrantyResponsibilities/images/performance.png.js +1 -1
  44. package/dist/lib/ipes/src/PerformanceWarrantyResponsibilities/index.vue.js +33 -39
  45. package/dist/lib/ipes/src/RiskClassification/index.vue.js +3 -5
  46. package/dist/lib/ipes/src/VehicleTrend/index.vue.js +1 -1
  47. package/dist/lib/ipes/src/WasteGas/index.vue.js +2 -10
  48. package/dist/lib/ipes/src/WasteWater/index.vue.js +2 -10
  49. package/dist/lib/ipes/src/WastewaterTargetRate/index.vue.js +21 -3
  50. package/dist/lib/ipes/src/WaterQualityStandard/index.vue.js +12 -10
  51. package/dist/lib/style.css +1 -1
  52. package/dist/lib/wgms/src/ChangeAlongRiver/index.vue.js +6 -3
  53. package/dist/lib/wgms/src/DistributionOfWaterQualityLevels/index.vue.js +3 -3
  54. package/dist/lib/wgms/src/DrinkingWaterComplianceRate/index.vue.js +5 -6
  55. package/dist/lib/wgms/src/RegionalQualityAnalysis/index.vue.js +23 -12
  56. package/dist/lib/wgms/src/UpstreamImpact/index.vue.js +7 -4
  57. package/dist/lib/wgms/src/WaterQualityRainfall/index.vue.js +9 -7
  58. package/dist/lib/wgms/src/WaterQualitySituation/index.vue.js +29 -22
  59. package/dist/lib/wgms/src/WaterQualityStatesAnalysis/index.vue.js +11 -6
  60. package/dist/lib/wgms/src/common/popup-table.vue.js +1 -1
  61. package/dist/lib/wgms/utils/echarts/echartsOptions.js +2 -2
  62. package/dist/lib/wgms/utils/tools.js +7 -0
  63. package/dist/style/style-ipes.css +1 -1
  64. package/package.json +2 -2
  65. package/dist/es/ipes/src/EmergencyWatch/images/empty.png.mjs +0 -3
  66. package/dist/lib/ipes/src/EmergencyWatch/images/empty.png.js +0 -7
@@ -6,6 +6,7 @@ const vue = require('vue');
6
6
  const dayjs = require('dayjs');
7
7
  require('echarts/lib/component/markLine');
8
8
  const BaseECharts_vue_vue_type_script_setup_true_lang = require('../../utils/echarts/BaseECharts.vue.js');
9
+ const tools = require('../../utils/tools.js');
9
10
  const index = require('./api/index.js');
10
11
 
11
12
  const _hoisted_1 = { class: "dv-wgms-change-along-river" };
@@ -236,11 +237,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
236
237
  };
237
238
  if (props.params?.factorCode === "w01001") {
238
239
  if (state.factorLimitValue && state.factorLimitValue.upValue) {
240
+ const num = tools.countDecimalPlaces(state.factorLimitValue.upValue);
239
241
  option2.series[0].markLine = {
240
242
  symbol: "none",
241
243
  data: [
242
244
  {
243
- yAxis: state.factorLimitValue.upValue,
245
+ yAxis: Number(state.factorLimitValue.upValue).toFixed(num),
244
246
  show: true,
245
247
  name: "水质超标上限",
246
248
  label: {
@@ -261,7 +263,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
261
263
  }
262
264
  },
263
265
  {
264
- yAxis: state.factorLimitValue.downValue == null ? "" : state.factorLimitValue.downValue,
266
+ yAxis: state.factorLimitValue.downValue == null ? "" : Number(state.factorLimitValue.downValue).toFixed(num),
265
267
  show: true,
266
268
  name: "水质超标下限",
267
269
  label: {
@@ -290,11 +292,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
290
292
  }
291
293
  } else {
292
294
  if (state.factorLimitValue.value != null) {
295
+ const num = tools.countDecimalPlaces(state.factorLimitValue.value);
293
296
  option2.series[0].markLine = {
294
297
  symbol: "none",
295
298
  data: [
296
299
  {
297
- yAxis: state.factorLimitValue.value,
300
+ yAxis: Number(state.factorLimitValue.value).toFixed(num),
298
301
  show: true,
299
302
  name: "水质超标线",
300
303
  label: {
@@ -3,7 +3,6 @@
3
3
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
4
4
 
5
5
  const vue = require('vue');
6
- const dayjs = require('dayjs');
7
6
  const commonArrow_vue_vue_type_script_setup_true_lang = require('../common/common-arrow.vue.js');
8
7
  require('../common/common-arrow.vue2.js');
9
8
  const utils = require('../../../utils.js');
@@ -26,8 +25,9 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
26
25
  default: () => {
27
26
  return {
28
27
  treeId: 3301,
29
- treeType: 1,
30
- year: dayjs().format("YYYY")
28
+ timeType: "year",
29
+ startTime: 16725024e5,
30
+ endTime: 17040384e5
31
31
  };
32
32
  }
33
33
  },
@@ -9,7 +9,6 @@ const iconLight1 = require('./images/icon-light-1.svg.js');
9
9
  const iconLight2 = require('./images/icon-light-2.svg.js');
10
10
  const iconLight3 = require('./images/icon-light-3.svg.js');
11
11
  const vue = require('vue');
12
- const dayjs = require('dayjs');
13
12
  const utils = require('../../../utils.js');
14
13
  const index = require('./api/index.js');
15
14
 
@@ -24,8 +23,9 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
24
23
  props: {
25
24
  params: { default: () => {
26
25
  return {
27
- startTime: dayjs().startOf("year").valueOf(),
28
- endTime: dayjs().endOf("year").valueOf(),
26
+ // startTime: dayjs().startOf('year').valueOf(),
27
+ // endTime: dayjs().endOf('year').valueOf(),
28
+ timeStr: "2023",
29
29
  timeType: "hour",
30
30
  factor: "8",
31
31
  factorFlag: false,
@@ -36,7 +36,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
36
36
  } },
37
37
  titleStyle: { default: () => {
38
38
  return {
39
- color: "#909399"
39
+ color: "var(--dv-color-text-primary)"
40
40
  };
41
41
  } },
42
42
  isLazy: { type: Boolean, default: false }
@@ -92,8 +92,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
92
92
  ]),
93
93
  vue.createElementVNode("div", _hoisted_5, vue.toDisplayString(i.label), 1),
94
94
  vue.createElementVNode("div", _hoisted_6, [
95
- vue.createElementVNode("span", null, vue.toDisplayString(item[i.props]), 1),
96
- vue.createElementVNode("span", null, vue.toDisplayString(i.unit), 1)
95
+ vue.createElementVNode("span", null, vue.toDisplayString(item[i.props] === null ? "--" : item[i.props] + i.unit), 1)
97
96
  ])
98
97
  ]);
99
98
  }), 64))
@@ -29,11 +29,20 @@ const _hoisted_4 = {
29
29
  const _sfc_main = /* @__PURE__ */ vue.defineComponent({
30
30
  __name: "index",
31
31
  props: {
32
- treeId: { default: "3301" },
33
- treeType: { default: 1 },
34
- year: { default: "2023" },
35
- data: {},
36
- isLazy: { type: Boolean }
32
+ treeId: {},
33
+ timeType: {},
34
+ startTime: {},
35
+ endTime: {},
36
+ data: { default: null },
37
+ isLazy: { type: Boolean, default: false },
38
+ params: { default: () => {
39
+ return {
40
+ treeId: "3301",
41
+ timeType: "year",
42
+ startTime: 16725024e5,
43
+ endTime: 17040384e5
44
+ };
45
+ } }
37
46
  },
38
47
  setup(__props, { expose: __expose }) {
39
48
  const props = __props;
@@ -52,7 +61,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
52
61
  const tableData = vue.ref([]);
53
62
  const getData = async () => {
54
63
  const params = {
55
- ...props
64
+ ...props.params
56
65
  };
57
66
  const { data } = await index.synthesisIndex(params);
58
67
  tableData.value = (data || []).map((item, index) => {
@@ -64,7 +73,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
64
73
  };
65
74
  });
66
75
  };
67
- vue.watch([() => props.data, () => props.treeId, () => props.treeType, () => props.year, () => props.isLazy], () => {
76
+ vue.watch([() => props.data, () => props.params, () => props.isLazy], () => {
68
77
  if (props.isLazy)
69
78
  return;
70
79
  if (props.data) {
@@ -87,11 +96,13 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
87
96
  changePercent: vue.withCtx((scope) => [
88
97
  vue.createElementVNode("span", {
89
98
  style: { "margin-right": "4px" },
90
- class: vue.normalizeClass(classObj[scope.row.type])
91
- }, vue.toDisplayString(scope.row.changePercent), 3),
92
- scope.row.type === "-1" ? (vue.openBlock(), vue.createElementBlock("img", _hoisted_2)) : vue.createCommentVNode("", true),
93
- scope.row.type === "1" ? (vue.openBlock(), vue.createElementBlock("img", _hoisted_3)) : vue.createCommentVNode("", true),
94
- scope.row.type === "0" ? (vue.openBlock(), vue.createElementBlock("img", _hoisted_4)) : vue.createCommentVNode("", true)
99
+ class: vue.normalizeClass(scope.row.changePercent !== null ? classObj[scope.row.type] : "")
100
+ }, vue.toDisplayString(scope.row.changePercent === null ? "--" : scope.row.changePercent), 3),
101
+ scope.row.changePercent !== null ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
102
+ scope.row.type === "-1" ? (vue.openBlock(), vue.createElementBlock("img", _hoisted_2)) : vue.createCommentVNode("", true),
103
+ scope.row.type === "1" ? (vue.openBlock(), vue.createElementBlock("img", _hoisted_3)) : vue.createCommentVNode("", true),
104
+ scope.row.type === "0" ? (vue.openBlock(), vue.createElementBlock("img", _hoisted_4)) : vue.createCommentVNode("", true)
105
+ ], 64)) : vue.createCommentVNode("", true)
95
106
  ]),
96
107
  _: 1
97
108
  }, 8, ["data"])
@@ -6,6 +6,7 @@ const vue = require('vue');
6
6
  const dayjs = require('dayjs');
7
7
  require('echarts/lib/component/markLine');
8
8
  const BaseECharts_vue_vue_type_script_setup_true_lang = require('../../utils/echarts/BaseECharts.vue.js');
9
+ const tools = require('../../utils/tools.js');
9
10
  const index = require('./api/index.js');
10
11
 
11
12
  const _hoisted_1 = { class: "dv-wgms-upstream-impact" };
@@ -98,7 +99,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
98
99
  rain: [],
99
100
  factorValue: resData.map((item) => item.value)
100
101
  };
101
- const dass = waterQualityData.quality.map((item, index) => {
102
+ const dass = waterQualityData.factorValue.map((item, index) => {
102
103
  return {
103
104
  value: item || item === 0 ? item : null
104
105
  };
@@ -220,11 +221,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
220
221
  };
221
222
  if (props.params?.factorCode === "w01001") {
222
223
  if (state.factorLimitValue && state.factorLimitValue.upValue) {
224
+ const num = tools.countDecimalPlaces(state.factorLimitValue.upValue);
223
225
  option2.series[0].markLine = {
224
226
  symbol: "none",
225
227
  data: [
226
228
  {
227
- yAxis: state.factorLimitValue.upValue,
229
+ yAxis: Number(state.factorLimitValue.upValue).toFixed(num),
228
230
  show: true,
229
231
  lineStyle: {
230
232
  type: "solid",
@@ -232,7 +234,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
232
234
  }
233
235
  },
234
236
  {
235
- yAxis: state.factorLimitValue.downValue == null ? "" : state.factorLimitValue.downValue,
237
+ yAxis: state.factorLimitValue.downValue == null ? "" : Number(state.factorLimitValue.downValue).toFixed(num),
236
238
  show: true,
237
239
  lineStyle: {
238
240
  type: "solid",
@@ -248,11 +250,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
248
250
  }
249
251
  } else {
250
252
  if (state.factorLimitValue.value != null) {
253
+ const num = tools.countDecimalPlaces(state.factorLimitValue.value);
251
254
  option2.series[0].markLine = {
252
255
  symbol: "none",
253
256
  data: [
254
257
  {
255
- yAxis: state.factorLimitValue.value,
258
+ yAxis: Number(state.factorLimitValue.value).toFixed(num),
256
259
  show: true,
257
260
  lineStyle: {
258
261
  type: "solid",
@@ -148,12 +148,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
148
148
  let str = `<div>${params[0].axisValue}</div>`;
149
149
  params.forEach((item, index) => {
150
150
  let unit2 = "";
151
- if (index === 0)
151
+ if (item.seriesName === "降雨量")
152
152
  unit2 = "mm/h";
153
- else if (index === 1)
154
- unit2 = props?.params?.factorUnit || "";
155
- else
153
+ else if (item.seriesName === "水位")
156
154
  unit2 = "m";
155
+ else
156
+ unit2 = props?.params?.factorUnit || "";
157
157
  str += `<div>${item.marker}${item.seriesName}:${item.value ? item.value : "--"}${unit2}</div>`;
158
158
  });
159
159
  return str;
@@ -401,11 +401,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
401
401
  };
402
402
  if (props.params?.factorCode === "w01001") {
403
403
  if (state.factorLimitValue && state.factorLimitValue.upValue) {
404
+ const num = tools.countDecimalPlaces(state.factorLimitValue.upValue);
404
405
  option2.series[1].markLine = {
405
406
  symbol: "none",
406
407
  data: [
407
408
  {
408
- yAxis: state.factorLimitValue.upValue,
409
+ yAxis: Number(state.factorLimitValue.upValue).toFixed(num),
409
410
  show: true,
410
411
  lineStyle: {
411
412
  type: "solid",
@@ -413,7 +414,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
413
414
  }
414
415
  },
415
416
  {
416
- yAxis: state.factorLimitValue.downValue == null ? "" : state.factorLimitValue.downValue,
417
+ yAxis: state.factorLimitValue.downValue == null ? "" : Number(state.factorLimitValue.downValue).toFixed(num),
417
418
  show: true,
418
419
  lineStyle: {
419
420
  type: "solid",
@@ -429,11 +430,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
429
430
  }
430
431
  } else {
431
432
  if (state.factorLimitValue.value != null) {
433
+ const num = tools.countDecimalPlaces(state.factorLimitValue.value);
432
434
  option2.series[1].markLine = {
433
435
  symbol: "none",
434
436
  data: [
435
437
  {
436
- yAxis: state.factorLimitValue.value,
438
+ yAxis: Number(state.factorLimitValue.value).toFixed(num),
437
439
  show: true,
438
440
  lineStyle: {
439
441
  type: "solid",
@@ -36,11 +36,16 @@ const _hoisted_20 = ["src"];
36
36
  const _sfc_main = /* @__PURE__ */ vue.defineComponent({
37
37
  __name: "index",
38
38
  props: {
39
- treeId: { default: "3301" },
40
- treeType: { default: 1 },
41
- year: { default: "2023" },
42
- data: {},
43
- isLazy: { type: Boolean, default: false }
39
+ data: { default: null },
40
+ isLazy: { type: Boolean, default: false },
41
+ params: { default: () => {
42
+ return {
43
+ treeId: "3301",
44
+ timeType: "day",
45
+ startTime: 16725024e5,
46
+ endTime: 17040384e5
47
+ };
48
+ } }
44
49
  },
45
50
  setup(__props, { expose: __expose }) {
46
51
  const props = __props;
@@ -67,12 +72,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
67
72
  });
68
73
  const getData = async () => {
69
74
  const params = {
70
- ...props
75
+ ...props.params
71
76
  };
72
77
  const { data } = await index.waterQualityStatus(params);
73
78
  list.value = data || [];
74
79
  };
75
- vue.watch([() => props.data, () => props.treeId, () => props.treeType, () => props.year, () => props.isLazy], () => {
80
+ vue.watch([() => props.data, () => props.params, () => props.isLazy], () => {
76
81
  if (props.isLazy)
77
82
  return;
78
83
  if (props.data) {
@@ -80,7 +85,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
80
85
  return;
81
86
  }
82
87
  getData();
83
- }, { immediate: true });
88
+ }, { immediate: true, deep: true });
84
89
  __expose({
85
90
  reload: getData
86
91
  });
@@ -98,33 +103,34 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
98
103
  vue.createElementVNode("div", _hoisted_6, [
99
104
  vue.createElementVNode("div", _hoisted_7, [
100
105
  _hoisted_8,
101
- vue.createElementVNode("span", _hoisted_9, vue.toDisplayString(item.excellentPercent) + "%", 1)
106
+ vue.createElementVNode("span", _hoisted_9, vue.toDisplayString(item.excellentPercent === null ? "--" : `${item.excellentPercent}%`), 1)
102
107
  ]),
103
108
  vue.createElementVNode("div", _hoisted_10, [
104
109
  vue.createVNode(ProgressBar_vue_vue_type_script_setup_true_lang.default, {
105
- percentage: item.excellentPercent
110
+ percentage: item.excellentPercent || 0
106
111
  }, null, 8, ["percentage"])
107
112
  ]),
108
113
  vue.createElementVNode("div", _hoisted_11, [
109
114
  vue.createElementVNode("div", null, [
110
115
  _hoisted_12,
111
- vue.createElementVNode("span", _hoisted_13, vue.toDisplayString(item.targetPercent) + "%", 1)
116
+ vue.createElementVNode("span", _hoisted_13, vue.toDisplayString(item.targetPercent === null ? "--" : `${item.targetPercent}%`), 1)
112
117
  ]),
113
118
  vue.createElementVNode("div", null, [
114
119
  _hoisted_14,
115
120
  vue.createElementVNode("span", {
116
121
  class: "dv-mr-4 dv-number1 up-num",
117
- style: vue.normalizeStyle({ color: vue.unref(getCompare)(item.yoyPercent).color })
118
- }, vue.toDisplayString(item.yoyPercent) + "%", 5),
122
+ style: vue.normalizeStyle({ color: item.yoyPercent === null ? "" : vue.unref(getCompare)(item.yoyPercent).color })
123
+ }, vue.toDisplayString(item.yoyPercent === null ? "--" : `${item.yoyPercent}%`), 5),
119
124
  vue.createElementVNode("span", {
120
125
  class: "dv-mr-6 up-num",
121
- style: vue.normalizeStyle({ color: vue.unref(getCompare)(item.yoyPercent).color })
122
- }, vue.toDisplayString(vue.unref(getCompare)(item.yoyPercent).label), 5),
123
- vue.createElementVNode("img", {
126
+ style: vue.normalizeStyle({ color: item.yoyPercent === null ? "" : vue.unref(getCompare)(item.yoyPercent).color })
127
+ }, vue.toDisplayString(item.yoyPercent === null ? "" : vue.unref(getCompare)(item.yoyPercent).label), 5),
128
+ item.yoyPercent !== null ? (vue.openBlock(), vue.createElementBlock("img", {
129
+ key: 0,
124
130
  style: { "height": "12px" },
125
131
  src: vue.unref(getCompare)(item.yoyPercent).img,
126
132
  alt: ""
127
- }, null, 8, _hoisted_15)
133
+ }, null, 8, _hoisted_15)) : vue.createCommentVNode("", true)
128
134
  ])
129
135
  ])
130
136
  ])
@@ -137,16 +143,17 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
137
143
  }, [
138
144
  vue.createElementVNode("div", _hoisted_17, vue.toDisplayString(child.stationTypeName), 1),
139
145
  vue.createElementVNode("div", _hoisted_18, [
140
- vue.createElementVNode("span", _hoisted_19, vue.toDisplayString(item.excellentPercent) + "%", 1),
146
+ vue.createElementVNode("span", _hoisted_19, vue.toDisplayString(item.excellentPercent === null ? "--" : `${item.excellentPercent}%`), 1),
141
147
  vue.createElementVNode("span", {
142
148
  class: "dv-mr-2 dv-number1 dv-danger",
143
- style: vue.normalizeStyle({ color: vue.unref(getCompare)(item.yoyPercent).color })
144
- }, vue.toDisplayString(item.yoyPercent) + "%", 5),
145
- vue.createElementVNode("img", {
149
+ style: vue.normalizeStyle({ color: item.yoyPercent === null ? "" : vue.unref(getCompare)(item.yoyPercent).color })
150
+ }, vue.toDisplayString(item.yoyPercent === null ? "--" : `${item.yoyPercent}%`), 5),
151
+ item.yoyPercent !== null ? (vue.openBlock(), vue.createElementBlock("img", {
152
+ key: 0,
146
153
  style: { "height": "12px" },
147
154
  src: vue.unref(getCompare)(item.yoyPercent).img,
148
155
  alt: ""
149
- }, null, 8, _hoisted_20)
156
+ }, null, 8, _hoisted_20)) : vue.createCommentVNode("", true)
150
157
  ])
151
158
  ]);
152
159
  }), 128))
@@ -14,16 +14,21 @@ const _hoisted_1 = {
14
14
  const _sfc_main = /* @__PURE__ */ vue.defineComponent({
15
15
  __name: "index",
16
16
  props: {
17
- treeId: { default: "3301" },
18
- treeType: { default: 1 },
19
- year: { default: "2023" },
20
- isLazy: { type: Boolean }
17
+ isLazy: { type: Boolean, default: false },
18
+ params: { default: () => {
19
+ return {
20
+ treeId: "3301",
21
+ timeType: "year",
22
+ startTime: 16725024e5,
23
+ endTime: 17040384e5
24
+ };
25
+ } }
21
26
  },
22
27
  setup(__props, { expose: __expose }) {
23
28
  const props = __props;
24
29
  const options = vue.shallowRef();
25
30
  const getData = async () => {
26
- const { data } = await index.waterQualityAnalyze({ ...props });
31
+ const { data } = await index.waterQualityAnalyze({ ...props.params });
27
32
  const xData = [];
28
33
  const goodList = [];
29
34
  const badList = [];
@@ -34,7 +39,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
34
39
  });
35
40
  options.value = echartsOptions.getDizhouQualityAnalysisOption(xData, goodList, badList);
36
41
  };
37
- vue.watch([() => props.treeId, () => props.treeType, () => props.year, () => props.isLazy], () => {
42
+ vue.watch([() => props.params, () => props.isLazy], () => {
38
43
  if (props.isLazy)
39
44
  return;
40
45
  getData();
@@ -77,7 +77,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
77
77
  const getData = (optionItem, item) => {
78
78
  if (optionItem.render)
79
79
  return optionItem.render(item, optionItem);
80
- return optionItem.key ? item[optionItem.key] : "/";
80
+ return optionItem.key ? item[optionItem.key] === null ? "--" : item[optionItem.key] : "/";
81
81
  };
82
82
  const checkLine = (item, index) => {
83
83
  if (currIndex.value === index) {
@@ -167,7 +167,7 @@ const getDizhouQualityAnalysisOption = (xData, goodList, badList) => {
167
167
  {
168
168
  name: "优良比例",
169
169
  type: "bar",
170
- barWidth: 15,
170
+ // barWidth: 15,
171
171
  data: goodList,
172
172
  itemStyle: {
173
173
  color: "var(--dv-color-success)"
@@ -176,7 +176,7 @@ const getDizhouQualityAnalysisOption = (xData, goodList, badList) => {
176
176
  {
177
177
  name: "劣V比例",
178
178
  type: "bar",
179
- barWidth: 15,
179
+ // barWidth: 15,
180
180
  itemStyle: {
181
181
  color: "var(--dv-color-danger)"
182
182
  },
@@ -65,7 +65,14 @@ const getAlgaeTime = (val) => {
65
65
  // 预警当天日数据 没选择历史就显示今日
66
66
  };
67
67
  };
68
+ const countDecimalPlaces = (number) => {
69
+ const numberAsString = number.toString();
70
+ if (numberAsString.includes("."))
71
+ return numberAsString.split(".")[1].length;
72
+ return 0;
73
+ };
68
74
 
75
+ exports.countDecimalPlaces = countDecimalPlaces;
69
76
  exports.getAlgaeTime = getAlgaeTime;
70
77
  exports.getDateEndTime = getDateEndTime;
71
78
  exports.install = install;