From 60da2c50884fbd01282c0e61d0d7f3b0845d6192 Mon Sep 17 00:00:00 2001 From: weipengfei <2187978347@qq.com> Date: Thu, 9 Nov 2023 16:00:10 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96websockt=E8=BF=9E=E6=8E=A5?= =?UTF-8?q?=E5=9C=B0=E5=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/app.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/config/app.js b/config/app.js index 9bfd4f2..351524e 100644 --- a/config/app.js +++ b/config/app.js @@ -8,6 +8,7 @@ let httpApiTwo let httpApiThree let httpApiFour let httpApiFive +let wsApi // 在打包之前请检查当前环境是否正确 const env = 'dev'; // 开发 @@ -20,12 +21,14 @@ switch (env) { httpApiTwo = 'https://nk.lihaink.cn' httpApiThree = 'http://ceshi-oa.lihaink.cn' httpApiFour = 'https://worker-task.lihaink.cn' + wsApi = 'wss://shop.lihaink.cn' break; case 'prew': httpApi = 'https://test.shop.lihaink.cn' //预发布环境 httpApiTwo = "https://nk.lihaink.cn" httpApiThree = 'http://ceshi-oa.lihaink.cn' httpApiFour = 'https://preview-worker-task.lihaink.cn' + wsApi = 'wss://test.shop.lihaink.cn' break; default: httpApi = "https://crmeb-test.shop.lihaink.cn" // 测试 @@ -33,15 +36,13 @@ switch (env) { httpApiThree = 'http://ceshi-oa.lihaink.cn' httpApiFour = 'https://ceshi-worker-task.lihaink.cn' httpApiFive = 'https://ceshi-zhibo.lihaink.cn' + wsApi = 'wss://crmeb-test.shop.lihaink.cn' } - - - // 聊天接口修改此字符 小程序聊天要求wss 例如:wss://mer.crmeb.net -// let wsApi = 'ws://192.168.3.20:8324' -let wsApi = 'wss://shop.lihaink.cn' +// wsApi = 'ws://192.168.1.17:8324' let wsApi_one = 'wss://ceshi-zhibo.lihaink.cn/chat_room' + module.exports = { // 请求域名 格式: https://您的域名 // #ifdef MP || APP-PLUS