From 872daddd00287cd44963483ba15f997d25a3da53 Mon Sep 17 00:00:00 2001
From: lxf <1371462558@qq.com>
Date: Sat, 05 Jul 2025 11:54:34 +0800
Subject: [PATCH] stye
---
src/components/fx-kline/index.vue | 14 +++++++++++---
1 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/src/components/fx-kline/index.vue b/src/components/fx-kline/index.vue
index 8b6c323..b0489d7 100644
--- a/src/components/fx-kline/index.vue
+++ b/src/components/fx-kline/index.vue
@@ -72,7 +72,11 @@
socket.value = new WebSocket(`${WS_URL}/1/${props.symbol}`)
socket.value.onmessage = (evt) => {
const { data } = evt
- const { code, data: _data } = JSON.parse(data)
+ let { code, data: _data } = JSON.parse(data)
+ // _data[0].high = Math.floor(Math.random() * 100) + 1
+ // _data[0].low = Math.floor(Math.random() * 100) + 1
+ // _data[0].close = Math.floor(Math.random() * 100) + 1
+ // _data[0].open = Math.floor(Math.random() * 100) + 1
if (code / 1 === 0) {
emits('data', _data[0])
updateCharts(_data[0])
@@ -154,8 +158,10 @@
width: quotesStore.stage === 'timeSharing' ? 0 : null,
}
})
+ // quotesStore[SET_STAGE]({ stage: 'timeSharing', seconds: 1000 })
+
if (!quotesStore.stage) {
- quotesStore[SET_STAGE]({ stage: '1min', seconds: 1 * 60 * 1000 })
+ quotesStore[SET_STAGE]({ stage: '1min', seconds: 1000 })
}
emits('loading', true)
@@ -202,8 +208,10 @@
}
})
if (!quotesStore.stage) {
- quotesStore[SET_STAGE]({ stage: '1min', seconds: 1 * 60 * 1000 })
+ quotesStore[SET_STAGE]({ stage: '1min', seconds: 1000 })
}
+ // quotesStore[SET_STAGE]({ stage: 'timeSharing', seconds: 1000 })
+
// console.log(data.value)
nextTick(() => {
--
Gitblit v1.9.3