2025-02-19 09:34:34 +08:00
|
|
|
<template>
|
2025-04-03 11:12:42 +08:00
|
|
|
<page-meta :page-font-size="fontValue+'px'" :root-font-size="fontValue+'px'"></page-meta>
|
|
|
|
|
<view class="message-page">
|
|
|
|
|
<!-- 列表 -->
|
|
|
|
|
<scroll-view style="width: 100%;height: 92vh;" @scrolltolower="onScrollTolower" scroll-y="true">
|
|
|
|
|
<view class="message-item" v-for="(item, index) in messageList" :key="index">
|
|
|
|
|
<!-- 左侧图标 -->
|
|
|
|
|
<view class="icon-wrapper" style="background-color: #b5bec9;">
|
|
|
|
|
<u-icon name="email" color="#fff" size="24"></u-icon>
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 消息内容 -->
|
|
|
|
|
<view class="content">
|
|
|
|
|
<view class="title-box">
|
|
|
|
|
<view class="title">{{item.custName}}</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="desc">{{ item.content }}</view>
|
2025-04-14 17:39:27 +08:00
|
|
|
<view class="img-box">
|
|
|
|
|
<view style="width: 110rpx;height: 110rpx;margin-right: 20rpx;" v-for="(imgItem,imgIndex) in item.complaintPictureList" :key="imgIndex">
|
|
|
|
|
<image :src="imgItem" mode="" style="width: 100rpx;height: 100rpx;" @click="opePopup(imgItem)"></image>
|
2025-04-03 11:12:42 +08:00
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="time">{{ item.crtime }}</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</scroll-view>
|
2025-04-14 17:39:27 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
<u-popup :show="showPic" mode="center" @close="showPic=false">
|
|
|
|
|
<image :src="imagerUrl" mode="aspectFit" style="height: 100vh;width: 100vw;" @click="showPic=false"></image>
|
|
|
|
|
</u-popup>
|
2025-04-03 11:12:42 +08:00
|
|
|
</view>
|
2025-02-19 09:34:34 +08:00
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
// import UTabs from '../../../uni_modules/uview-ui/components/u-tabs/u-tabs.vue'
|
|
|
|
|
// import Tabs from '../../components/Tabs.vue'
|
|
|
|
|
// import UIcon from '../../../uni_modules/uview-ui/components/u-icon/u-icon.vue'
|
2025-04-27 15:58:51 +08:00
|
|
|
|
2025-02-19 09:34:34 +08:00
|
|
|
import { getqueryPlaintApi } from '@/api/mine/index'
|
|
|
|
|
export default {
|
|
|
|
|
name: 'index',
|
|
|
|
|
// components: { UIcon, Tabs, UTabs },
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
2025-04-27 15:58:51 +08:00
|
|
|
fontValue:uni.getStorageSync('fontSize') || 8,
|
2025-02-19 09:34:34 +08:00
|
|
|
searchText: '',
|
|
|
|
|
currentTab: 0,
|
|
|
|
|
// tabList: ['全部', '已查看', '未查看'],
|
|
|
|
|
tabList: ['通知列表'],
|
|
|
|
|
pageNum: 1,
|
|
|
|
|
pageSize: 10,
|
|
|
|
|
total: 0,
|
|
|
|
|
messageList: [],
|
2025-04-14 17:39:27 +08:00
|
|
|
messageNumber:0,
|
|
|
|
|
showPic:false,
|
|
|
|
|
imagerUrl:""
|
2025-02-19 09:34:34 +08:00
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
onLoad(){
|
|
|
|
|
this.getNoticeList()
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
// 翻页
|
|
|
|
|
onScrollTolower(){
|
|
|
|
|
console.log(this.messageList.length)
|
|
|
|
|
// if(this.total>this.messageList.length){
|
|
|
|
|
// this.pageNum++
|
|
|
|
|
// this.getNoticeList()
|
|
|
|
|
// }
|
|
|
|
|
},
|
2025-04-14 17:39:27 +08:00
|
|
|
//获取通知消息
|
|
|
|
|
async getNoticeList() {
|
|
|
|
|
let param = {
|
|
|
|
|
// "current": this.pageNum,
|
|
|
|
|
// "size": this.pageSize,
|
2025-04-27 15:58:51 +08:00
|
|
|
// "custId": uni.getStorageSync('custId'),
|
2025-04-14 17:39:27 +08:00
|
|
|
}
|
|
|
|
|
const res = await getqueryPlaintApi(param)
|
|
|
|
|
console.log(res)
|
|
|
|
|
this.messageList = res
|
|
|
|
|
// this.total = res.total;
|
|
|
|
|
// if(this.pageNum==1){
|
|
|
|
|
// this.messageList = res.records
|
|
|
|
|
// }else{
|
|
|
|
|
// this.messageList.push(...res.records)
|
|
|
|
|
// }
|
|
|
|
|
},
|
|
|
|
|
handleTabChange(index) {
|
|
|
|
|
console.log('?? ~ changeTab ~ index:', index)
|
|
|
|
|
this.currentTab = index
|
|
|
|
|
},
|
|
|
|
|
opePopup(item){
|
|
|
|
|
this.imagerUrl = item;
|
|
|
|
|
this.showPic = true
|
|
|
|
|
}
|
|
|
|
|
}
|
2025-02-19 09:34:34 +08:00
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style scoped lang="scss">
|
|
|
|
|
page {
|
|
|
|
|
background: #fff;
|
|
|
|
|
}
|
|
|
|
|
.message-page {
|
2025-06-17 16:19:23 +08:00
|
|
|
height: 96vh;
|
|
|
|
|
overflow-y: auto;
|
2025-02-19 09:34:34 +08:00
|
|
|
background-color: #f5f5f5;
|
|
|
|
|
background: #fff;
|
|
|
|
|
padding: 12px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.message-list {
|
|
|
|
|
padding: 12px 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.message-item {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: flex-start;
|
|
|
|
|
background-color: #ffffff;
|
|
|
|
|
padding: 16px;
|
|
|
|
|
margin-bottom: 12px;
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.icon-wrapper {
|
|
|
|
|
width: 30px;
|
|
|
|
|
height: 30px;
|
|
|
|
|
border-radius: 50%;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: center;
|
|
|
|
|
margin-right: 12px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.upgrade {
|
|
|
|
|
background-color: #2ed573;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.warning {
|
|
|
|
|
background-color: #ff7f50;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.read {
|
|
|
|
|
background-color: #b5bec9;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.content {
|
|
|
|
|
flex: 1;
|
|
|
|
|
margin-right: 12px;
|
|
|
|
|
}
|
|
|
|
|
.title-box{
|
|
|
|
|
width: 100%;
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
align-items: center;
|
|
|
|
|
}
|
|
|
|
|
.title {
|
2025-04-03 11:12:42 +08:00
|
|
|
font-size: 32rpx;
|
2025-02-19 09:34:34 +08:00
|
|
|
font-weight: bold;
|
|
|
|
|
color: #333;
|
|
|
|
|
margin-bottom: 4px;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.desc {
|
2025-04-03 11:12:42 +08:00
|
|
|
font-size: 26rpx;
|
2025-02-19 09:34:34 +08:00
|
|
|
color: #666;
|
|
|
|
|
// padding: ;
|
|
|
|
|
}
|
|
|
|
|
.img-box{
|
|
|
|
|
width: 94%;
|
|
|
|
|
margin: 10px auto;
|
|
|
|
|
display: flex;
|
2025-04-14 17:39:27 +08:00
|
|
|
align-items: center;
|
2025-02-19 09:34:34 +08:00
|
|
|
height: auto;
|
|
|
|
|
margin-bottom: 10px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.right-info {
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-direction: column;
|
|
|
|
|
align-items: flex-end;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.time {
|
2025-04-03 11:12:42 +08:00
|
|
|
font-size: 24rpx;
|
2025-02-19 09:34:34 +08:00
|
|
|
color: #999;
|
|
|
|
|
margin-bottom: 4px;
|
|
|
|
|
margin-top: 10px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.unread-dot {
|
|
|
|
|
width: 8px;
|
|
|
|
|
height: 8px;
|
|
|
|
|
border-radius: 50%;
|
|
|
|
|
background-color: #ff0000;
|
|
|
|
|
}
|
|
|
|
|
</style>
|