|
|
@ -4,35 +4,38 @@ |
|
|
|
|
|
|
|
|
<view class="main_section"> |
|
|
<view class="main_section"> |
|
|
<view class="section_1"> |
|
|
<view class="section_1"> |
|
|
<view class="item" @click="openViewSysMsgList()"> |
|
|
|
|
|
<view class="left"> |
|
|
|
|
|
<image class="pic" src="@/static/images/common/xi_tong_xiao_xi.png"></image> |
|
|
|
|
|
<view>系统消息</view> |
|
|
|
|
|
</view> |
|
|
|
|
|
<view class="right"> |
|
|
|
|
|
<view>99</view> |
|
|
|
|
|
<fui-icon name="arrowright" :size="60"></fui-icon> |
|
|
|
|
|
</view> |
|
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
<view class="item" @click="openViewImChatInfo({user_id:1})"> |
|
|
<!-- <view class="item" @click="openViewSysMsgList()">--> |
|
|
<view class="left"> |
|
|
<!-- <view class="left">--> |
|
|
<image class="pic" src="@/static/images/common/yong_hu.png"></image> |
|
|
<!-- <image class="pic" src="@/static/images/common/xi_tong_xiao_xi.png"></image>--> |
|
|
<view>张老师</view> |
|
|
<!-- <view>系统消息</view>--> |
|
|
</view> |
|
|
<!-- </view>--> |
|
|
<view class="right"> |
|
|
<!-- <view class="right">--> |
|
|
<view>99</view> |
|
|
<!-- <view>99</view>--> |
|
|
<fui-icon name="arrowright" :size="60"></fui-icon> |
|
|
<!-- <fui-icon name="arrowright" :size="60"></fui-icon>--> |
|
|
</view> |
|
|
<!-- </view>--> |
|
|
</view> |
|
|
<!-- </view>--> |
|
|
|
|
|
|
|
|
<view class="item" @click="openViewImChatInfo({user_id:2})"> |
|
|
<view |
|
|
|
|
|
v-for="(v,k) in contactList" |
|
|
|
|
|
:key="k" |
|
|
|
|
|
class="item" |
|
|
|
|
|
@click="openViewImChatInfo(v)" |
|
|
|
|
|
> |
|
|
<view class="left"> |
|
|
<view class="left"> |
|
|
<image class="pic" src="@/static/images/common/yong_hu.png"></image> |
|
|
<image |
|
|
<view>李老师</view> |
|
|
v-if="v.type==2" |
|
|
|
|
|
class="pic" |
|
|
|
|
|
:src="(v.header ? $util.img(v.header) : `@/static/images/common/yong_hu.png`)" |
|
|
|
|
|
model="aspectFit" |
|
|
|
|
|
></image> |
|
|
|
|
|
|
|
|
|
|
|
<image v-else class="pic" src="@/static/images/common/xi_tong_xiao_xi.png"></image> |
|
|
|
|
|
|
|
|
|
|
|
<view>{{v.name}}</view> |
|
|
</view> |
|
|
</view> |
|
|
<view class="right"> |
|
|
<view class="right"> |
|
|
<view>99</view> |
|
|
<view>{{v.count >= 99 ? '99':v.count}}</view> |
|
|
<fui-icon name="arrowright" :size="60"></fui-icon> |
|
|
<fui-icon name="arrowright" :size="60"></fui-icon> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
@ -44,6 +47,7 @@ |
|
|
|
|
|
|
|
|
<script> |
|
|
<script> |
|
|
import memberApi from '@/api/member.js'; |
|
|
import memberApi from '@/api/member.js'; |
|
|
|
|
|
import commonApi from '@/api/common.js'; |
|
|
import AQUplodeImgMulti from '@/components/AQ/AQUplodeImgMulti'; |
|
|
import AQUplodeImgMulti from '@/components/AQ/AQUplodeImgMulti'; |
|
|
import AQTabber from "@/components/AQ/AQTabber" |
|
|
import AQTabber from "@/components/AQ/AQTabber" |
|
|
|
|
|
|
|
|
@ -61,11 +65,36 @@ export default { |
|
|
content: '', |
|
|
content: '', |
|
|
mailbox: '', |
|
|
mailbox: '', |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
//联系人列表 |
|
|
|
|
|
contactList:[], |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
onLoad() { |
|
|
onLoad() { |
|
|
}, |
|
|
}, |
|
|
|
|
|
onShow() { |
|
|
|
|
|
this.init(); |
|
|
|
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
//初始化 |
|
|
|
|
|
async init(){ |
|
|
|
|
|
this.getContactList() |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
//获取联系人列表 |
|
|
|
|
|
async getContactList(){ |
|
|
|
|
|
let res = await commonApi.getContactList() |
|
|
|
|
|
console.log('获取联系人列表', res) |
|
|
|
|
|
if (res.code != 1) { |
|
|
|
|
|
uni.showToast({ |
|
|
|
|
|
title: res.msg, |
|
|
|
|
|
icon: 'none' |
|
|
|
|
|
}) |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
this.contactList = res.data |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
//######AQ上传文件组件相关###### |
|
|
//######AQ上传文件组件相关###### |
|
|
// 上传文件回调 |
|
|
// 上传文件回调 |
|
|
AQUploadSuccess(res) { |
|
|
AQUploadSuccess(res) { |
|
|
@ -118,10 +147,19 @@ export default { |
|
|
|
|
|
|
|
|
//跳转页面-聊天页面 |
|
|
//跳转页面-聊天页面 |
|
|
openViewImChatInfo(v){ |
|
|
openViewImChatInfo(v){ |
|
|
let user_id = 1 |
|
|
|
|
|
|
|
|
if(v.type == 1){ |
|
|
|
|
|
//系统消息 |
|
|
|
|
|
this.openViewSysMsgList |
|
|
|
|
|
}else{ |
|
|
|
|
|
//站内信 |
|
|
|
|
|
let hair_staff_id = v.hair_staff_id//发信人id |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: `/pages/common/im_chat_info?user_id=${user_id}` |
|
|
url: `/pages/common/im_chat_info?hair_staff_id=${hair_staff_id}` |
|
|
}) |
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
@ -186,6 +224,7 @@ export default { |
|
|
.pic{ |
|
|
.pic{ |
|
|
width: 68rpx; |
|
|
width: 68rpx; |
|
|
height: 68rpx; |
|
|
height: 68rpx; |
|
|
|
|
|
border-radius: 50%; |
|
|
} |
|
|
} |
|
|
view{ |
|
|
view{ |
|
|
color: #D9001B; |
|
|
color: #D9001B; |
|
|
@ -196,6 +235,11 @@ export default { |
|
|
display: flex; |
|
|
display: flex; |
|
|
align-items: center; |
|
|
align-items: center; |
|
|
view{ |
|
|
view{ |
|
|
|
|
|
display: flex; |
|
|
|
|
|
justify-content: center; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
width: 50rpx; |
|
|
|
|
|
height: 50rpx; |
|
|
padding: 5rpx; |
|
|
padding: 5rpx; |
|
|
border: 1px solid #BBBBBB; |
|
|
border: 1px solid #BBBBBB; |
|
|
border-radius: 50%; |
|
|
border-radius: 50%; |
|
|
|