This commit is contained in:
cansnow
2025-12-11 22:33:31 +08:00
parent 375917f06c
commit 5a086fa1fa
44 changed files with 1978 additions and 359 deletions
@@ -10,10 +10,10 @@
<uni-icons class="selectedIcon" size="30" color="#07c160" type="checkbox-filled" v-if="selectClientMsgIDItems.indexOf(item.clientMsgID)>-1"></uni-icons>
<uni-icons class="selectedIcon" size="30" color="#ccc" type="circle" v-else></uni-icons>
</template>
<message-item-render
@messageItemRender="messageItemRender"
<MessageItemRender
@userEvent="onUserMessageEvent"
:source="item"
:conversationID="storeCurrentConversation.conversationID"
:isSender="item.sendID === storeCurrentUserID"
/>
<!-- :isActive="selectClientMsgIDItems.indexOf(item.clientMsgID)>-1" -->
@@ -88,18 +88,6 @@
},
methods: {
...mapActions("message", ["getHistoryMesageList"]),
messageItemRender(clientMsgID) {
if (
this.initFlag &&
clientMsgID ===
this.storeHistoryMessageList[this.storeHistoryMessageList.length - 1]
.clientMsgID
) {
this.initFlag = false;
setTimeout(() => this.scrollToBottom(true), 200);
this.checkInitHeight();
}
},
async loadMessageList(isLoadMore = false) {
this.messageLoadState.loading = true;
const lastMsgID = this.storeHistoryMessageList[0]?.clientMsgID;
@@ -192,6 +180,16 @@
});
},
onUserMessageEvent(e,data){
if(e.type == 'messageItemRender'){
if (
this.initFlag && data === this.storeHistoryMessageList[this.storeHistoryMessageList.length - 1].clientMsgID
) {
this.initFlag = false;
setTimeout(() => this.scrollToBottom(true), 200);
this.checkInitHeight();
}
return ;
}
this.$emit('userEvent',e,data)
},
empty(){}