From 02fa821a2fa3f7571ec24f2d80dc9d0d61a4cbec Mon Sep 17 00:00:00 2001
From: zprobot <1727697083@qq.com>
Date: Sat, 23 Dec 2023 16:46:16 +0800
Subject: [PATCH] label_control
---
src/components/AeShow/index.vue | 28 ++++++++++++++++++++++++----
1 file changed, 24 insertions(+), 4 deletions(-)
diff --git a/src/components/AeShow/index.vue b/src/components/AeShow/index.vue
index 680bdbd..ffe2c64 100644
--- a/src/components/AeShow/index.vue
+++ b/src/components/AeShow/index.vue
@@ -14,9 +14,25 @@
"
active-text="Bar"
inactive-text="Box"
- @change = "changeShow"
+ @change = "changeShowBar"
+ />
+
+
{{ item }}
@@ -54,6 +70,7 @@ let imgH = 500
// database
let proteinTable = []
const showBar = ref(false)
+const showLabel = ref(false)
// component show
const showImg = ref(false)
// data history
@@ -334,7 +351,7 @@ const init = () => {
borderColor0: '#030609',
},
label: {
- show: true,
+ show: showLabel.value,
position: 'right',
formatter: function () {
return `samples: ${samples.shift()}`
@@ -421,7 +438,7 @@ const init = () => {
borderColor0: '#030609',
},
label: {
- show: true,
+ show: showLabel.value,
position: 'right',
formatter: function () {
return `samples: ${samples[index].shift()}`
@@ -540,7 +557,10 @@ const countSingleValue = (data, dimension) => {
}
//
-const changeShow = () => {
+const changeShowBar = () => {
+ init()
+}
+const changeShowLabel = () => {
init()
}