会话存档

This commit is contained in:
liuye
2023-08-22 10:23:36 +08:00
parent cdc304deed
commit 285b8b1cf5
66 changed files with 2510 additions and 283 deletions

View File

@@ -1,211 +0,0 @@
<template>
<div class="PercentageDetail">
<div class="header">
<div class="left">
<h2>小区管理</h2>
<p>共21条已办结18条</p>
</div>
<div class="right">
<h4>86%</h4>
<p>办结率</p>
</div>
</div>
<div class="info-content">
<div class="title">分类统计</div>
<div class="percentage">
<div class="item">
<div class="mini-title">小区管理</div>
<div class="info">
<div class="line-bg"><div class="active-bg"></div></div>共11条 | 已办结9
</div>
</div>
<div class="item">
<div class="mini-title">小区管理</div>
<div class="info">
<div class="line-bg" style="width:44%;"><div class="active-bg"></div></div>共11条 | 已办结9
</div>
</div>
<div class="item">
<div class="mini-title">小区管理</div>
<div class="info">
<div class="line-bg" style="width:30%;"><div class="active-bg"></div></div>共11条 | 已办结9
</div>
</div>
</div>
</div>
</div>
</template>
<script>
export default {
props: {},
data() {
return {
contents: [
{
label: '待受理',
num: 5
},
{
label: '办理中',
num: 5
},
{
label: '今日上报',
num: 5
},
{
label: '今日办结',
num: 5
}
]
}
},
onLoad() {
},
onShow() {},
methods: {
getList() {
this.$http
.post('/app/appvisitvondolence/list', null, {
params: {
size: this.size,
current: this.current,
createUserId: this.currentTabs == 1 ? this.user.id : '',
},
})
.then((res) => {
if (res.code == 0) {
this.datas = this.current > 1 ? [...this.datas, ...res.data.records] : res.data.records
this.pages = res.data.pages
}
})
},
goDetail(item) {
uni.navigateTo({ url: `./Detail?id=${item.id}` })
},
change(index) {
this.currentTabs = index
this.getList()
},
},
onReachBottom() {
this.current = this.current + 1
this.getList()
},
}
</script>
<style scoped lang="scss">
.PercentageDetail {
background-color: #F3F7F8;
padding: 32px 30px 0;
.header{
width: 100%;
background: #FFF;
border-radius: 16px;
margin-bottom: 30px;
display: flex;
padding: 32px 32px 38px 24px;
box-sizing: border-box;
.left{
width: calc(100% - 112px);
h2{
font-size: 42px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #333;
line-height: 48px;
margin-bottom: 16px;
}
p{
font-size: 30px;
font-family: PingFangSC-Regular, PingFang SC;
color: #999;
line-height: 42px;
}
}
.right{
width: 112px;
background: #E6FFF1;
border-radius: 8px;
text-align: center;
color: #42D784;
h4{
font-size: 36px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
line-height: 42px;
padding: 8px 0 4px 0;
}
p{
font-size: 24px;
font-family: PingFangSC-Regular, PingFang SC;
line-height: 34px;
}
}
}
.info-content{
width: 100%;
background: #FFF;
border-radius: 16px;
margin-bottom: 24px;
.title{
font-size: 32px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #333;
line-height: 48px;
padding: 24px 16px 24px 24px;
img{
float: right;
width: 40px;
height: 40px;
}
}
.percentage{
padding: 16px 0 0 26px;
.item{
width: 100%;
padding-bottom: 32px;
.mini-title{
font-size: 30px;
font-family: PingFangSC-Regular, PingFang SC;
color: #333;
line-height: 48px;
margin-bottom: 14px;
}
.info{
width: 100%;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
color: #999;
line-height: 48px;
.line-bg{
display: inline-block;
width: 56%;
height: 14px;
background: #D7D8D9;
border-radius: 8px;
margin-right: 12px;
.active-bg{
width: 80%;
height: 100%;
background: #257FF1;
border-radius: 8px;
}
}
img{
width: 32px;
height: 32px;
vertical-align: middle;
}
}
}
}
}
}
</style>

View File

@@ -1,60 +0,0 @@
<template>
<div class="UserList">
<div class="item">
<img src="./components/img/user-img.png" alt="">
<div class="info">
<h2>李毅</h2>
<p>共受理23条 | 已办结17条</p>
</div>
</div>
</div>
</template>
<script>
export default {
name: 'UserList',
data() {
return {
}
},
methods: {
},
}
</script>
<style scoped lang="scss">
.UserList {
height: 100%;
.item{
padding: 24px 0 0 32px;
background-color: #fff;
img{
width: 80px;
height: 80px;
margin-right: 32px;
}
.info{
display: inline-block;
width: calc(100% - 112px);
padding-bottom: 24px;
border-bottom: 1px solid #E4E5E6;
h2{
font-size: 32px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #333;
line-height: 44px;
margin-bottom: 6px;
}
p{
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
color: #666;
line-height: 40px;
}
}
}
}
</style>

View File

@@ -0,0 +1,309 @@
<template>
<section class="AppConversation">
<AiTopFixed>
<u-search v-model="keyword" :clearabled="true" placeholder="搜索" :show-action="false" bg-color="#F5F5F5"
search-icon-color="#999" color="#999" height="58" @search="getUserListInit" @clear="getDeptListInit">
</u-search>
<div class="hint">
<span v-for="(item, index) in selectDeptPath" :key="index">
<span v-if="index>0" class="mar-h4">/</span>
<span class="color-3F8DF5" @click="deptNameClick(item, index)">{{ item.name }}</span>
</span>
</div>
</AiTopFixed>
<div class="header-middle">
<div class="cards" v-for="item in treeList" :key="item.id" @click="itemClick(item)">
<div class="imges">
<img src="./img/dept-img.png" alt="" class="avatras"/>
</div>
<div class="rightes">
<div class="applicationNames">{{ item.name }}</div>
</div>
</div>
<div v-if="userList.length">
<div class="userCards" v-for="e in userList" :key="e.id" @click="toList(e)">
<div class="imges">
<img :src="e.avatar" alt="" class="avatras" v-if="e.avatar">
<img src="./img/user-img.png" alt="" class="avatras" v-else/>
</div>
<div class="rights fill">
<div class="applicationNames" v-html="brightenKeyword(e.name, keyword)"></div>
<div class="idNumbers">{{ e.mobile }}</div>
</div>
</div>
</div>
<AiEmpty description="暂无数据" v-if="!hasData"/>
</div>
</section>
</template>
<script>
export default {
name: "AppConversation",
appName: "会话存档",
data() {
return {
selected: [],
allData: null,
treeList: [],
selectDeptPath: [],
userList: [],
keyword: ''
}
},
computed: {
hasData() {
return this.treeList?.length > 0 || this.userList?.length > 0
}
},
onLoad() {
this.getAllDepts()
},
methods: {
isSelected(id, corpId) {
return !!this.selected.find(e => e.id == id && e.corpId == corpId)
},
getAllDepts() {
this.$http.post('/app/wxcp/wxdepartment/listAllByCorp').then((res) => {
if (res?.data) {
let parents = res.data.map(e => e.parentid)
this.allData = res.data.map(e => ({...e, hasChildren: parents.includes(e.id), isChecked: this.isSelected(e.id, e.corpId)}))
this.deptInit()
}
})
},
deptInit() {
this.treeList = this.allData.filter(e => !e.parentid)
this.selectDeptPath = [{name: "可选范围", id: ''}]
},
itemClick({id, name, corpId}) {
let index = this.selectDeptPath.findIndex(e => e.id == id && e.corpId == corpId)
if (index == -1) {
this.selectDeptPath.push({name, id, corpId})
this.getDeptsAndUsersByParent(id, corpId)
}
},
getDeptsAndUsersByParent(departmentId, corpId) {
this.treeList = this.allData.filter(e => e.parentid == departmentId && e.corpId == corpId)
this.userList = []
this.$http.post(`/app/wxcp/wxuser/listByDeptId`, null, {
params: {departmentId, status: 1, cid: corpId, name: this.keyword}
}).then(res => {
if (res?.data) {
if(this.keyword) {
res.data.map((item) => {
var nameList = item.name.split(this.keyword)
console.log(nameList)
})
}
this.userList = res.data
}
})
},
getRedWords(contentText, keyword) {
let keywordArray = keyword.split('');
let wordsArray = [];
for(let key of keywordArray){
if(contentText.includes(key)){
wordsArray.push(key)
}
}
return wordsArray;
},
brightenKeyword(contentText, keyword) {
let wordsArray = this.getRedWords(contentText, keyword);
let res = contentText;//res的初始值是不带任何红色格式的
//遍历相同字数组,
for(let word of wordsArray){
const Reg = new RegExp(word, 'i');
//替换每一个相同字
res = res.replace(Reg, `<span style="color: #1365DD;">${word}</span>`);
}
return res;
},
getUserListInit() {
var e = this.selectDeptPath[this.selectDeptPath.length - 1]
if(!e.id) { //第一级 根节点
return this.$u.toast('请选择部门后再搜索人员')
}
this.getDeptsAndUsersByParent(e.id, e.corpId)
},
getDeptListInit() {
var e = this.selectDeptPath[this.selectDeptPath.length - 1]
if(!e.id) { //第一级
this.treeList = this.allData.filter(e => !e.parentid)
this.userList = []
}else {
this.getDeptsAndUsersByParent(e.id || '', e.corpId || '')
}
},
deptNameClick(row, index) {
this.userList = []
if (!index) { //第一级别
this.deptInit()
} else {
let length = this.selectDeptPath.length - index
this.selectDeptPath.splice(index + 1, length)
this.getDeptsAndUsersByParent(row.id, row.corpId)
}
},
itemCheck(row, kind) {
row.isChecked = !row.isChecked
if (row.isChecked) {
this.selected.push({...row, kind})
} else {
let index = this.selected.findIndex(e => e.id == row.id)
this.selected.splice(index, 1)
}
this.$forceUpdate()
},
toList(row) {
uni.navigateTo({url: `./list?id=${row.id}`})
}
}
}
</script>
<style lang="scss" scoped>
.AppConversation {
height: 100%;
background: #fff;
.header-top {
background: #fff;
padding: 20px 32px;
}
.header-middle {
// padding-bottom: 140px;
.hint {
padding: 28px 20px 28px 32px;
line-height: 56px;
box-shadow: 0 1px 0 0 #e4e5e6;
font-size: 30px;
font-weight: 500;
word-break: break-all;
}
.empty-div {
height: 16px;
background: #f5f5f5;
}
.imges {
display: flex;
align-items: center;
.avatras {
width: 74px;
height: 74px;
border-radius: 8px;
}
}
.cards {
display: flex;
align-items: center;
height: 120px;
line-height: 120px;
padding: 0 0 0 32px;
img {
width: 74px;
height: 74px;
border-radius: 8px;
}
.rightes {
width: calc(100% - 106px);
display: flex;
align-items: center;
margin-left: 32px;
border-bottom: 1px solid #e4e5e6;
.applicationNames {
flex: 1;
min-width: 0;
font-size: 36px;
font-weight: 500;
color: #333333;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.imgs {
flex-shrink: 0;
width: 40px;
height: 40px;
margin-right: 20px;
}
}
}
.userCards {
display: flex;
align-items: center;
height: 120px;
line-height: 120px;
padding: 0 0 0 32px;
.rights {
display: flex;
justify-content: space-between;
align-items: center;
margin-left: 32px;
border-bottom: 1px solid #e4e5e6;
padding-right: 40px;
height: inherit;
.applicationNames {
font-size: 36px;
font-weight: 500;
color: #333333;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.idNumbers {
color: #666;
}
}
}
}
.subBtn {
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 118px;
background: #f4f8fb;
div {
width: 192px;
height: 80px;
line-height: 80px;
text-align: center;
background: #1365dd;
border-radius: 4px;
font-size: 32px;
color: #fff;
margin: 20px 34px 0 0;
float: right;
}
}
.color-3F8DF5 {
color: #3F8DF5;
}
.mar-h4 {
margin: 0 4px;
}
}
</style>

View File

@@ -0,0 +1,632 @@
<template>
<div class="conversationDetail">
<AiTopFixed>
<u-tabs :list="tabList" :is-scroll="false" :current="currentTabs" height="96" bg-color="#ffffff"
inactive-color="#666666" :bar-style="barStyle" :active-item-style="activeStyle" active-color="#3975C6 " @change="change">
</u-tabs>
<div class="top-search">
<div class="left" @click="isShowDate=true">
<div class="color-999" v-if="!dateList.length">开始时间-结束时间</div>
<div v-else>{{dateList[0]}}{{dateList[1]}}</div>
<img src="./img/del-icon.png" alt="" v-if="dateList.length" @click.stop="clearDate()">
</div>
<div class="right">
<u-search v-model="keyword" :clearabled="true" placeholder="请输入关键词" :show-action="false" bg-color="#F5F5F5"
search-icon-color="#999" color="#999" height="58" @search="getListInit" @clear="getListInit">
</u-search>
</div>
</div>
</AiTopFixed>
<scroll-view :scroll-top="scrollTop" scroll-y="true" class="scroll-Y" @scroll="scroll" v-if="list.length" :style="{height: scrollHeight+'px'}">
<div class="conversation-list">
<div v-for="(item, index) in list" :key="index">
<div class="item" :class="item.userId == id ? 'item-right' : 'item-left'">
<!-- <img src="./img/fail-icon.png" alt="" class="fail-img" v-if="item.userId == user.wxUserId"> -->
<img :src="item.userAvatar" alt="" class="user-img" v-if="item.userId != id && item.userAvatar">
<img src="./img/user-img.png" alt="" class="user-img" v-if="item.userId != id && !item.userAvatar">
<p class="user-name">{{item.userName}}<span>{{item.msgSendTime}}</span></p>
<div class="content">
<span class="cir" v-if="item.msgType == 'text'"></span>
<p class="content-text" v-if="item.msgType == 'text'">{{item.content}}</p>
<div class="img-list" v-if="item.msgType == 'image'">
<img :src="item.sdkFileUrl" alt="" @click="previewImage(item.sdkFileUrl)">
</div>
<audio :src="item.sdkFileUrl" controls style="display: block;" v-if="item.msgType == 'voice'"></audio>
<video :src="item.sdkFileUrl" v-if="item.msgType == 'video'" />
<div class="file" @click="prevFile(item)" v-if="item.msgType == 'file'">
<u-row justify="between">
<label class="left">
<img :src="$cdn + 'common/appendix.png'" alt="">
<span>{{ item.sdkFileName }}</span>
</label>
<span>{{ item.fileSizeStr }}</span>
</u-row>
</div>
<div class="revoke-text" v-if="item.msgType == 'revoke'">{{item.userName}}撤回了一条消息</div>
<div class="revoke-text" v-if="item.msgType == 'disagree'">对方不同意会话存档内容你将无法继续提供服务</div>
<div class="revoke-text" v-if="item.msgType == 'agree'">对方同意会话存档内容你可以继续提供服务</div>
<div class="card-info" v-if="item.msgType == 'card'" @click="openUser(item.type, item.cardUserId)">
<div class="top">
<div class="card-left">
<h3>{{item.cardCorpName}}</h3>
<p>{{item.cardUserName}}</p>
<!-- <div>{{item.cardUserId}}</div> -->
</div>
<div class="card-right">
<img :src="item.cardUserAvatar" alt="" v-if="item.cardUserAvatar">
<img src="./img/user-img.png" alt="" v-else>
</div>
</div>
<div class="bottom">个人名片</div>
</div>
<img :src="item.sdkFileUrl" alt="" v-if="item.msgType == 'emotion'" :style="[{width: item.width/2+'px'}, {height: item.height/2+'px'}]">
<div class="map-info" v-if="item.msgType == 'location'" @click="openMap(item)">
<map style="width: 100%; height: 100%;" :latitude="item.lat" :longitude="item.lng" :scale="item.zoom" :enable-zoom="false" :enable-scroll="false">
<cover-view style='width:100%;height:100%'></cover-view>
</map>
<div class="address-text">
<p>{{item.title}}</p>
<p>{{item.address}}</p>
</div>
</div>
<div class="card-info" v-if="item.msgType == 'weapp'" @click="openApp(item)">
<div class="top">
<div class="card-left">
<h3 class="display-name">{{item.displayName}}</h3>
<p>{{item.title}}</p>
</div>
<div class="card-right">
<img src="./img/app-icon.png" alt="" >
</div>
</div>
<div class="bottom"><img src="./img/app-mini-icon.png" alt="" >小程序</div>
</div>
<div class="card-info" v-if="item.msgType == 'link'" @click="openLink(item)">
<div class="top">
<div class="card-left">
<p>{{item.title}}</p>
<div>{{item.username}}</div>
</div>
<div class="card-right" v-if="item.imageUrl">
<img :src="item.imageUrl" alt="" >
</div>
</div>
<div class="bottom">分享链接</div>
</div>
</div>
<img :src="item.userAvatar" alt="" class="user-img" v-if="item.userId == id">
<!-- <img src="./img/fail-icon.png" alt="" class="fail-img" v-if="item.userId != user.wxUserId"> -->
</div>
</div>
</div>
</scroll-view>
<AiEmpty v-else/>
<u-calendar v-model="isShowDate" @change="onDateChange" mode="range"></u-calendar>
<!-- <div class="footer" @click="toGroup">{{type == 1 ? '群详情' : '个人信息'}}</div> -->
</div>
</template>
<script>
import {mapState, mapActions} from "vuex";
export default {
name: "conversationDetail",
data() {
return {
tabList: [
{name: '全部', value: ''},
{name: '图片/视频', value: 'imagevideo'},
{name: '语音', value: 'voice'},
{name: '文件', value: 'file'},
],
currentTabs: 0,
barStyle: {
'width': '24px',
'height': '2px',
'border-radius': '0',
'bottom': '5px'
},
activeStyle: {
'font-weight' : '400',
'color': '#000000'
},
keyword: '',
toUserId: '',
roomId: '',
current: 1,
pages: 2,
list: [],
type: '',
isShowDate: false,
dateList: [],
scrollTop: 0,
scrollHeight: '',
preveHeight: '',
id: ''
};
},
computed: {
...mapState(['user']),
},
onLoad(option) {
if(option.toUserId) {
this.toUserId = option.toUserId
}else {
this.roomId = option.roomId
}
this.type = option.type
this.id = option.id
this.getList()
console.log()
this.scrollHeight = uni.getSystemInfoSync().windowHeight - 150
this.injectJWeixin('openLocation')
},
onShow() {
document.title = '会话详情'
},
// onPullDownRefresh() {
// if(this.current > this.pages) {
// uni.stopPullDownRefresh()
// return this.$u.toast('已加载完成,没有更多数据')
// }else {
// this.current ++
// this.getList()
// setTimeout(() => {
// uni.stopPullDownRefresh()
// }, 1000)
// }
// },
methods: {
scroll(e) {
if(e.detail.scrollTop == 0) {
if(this.current > this.pages) {
return this.$u.toast('已加载完成,没有更多数据')
}else {
this.current ++
this.getList()
}
}
},
toGroup() {
if(this.type == 1) {
uni.navigateTo({url: `./groupDetail`})
}else {
uni.navigateTo({url: `./userInfo`})
}
},
change(index) {
this.keyword = ''
this.currentTabs = index
this.getListInit()
},
onDateChange (e) {
this.dateList = [e.startDate, e.endDate]
this.getListInit()
},
clearDate() {
this.dateList = []
this.getListInit()
},
getListInit() {
this.current = 1
this.pages = 2
this.list = []
this.getList()
},
getList() {
if(this.current > 1) {
uni.createSelectorQuery().select(".conversation-list").boundingClientRect((res) => {
this.preveHeight = res.height
}).exec();
}
this.$http.post(`/app/appsessionarchiveinfo/list`, null, {
params: {
current: this.current,
size: 10,
msgType: this.tabList[this.currentTabs].value,
// msgType: 'link',
userId: this.id,
toUserId: this.toUserId,
roomId: this.roomId,
type: this.type,
content: this.keyword,
startTime: this.dateList.length ? this.dateList[0] : '',
endTime: this.dateList.length ? this.dateList[1] : ''
}
}).then(res=> {
if(res?.data) {
res.data.records.map((item) => {
if(item.msgType == 'location') {
item.covers = [{
latitude: item.lat,
longitude: item.lng,
label: {
content: item.address
},
callout: {
content: item.title
}
}]
}
})
this.list = this.current > 1 ? [ ...res.data.records, ...this.list]: res.data.records
this.pages = res.data.pages
this.$nextTick(() => {
uni.createSelectorQuery().select(".conversation-list").boundingClientRect((res) => {
if(this.current == 1) {
this.scrollTop = res.height - this.scrollHeight
}else {
this.scrollTop = res.height - this.preveHeight
}
}).exec();
})
}
})
},
previewImage(img) {
uni.previewImage({
urls: [img],
current: img
})
},
...mapActions(['previewFile', 'injectJWeixin']),
prevFile(file) {
var fileInfo = {url: file.sdkFileUrl, name: file.sdkFileName, size: file.fileSizeStr}
this.$loading()
this.previewFile({ ...fileInfo }).then(()=>{
this.$hideLoading()
})
},
openLink(row) {
window.open(row.linkUrl);
},
openApp(row) {
uni.navigateToMiniProgram({
// appId: row.goodsJdAppid,
// path: row.goodsJdUrl
})
},
openUser(type, userid) { //缺少名片人员区分内部还是外部
console.log(row)
// userid && this.injectJWeixin('openUserProfile').then(() => {
// this.wxInvoke(['openUserProfile', {type, userid}, () => 0])
// })
},
openMap(row) {
wx.openLocation({
latitude: row.lat, // 纬度浮点数范围为90 ~ -90
longitude: row.lng, // 经度浮点数范围为180 ~ -180。
name: row.title, // 位置名
address: row.address, // 地址详情说明
scale: row.zoom, // 地图缩放级别,整形值,范围从1~28。默认为16
fail: () => {
location.reload()
}
});
}
},
onReachBottom() {
// this.current ++
// this.getList()
}
};
</script>
<style lang="scss" scoped>
.conversationDetail {
height: 100%;
::v-deep .AiTopFixed {
.placeholder {
.content {
padding: 0 !important;
}
}
.fixed {
margin: 0 !important;
.content {
padding: 0 !important;
}
}
}
.top-search {
padding: 20px 32px;
display: flex;
.left {
width: 400px;
div {
display: inline-block;
line-height: 64px;
}
img {
display: inline-block;
width: 32px;
height: 32px;
margin-left: 8px;
vertical-align: middle;
}
}
.right {
width: calc(100% - 400px);
}
}
.conversation-list {
padding: 48px 32px 160px;
// background-color: #EBECF0;
.item {
margin-bottom: 48px;
display: flex;
position: relative;
.user-name {
position: absolute;
top: 0;
left: 24px;
font-family: PingFangSC-Regular;
font-size: 22px;
color: #666;
padding:0 0 0 64px;
span {
display: inline-block;
margin: 0 12px;
font-family: PingFangSC-Regular;
font-size: 20px;
color: #999;
}
}
.user-img {
width: 72px;
height: 72px;
margin-right: 20px;
border-radius: 50%;
}
.content {
max-width: calc(100% - 144px);
position: relative;
margin-top: 44px;
.cir {
width: 0px;
height: 0px;
border: 10px solid transparent;
position: absolute;
top: 20px;
}
.content-text {
display: inline-block;
padding: 14px 54px 14px 32px;
width: 100%;
background-color: #fff;
font-family: PingFangSC-Regular;
font-size: 32px;
color: #333;
word-break: break-all;
box-sizing: border-box;
}
}
.fail-img {
width: 32px;
height: 32px;
margin: auto 0 auto 24px;
}
.img-list {
img {
max-width: 400px;
margin: 0 16px 16px 0;
}
}
::v-deep .uni-audio-default {
height: 72px;
width: 280px!important;
min-width: 0!important;
}
::v-deep .uni-audio-left {
height: 72px;
width: 72px;
.uni-audio-button {
margin: 14px;
}
}
::v-deep .uni-audio-right {
height: 72px;
margin-left: 72px;
padding: 10px 32px 10px 0;
}
.revoke-text {
line-height: 54px;
padding: 0 24px;
border-radius: 8px;
background-color: #EEE;
color: #999;
margin-top: 16px;
}
.file {
height: 128px;
background: #FFFFFF;
border-radius: 8px;
border: 1px solid #CCCCCC;
box-sizing: border-box;
padding: 0 16px;
margin-bottom: 32px;
& > .u-row {
height: 100%;
.left {
width: 522px;
display: flex;
align-items: center;
& > img {
width: 96px;
height: 96px;
}
& > span {
font-size: 32px;
color: #333333;
display: inline-block;
line-height: 44px;
text-overflow: ellipsis;
overflow-x: hidden;
white-space: nowrap;
}
}
& > span {
font-size: 28px;
color: #999;
margin: -8px 0 0 16px;
}
}
}
.card-info {
width: 450px;
background: #FFF;
.top {
padding: 16px 32px;
display: flex;
.card-left {
width: calc(100% - 120px);
h3 {
font-family: PingFangSC-Regular;
font-size: 32px;
color: #333;
line-height: 44px;
margin-bottom: 30px;
}
p {
font-family: PingFangSC-SNaNpxibold;
font-size: 32px;
color: #333;
line-height: 44px;
}
div {
font-family: PingFangSC-Regular;
font-size: 24px;
color: #999;
line-height: 34px;
}
.display-name {
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: 24px;
color: #999;
line-height: 34px;
margin-bottom: 10px;
}
}
.card-right {
img {
width: 84px;
height: 84px;
}
}
}
.bottom {
padding-left: 32px;
line-height: 48px;
font-family: PingFangSC-Regular;
font-size: 22px;
color: #999;
border-top: 1px solid #eee;
img {
width: 20px;
height: 20px;
margin-right: 8px;
}
}
}
.map-info {
width: 560px;
height: 400px;
.address-text {
position: absolute;
bottom: 0;
left: 0;
width: 560px;
background-color: rgba(0, 0, 0, .7);
p {
color: #fff;
line-height: 44px;
font-size: 24px;
padding-left: 32px;
word-break: break-all;
}
}
}
}
.item-left {
.content {
.cir {
left: -18px;
border-right-color: #fff;
}
}
}
.item-right {
width: 100%;
justify-content: right;
.user-name {
left: 0;
right: 82px;
text-align: right;
}
.user-img {
margin: 0 0 0 20px;
}
.content {
.cir {
border-left-color: #C7E7FE;
right: -18px;
}
.content-text {
background-color: #C7E7FE;
padding: 14px 32px 14px 54px;
}
.img-list {
img {
max-width: 400px;
margin: 0 0 16px 16px;
}
}
}
.fail-img {
margin: auto 24px auto 0;
}
}
}
.footer{
width: 100%;
height: 112px;
line-height: 112px;
background: #1365DD;
box-shadow: inset 0px 1px 0px 0px #EEEEEE;
font-size: 32px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #FFF;
text-align: center;
position: fixed;
bottom: 0;
left: 0;
z-index: 99;
}
}
</style>

View File

@@ -0,0 +1,127 @@
<template>
<div class="groupDetail">
<div class="bg-fff">
<div class="group-info">
<img src="./img/down-icon.png" alt="">
<div>
<h3>县政法委</h3>
<p>群成员45</p>
</div>
</div>
<img src="./img/down-icon.png" alt="" class="group-img">
<p class="text">使用微信或企业微信扫码加入</p>
<div class="btn">申请加入群聊</div>
<div class="btn">进入群聊</div>
</div>
<div class="flex">
<div class="item">
<img src="./img/retransmission-icon.png" alt="">
<p>转发到聊天</p>
</div>
<div class="item">
<img src="./img/wechat-icon.png" alt="">
<p>分享到微信</p>
</div>
<div class="item">
<img src="./img/down-icon.png" alt="">
<p>保存到相册</p>
</div>
</div>
</div>
</template>
<script>
export default {
name: "groupDetail",
appName: "群详情",
data() {
return {
};
},
onShow() {
},
methods: {
},
};
</script>
<style lang="scss" scoped>
.groupDetail {
height: 100vh;
background-color: #f5f5f5;
.bg-fff {
background-color: #fff;
margin: 48px 32px 52px;
padding: 64px 32px 72px;
.group-info {
display: flex;
margin-bottom: 72px;
img {
width: 96px;
height: 96px;
margin: 0 20px 0 40px;
}
h3 {
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 36px;
color: #333;
line-height: 52px;
margin-bottom: 4px;
}
p {
font-family: PingFangSC-Regular;
font-size: 28px;
color: #999;
}
}
.group-img {
width: 386px;
height: 386px;
margin: 0 0 40px 118px;
}
.text {
text-align: center;
font-family: PingFangSC-Regular;
font-size: 28px;
color: #666;
margin-bottom: 80px;
}
.btn {
width: 100%;
height: 100px;
text-align: center;
line-height: 100px;
background: #3975C6;
border-radius: 8px;
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 32px;
color: #FFF;
margin-bottom: 32px;
}
}
.flex {
padding: 0 100px;
display: flex;
justify-content: space-between;
.item {
text-align: center;
img {
width: 62px;
height: 62px;
margin-bottom: 4px;
}
p {
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: 26px;
color: #999;
}
}
}
}
</style>

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 830 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 757 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 814 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 793 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

View File

@@ -0,0 +1,285 @@
<template>
<div class="conversation-list">
<AiTopFixed>
<u-tabs :list="tabList" :is-scroll="false" :current="currentTabs" height="96" bg-color="#3975C6"
inactive-color="#A1C1E8" :bar-style="barStyle" :active-item-style="activeStyle" active-color="#ffffff " @change="change">
</u-tabs>
<div class="top-search">
<div class="left">
<AiPagePicker type="dept" :selected.sync="deptUserList" nodeKey="id" single @select="deptSelect">
<span class="label" v-if="deptUserList.length">{{deptUserList[0].name}}</span>
<span v-else style="color:#999;">部门名称</span>
<div class="clear-btn" v-if="deptUserList.length" @click.stop="clearDept">
<img src="./img/del-icon.png" alt="" class="del-icon">
</div>
<u-icon name="arrow-down" color="#999" size="24" style="margin-left:8px;" v-else/>
</AiPagePicker>
</div>
<div class="right">
<u-search v-model="keyword" :clearabled="true" :placeholder="currentTabs != 1 ? '请输入群名称' : '请输入昵称'" :show-action="false" bg-color="#F5F5F5"
search-icon-color="#999" color="#999" height="58" @search="getListInit" @clear="getListInit">
</u-search>
</div>
</div>
<!-- <div class="top-search">
<div class="left">
<u-search v-model="keyword" :clearabled="true" :placeholder="currentTabs != 1 ? '请输入群名称' : '请输入昵称'" :show-action="false" bg-color="#F5F5F5"
search-icon-color="#999" color="#999" height="58" @search="getListInit" @clear="getListInit">
</u-search>
</div>
</div>
<div class="top-select">
<div class="item">
<AiAreaPicker v-model="areaId" :areaId="user.areaId" @select="areaSelect" :name.sync="areaName" style="color: #666" selectRoot>
<span style="margin-left: 4px" v-if="areaName">{{ areaName }}</span>
<span v-else style="color:#999;">行政区划</span>
<u-icon name="arrow-down" color="#999" size="28" style="margin-left: 4px" />
</AiAreaPicker>
</div>
<div class="item">
<AiPagePicker type="dept" :selected.sync="deptUserList" nodeKey="id" single @select="deptSelect">
<span class="label" v-if="deptUserList.length">{{deptUserList[0].name}}</span>
<span v-else style="color:#999;">部门名称</span>
<u-icon name="arrow-down" color="#999" size="24" style="margin-left:8px;"/>
</AiPagePicker>
</div>
</div> -->
</AiTopFixed>
<div class="user-list" v-if="list.length">
<div class="item" v-for="(item, index) in list" :key="index" @click="toDetail(item)">
<img :src="item.toUserAvatar" alt="" v-if="currentTabs == 1">
<img src="./img/group-img.png" alt="" v-else>
<div class="item-border">
<div class="flex-left">
<p>{{currentTabs == 1 ? item.toUserName : item.roomName}}</p>
</div>
<div class="flex-right" :class="`type`+item.userType" v-if="item.userType > 0">{{item.userType == 1 ? '内部' : '外部'}}</div>
</div>
</div>
</div>
<AiEmpty v-else/>
</div>
</template>
<script>
import {mapState} from "vuex";
export default {
name: "conversationList",
data() {
return {
tabList: [
{name: '群聊会话'},
{name: '私聊会话'},
],
currentTabs: 0,
barStyle: {
'width': '24px',
'height': '2px',
'border-radius': '0',
'bottom': '5px'
},
activeStyle: {
'font-weight' : '400',
},
keyword: '',
areaId: '',
areaName: '',
current: 1,
pages: 2,
list: [],
deptUserList: [],
id: ''
};
},
computed: {
...mapState(['user']),
},
onLoad(options) {
this.areaId = this.user.areaId
this.areaName = this.user.areaName
// this.deptUserList = [{id: this.user.departId, name: this.user.departName}]
this.id = options.id
this.getList()
},
onShow() {
document.title = '会话存档'
},
methods: {
clearDept() {
this.deptUserList = []
this.getListInit()
},
change(index) {
this.keyword = ''
this.currentTabs = index
this.getListInit()
},
getListInit() {
this.current = 1
this.pages = 2
this.list = []
this.getList()
},
areaSelect(e) {
this.areaId = e
this.getListInit()
},
deptSelect(e) {
this.deptUserList = e
this.getListInit()
},
getList() {
if(this.current > this.pages) return
this.$http.post(`/app/appsessionarchiveindex/list`, null, {
params: {
current: this.current,
size: 15,
type: this.currentTabs == 1 ? 0 : 1,
// areaId: this.areaId,
userId: this.id,
toUserName: this.currentTabs == 1 ? this.keyword : '',
roomName: this.currentTabs == 1 ? '' : this.keyword,
departmentId: this.deptUserList.length ? this.deptUserList[0].id : ''
}
}).then(res=> {
if(res?.data) {
res.data.records.map((item) => {
if(item.type == 1) {
item.userType = item.roomType
}else {
item.userType = item.toUserType
}
})
this.list = this.current > 1 ? [...this.list, ...res.data.records]: res.data.records
this.pages = res.data.pages
}
})
},
toDetail(row) {
var query = row.type == 1 ? `?roomId=${row.roomId}` : `?toUserId=${row.toUserId}`
uni.navigateTo({ url: `./conversationDetail${query}&type=${row.type}&id=${this.id}`})
}
},
onReachBottom() {
this.current ++
this.getList()
}
};
</script>
<style lang="scss" scoped>
.conversation-list {
height: 100%;
::v-deep .AiTopFixed {
.placeholder {
.content {
padding: 0 !important;
}
}
.fixed {
margin: 0 !important;
.content {
padding: 0 !important;
}
}
}
.top-search {
padding: 20px 32px;
display: flex;
.left {
width: 350px;
line-height: 64px;
.clear-btn {
display: inline-block;
padding: 0 16px;
}
.del-icon {
width: 32px;
height: 32px;
vertical-align: middle;
}
}
.right {
width: calc(100% - 350px);
}
}
.top-select {
display: flex;
padding: 28px 0;
.item {
flex: 1;
padding: 0 8px;
text-align: center;
span {
display: inline-block;
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 28px;
color: #666;
line-height: 40px;
}
}
}
.user-list {
border-top: 1px solid #eee;
background-color: #fff;
.item {
padding: 24px 0 0 32px;
display: flex;
.item-border {
width: calc(100% - 112px);
padding-right: 32px;
display: flex;
justify-content: space-between;
border-bottom: 1px solid #eee;
}
.flex-left {
padding-right: 8px;
box-sizing: border-box;
}
.flex-right {
font-size: 24px;
margin-top: 26px;
width: 78px;
height: 34px;
line-height: 34px;
text-align: center;
border-radius: 4px;
}
.type1 {
background-color: #EAF4FF;
color: #267EF0;
}
.type2 {
background-color: #FDEEE1;
color: #FB7D29;
}
img {
width: 80px;
height: 80px;
border-radius: 50%;
margin-right: 32px;
}
p {
padding-bottom: 32px;
width: calc(100% - 112px);
line-height: 80px;
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 32px;
color: #333;
letter-spacing: 0.3px;
display: inline-block;
vertical-align: top;
width: 100%;
}
}
.item:nth-last-child(1) {
p {
border-bottom: 0;
}
}
}
}
</style>

View File

@@ -0,0 +1,110 @@
<template>
<div class="triggerAlarm">
<div class="trigger-list">
<div class="item">
<div class="top">
<div class="title-flex">
<p>敏感词告警</p>
<span>2023-02-22 12:23:23</span>
</div>
<p class="item-content">群主为李白的群会话网格群14xxxx居民触发敏感词<span>法轮功</span>请及时处置</p>
</div>
<div class="bottom">
<p>查看详情</p>
<u-icon name="arrow-right" color="#999" size="28"></u-icon>
</div>
</div>
<div class="item">
<div class="top">
<div class="title-flex">
<p>敏感词告警</p>
<span>2023-02-22 12:23:23</span>
</div>
<p class="item-content">群主为李白的群会话网格群14xxxx居民触发敏感词<span>法轮功</span>请及时处置</p>
</div>
<div class="bottom">
<p>查看详情</p>
<u-icon name="arrow-right" color="#999" size="28"></u-icon>
</div>
</div>
</div>
</div>
</template>
<script>
export default {
name: "triggerAlarm",
data() {
return {
};
},
onShow() {
document.title = '触发告警'
},
methods: {
},
};
</script>
<style lang="scss" scoped>
.triggerAlarm {
height: 100vh;
background-color: #F5F5F5;
.trigger-list {
padding: 32px 0 0 32px;
.item {
width: calc(100% - 32px);
background: #FFF;
border-radius: 16px;
margin-bottom: 32px;
.top {
padding: 32px;
.title-flex {
display: flex;
justify-content: space-between;
margin-bottom: 16px;
p {
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: 28px;
color: #000;
line-height: 28px;
}
span {
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: 26px;
color: #999;
line-height: 24px;
}
}
.item-content {
color: #666;
font-size: 26px;
font-family: PingFangSC;
font-weight: 400;
line-height: 40px;
span {
color: #E6736E;
}
}
}
.bottom {
display: flex;
justify-content: space-between;
padding: 24px 32px;
border-top: 1px solid #eee;
p {
font-family: PingFangSC-Regular;
font-size: 24px;
color: #666;
line-height: 24px;
}
}
}
}
}
</style>

View File

@@ -0,0 +1,87 @@
<template>
<div class="userInfo">
<div class="user-info">
<img src="./img/user-img.png" alt="" class="user-img">
<div class="user-name">
<h3>卓作旺<img src="./img/ic-man@2x.png" alt=""></h3>
<p>出差ing</p>
</div>
</div>
<div class="btn">添加联系人为好友</div>
<div class="btn bg-fff">发消息</div>
</div>
</template>
<script>
export default {
name: "userInfo",
data() {
return {
};
},
onShow() {
document.title = '个人信息'
},
methods: {
},
};
</script>
<style lang="scss" scoped>
.userInfo {
height: 100vh;
background-color: #F5F5F5;
.user-info {
display: flex;
padding: 40px 32px;
background-color: #fff;
margin-bottom: 40px;
.user-img {
width: 120px;
height: 120px;
margin-right: 24px;
}
.user-name {
margin-top: 6px;
h3 {
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 36px;
color: #333;
line-height: 50px;
margin-bottom: 18px;
img {
width: 24px;
height: 24px;
margin-left: 8px;
}
}
p {
font-family: PingFangSC-Regular;
font-size: 28px;
color: #999;
line-height: 40px;
}
}
}
.btn {
width: calc(100% - 64px);
margin: 0 0 32px 32px;
height: 112px;
line-height: 112px;
text-align: center;
background: #3975C6;
border-radius: 8px;
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 32px;
color: #FFF;
}
.bg-fff {
background-color: #fff;
color: #000;
}
}
</style>

View File

@@ -0,0 +1,261 @@
<template>
<div class="AppSensitive">
<AiTopFixed>
<div class="top-search">
<div class="left">
<AiPagePicker type="dept" :selected.sync="deptUserList" nodeKey="id" single @select="deptSelect">
<span class="label" v-if="deptUserList.length">{{deptUserList[0].name}}</span>
<span v-else style="color:#999;">部门名称</span>
<div class="clear-btn" v-if="deptUserList.length" @click.stop="clearDept">
<img src="./img/del-icon.png" alt="" class="del-icon">
</div>
<u-icon name="arrow-down" color="#999" size="24" style="margin-left:8px;" v-else />
</AiPagePicker>
</div>
<div class="right">
<u-search v-model="keyword" :clearabled="true" placeholder="触发敏感词" :show-action="false" bg-color="#F5F5F5"
search-icon-color="#999" color="#999" height="58" @search="getListInit" @clear="getListInit">
</u-search>
</div>
</div>
</AiTopFixed>
<div class="user-list">
<div class="item" v-for="(item, index) in list" :key="index" @click="toConversationRecord(item)">
<img src="./img/group-img.png" alt="" v-if="item.type == 1">
<img :src="item.userAvatar" alt="" v-if="item.type != 1 && item.userAvatar">
<img src="./img/user-img.png" alt="" v-if="item.type != 1 && !item.userAvatar">
<div class="item-right">
<div class="name-flex">
<p v-if="item.type == 1">{{item.toName}}</p>
<p v-else>{{item.userName}}</p>
<div class="time">{{item.createTime.substring(0, 16)}}</div>
</div>
<div v-html="item.text" class="item-content"></div>
</div>
</div>
</div>
</div>
</template>
<script>
export default {
name: "AppSensitive",
appName: "敏感词触发记录",
data() {
return {
keyword: '',
current: 1,
pages: 2,
list: [],
deptUserList: []
};
},
onLoad() {
this.getListInit()
},
onShow() {
document.title = '触发记录'
},
methods: {
clearDept() {
this.deptUserList = []
this.getListInit()
},
getListInit() {
this.current = 1
this.pages = 2
this.list = []
this.getList()
},
getList() {
if(this.current > this.pages) return
this.$http.post(`/app/appsessionarchivekeywordrecord/list`, null, {
params: {
current: this.current,
size: 15,
content: this.keyword,
departmentId: this.deptUserList.length ? this.deptUserList[0].id : ''
}
}).then(res=> {
if(res?.data) {
res.data.records.map((item) => {
if(item.type == 1) {
item.text = item.userName + ':' + this.changeKeyRed(item.content, item.wordName)
}else {
item.text = this.changeKeyRed(item.content, item.wordName)
}
})
this.list = this.current > 1 ? [...this.list, ...res.data.records] : res.data.records
this.pages = res.data.pages
}
})
},
toConversationRecord(row) {
uni.navigateTo({url: `./conversationRecord?userId=${row.userId}&toUserId=${row.toUserId}&toName=${row.toName}&type=${row.type}&seq=${row.seq}&msgId=${row.msgId}`})
},
deptSelect(e) {
this.deptUserList = e
this.getListInit()
},
changeKeyRed (str, keyWord) {
if (str != null && keyWord != null) {
var substr = "/" + keyWord + "/g";
var replaceStr = str.replace(eval(substr), "<span style='color:#e6736e'>" + keyWord + "</span>")
return replaceStr;
} else {
return str;
}
},
},
onReachBottom() {
this.current ++
this.getList()
}
};
</script>
<style lang="scss" scoped>
.AppSensitive {
height: 100%;
::v-deep .AiTopFixed {
.placeholder {
.content {
padding: 0 !important;
}
}
.fixed {
margin: 0 !important;
.content {
padding: 0 !important;
}
}
}
.top-search {
padding: 20px 32px;
display: flex;
.left {
width: 350px;
line-height: 64px;
.clear-btn {
display: inline-block;
padding: 0 16px;
}
.del-icon {
width: 32px;
height: 32px;
vertical-align: middle;
}
}
.right {
width: calc(100% - 350px);
}
}
.top-select {
display: flex;
padding: 28px 0;
border-bottom: 1px solid #eee;
.item {
flex: 1;
padding: 0 8px;
text-align: center;
span {
display: inline-block;
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 28px;
color: #666;
line-height: 40px;
}
}
}
.user-list {
background-color: #fff;
.item {
padding: 24px 0 0 32px;
display: flex;
box-sizing: border-box;
img {
width: 80px;
height: 80px;
margin-right: 32px;
border-radius: 50%;
}
.item-right {
width: calc(100% - 112px);
border-bottom: 1px solid #eee;
padding: 0 32px 20px 0;
box-sizing: border-box;
// display: flex;
// justify-content: space-between;
// border-bottom: 1px solid #eee;
// padding-right: 32px;
// box-sizing: border-box;
// .user {
// width: calc(100% - 240px);
// p {
// line-height: 44px;
// font-family: PingFangSC-Medium;
// font-weight: 500;
// font-size: 32px;
// color: #333;
// letter-spacing: 0.3px;
// margin-bottom: 8px;
// }
// div {
// color: #666;
// font-size: 28px;
// font-family: PingFangSC;
// line-height: 40px;
// padding-bottom: 20px;
// span {
// color: #e6736e;
// }
// }
// }
// .time {
// font-family: PingFangSC-Regular;
// font-size: 26px;
// color: #999;
// }
.name-flex {
display: flex;
justify-content: space-between;
width: 100%;
p {
width: calc(100% - 240px);
line-height: 44px;
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 32px;
color: #333;
margin-bottom: 8px;
}
.time {
font-family: PingFangSC-Regular;
font-size: 26px;
color: #999;
}
}
.content {
color: #666;
font-size: 28px;
font-family: PingFangSC;
line-height: 40px;
padding-bottom: 20px;
word-break: break-all;
span {
color: #e6736e;
}
}
}
}
.item:nth-last-child(1) {
p {
border-bottom: 0;
}
}
}
}
</style>

View File

@@ -0,0 +1,687 @@
<template>
<div class="conversationRecord">
<AiTopFixed>
<div class="top-search">
<div class="left" @click="isShowDate=true">
<div class="color-999" v-if="!dateList.length">开始时间-结束时间</div>
<div v-else>{{dateList[0]}}{{dateList[1]}}</div>
<!-- <img src="./img/del-icon.png" alt="" v-if="dateList.length" @click.stop="clearDate()"> -->
<div class="clear-btn" v-if="dateList.length" @click.stop="clearDate">
<img src="./img/del-icon.png" alt="" class="del-icon">
</div>
</div>
<div class="right">
<u-search v-model="keyword" :clearabled="true" placeholder="请输入关键词" :show-action="false" bg-color="#F5F5F5"
search-icon-color="#999" color="#999" height="58" @search="getListInit" @clear="getListInit">
</u-search>
</div>
</div>
</AiTopFixed>
<scroll-view :scroll-top="scrollTop" scroll-y="true" class="scroll-Y" @scroll="scroll" v-if="list.length" :style="{height: scrollHeight+'px'}">
<div class="conversation-list">
<div v-for="(item, index) in list" :key="index">
<div class="item" :class="item.userId == user.wxUserId ? 'item-right' : 'item-left'">
<img src="./img/fail-icon.png" alt="" class="fail-img" v-if="item.userId == user.wxUserId && item.isKeyword == 1">
<img :src="item.userAvatar" alt="" class="user-img" v-if="item.userId != user.wxUserId && item.userAvatar">
<img src="./img/user-img.png" alt="" class="user-img" v-if="item.userId != user.wxUserId && !item.userAvatar">
<p class="user-name">{{item.userName}}<span>{{item.msgSendTime}}</span></p>
<div class="content">
<span class="cir" v-if="item.msgType == 'text'"></span>
<p class="content-text" v-if="item.msgType == 'text'">{{item.content}}</p>
<div class="img-list" v-if="item.msgType == 'image'">
<img :src="item.sdkFileUrl" alt="" @click="previewImage(item.sdkFileUrl)">
</div>
<audio :src="item.sdkFileUrl" controls style="display: block;" v-if="item.msgType == 'voice'"></audio>
<video :src="item.sdkFileUrl" v-if="item.msgType == 'video'" />
<div class="file" @click="prevFile(item)" v-if="item.msgType == 'file'">
<u-row justify="between">
<label class="left">
<img :src="$cdn + 'common/appendix.png'" alt="">
<span>{{ item.sdkFileName }}</span>
</label>
<span>{{ item.fileSizeStr }}</span>
</u-row>
</div>
<div class="revoke-text" v-if="item.msgType == 'revoke'">{{item.userName}}撤回了一条消息</div>
<div class="revoke-text" v-if="item.msgType == 'disagree'">对方不同意会话存档内容你将无法继续提供服务</div>
<div class="revoke-text" v-if="item.msgType == 'agree'">对方同意会话存档内容你可以继续提供服务</div>
<div class="card-info" v-if="item.msgType == 'card'" @click="openUser(item.type, item.cardUserId)">
<div class="top">
<div class="card-left">
<h3>{{item.cardCorpName}}</h3>
<p>{{item.cardUserName}}</p>
<!-- <div>{{item.cardUserId}}</div> -->
</div>
<div class="card-right">
<img :src="item.cardUserAvatar" alt="" v-if="item.cardUserAvatar">
<img src="./img/user-img.png" alt="" v-else>
</div>
</div>
<div class="bottom">个人名片</div>
</div>
<img :src="item.sdkFileUrl" alt="" v-if="item.msgType == 'emotion'" :style="[{width: item.width/2+'px'}, {height: item.height/2+'px'}]">
<div class="map-info" v-if="item.msgType == 'location'" @click="openMap(item)">
<map style="width: 100%; height: 100%;" :latitude="item.lat" :longitude="item.lng" :scale="item.zoom" :enable-zoom="false" :enable-scroll="false">
<cover-view style='width:100%;height:100%'></cover-view>
</map>
<div class="address-text">
<p>{{item.title}}</p>
<p>{{item.address}}</p>
</div>
</div>
<div class="card-info" v-if="item.msgType == 'weapp'" @click="openApp(item)">
<div class="top">
<div class="card-left">
<h3 class="display-name">{{item.displayName}}</h3>
<p>{{item.title}}</p>
</div>
<div class="card-right">
<img src="./img/app-icon.png" alt="" >
</div>
</div>
<div class="bottom"><img src="./img/app-mini-icon.png" alt="" >小程序</div>
</div>
<div class="card-info" v-if="item.msgType == 'link'" @click="openLink(item)">
<div class="top">
<div class="card-left">
<p>{{item.title}}</p>
<div>{{item.username}}</div>
</div>
<div class="card-right" v-if="item.imageUrl">
<img :src="item.imageUrl" alt="" >
</div>
</div>
<div class="bottom">分享链接</div>
</div>
</div>
<img :src="item.userAvatar" alt="" class="user-img" v-if="item.userId == user.wxUserId">
<img src="./img/fail-icon.png" alt="" class="fail-img" v-if="item.userId != user.wxUserId && item.isKeyword == 1">
</div>
</div>
</div>
</scroll-view>
<AiEmpty v-else/>
<u-calendar v-model="isShowDate" @change="onDateChange" mode="range"></u-calendar>
</div>
</template>
<script>
import {mapState, mapActions} from "vuex";
export default {
name: "conversationRecord",
data() {
return {
keyword: '',
list: [],
params: {},
id: '',
isShowDate: false,
dateList: [],
current: null,
preCurrent: null,
pages: 2,
scrollTop: 0,
scrollHeight: '',
preveHeight: ''
};
},
computed: {
...mapState(['user']),
},
onLoad(option) {
console.log(option)
this.params = {...option}
// this.params = {
// userId: 'ChenChen',
// toUserId: 'LiuYe',
// toName: '刘烨',
// type: '0',
// seq: '12481'
// }
this.id = this.params.userId
this.scrollHeight = uni.getSystemInfoSync().windowHeight - 56
this.injectJWeixin('openLocation')
this.getKeywordList()
},
onShow() {
document.title = '会话详情'
},
methods: {
scroll(e) {
if(e.detail.scrollTop == 0) {
if(this.current > this.pages) {
return this.$u.toast('已加载完成,没有更多数据')
}else {
this.current ++
this.getList()
}
}
},
onDateChange (e) {
this.dateList = [e.startDate, e.endDate]
this.getListInit()
},
clearDate() {
this.dateList = []
this.getListInit()
},
getKeywordList() {
this.$http.post(`/app/appsessionarchiveinfo/listByKeywordRecord`, null, {
params: {
userId: this.id,
size: 10,
// msgType: this.msgTypeList[this.msgType].value,
toUserId: this.params.type == 1 ? '' : this.params.toUserId,
roomId: this.params.type == 1 ? this.params.roomId : '',
type: this.params.type,
content: this.keyword,
startTime: this.time ? this.time[0] : '',
endTime: this.time ? this.time[1] : '',
seq: this.params.seq,
msgId: this.params.msgId
}
}).then(res => {
if (res.code === 0) {
this.current = res.data.current
this.preCurrent = res.data.current
res.data.records.map((item) => {
// if(item.msgType == 'text') {
// item.text = this.changeKeyRed(item.content, item.wordName)
// }
if(item.msgType == 'location') {
item.covers = [{
latitude: item.lat,
longitude: item.lng,
label: {
content: item.address
},
callout: {
content: item.title
}
}]
}
})
this.list = res.data.records
this.pages = res.data.pages
this.$nextTick(() => {
uni.createSelectorQuery().select(".conversation-list").boundingClientRect((res) => {
this.scrollTop = res.height - this.scrollHeight
}).exec();
})
}
this.isLoading = false
}).catch(() => {
this.isLoading = false
})
},
getListInit() {
this.current = 1
this.pages = 2
this.list = []
this.getList()
},
getList() {
if(this.current > 1) {
uni.createSelectorQuery().select(".conversation-list").boundingClientRect((res) => {
this.preveHeight = res.height
}).exec();
}
this.$http.post(`/app/appsessionarchiveinfo/list`, null, {
params: {
userId: this.id,
current: this.current,
size: 10,
// msgType: this.tabList[this.currentTabs].value,
// msgType: 'file',
toUserId: this.params.toUserId,
roomId: this.params.roomId,
type: this.params.type,
content: this.keyword,
startTime: this.dateList.length ? this.dateList[0] : '',
endTime: this.dateList.length ? this.dateList[1] : ''
}
}).then(res=> {
if(res?.data) {
res.data.records.map((item) => {
if(item.msgType == 'location') {
item.covers = [{
latitude: item.lat,
longitude: item.lng,
label: {
content: item.address
},
callout: {
content: item.title
}
}]
}
})
this.list = this.current > 1 ? [ ...res.data.records, ...this.list]: res.data.records
this.$nextTick(() => {
uni.createSelectorQuery().select(".conversation-list").boundingClientRect((res) => {
if(this.current == 1) {
this.scrollTop = res.height - this.scrollHeight
}else {
this.scrollTop = res.height - this.preveHeight
}
}).exec();
})
}
})
},
getListPre() {
if(this.current > 1) {
uni.createSelectorQuery().select(".conversation-list").boundingClientRect((res) => {
this.preveHeight = res.height
}).exec();
}
this.$http.post(`/app/appsessionarchiveinfo/list`, null, {
params: {
userId: this.id,
current: this.preCurrent,
size: 10,
// msgType: this.tabList[this.currentTabs].value,
toUserId: this.params.toUserId,
roomId: this.params.roomId,
type: this.params.type,
content: this.keyword,
startTime: this.dateList.length ? this.dateList[0] : '',
endTime: this.dateList.length ? this.dateList[1] : ''
}
}).then(res=> {
if(res?.data) {
res.data.records.map((item) => {
if(item.msgType == 'location') {
item.covers = [{
latitude: item.lat,
longitude: item.lng,
label: {
content: item.address
},
callout: {
content: item.title
}
}]
}
})
this.list = [...this.list, ...res.data.records]
this.$nextTick(() => {
uni.createSelectorQuery().select(".conversation-list").boundingClientRect((res) => {
if(this.current == 1) {
this.scrollTop = res.height - this.scrollHeight
}else {
this.scrollTop = res.height - this.preveHeight
}
}).exec();
})
}
})
},
changeKeyRed (str, keyWord) {
if (str != null && keyWord != null) {
var substr = "/" + keyWord + "/g";
var replaceStr = str.replace(eval(substr), "<span style='color:#e6736e'>" + keyWord + "</span>")
return replaceStr;
} else {
return str;
}
},
previewImage(img) {
uni.previewImage({
urls: [img],
current: img
})
},
...mapActions(['previewFile', 'injectJWeixin']),
prevFile(file) {
var fileInfo = {url: file.sdkFileUrl, name: file.sdkFileName, size: file.fileSizeStr}
this.$loading()
this.previewFile({ ...fileInfo }).then(()=>{
this.$hideLoading()
})
},
openLink(row) {
window.open(row.linkUrl);
},
openApp(row) {
uni.navigateToMiniProgram({
// appId: row.goodsJdAppid,
// path: row.goodsJdUrl
})
},
openUser(type, userid) { //缺少名片人员区分内部还是外部
console.log(row)
// userid && this.injectJWeixin('openUserProfile').then(() => {
// this.wxInvoke(['openUserProfile', {type, userid}, () => 0])
// })
},
openMap(row) {
wx.openLocation({
latitude: row.lat, // 纬度浮点数范围为90 ~ -90
longitude: row.lng, // 经度浮点数范围为180 ~ -180。
name: row.title, // 位置名
address: row.address, // 地址详情说明
scale: row.zoom, // 地图缩放级别,整形值,范围从1~28。默认为16
fail: () => {
location.reload()
}
});
}
},
onReachBottom() {
if(this.preCurrent > 1) {
this.preCurrent --
this.getListPre()
}
}
};
</script>
<style lang="scss" scoped>
.conversationRecord {
height: 100%;
::v-deep .AiTopFixed {
.placeholder {
.content {
padding: 0 !important;
}
}
.fixed {
margin: 0 !important;
.content {
padding: 0 !important;
}
}
}
.top-search {
padding: 20px 32px;
display: flex;
.left {
width: 400px;
.clear-btn {
display: inline-block;
padding: 0 16px;
}
.del-icon {
width: 32px;
height: 32px;
vertical-align: middle;
}
div {
display: inline-block;
line-height: 64px;
}
}
.right {
width: calc(100% - 400px);
}
}
.conversation-list {
padding: 48px 32px;
// background-color: #EBECF0;
.item {
margin-bottom: 48px;
display: flex;
position: relative;
.user-name {
position: absolute;
top: 0;
left: 24px;
font-family: PingFangSC-Regular;
font-size: 22px;
color: #666;
padding:0 0 0 64px;
span {
display: inline-block;
margin: 0 12px;
font-family: PingFangSC-Regular;
font-size: 20px;
color: #999;
}
}
.user-img {
width: 72px;
height: 72px;
margin-right: 20px;
border-radius: 50%;
}
.content {
max-width: calc(100% - 144px);
position: relative;
margin-top: 44px;
.cir {
width: 0px;
height: 0px;
border: 10px solid transparent;
position: absolute;
top: 20px;
}
.content-text {
display: inline-block;
padding: 14px 54px 14px 32px;
width: 100%;
background-color: #fff;
font-family: PingFangSC-Regular;
font-size: 32px;
color: #333;
word-break: break-all;
box-sizing: border-box;
}
}
.fail-img {
width: 32px;
height: 32px;
padding-top: 44px;
margin: auto 0 auto 24px;
}
.img-list {
img {
max-width: 400px;
margin: 0 16px 16px 0;
}
}
::v-deep .uni-audio-default {
height: 72px;
width: 280px!important;
min-width: 0!important;
}
::v-deep .uni-audio-left {
height: 72px;
width: 72px;
.uni-audio-button {
margin: 14px;
}
}
::v-deep .uni-audio-right {
height: 72px;
margin-left: 72px;
padding: 10px 32px 10px 0;
}
.revoke-text {
line-height: 54px;
padding: 0 24px;
border-radius: 8px;
background-color: #EEE;
color: #999;
margin-top: 16px;
}
.file {
height: 128px;
background: #FFFFFF;
border-radius: 8px;
border: 1px solid #CCCCCC;
box-sizing: border-box;
padding: 0 16px;
margin-bottom: 32px;
& > .u-row {
height: 100%;
.left {
width: 522px;
display: flex;
align-items: center;
& > img {
width: 96px;
height: 96px;
}
& > span {
font-size: 32px;
color: #333333;
display: inline-block;
line-height: 44px;
text-overflow: ellipsis;
overflow-x: hidden;
white-space: nowrap;
}
}
& > span {
font-size: 28px;
color: #999;
margin: -8px 0 0 16px;
}
}
}
.card-info {
width: 450px;
background: #FFF;
.top {
padding: 16px 32px;
display: flex;
.card-left {
width: calc(100% - 120px);
h3 {
font-family: PingFangSC-Regular;
font-size: 32px;
color: #333;
line-height: 44px;
margin-bottom: 30px;
}
p {
font-family: PingFangSC-SNaNpxibold;
font-size: 32px;
color: #333;
line-height: 44px;
}
div {
font-family: PingFangSC-Regular;
font-size: 24px;
color: #999;
line-height: 34px;
}
.display-name {
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: 24px;
color: #999;
line-height: 34px;
margin-bottom: 10px;
}
}
.card-right {
img {
width: 84px;
height: 84px;
}
}
}
.bottom {
padding-left: 32px;
line-height: 48px;
font-family: PingFangSC-Regular;
font-size: 22px;
color: #999;
border-top: 1px solid #eee;
img {
width: 20px;
height: 20px;
margin-right: 8px;
}
}
}
.map-info {
width: 560px;
height: 400px;
.address-text {
position: absolute;
bottom: 0;
left: 0;
width: 560px;
background-color: rgba(0, 0, 0, .7);
p {
color: #fff;
line-height: 44px;
font-size: 24px;
padding-left: 32px;
word-break: break-all;
}
}
}
}
.item-left {
.content {
.cir {
left: -18px;
border-right-color: #fff;
}
}
}
.item-right {
width: 100%;
justify-content: right;
.user-name {
left: 0;
right: 82px;
text-align: right;
}
.user-img {
margin: 0 0 0 20px;
}
.content {
.cir {
border-left-color: #C7E7FE;
right: -18px;
}
.content-text {
background-color: #C7E7FE;
padding: 14px 32px 14px 54px;
}
.img-list {
img {
max-width: 400px;
margin: 0 0 16px 16px;
}
}
}
.fail-img {
margin: auto 24px auto 0;
}
}
}
}
</style>

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 830 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 757 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 814 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 793 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

View File

@@ -112,7 +112,7 @@ export default {
submit() { //status 1 2 3
var url = '', successText = '', params = ''
if (this.status == 1) {
url = `/app/appclapeventinfo/transfer`
url = `/app/appsessionarchivereportinfo/transfer`
successText = '转交成功'
params = {
...this.forms,
@@ -126,14 +126,14 @@ export default {
}
}
if (this.status == 2) {
url = `/app/appclapeventinfo/refuse`
url = `/app/appsessionarchivereportinfo/finish`
successText = '拒绝成功'
params = {...this.forms}
params = {...this.forms, eventStatus: 3}
}
if (this.status == 3) {
url = `/app/appclapeventinfo/finishByGirdMember`
url = `/app/appsessionarchivereportinfo/finish`
successText = '办结成功'
params = {...this.forms}
params = {...this.forms, eventStatus: 2}
}
params.id = this.id
this.$http.post(url, params).then((res) => {

View File

@@ -20,10 +20,10 @@
<span class="card-right">{{ data.groupName }}</span>
</div>
<div class="card">
<!-- <div class="card">
<span class="card-left">所属网格</span>
<span class="card-right">{{ data.girdName }}</span>
</div>
</div> -->
<div class="card">
<span class="card-left">联系方式</span>
@@ -92,12 +92,12 @@
<div class="fixedBtn">
<div class="status00" v-if="data.eventStatus == 0">
<div class="columns border-r" @click="toContent(1)">
<!-- <img src="./components/img/zhuanjiao.png" alt="" /> -->
<img src="./components/img/zhuanjiao.png" alt="" />
<span class="hint">转交事件</span>
</div>
<div class="columns" @click="toContent(2)">
<!-- <img src="./components/img/jujue.png" alt="" /> -->
<img src="./components/img/jujue.png" alt="" />
<span class="hint">拒绝受理</span>
</div>
@@ -164,11 +164,11 @@ export default {
})
},
onShow() {
document.title = this.user.corpId == 'wpytYEDgAACQq2uZ5x54MvlJ9fgvSPXQ' ? '微心愿' : '随手拍'
document.title = '工单详情'
},
methods: {
getDetail() {
this.$http.post(`/app/appclapeventinfo/queryDetailById?id=${this.id}`).then((res) => {
this.$http.post(`/app/appsessionarchivereportinfo/queryDetailById?id=${this.id}`).then((res) => {
if (res?.data) {
this.data = res.data
}
@@ -180,7 +180,7 @@ export default {
},
doThings() {
this.$http.post(`/app/appclapeventinfo/acceptance?id=${this.id}`).then((res) => {
this.$http.post(`/app/appsessionarchivereportinfo/finish?id=${this.id}&eventStatus=1`).then((res) => {
if (res.code == 0) {
this.getDetail()
}

View File

Before

Width:  |  Height:  |  Size: 623 B

After

Width:  |  Height:  |  Size: 623 B

View File

Before

Width:  |  Height:  |  Size: 810 B

After

Width:  |  Height:  |  Size: 810 B

View File

Before

Width:  |  Height:  |  Size: 815 B

After

Width:  |  Height:  |  Size: 815 B

View File

Before

Width:  |  Height:  |  Size: 3.2 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

View File

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

View File

Before

Width:  |  Height:  |  Size: 2.6 KiB

After

Width:  |  Height:  |  Size: 2.6 KiB

View File

Before

Width:  |  Height:  |  Size: 314 B

After

Width:  |  Height:  |  Size: 314 B

View File

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 21 KiB

After

Width:  |  Height:  |  Size: 21 KiB

View File

Before

Width:  |  Height:  |  Size: 803 B

After

Width:  |  Height:  |  Size: 803 B

View File

Before

Width:  |  Height:  |  Size: 373 B

After

Width:  |  Height:  |  Size: 373 B

View File

Before

Width:  |  Height:  |  Size: 766 B

After

Width:  |  Height:  |  Size: 766 B

View File

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

View File

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

Before

Width:  |  Height:  |  Size: 88 KiB

After

Width:  |  Height:  |  Size: 88 KiB