From 9cd30f4fa434a77af989209b8a31a102226cb074 Mon Sep 17 00:00:00 2001 From: wangyi <3432649580@qq.com> Date: Wed, 29 Oct 2025 11:10:54 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9http?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- utils/http.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utils/http.js b/utils/http.js index 51668a2..0cedb03 100644 --- a/utils/http.js +++ b/utils/http.js @@ -43,8 +43,8 @@ const httpInterceptor = { } //4 添加token,优先用store,没有则回退到body中的token,保持与Apifox一致 const memberStore = useUserStore() - // const token = memberStore.userInfo?.token || options.data?.token - const token = '1b3a58424c5324e40d4bf4d085e18047' + const token = memberStore.userInfo?.token || options.data?.token + // const token = '1b3a58424c5324e40d4bf4d085e18047' if (token) { options.header.token = token } From 3a7d24916024fe2ef0c4ecf638cff8b658bd92d5 Mon Sep 17 00:00:00 2001 From: ZhangYong Date: Wed, 29 Oct 2025 11:53:40 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E5=AF=B9=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/deepExploration/deepExploration.js | 71 ++++++++++++++++++++++++-- api/tcpConnection.js | 2 +- pages/deepExploration/MainForceActions.vue | 80 ++++++++++++++++++++++++++---- 3 files changed, 140 insertions(+), 13 deletions(-) diff --git a/api/deepExploration/deepExploration.js b/api/deepExploration/deepExploration.js index 96e9cad..34dfc8f 100644 --- a/api/deepExploration/deepExploration.js +++ b/api/deepExploration/deepExploration.js @@ -1,10 +1,75 @@ import { http } from '@/utils/http.js' -//点击主力追踪 -export const getModel1 = () => { +//主力追踪意图 +export const getModel1First = (data) => { return http({ - method: 'GET', + method: 'POST', url: '/api/coze/trackingFirst', + data + }) +} + +//主力追踪意图 +export const getModel1Second = (data) => { + return http({ + method: 'POST', + url: '/api/coze/trackingSecond', + data + }) +} + + +//主力追踪意图 +export const getModel2First = (data) => { + return http({ + method: 'POST', + url: '/api/coze/radarFirst', + data + }) +} + +//主力追踪意图 +export const getModel2Second = (data) => { + return http({ + method: 'POST', + url: '/api/coze/radarSecond', + data + }) +} + +//主力追踪意图 +export const getModel3First = (data) => { + return http({ + method: 'POST', + url: '/api/coze/decodingFirst', + data + }) +} + +//主力追踪意图 +export const getModel3Second = (data) => { + return http({ + method: 'POST', + url: '/api/coze/decodingSecond', + data + }) +} + +//主力追踪意图 +export const getModel4First = (data) => { + return http({ + method: 'POST', + url: '/api/coze/fundsFirst', + data + }) +} + +//主力追踪意图 +export const getModel4Second = (data) => { + return http({ + method: 'POST', + url: '/api/coze/fundsSecond', + data }) } \ No newline at end of file diff --git a/api/tcpConnection.js b/api/tcpConnection.js index 235c1ad..c701ca3 100644 --- a/api/tcpConnection.js +++ b/api/tcpConnection.js @@ -7,7 +7,7 @@ // 引用TCP插件 // const TCPSocket = uni.requireNativePlugin('Aimer-TCPPlugin'); -const TCPSocket = uni.requireNativePlugin("Aimer-TCPPlugin"); +// const TCPSocket = uni.requireNativePlugin("Aimer-TCPPlugin"); // TCP连接配置 const TCP_CONFIG = { diff --git a/pages/deepExploration/MainForceActions.vue b/pages/deepExploration/MainForceActions.vue index 6f40650..f9e87fc 100644 --- a/pages/deepExploration/MainForceActions.vue +++ b/pages/deepExploration/MainForceActions.vue @@ -5,7 +5,7 @@ - @@ -69,6 +69,16 @@ import { onLoad } from '@dcloudio/uni-app' + import { + getModel1First, + getModel1Second, + getModel2First, + getModel2Second, + getModel3First, + getModel3Second, + getModel4First, + getModel4Second, + } from '/api/deepExploration/deepExploration.js' // 响应式变量定义 const type = ref('deepExploration') @@ -92,6 +102,29 @@ }, ]) + //搜索股票 + const searchStock = () => { + console.log('搜索参数:', stockName.value); + if (currentIndex.value == 0) { + handleModel(0) + } else if (currentIndex.value == 1) { + console.log(index); + handleModel(1) + } else if (currentIndex.value == 2) { + console.log(index); + handleModel(2) + } else if (currentIndex.value == 3) { + console.log(index); + handleModel(3) + }else{ + uni.showToast({ + title: '请选择模块', + icon: 'none', + duration: 2000 + }) + } + + } //点击四大模块 const handleModel = (index) => { currentIndex.value = index @@ -110,9 +143,42 @@ } } + const stockName = ref('') + const searchName = ref('') + const stockCode = ref('') + const language = ref('') + const recordId = ref('') + const parentId = ref('') + const stockId = ref('') //点击主力追踪 - const handleTrack = () => { - + const handleTrack = async () => { + try { + const result = await getModel1First({ + content: searchName.value, + language: "cn", + marketList: "hk,cn,usa,my,sg,vi,in,gb", + model: 1 + }) + console.log('result', result); + if (result.code == 200) { + stockCode.value = result.data.code + stockName.value = result.data.name + recordId.value = result.data.recordId + parentId.value = result.data.parentId + stockId.value = result.data.stockId + language.value = result.data.language + const res = await getModel1Second({ + language: language.value, + recordId: recordId.value, + parentId: parentId.value, + stockId: stockId.value + }) + console.log('res', res); + } + + } catch { + + } } //点击主力雷达 @@ -129,12 +195,7 @@ const handleCapitalFlow = () => { } - const stockName = ref('TSLA') - //搜索股票 - const searchStock = () => { - console.log('搜索参数:', stockName.value); - } // 1. K线图配置 const opts = ref({ @@ -733,7 +794,8 @@ width: 100%; } } - *{ + + * { box-sizing: border-box; } \ No newline at end of file