diff --git a/src/store/dataList.js b/src/store/dataList.js index 7c2d74b..9b39b3e 100644 --- a/src/store/dataList.js +++ b/src/store/dataList.js @@ -24,11 +24,15 @@ export const useDataStore = defineStore('data', () => { const AIRadar = ref(null) const loading = ref(false) const klineData = ref(null) - + const activeTabIndex = ref(null) const setKlineData = (data) => { klineData.value = data } + const setActiveTabIndex = (index) => { + activeTabIndex.value = index + } + const getQueryVariable = (variable) => { const query = window.location.search.substring(1) // console.log(query,'query') @@ -179,10 +183,12 @@ export const useDataStore = defineStore('data', () => { // loading, // AIRadar, // fetchChartData, + activeTabIndex, klineData, setKlineData, initData, getMarket, - getQueryVariable + getQueryVariable, + setActiveTabIndex } }) diff --git a/src/views/AIchat.vue b/src/views/AIchat.vue index e379366..f8b81fe 100644 --- a/src/views/AIchat.vue +++ b/src/views/AIchat.vue @@ -1,5 +1,5 @@