From 23bf4790df6b393cafbbce2a1c0c070d5f0dd929 Mon Sep 17 00:00:00 2001 From: "DESKTOP-FUDKNA8\\znjsz" Date: Wed, 28 Feb 2024 16:07:44 +0800 Subject: [PATCH 01/17] add 2 extra pages --- src/AlertListScreen.vue | 18 ++++++++++++++++++ src/App.vue | 9 +++++++-- src/MainScreen.vue | 18 ++++++++++++++++++ src/utils/useWebsocket.js | 3 ++- 4 files changed, 45 insertions(+), 3 deletions(-) create mode 100644 src/AlertListScreen.vue create mode 100644 src/MainScreen.vue diff --git a/src/AlertListScreen.vue b/src/AlertListScreen.vue new file mode 100644 index 0000000..cdb87ae --- /dev/null +++ b/src/AlertListScreen.vue @@ -0,0 +1,18 @@ + + + + + diff --git a/src/App.vue b/src/App.vue index 652ae79..94871f5 100644 --- a/src/App.vue +++ b/src/App.vue @@ -1,17 +1,20 @@ + + + + diff --git a/src/utils/useWebsocket.js b/src/utils/useWebsocket.js index 7e96d21..e6896f5 100644 --- a/src/utils/useWebsocket.js +++ b/src/utils/useWebsocket.js @@ -1,6 +1,7 @@ import Client from "./ws"; -export default function useWebsocket(store, path) { +export default function useWebsocket(store, path, excludePaths = []) { + if (excludePaths.includes(path)) return; // connect0(store); connectPath(store, path); } From 8d30507f1b5987dbe49d8993ba4e9fb84b5e6de1 Mon Sep 17 00:00:00 2001 From: "DESKTOP-FUDKNA8\\znjsz" Date: Wed, 28 Feb 2024 17:02:33 +0800 Subject: [PATCH 02/17] update --- src/AlertListScreen.vue | 227 ++++++++++++++++- src/MainScreen.vue | 235 +++++++++++++++++- src/components/mainscreen/SumRate.vue | 10 + src/components/mainscreen/SumYield.vue | 84 +++++++ .../mainscreen/TeamChartDayOptions.js | 59 +++++ src/components/mainscreen/TodayRate.vue | 10 + src/components/mainscreen/TodayYield.vue | 84 +++++++ 7 files changed, 689 insertions(+), 20 deletions(-) create mode 100644 src/components/mainscreen/SumRate.vue create mode 100644 src/components/mainscreen/SumYield.vue create mode 100644 src/components/mainscreen/TeamChartDayOptions.js create mode 100644 src/components/mainscreen/TodayRate.vue create mode 100644 src/components/mainscreen/TodayYield.vue diff --git a/src/AlertListScreen.vue b/src/AlertListScreen.vue index cdb87ae..118de01 100644 --- a/src/AlertListScreen.vue +++ b/src/AlertListScreen.vue @@ -1,18 +1,225 @@ + - + + diff --git a/src/MainScreen.vue b/src/MainScreen.vue index 38f2bf9..53def8e 100644 --- a/src/MainScreen.vue +++ b/src/MainScreen.vue @@ -1,18 +1,233 @@ + - + + diff --git a/src/components/mainscreen/SumRate.vue b/src/components/mainscreen/SumRate.vue new file mode 100644 index 0000000..5eb7af0 --- /dev/null +++ b/src/components/mainscreen/SumRate.vue @@ -0,0 +1,10 @@ + + + diff --git a/src/components/mainscreen/SumYield.vue b/src/components/mainscreen/SumYield.vue new file mode 100644 index 0000000..06c345f --- /dev/null +++ b/src/components/mainscreen/SumYield.vue @@ -0,0 +1,84 @@ + + + + + diff --git a/src/components/mainscreen/TeamChartDayOptions.js b/src/components/mainscreen/TeamChartDayOptions.js new file mode 100644 index 0000000..18a4820 --- /dev/null +++ b/src/components/mainscreen/TeamChartDayOptions.js @@ -0,0 +1,59 @@ +export const options = { + color: ['#a4c9d1', '#72340b', '#ffd601' ], + grid: { + top: 8, + bottom: 20, + left: 42, + right: 28, + }, + legend: { + show: false, + }, + xAxis: { + max: 100, + splitLine: { + lineStyle: { + color: "#fff2", + }, + }, + axisLabel: { + fontSize: 16, + color: "#e5e5e5a3", + }, + }, + yAxis: { + type: "category", + data: ["A组", "B组", "C组"], + inverse: true, + max: 2, // only the largest 3 bars will be displayed + axisLabel: { + fontSize: 16, + color: "#e5e5e5a3", + }, + splitLine: { + lineStyle: { + color: "#e5e5e5", + }, + }, + }, + series: [ + { + type: "bar", + data: [34, 2, 23], + label: { + show: true, + position: "right", + formatter: "{c}%", + color: "#fff", + fontSize: 16, + }, + }, + ], + +}; + +export default function setup(echartInstance, dataArr) { + const new_options = { ...options }; + new_options.series[0].data = dataArr; + echartInstance.setOption(new_options); +} diff --git a/src/components/mainscreen/TodayRate.vue b/src/components/mainscreen/TodayRate.vue new file mode 100644 index 0000000..6a895ab --- /dev/null +++ b/src/components/mainscreen/TodayRate.vue @@ -0,0 +1,10 @@ + + + diff --git a/src/components/mainscreen/TodayYield.vue b/src/components/mainscreen/TodayYield.vue new file mode 100644 index 0000000..d1bc826 --- /dev/null +++ b/src/components/mainscreen/TodayYield.vue @@ -0,0 +1,84 @@ + + + + + From fb4c1500e713b1279e44459cbf26619fad2bdda0 Mon Sep 17 00:00:00 2001 From: "DESKTOP-FUDKNA8\\znjsz" Date: Thu, 29 Feb 2024 15:23:31 +0800 Subject: [PATCH 03/17] update bg --- src/AlertListScreen.vue | 10 ++++++++++ src/MainScreen.vue | 10 ++++++++++ src/assets/full-lines.png | Bin 0 -> 1000956 bytes 3 files changed, 20 insertions(+) create mode 100644 src/assets/full-lines.png diff --git a/src/AlertListScreen.vue b/src/AlertListScreen.vue index 118de01..7d7abab 100644 --- a/src/AlertListScreen.vue +++ b/src/AlertListScreen.vue @@ -47,6 +47,7 @@ function handleResolutionChange(width, height) {