chore:微信小程序真机版本可以运行,微信小程序客服图标显示正常

This commit is contained in:
2026-04-20 17:50:37 +08:00
parent d8b78168a8
commit 8af3c0ccb9
3 changed files with 13 additions and 9 deletions

View File

@@ -64,11 +64,13 @@ export default {
// #ifdef MP-WEIXIN
return new Promise((resolve, reject) => {
const match = Config.baseUrl.match(/^(?:https?:\/\/|wss?:\/\/)([^\/\s:]+)/);
const domain = match ? match[1] : '';
const socketTask = wx.connectSocket({
url: `wss://${domain}/ws/aikefu`,
header: {}
});
const domain = match ? match[1] : '';
const wssUrl = `wss://${domain}/ws/aikefu`;
console.log(`wssUrl = ${wssUrl}`);
const socketTask = wx.connectSocket({
url: wssUrl,
header: {}
});
let content = '';
let conversationId = '';