From fa83bc4c1d2522265956237a7d66f8abbf6ab399 Mon Sep 17 00:00:00 2001 From: zsw Date: Thu, 26 Sep 2024 18:26:31 +0800 Subject: [PATCH] message page --- lib/im/SocketClient.dart | 2 +- lib/im/database/message.dart | 2 +- lib/retrofit/min_api.dart | 3 +-- lib/retrofit/retrofit_api.dart | 4 ++-- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/lib/im/SocketClient.dart b/lib/im/SocketClient.dart index 0396afcd..757e808e 100644 --- a/lib/im/SocketClient.dart +++ b/lib/im/SocketClient.dart @@ -16,7 +16,7 @@ import 'package:shared_preferences/shared_preferences.dart'; class SocketClient { //47.93.216.24:9090 线上 192.168.10.129:9090 测试 - final String ip = !kDebugMode ? '192.168.10.129' : '47.93.216.24'; + final String ip = kDebugMode ? '192.168.10.129' : '47.93.216.24'; final num port = 9090; Socket _socket; SharedPreferences _shared; diff --git a/lib/im/database/message.dart b/lib/im/database/message.dart index d25d8b64..0ff06e5f 100644 --- a/lib/im/database/message.dart +++ b/lib/im/database/message.dart @@ -79,7 +79,7 @@ createSendMessage(var toId, String content, {String attach, int msgType, userId, }; } -createMessage(var toId, Uint8List dataBytes, {String attach, int msgType, userId, replyId}) ccc{ +createMessage(var toId, Uint8List dataBytes, {String attach, int msgType, userId, replyId}) { String content = ""; MsgType type = MsgType.values[msgType]; if (type == MsgType.TEXT) { diff --git a/lib/retrofit/min_api.dart b/lib/retrofit/min_api.dart index f34e728b..d454a7eb 100644 --- a/lib/retrofit/min_api.dart +++ b/lib/retrofit/min_api.dart @@ -27,9 +27,8 @@ import 'data/shopping_home_config.dart'; part 'min_api.g.dart'; -// const localBaseUrl = "http://192.168.10.54:8765/app/";///本地 +const localBaseUrl = "http://192.168.10.54:8765/app/";///本地 // const localBaseUrl = "http://pos-test.api.lotus-wallet.com/app/";///测试 -const localBaseUrl = "https://pos.api.lotus-wallet.com/app/";///线上 const serviceBaseUrl = "https://pos.api.lotus-wallet.com/app/";///线上 diff --git a/lib/retrofit/retrofit_api.dart b/lib/retrofit/retrofit_api.dart index e569623f..a7a07276 100644 --- a/lib/retrofit/retrofit_api.dart +++ b/lib/retrofit/retrofit_api.dart @@ -70,13 +70,13 @@ import 'data/wx_pay.dart'; part 'retrofit_api.g.dart'; -// const localBaseUrl = "http://192.168.10.54:8766/app/";///本地 +const localBaseUrl = "http://192.168.10.54:8766/app/";///本地 // const localBaseUrl = "http://platform.test.api.lotus-wallet.com/app/";///测试 -const localBaseUrl = "https://pos.platform.lotus-wallet.com/app/";///线上 const serviceBaseUrl = "https://pos.platform.lotus-wallet.com/app/";///线上 const ipBaseUrl = "http://whois.pconline.com.cn"; +///ip @RestApi(baseUrl: localBaseUrl) abstract class ApiService {