|
@@ -3,7 +3,7 @@
|
|
|
<view class="list-wrap">
|
|
<view class="list-wrap">
|
|
|
<block v-if="$util.isEmpty(list.data) === false">
|
|
<block v-if="$util.isEmpty(list.data) === false">
|
|
|
<block v-for="(item, index) in list.data" :key="index">
|
|
<block v-for="(item, index) in list.data" :key="index">
|
|
|
- <tui-list-cell :arrow="true" @click="pageTo({ url: '/admin/chat/chatPage', query: {userId: item.userId, customId: item.id, staffId: getLoginInfo.shopAdminId, shopId: getLoginInfo.shopId, name: getLoginInfo.name, avatar: shopAvatar } })">
|
|
|
|
|
|
|
+ <tui-list-cell :arrow="true" @click="handleItemClick(item)">
|
|
|
<view class="user-card">
|
|
<view class="user-card">
|
|
|
<view class="user-avatar">
|
|
<view class="user-avatar">
|
|
|
<image :src="item.avatar || getDefaultImage()" class="avatar-img" mode="aspectFill" />
|
|
<image :src="item.avatar || getDefaultImage()" class="avatar-img" mode="aspectFill" />
|
|
@@ -90,6 +90,22 @@ export default {
|
|
|
this.shopAvatar = this.getLoginInfo.avatar != '' ? this.getLoginInfo.avatar : this.$constant.imgUrl + '/retail/default-img.png';
|
|
this.shopAvatar = this.getLoginInfo.avatar != '' ? this.getLoginInfo.avatar : this.$constant.imgUrl + '/retail/default-img.png';
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
|
|
|
+ handleItemClick(item) {
|
|
|
|
|
+ if (item.unReadNum > 0) {
|
|
|
|
|
+ item.unReadNum = 0;
|
|
|
|
|
+ }
|
|
|
|
|
+ this.pageTo({
|
|
|
|
|
+ url: '/admin/chat/chatPage',
|
|
|
|
|
+ query: {
|
|
|
|
|
+ userId: item.userId,
|
|
|
|
|
+ customId: item.id,
|
|
|
|
|
+ staffId: this.getLoginInfo.shopAdminId,
|
|
|
|
|
+ shopId: this.getLoginInfo.shopId,
|
|
|
|
|
+ name: this.getLoginInfo.name,
|
|
|
|
|
+ avatar: this.shopAvatar
|
|
|
|
|
+ }
|
|
|
|
|
+ });
|
|
|
|
|
+ },
|
|
|
init() {
|
|
init() {
|
|
|
this.getMyCustomList();
|
|
this.getMyCustomList();
|
|
|
},
|
|
},
|