增量提交
This commit is contained in:
@@ -174,6 +174,11 @@ class WebSocketManager {
|
||||
console.log('收到WebSocket消息:', res.data)
|
||||
try {
|
||||
const data = JSON.parse(res.data)
|
||||
// AI 消息打字机效果
|
||||
if (data.type === 'miniprogram_message_response' && data.data && data.data.content) {
|
||||
const handlers = this.messageHandlers.get('ai_message') || []
|
||||
handlers.forEach(h => { try { h(data.data) } catch(e) { console.error(e) } })
|
||||
}
|
||||
this.handleMessage(data)
|
||||
} catch (e) {
|
||||
console.error('解析WebSocket消息失败:', e)
|
||||
@@ -357,7 +362,7 @@ const constants = {
|
||||
API_BASE: 'https://pactgo.cn/api/v1',
|
||||
|
||||
// WebSocket地址
|
||||
WEBSOCKET_URL: 'wss://pactgo.cn/ws/task',
|
||||
WEBSOCKET_URL: 'wss://pactgo.cn/api/v1/ws/miniprogram',
|
||||
|
||||
// 任务状态
|
||||
TASK_STATUS: {
|
||||
|
||||
Reference in New Issue
Block a user