1231233
This commit is contained in:
@@ -13,3 +13,10 @@ export function getUnreadNotifyMessageCount() {
|
|||||||
method: 'get'
|
method: 'get'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function getCheckNotice() {
|
||||||
|
return request({
|
||||||
|
url: '/cai/unread/checkNotice',
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@@ -35,10 +35,19 @@ export function updateNotice(data) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 修改公告
|
||||||
|
export function dealNotice(data) {
|
||||||
|
return request({
|
||||||
|
url: '/system/notice/deal',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
// 删除公告
|
// 删除公告
|
||||||
export function delNotice(noticeId) {
|
export function delNotice(noticeId) {
|
||||||
return request({
|
return request({
|
||||||
url: '/system/notice/' + noticeId,
|
url: '/system/notice/' + noticeId,
|
||||||
method: 'delete'
|
method: 'delete'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
186
src/layout/components/CaiNotice/index.vue
Normal file
186
src/layout/components/CaiNotice/index.vue
Normal file
@@ -0,0 +1,186 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<el-popover placement="bottom" width="200" trigger="click">
|
||||||
|
<!-- icon 展示 -->
|
||||||
|
<el-badge slot="reference" :is-dot="unreadCount > 0" type="danger">
|
||||||
|
<svg-icon icon-class="message" @click="getList"/>
|
||||||
|
</el-badge>
|
||||||
|
<!-- 弹出列表 -->
|
||||||
|
<el-empty v-if="unreadAllCount === 0" description="所有数据已审核"></el-empty>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.accountCashCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('accountCash')" type="warning">提现待审核</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>w
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.accountCashCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.userAlbumCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('userAlbum')" type="warning">相册待审核</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.userAlbumCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.userCameraAuditCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('userCameraAudit')" type="warning">自拍待审核</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.userCameraAuditCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.anchorApplyCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('anchorApply')" type="warning">主播申请待审核</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.anchorApplyCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.dynamicCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('dynamic')" type="warning">动态待审核</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.dynamicCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.reportCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('report')" type="warning">举报待处理</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.reportCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.userGreetCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('userGreet')" type="warning">群发待审核</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.userGreetCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row class="message-fid" v-show="unreadInfo.userAvatarCount > 0">
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-link @click="goToAudit('userAvatar')" type="warning">头像待审核</el-link>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-divider direction="vertical"></el-divider>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6"><span style="color: red">{{ unreadInfo.userAvatarCount }}</span></el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-popover>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
|
||||||
|
import {getUnreadNotifyMessageCount, getUnreadNotifyMessageList} from "@/api/cai/unreadNotifyMessage";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'NotifyMessage',
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
// 遮罩层
|
||||||
|
loading: false,
|
||||||
|
// 列表
|
||||||
|
unreadInfo: {
|
||||||
|
accountCashCount: 0,
|
||||||
|
userAlbumCount: 0,
|
||||||
|
userCameraAuditCount: 0,
|
||||||
|
anchorApplyCount: 0,
|
||||||
|
dynamicCount: 0,
|
||||||
|
reportCount: 0,
|
||||||
|
userGreetCount: 0,
|
||||||
|
userAvatarCount: 0,
|
||||||
|
},
|
||||||
|
unreadAllCount: 0,
|
||||||
|
unreadCount: 1,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
// 首次加载小红点
|
||||||
|
this.getUnreadCount()
|
||||||
|
// 轮询刷新小红点
|
||||||
|
setInterval(() => {
|
||||||
|
this.$notify.error({
|
||||||
|
title: '告警',
|
||||||
|
message: '检测到有支付错误告警,请及时检测并解决',
|
||||||
|
duration: 0
|
||||||
|
});
|
||||||
|
this.getUnreadCount()
|
||||||
|
}, 1000 * 60)
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
getList: function () {
|
||||||
|
this.loading = true;
|
||||||
|
getUnreadNotifyMessageList().then(response => {
|
||||||
|
this.unreadInfo = response.data;
|
||||||
|
let allNum = 0;
|
||||||
|
for (const i in this.unreadInfo){
|
||||||
|
let val = this.unreadInfo[i]
|
||||||
|
if(val){
|
||||||
|
allNum = allNum + val
|
||||||
|
}
|
||||||
|
}
|
||||||
|
this.unreadAllCount = allNum
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
getUnreadCount: function () {
|
||||||
|
getUnreadNotifyMessageCount().then(response => {
|
||||||
|
this.unreadCount = response.data;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
goToAudit: function (type) {
|
||||||
|
switch (type) {
|
||||||
|
case "accountCash":
|
||||||
|
this.$router.push({path: "/audit/accountCash", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
case "userAlbum":
|
||||||
|
this.$router.push({path: "/kk/userAlbum", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
case "userCameraAudit":
|
||||||
|
this.$router.push({path: "/audit/userCameraAudit", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
case "anchorApply":
|
||||||
|
this.$router.push({path: "/kk/anchorApply", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
case "dynamic":
|
||||||
|
this.$router.push({path: "/audit/dynamic", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
case "report":
|
||||||
|
this.$router.push({path: "/audit/report", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
case "userGreet":
|
||||||
|
this.$router.push({path: "/audit/userGreet", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
case "userAvatar":
|
||||||
|
this.$router.push({path: "/audit/userPictureAudit", query: {auditStatus: true}});
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.el-badge__content.is-fixed {
|
||||||
|
top: 10px; /* 保证徽章的位置 */
|
||||||
|
}
|
||||||
|
|
||||||
|
.message-fid {
|
||||||
|
margin: 10px 0 10px 0;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -6,13 +6,15 @@
|
|||||||
<top-nav id="topmenu-container" class="topmenu-container" v-if="topNav"/>
|
<top-nav id="topmenu-container" class="topmenu-container" v-if="topNav"/>
|
||||||
|
|
||||||
<div class="right-menu">
|
<div class="right-menu">
|
||||||
|
|
||||||
<template v-if="device!=='mobile'">
|
<template v-if="device!=='mobile'">
|
||||||
|
|
||||||
|
<el-link class='right-menu-item' style="font-size: 14px; color: red" type="danger" @click="payNoticeGo">{{payNotice}}</el-link>
|
||||||
<search id="header-search" class="right-menu-item" />
|
<search id="header-search" class="right-menu-item" />
|
||||||
|
|
||||||
<el-tooltip content="待审核" effect="dark" placement="bottom">
|
<el-tooltip content="待审核" effect="dark" placement="bottom">
|
||||||
<notify-message class="right-menu-item hover-effect" />
|
<notify-message class="right-menu-item hover-effect" />
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
|
|
||||||
<screenfull id="screenfull" class="right-menu-item hover-effect" />
|
<screenfull id="screenfull" class="right-menu-item hover-effect" />
|
||||||
|
|
||||||
<el-tooltip content="布局大小" effect="dark" placement="bottom">
|
<el-tooltip content="布局大小" effect="dark" placement="bottom">
|
||||||
@@ -64,13 +66,14 @@ export default {
|
|||||||
Search,
|
Search,
|
||||||
RuoYiGit,
|
RuoYiGit,
|
||||||
RuoYiDoc,
|
RuoYiDoc,
|
||||||
NotifyMessage
|
NotifyMessage,
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters([
|
...mapGetters([
|
||||||
'sidebar',
|
'sidebar',
|
||||||
'avatar',
|
'avatar',
|
||||||
'device'
|
'device',
|
||||||
|
'payNotice'
|
||||||
]),
|
]),
|
||||||
setting: {
|
setting: {
|
||||||
get() {
|
get() {
|
||||||
@@ -89,7 +92,19 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
created() {
|
||||||
|
// 进入系统后立即启动定时任务
|
||||||
|
this.$store.dispatch('startPolling')
|
||||||
|
console.log(this.payNotice);
|
||||||
|
},
|
||||||
|
beforeDestroy() {
|
||||||
|
// 退出系统时关闭定时任务(可选)
|
||||||
|
this.$store.dispatch('stopPolling')
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
payNoticeGo(){
|
||||||
|
this.$router.push({path: "/system/notice", query: {auditStatus: true}});
|
||||||
|
},
|
||||||
toggleSideBar() {
|
toggleSideBar() {
|
||||||
this.$store.dispatch('app/toggleSideBar')
|
this.$store.dispatch('app/toggleSideBar')
|
||||||
},
|
},
|
||||||
@@ -151,7 +166,6 @@ export default {
|
|||||||
&:focus {
|
&:focus {
|
||||||
outline: none;
|
outline: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.right-menu-item {
|
.right-menu-item {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding: 0 8px;
|
padding: 0 8px;
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ const getters = {
|
|||||||
size: state => state.app.size,
|
size: state => state.app.size,
|
||||||
device: state => state.app.device,
|
device: state => state.app.device,
|
||||||
dict: state => state.dict.dict,
|
dict: state => state.dict.dict,
|
||||||
|
payNotice: state => state.user.payNotice,
|
||||||
visitedViews: state => state.tagsView.visitedViews,
|
visitedViews: state => state.tagsView.visitedViews,
|
||||||
cachedViews: state => state.tagsView.cachedViews,
|
cachedViews: state => state.tagsView.cachedViews,
|
||||||
token: state => state.user.token,
|
token: state => state.user.token,
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import { login, logout, getInfo } from '@/api/login'
|
import { login, logout, getInfo } from '@/api/login'
|
||||||
import { getToken, setToken, removeToken } from '@/utils/auth'
|
import { getToken, setToken, removeToken } from '@/utils/auth'
|
||||||
|
import {getCheckNotice} from "@/api/cai/unreadNotifyMessage";
|
||||||
|
|
||||||
const user = {
|
const user = {
|
||||||
state: {
|
state: {
|
||||||
@@ -8,11 +9,15 @@ const user = {
|
|||||||
name: '',
|
name: '',
|
||||||
avatar: '',
|
avatar: '',
|
||||||
filePrefix: '',
|
filePrefix: '',
|
||||||
|
payNotice: '',
|
||||||
roles: [],
|
roles: [],
|
||||||
permissions: []
|
permissions: []
|
||||||
},
|
},
|
||||||
|
|
||||||
mutations: {
|
mutations: {
|
||||||
|
SET_PAY_NOTICE: (state, payNotice) => {
|
||||||
|
state.payNotice = payNotice
|
||||||
|
},
|
||||||
SET_TOKEN: (state, token) => {
|
SET_TOKEN: (state, token) => {
|
||||||
state.token = token
|
state.token = token
|
||||||
},
|
},
|
||||||
@@ -39,6 +44,43 @@ const user = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
actions: {
|
actions: {
|
||||||
|
// 单次请求并更新数据
|
||||||
|
getNotice({ commit }) {
|
||||||
|
return new Promise((resolve, reject) => {
|
||||||
|
// 替换为你的实际接口请求
|
||||||
|
getCheckNotice()
|
||||||
|
.then(res => {
|
||||||
|
commit('SET_PAY_NOTICE', res.data)
|
||||||
|
resolve()
|
||||||
|
})
|
||||||
|
.catch(error => {
|
||||||
|
console.error('数据请求失败:', error)
|
||||||
|
reject(error)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 启动定时更新(每3秒一次)
|
||||||
|
startPolling({ dispatch }) {
|
||||||
|
// 先立即请求一次,避免等待3秒
|
||||||
|
dispatch('getNotice')
|
||||||
|
|
||||||
|
// 设置定时器,每3秒执行一次
|
||||||
|
const intervalId = setInterval(() => {
|
||||||
|
dispatch('getNotice')
|
||||||
|
}, 60000)
|
||||||
|
|
||||||
|
// 存储定时器ID,方便后续关闭(可选)
|
||||||
|
localStorage.setItem('pollingIntervalId', intervalId)
|
||||||
|
},
|
||||||
|
|
||||||
|
// 关闭定时更新(可选,如退出系统时)
|
||||||
|
stopPolling() {
|
||||||
|
const intervalId = localStorage.getItem('pollingIntervalId')
|
||||||
|
if (intervalId) {
|
||||||
|
clearInterval(intervalId)
|
||||||
|
localStorage.removeItem('pollingIntervalId')
|
||||||
|
}
|
||||||
|
},
|
||||||
// 登录
|
// 登录
|
||||||
Login({ commit }, userInfo) {
|
Login({ commit }, userInfo) {
|
||||||
const username = userInfo.username.trim()
|
const username = userInfo.username.trim()
|
||||||
|
|||||||
@@ -93,7 +93,7 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="性别" prop="gender">
|
<el-form-item label="性别" prop="gender">
|
||||||
<el-select v-model="form.gender" placeholder="请输入性别" size="small">
|
<el-select v-model="form.gender" placeholder="请输入性别" size="small">
|
||||||
<el-option key="1" value="2" label="女" />
|
<el-option key="1" value="1" label="女" />
|
||||||
<el-option key="2" value="2" label="男" />
|
<el-option key="2" value="2" label="男" />
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|||||||
@@ -36,6 +36,14 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="标识" prop="appid">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.appid"
|
||||||
|
placeholder="请输入标记"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="链路号" prop="traceId">
|
<el-form-item label="链路号" prop="traceId">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="queryParams.traceId"
|
v-model="queryParams.traceId"
|
||||||
@@ -199,7 +207,8 @@ export default {
|
|||||||
usercode: undefined,
|
usercode: undefined,
|
||||||
mobile: undefined,
|
mobile: undefined,
|
||||||
orderNo: undefined,
|
orderNo: undefined,
|
||||||
traceId: undefined
|
traceId: undefined,
|
||||||
|
appid: undefined
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -9,14 +9,6 @@
|
|||||||
@keyup.enter.native="handleQuery"
|
@keyup.enter.native="handleQuery"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="操作人员" prop="createBy">
|
|
||||||
<el-input
|
|
||||||
v-model="queryParams.createBy"
|
|
||||||
placeholder="请输入操作人员"
|
|
||||||
clearable
|
|
||||||
@keyup.enter.native="handleQuery"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="类型" prop="noticeType">
|
<el-form-item label="类型" prop="noticeType">
|
||||||
<el-select v-model="queryParams.noticeType" placeholder="公告类型" clearable>
|
<el-select v-model="queryParams.noticeType" placeholder="公告类型" clearable>
|
||||||
<el-option
|
<el-option
|
||||||
@@ -27,6 +19,16 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="状态" prop="status">
|
||||||
|
<el-select v-model="queryParams.status" placeholder="公告类型" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.sys_notice_status"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
@@ -34,7 +36,7 @@
|
|||||||
</el-form>
|
</el-form>
|
||||||
|
|
||||||
<el-row :gutter="10" class="mb8">
|
<el-row :gutter="10" class="mb8">
|
||||||
<el-col :span="1.5">
|
<!-- <el-col :span="1.5">
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
plain
|
plain
|
||||||
@@ -54,7 +56,7 @@
|
|||||||
@click="handleUpdate"
|
@click="handleUpdate"
|
||||||
v-hasPermi="['system:notice:edit']"
|
v-hasPermi="['system:notice:edit']"
|
||||||
>修改</el-button>
|
>修改</el-button>
|
||||||
</el-col>
|
</el-col>-->
|
||||||
<el-col :span="1.5">
|
<el-col :span="1.5">
|
||||||
<el-button
|
<el-button
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -71,7 +73,7 @@
|
|||||||
|
|
||||||
<el-table v-loading="loading" :data="noticeList" @selection-change="handleSelectionChange">
|
<el-table v-loading="loading" :data="noticeList" @selection-change="handleSelectionChange">
|
||||||
<el-table-column type="selection" width="55" align="center" />
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
<el-table-column label="序号" align="center" prop="noticeId" width="100" />
|
<!-- <el-table-column label="序号" align="center" prop="noticeId" width="100" />-->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="公告标题"
|
label="公告标题"
|
||||||
align="center"
|
align="center"
|
||||||
@@ -88,21 +90,27 @@
|
|||||||
<dict-tag :options="dict.type.sys_notice_status" :value="scope.row.status"/>
|
<dict-tag :options="dict.type.sys_notice_status" :value="scope.row.status"/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="创建者" align="center" prop="createBy" width="100" />
|
<!-- <el-table-column label="创建者" align="center" prop="createBy" width="100" />-->
|
||||||
<el-table-column label="创建时间" align="center" prop="createTime" width="100">
|
<el-table-column label="创建时间" align="center" prop="createTime" width="150" />
|
||||||
<template slot-scope="scope">
|
<el-table-column label="处理人" align="center" prop="dealBy" width="100" />
|
||||||
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
|
<el-table-column label="处理时间" align="center" prop="dealTime" width="150" />
|
||||||
</template>
|
<el-table-column label="备注" align="center" prop="remark" width="150" show-overflow-tooltip/>
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<!-- <el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="text"
|
type="text"
|
||||||
icon="el-icon-edit"
|
icon="el-icon-edit"
|
||||||
@click="handleUpdate(scope.row)"
|
@click="handleUpdate(scope.row)"
|
||||||
v-hasPermi="['system:notice:edit']"
|
v-hasPermi="['system:notice:edit']"
|
||||||
>修改</el-button>
|
>修改</el-button>-->
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-edit"
|
||||||
|
@click="handleDeal(scope.row)"
|
||||||
|
v-hasPermi="['system:notice:edit']"
|
||||||
|
>处理</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="text"
|
type="text"
|
||||||
@@ -170,7 +178,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { listNotice, getNotice, delNotice, addNotice, updateNotice } from "@/api/system/notice";
|
import {listNotice, getNotice, delNotice, addNotice, updateNotice, dealNotice} from "@/api/system/notice";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "Notice",
|
name: "Notice",
|
||||||
@@ -277,6 +285,23 @@ export default {
|
|||||||
this.title = "修改公告";
|
this.title = "修改公告";
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
/** 修改按钮操作 */
|
||||||
|
handleDeal(row) {
|
||||||
|
this.$prompt('请输入处理备注', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
}).then(({ value }) => {
|
||||||
|
dealNotice({
|
||||||
|
noticeId: row.noticeId,
|
||||||
|
remark: value
|
||||||
|
}).then(response => {
|
||||||
|
this.$modal.msgSuccess("处理成功");
|
||||||
|
this.open = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
}).catch(() => {
|
||||||
|
});
|
||||||
|
},
|
||||||
/** 提交按钮 */
|
/** 提交按钮 */
|
||||||
submitForm: function() {
|
submitForm: function() {
|
||||||
this.$refs["form"].validate(valid => {
|
this.$refs["form"].validate(valid => {
|
||||||
@@ -309,4 +334,4 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user