diff --git a/src/components/BarEchartG.vue b/src/components/BarEchartG.vue new file mode 100644 index 0000000..35c9395 --- /dev/null +++ b/src/components/BarEchartG.vue @@ -0,0 +1,258 @@ + + + diff --git a/src/components/History1.vue b/src/components/History1.vue index 22e8095..19bc96e 100644 --- a/src/components/History1.vue +++ b/src/components/History1.vue @@ -49,6 +49,12 @@ {{ item.value }} + + 数值 + + {{ item.value }} + + @@ -59,7 +65,7 @@ import { onMounted, reactive, ref, toRefs } from "vue"; import { ElMessage } from "element-plus"; import myApi from "@/api/myApi.js"; -import BarEchart from "./BarEchart.vue"; +import BarEchart from "./BarEchartG.vue"; import Process from "./Process.vue"; import Date from "@/components/Date.vue"; export default { @@ -75,14 +81,8 @@ export default { { id: "echart0", title: "降水量-柱状图", - legend: ["降水量"], - color: ["#6fdbce"], - }, - { - id: "echart1", - title: "降水量-柱状图", - legend: ["降水量"], - color: ["#6fdbce"], + legend: ["降水量", "数据2", "数据3"], + color: ["#6fdbce", "#f00", "#0000ff"], } ], fxOptions: [