update 芯片投入

Šī revīzija ir iekļauta:
DESKTOP-FUDKNA8\znjsz 2024-04-18 14:49:49 +08:00
vecāks cddd23855c
revīzija 691f63438a
2 mainīti faili ar 39 papildinājumiem un 24 dzēšanām

Parādīt failu

@ -20,34 +20,50 @@ import LeftChartBase from "./LeftChartBase.vue";
export default {
name: "chip-investChart",
components: { LeftChartBase },
props: {
legend: {
type: Array,
default: () => [
{ label: "2023年", color: "#12f7f1" },
{ label: "2024年", color: "#58adfa" },
data() {
const year = new Date().getFullYear();
//
const cities = ["瑞昌", "邯郸", "株洲", "佳木斯", "成都", "凯盛", "蚌埠"];
return {
legend: [
{ label: `${year - 1}`, color: "#12f7f1" },
{ label: `${year}`, color: "#58adfa" },
],
},
xAxis: {
type: Array,
default: () => ["成都", "邯郸", "株洲", "瑞昌", "heels", "socks"],
},
series: {
type: Array,
default: () => [
xAxis: cities,
};
},
computed: {
series() {
const chipInvest = this.$store.getters.home.chipInvest;
console.log("FTO ==> ", chipInvest);
if (!chipInvest || !chipInvest.current || !chipInvest.previous) {
return [
{
name: "样例数据--2023年",
data: Array.from({ length: 7 }, () =>
Math.floor(Math.random() * 1000)
),
},
{
name: "样例数据--2024年",
data: Array.from({ length: 7 }, () =>
Math.floor(Math.random() * 1000)
),
},
];
}
return [
{
name: "2023年",
data: Array.from({ length: 7 }, () =>
Math.floor(Math.random() * 1000)
),
name: `${new Date().getFullYear() - 1}`,
data: chipInvest.previous,
},
{
name: "2024年",
data: Array.from({ length: 7 }, () =>
Math.floor(Math.random() * 1000)
),
name: `${new Date().getFullYear()}`,
data: chipInvest.current,
},
],
];
},
},
};

Parādīt failu

@ -35,7 +35,6 @@ export default {
computed: {
series() {
const ftoInvest = this.$store.getters.home.ftoInvest;
console.log("FTO ==> ", ftoInvest);
if (!ftoInvest || !ftoInvest.current || !ftoInvest.previous) {
return [