mirror of
https://github.com/WuKongIM/WuKongIMFlutterSDK
synced 2025-05-29 23:22:52 +00:00
fix:update send noPersist message
This commit is contained in:
parent
913c75a4dd
commit
e726086953
@ -97,4 +97,6 @@
|
||||
### 1.4.8
|
||||
* fix: Upgrade send message api
|
||||
### 1.4.9
|
||||
* fix: Upgrade save channel member extra data api
|
||||
* fix: Upgrade save channel member extra data api
|
||||
### 1.4.9
|
||||
* fix: Upgrade send noPersist message
|
@ -572,9 +572,7 @@ class WKMessageManager {
|
||||
wkMsg.channelType = channel.channelType;
|
||||
wkMsg.fromUID = WKIM.shared.options.uid!;
|
||||
wkMsg.contentType = messageContent.contentType;
|
||||
int tempOrderSeq = await MessageDB.shared
|
||||
.queryMaxOrderSeq(wkMsg.channelID, wkMsg.channelType);
|
||||
wkMsg.orderSeq = tempOrderSeq + 1;
|
||||
|
||||
wkMsg.content = _getSendPayload(wkMsg);
|
||||
wkMsg.setChannelInfo(channel);
|
||||
WKChannel? from = await WKIM.shared.channelManager
|
||||
@ -582,18 +580,24 @@ class WKMessageManager {
|
||||
if (from != null) {
|
||||
wkMsg.setFrom(from);
|
||||
}
|
||||
int row = await saveMsg(wkMsg);
|
||||
wkMsg.clientSeq = row;
|
||||
WKIM.shared.messageManager.setOnMsgInserted(wkMsg);
|
||||
if (row > 0) {
|
||||
WKUIConversationMsg? uiMsg =
|
||||
await WKIM.shared.conversationManager.saveWithLiMMsg(wkMsg, 0);
|
||||
if (uiMsg != null) {
|
||||
List<WKUIConversationMsg> uiMsgs = [];
|
||||
uiMsgs.add(uiMsg);
|
||||
WKIM.shared.conversationManager.setRefreshUIMsgs(uiMsgs);
|
||||
if (!options.header.noPersist) {
|
||||
int tempOrderSeq = await MessageDB.shared
|
||||
.queryMaxOrderSeq(wkMsg.channelID, wkMsg.channelType);
|
||||
wkMsg.orderSeq = tempOrderSeq + 1;
|
||||
int row = await saveMsg(wkMsg);
|
||||
wkMsg.clientSeq = row;
|
||||
if (row > 0) {
|
||||
WKUIConversationMsg? uiMsg =
|
||||
await WKIM.shared.conversationManager.saveWithLiMMsg(wkMsg, 0);
|
||||
WKIM.shared.messageManager.setOnMsgInserted(wkMsg);
|
||||
if (uiMsg != null) {
|
||||
List<WKUIConversationMsg> uiMsgs = [];
|
||||
uiMsgs.add(uiMsg);
|
||||
WKIM.shared.conversationManager.setRefreshUIMsgs(uiMsgs);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (wkMsg.messageContent is WKMediaMessageContent) {
|
||||
// 附件消息
|
||||
if (_uploadAttachmentBack != null) {
|
||||
|
@ -15,7 +15,7 @@ description: wukong IM flutter sdk
|
||||
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
||||
# In Windows, build-name is used as the major, minor, and patch parts
|
||||
# of the product and file versions while build-number is used as the build suffix.
|
||||
version: 1.4.9
|
||||
version: 1.5.0
|
||||
homepage: https://github.com/WuKongIM/WuKongIMFlutterSDK
|
||||
|
||||
environment:
|
||||
|
Loading…
x
Reference in New Issue
Block a user