|
|
|
@ -1,94 +1,96 @@
|
|
|
|
<template>
|
|
|
|
<template>
|
|
|
|
<view class="g_pb_24">
|
|
|
|
<view class="g_pb_24">
|
|
|
|
<div v-for="(item, index) in machineList" :key="index" class="customitem g_bg_f">
|
|
|
|
<div style="width: calc(100vw - 20px);margin: 10px auto;border-radius: 8px;overflow: hidden;">
|
|
|
|
<Tooltip ref="tooltipRef" color="white" :isSelf="true" :top="150">
|
|
|
|
<div v-for="(item, index) in machineList" :key="index" class="customitem g_bg_f">
|
|
|
|
<div class="g_flex_row_start" hover-class="thover" style="padding: 12px 16px" @click="goChatPage(item)" :style="{ backgroundColor: item.stickTop ? '#f5f5f5' : '#fff' }">
|
|
|
|
<Tooltip ref="tooltipRef" color="white" :isSelf="true" :top="150">
|
|
|
|
<div
|
|
|
|
<div class="g_flex_row_start" hover-class="thover" style="padding: 12px 16px" @click="goChatPage(item)" :style="{ backgroundColor: item.stickTop ? '#f5f5f5' : '#fff' }">
|
|
|
|
class="g_flex_none"
|
|
|
|
<div
|
|
|
|
style="border-radius: 50%; width: 48px; height: 48px; background-size: cover; background-repeat: no-repeat; position: relative"
|
|
|
|
class="g_flex_none"
|
|
|
|
:style="{
|
|
|
|
style="border-radius: 50%; width: 48px; height: 48px; background-size: cover; background-repeat: no-repeat; position: relative"
|
|
|
|
'background-image': item.userinfo && item.userinfo[0].avatar ? 'url(' + item.userinfo[0].avatar + ')' : 'none',
|
|
|
|
:style="{
|
|
|
|
}"
|
|
|
|
'background-image': item.userinfo && item.userinfo[0].avatar ? 'url(' + item.userinfo[0].avatar + ')' : 'none',
|
|
|
|
>
|
|
|
|
}"
|
|
|
|
<div v-if="item.waitcount" style="position: absolute; right: -6px; top: -6px; background-color: #f5222d; width: 20px; height: 20px; border-radius: 50%; text-align: center; line-height: 20px; font-size: 12px; color: #fff">
|
|
|
|
>
|
|
|
|
{{ item.waitcount > 99 ? "99+" : item.waitcount }}
|
|
|
|
<div v-if="item.waitcount" style="position: absolute; right: -6px; top: -6px; background-color: #f5222d; width: 20px; height: 20px; border-radius: 50%; text-align: center; line-height: 20px; font-size: 12px; color: #fff">
|
|
|
|
</div>
|
|
|
|
{{ item.waitcount > 99 ? "99+" : item.waitcount }}
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="bottom-line g_flex_column_center g_flex_1" style="padding-left: 10px">
|
|
|
|
|
|
|
|
<div class="g_fs_17 g_flex_row_between" v-if="item.userinfo && item.userinfo[0].name">
|
|
|
|
|
|
|
|
<div class="g_ell_1 g_flex_1" style="color: #333">
|
|
|
|
|
|
|
|
{{ item.userinfo[0].name }} <span v-if="item.subtitle" style="color: orange">@{{ item.subtitle }}</span>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="g_flex_none g_fs_12 g_ml_10" style="color: #999">
|
|
|
|
|
|
|
|
{{ item.time }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- 普通文本 -->
|
|
|
|
<div class="bottom-line g_flex_column_center g_flex_1" style="padding-left: 10px">
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 0">
|
|
|
|
<div class="g_fs_17 g_flex_row_between" v-if="item.userinfo && item.userinfo[0].name">
|
|
|
|
{{ item.lastMessage.text }}
|
|
|
|
<div class="g_ell_1 g_flex_1" style="color: #333">
|
|
|
|
</div>
|
|
|
|
{{ item.userinfo[0].name }} <span v-if="item.subtitle" style="color: orange">@{{ item.subtitle }}</span>
|
|
|
|
<!-- tip通知 -->
|
|
|
|
</div>
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 10">
|
|
|
|
<div class="g_flex_none g_fs_12 g_ml_10" style="color: #999">
|
|
|
|
{{ item.lastMessage.text }}
|
|
|
|
{{ item.time }}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- 图片消息 -->
|
|
|
|
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 1 && item.lastMessage.attachment && item.lastMessage.attachment.raw">[图片]</div>
|
|
|
|
|
|
|
|
<!-- 图片消息 -->
|
|
|
|
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 3 && item.lastMessage.attachment && item.lastMessage.attachment.raw">[视频]</div>
|
|
|
|
|
|
|
|
<!-- 自定义消息 -->
|
|
|
|
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 100 && item.lastMessage.attachment && item.lastMessage.attachment.raw">
|
|
|
|
|
|
|
|
<!-- 100001 商家后台 职位卡片 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 100001">
|
|
|
|
|
|
|
|
{{ JSON.parse(item.lastMessage.attachment.raw).obj.jobName }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- 1000011 职位列表 -->
|
|
|
|
<!-- 普通文本 -->
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 100011">[职位列表]</div>
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 0">
|
|
|
|
<!-- 200001 系统提醒 -->
|
|
|
|
{{ item.lastMessage.text }}
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 200001">
|
|
|
|
|
|
|
|
用户[
|
|
|
|
|
|
|
|
<span class="viewdetails">
|
|
|
|
|
|
|
|
{{ item.lastMessage && item.lastMessage.attachment && item.lastMessage.attachment.raw && JSON.parse(item.lastMessage.attachment.raw).userName }}
|
|
|
|
|
|
|
|
</span>
|
|
|
|
|
|
|
|
],询单需要人工介入,请尽快回复
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 200002 系统通知 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 200002">
|
|
|
|
|
|
|
|
<span class="">
|
|
|
|
|
|
|
|
{{ item.lastMessage && item.lastMessage.text }}
|
|
|
|
|
|
|
|
</span>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 未知 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).name">
|
|
|
|
|
|
|
|
{{ JSON.parse(item.lastMessage.attachment.raw).name }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 未知 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 100002">
|
|
|
|
|
|
|
|
{{ "工单" }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- 常用回复 -->
|
|
|
|
<!-- tip通知 -->
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).typs == 'msg'">
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 10">
|
|
|
|
{{ item.lastMessage.text }}
|
|
|
|
{{ item.lastMessage.text }}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- 100000 移动端职位卡片 -->
|
|
|
|
<!-- 图片消息 -->
|
|
|
|
<div v-else>
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 1 && item.lastMessage.attachment && item.lastMessage.attachment.raw">[图片]</div>
|
|
|
|
{{ JSON.parse(item.lastMessage.attachment.raw).title }}
|
|
|
|
<!-- 图片消息 -->
|
|
|
|
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 3 && item.lastMessage.attachment && item.lastMessage.attachment.raw">[视频]</div>
|
|
|
|
|
|
|
|
<!-- 自定义消息 -->
|
|
|
|
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="item.lastMessage && item.lastMessage.messageType == 100 && item.lastMessage.attachment && item.lastMessage.attachment.raw">
|
|
|
|
|
|
|
|
<!-- 100001 商家后台 职位卡片 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 100001">
|
|
|
|
|
|
|
|
{{ JSON.parse(item.lastMessage.attachment.raw).obj.jobName }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 1000011 职位列表 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 100011">[职位列表]</div>
|
|
|
|
|
|
|
|
<!-- 200001 系统提醒 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 200001">
|
|
|
|
|
|
|
|
用户[
|
|
|
|
|
|
|
|
<span class="viewdetails">
|
|
|
|
|
|
|
|
{{ item.lastMessage && item.lastMessage.attachment && item.lastMessage.attachment.raw && JSON.parse(item.lastMessage.attachment.raw).userName }}
|
|
|
|
|
|
|
|
</span>
|
|
|
|
|
|
|
|
],询单需要人工介入,请尽快回复
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 200002 系统通知 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 200002">
|
|
|
|
|
|
|
|
<span class="">
|
|
|
|
|
|
|
|
{{ item.lastMessage && item.lastMessage.text }}
|
|
|
|
|
|
|
|
</span>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 未知 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).name">
|
|
|
|
|
|
|
|
{{ JSON.parse(item.lastMessage.attachment.raw).name }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 未知 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).type == 100002">
|
|
|
|
|
|
|
|
{{ "工单" }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 常用回复 -->
|
|
|
|
|
|
|
|
<div v-if="JSON.parse(item.lastMessage.attachment.raw).typs == 'msg'">
|
|
|
|
|
|
|
|
{{ item.lastMessage.text }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 100000 移动端职位卡片 -->
|
|
|
|
|
|
|
|
<div v-else>
|
|
|
|
|
|
|
|
{{ JSON.parse(item.lastMessage.attachment.raw).title }}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 暂无新消息 -->
|
|
|
|
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="!item.lastMessage">暂无新消息</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- 暂无新消息 -->
|
|
|
|
|
|
|
|
<div class="g_fs_14 g_ell_1" style="color: #999; font-size: 12px" v-if="!item.lastMessage">暂无新消息</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<template #content>
|
|
|
|
<template #content>
|
|
|
|
<view class="g_fs_16" style="">
|
|
|
|
<view class="g_fs_16" style="">
|
|
|
|
<view class="g_flex_column_center g_h_32" @click="topMessage(item, index)">
|
|
|
|
<view class="g_flex_column_center g_h_32" @click="topMessage(item, index)">
|
|
|
|
<view>{{ item.stickTop ? "取消置顶" : "置顶消息" }} </view>
|
|
|
|
<view>{{ item.stickTop ? "取消置顶" : "置顶消息" }} </view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="g_flex_column_center g_h_32" @click="deleteMessage(item, index)">
|
|
|
|
<view class="g_flex_column_center g_h_32" @click="deleteMessage(item, index)">
|
|
|
|
<view>不显示</view>
|
|
|
|
<view>不显示</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</Tooltip>
|
|
|
|
</Tooltip>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="" v-if="machineList && machineList.length == 0">
|
|
|
|
<view class="" v-if="machineList && machineList.length == 0">
|
|
|
|
|