21
This commit is contained in:
+2
-2
@@ -2,8 +2,8 @@
|
||||
"name" : "瞬聊",
|
||||
"appid" : "__UNI__E41111F",
|
||||
"description" : "一款即时聊天软件",
|
||||
"versionName" : "3.3.6",
|
||||
"versionCode" : 336,
|
||||
"versionName" : "3.3.7",
|
||||
"versionCode" : 337,
|
||||
"transformPx" : false,
|
||||
"app-plus" : {
|
||||
"bounce" : "none",
|
||||
|
||||
+1
-5
@@ -35,11 +35,7 @@
|
||||
"path": "pages/conversation/conversationList/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "",
|
||||
"enablePullDownRefresh": false,
|
||||
"disableScroll": true,
|
||||
"app-plus": {
|
||||
"bounce": "none"
|
||||
}
|
||||
"enablePullDownRefresh": true
|
||||
}
|
||||
},
|
||||
{
|
||||
|
||||
@@ -185,7 +185,7 @@
|
||||
this.onUserMessageEvent({type: 'cancelSelect'});
|
||||
},
|
||||
async doForwarMsg(userList, groupList, msgiem)
|
||||
{b
|
||||
{
|
||||
//console.log(userList,groupList);
|
||||
const _this = this;
|
||||
for (var i = 0; i < userList.length; i++) {
|
||||
@@ -219,7 +219,7 @@
|
||||
uni.$u.toast(errMsg);
|
||||
});
|
||||
},
|
||||
onUserMessageEvent(e, data) {
|
||||
async onUserMessageEvent(e, data) {
|
||||
const _this = this;
|
||||
if (e.type == 'select') {
|
||||
this.selectFlag = true;
|
||||
@@ -248,8 +248,9 @@
|
||||
if (e.type == 'deleteMsg' || e.type == 'deleteServerMsg') {
|
||||
let method = IMSDK.IMMethods.DeleteMessageFromLocalStorage;
|
||||
if(e.type == 'deleteServerMsg'){
|
||||
method = IMSDK.IMMethods.DeleteMessage
|
||||
method = IMSDK.IMMethods.RevokeMessage
|
||||
}
|
||||
console.log(method);
|
||||
let deleteMsgs = [];
|
||||
if (!data) {
|
||||
deleteMsgs = [...this.selectItems];
|
||||
@@ -258,10 +259,11 @@
|
||||
}
|
||||
for (let i = 0; i < deleteMsgs.length; i++) {
|
||||
let element = deleteMsgs[i];
|
||||
IMSDK.asyncApi(method, IMSDK.uuid(), {
|
||||
let a = await IMSDK.asyncApi(method, IMSDK.uuid(), {
|
||||
conversationID: _this.storeCurrentConversation.conversationID,
|
||||
clientMsgID: element.clientMsgID
|
||||
});
|
||||
console.log(a);
|
||||
}
|
||||
this.selectItems = [];
|
||||
this.$refs.chatingListRef.loadMessageList();
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<view class="left_info">
|
||||
<view class="avatar">
|
||||
<my-avatar :isGroup="isGroup" :isNotify="isNotify" :src="source.faceURL" :desc="source.showName" size="46" />
|
||||
<u-badge max="99" :value="source.unreadCount"></u-badge>
|
||||
<u-badge v-if="source.unreadCount>0" max="99" :value="source.unreadCount"></u-badge>
|
||||
</view>
|
||||
<view class="details">
|
||||
<view class="title">
|
||||
|
||||
@@ -1,17 +1,6 @@
|
||||
<template>
|
||||
<view class="conversation_container">
|
||||
<chat-header ref="chatHeaderRef" />
|
||||
<scroll-view class="scroll-view"
|
||||
scroll-y="true"
|
||||
refresher-enabled="true"
|
||||
:refresher-triggered="refreshing"
|
||||
:scroll-top="scrollTop"
|
||||
:scroll-with-animation="true"
|
||||
@scroll="scroll"
|
||||
@refresherrefresh="onRefresh"
|
||||
@refresherrestore="onRestore"
|
||||
@refresherabort="onRestore"
|
||||
@scrolltolower="scrolltolower">
|
||||
<uni-swipe-action ref="swipe_action">
|
||||
<uni-swipe-action-item
|
||||
:right-options="swipe_actions"
|
||||
@@ -21,7 +10,6 @@
|
||||
<conversation-item @longtapEvent="showExtendMenu(item)" :source="item"/>
|
||||
</uni-swipe-action-item>
|
||||
</uni-swipe-action>
|
||||
</scroll-view>
|
||||
<view class="loading_wrap" v-if="storeProgress > 0 && storeProgress < 100">
|
||||
<u-loading-icon :vertical="true" :text="storeProgress + '%'"></u-loading-icon>
|
||||
</view>
|
||||
@@ -174,32 +162,33 @@
|
||||
})
|
||||
},
|
||||
|
||||
scroll(e) {
|
||||
this.old.scrollTop = e.detail.scrollTop;
|
||||
},
|
||||
onRefresh() {
|
||||
if (this.refreshing) return;
|
||||
console.log('onRefresh');
|
||||
this.refreshing = true;
|
||||
this.queryList(true);
|
||||
},
|
||||
onRestore() {
|
||||
this.refreshing = false;
|
||||
console.log("onRestore");
|
||||
},
|
||||
scrolltolower() {
|
||||
this.queryList();
|
||||
},
|
||||
async queryList(isFirstPage = false) {
|
||||
console.log(1);
|
||||
await this.$store.dispatch("conversation/getConversationList",isFirstPage);
|
||||
console.log(2);
|
||||
uni.stopPullDownRefresh();
|
||||
this.refreshing = false;
|
||||
},
|
||||
closeAllSwipe() {
|
||||
this.$refs.swipeWrapperRef.closeAll();
|
||||
},
|
||||
},
|
||||
onReachBottom() {
|
||||
this.scrolltolower();
|
||||
},
|
||||
onPullDownRefresh() {
|
||||
this.queryList(true);
|
||||
},
|
||||
onPageScroll(res) {
|
||||
this.old.scrollTop = res.scrollTop;
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
@@ -225,11 +214,6 @@
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.scroll-view {
|
||||
height: 0;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.loading_wrap {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
|
||||
@@ -56,6 +56,7 @@ const actions = {
|
||||
count: 500,
|
||||
},
|
||||
);
|
||||
console.log(data);
|
||||
commit("SET_CONVERSATION_LIST", [
|
||||
...(isFirstPage ? [] : state.conversationList),
|
||||
...data,
|
||||
|
||||
Reference in New Issue
Block a user