|
@@ -9,23 +9,24 @@
|
|
|
|
|
|
<template>
|
|
|
<div class="visual-con hz_body">
|
|
|
+ <router-view ref="senEventCenter"></router-view>
|
|
|
<div class="s_header">
|
|
|
<div class="head_btn">
|
|
|
- <div @click="jumpTo('/SentryCockpit',0)" :class="routerIdx == 0 ? 'on' : ''">
|
|
|
- <i>驾驶舱</i>
|
|
|
- </div>
|
|
|
- <div @click="jumpTo('/SenEquipmentCenter',1)" :class="routerIdx == 1 ? 'on' : ''">
|
|
|
- <i>设备中心</i>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="header_tit"><i>{{title}}</i></div>
|
|
|
- <div class="head_btn">
|
|
|
- <div @click="jumpTo('/SenEventCenter',2)" :class="routerIdx == 2 ? 'on' : ''">
|
|
|
- <i>事件中心</i>
|
|
|
- </div>
|
|
|
- <div @click="jumpTo('/useCenter',3)" :class="routerIdx == 3 ? 'on' : ''">
|
|
|
- <i>用户中心</i>
|
|
|
- </div>
|
|
|
+ <div @click="jumpTo('/SentryCockpit',0)" :class="routerIdx == 0 ? 'on' : ''">
|
|
|
+ <i>驾驶舱</i>
|
|
|
+ </div>
|
|
|
+ <div @click="jumpTo('/SenEquipmentCenter',1)" :class="routerIdx == 1 ? 'on' : ''">
|
|
|
+ <i>设备中心</i>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="header_tit"><i>{{title}}</i></div>
|
|
|
+ <div class="head_btn">
|
|
|
+ <div @click="jumpTo('/SenEventCenter',2)" :class="routerIdx == 2 ? 'on' : ''">
|
|
|
+ <i>事件中心</i>
|
|
|
+ </div>
|
|
|
+ <div @click="jumpTo('/useCenter',3)" :class="routerIdx == 3 ? 'on' : ''">
|
|
|
+ <i>用户中心</i>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<div class="head_tx">
|
|
|
<span><img src="../assets/images/sentinel/hz_tx.png" /></span>
|
|
@@ -72,7 +73,23 @@
|
|
|
<p>所在街道:无</p>
|
|
|
<p>事件坐标:{{eventDetails.longitude}};{{eventDetails.latitude}}</p>
|
|
|
<p>所属部门:无</p>
|
|
|
- <p>处理流程:<a @click="dialogVisible = true">详情</a></p>
|
|
|
+<!-- <p>处理流程:<a @click="dialogVisible = true">详情</a></p>-->
|
|
|
+ <p>处理流程:<a @click="ceshi">详情</a></p>
|
|
|
+ <button v-if="eventDetails.eventStatus=='event_confirmation'" @click="eventSignature(eventDetails)">签收</button>
|
|
|
+ <button v-if="eventDetails.eventStatus=='event_signature'" @click="configDept(eventDetails)">联动</button>
|
|
|
+ <button v-if="eventDetails.eventStatus=='event_signature'" @click="eventCompletion(eventDetails)">办结</button>
|
|
|
+ <button v-if="eventDetails.eventStatus=='event_completion'" @click="eventReview(eventDetails)">审核</button>
|
|
|
+ <button v-if="eventDetails.eventStatus=='event_archiving'" @click="eventArchiving(eventDetails)">归档</button>
|
|
|
+ <el-tree class="tree-border tree_scroll" style="height: 20vh; overflow-y:scroll" :data="deptOptionsLiandong" v-if="eventDetails.eventStatus=='event_confirmation'||eventDetails.eventStatus=='event_signature'"
|
|
|
+ show-checkbox ref="LiandongDept" node-key="id" :check-strictly="true"
|
|
|
+ :accordion="true" empty-text="加载中,请稍候" :props="defaultProps"></el-tree>
|
|
|
+ <div v-if="eventDetails.eventStatus=='event_completion'">
|
|
|
+ <el-radio-group v-model="reviewStatus" v-for="(item,idx) in reviewStatusList">
|
|
|
+ <el-radio :label="item.value" :name="item.value">{{ item.name }}</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
+ </div>
|
|
|
+ <textarea v-model="reviewDescription"> </textarea>
|
|
|
+ <button @click="addEventLogDescription(eventDetails)">发送</button>
|
|
|
</div>
|
|
|
</div>
|
|
|
<!--弹框 开始-->
|
|
@@ -174,11 +191,28 @@
|
|
|
selectByDeviceId,selectDailyThreshold
|
|
|
} from "@/api/sentinel"
|
|
|
let echarts = require("echarts");
|
|
|
- import {getEventList, getEventLog} from "@/api/event";
|
|
|
+ import {
|
|
|
+ addEventLogDescription,
|
|
|
+ getDescriptionById,
|
|
|
+ getEventLog,
|
|
|
+ eventSignature,
|
|
|
+ eventCompletion,
|
|
|
+ eventReview,
|
|
|
+ eventArchiving,
|
|
|
+ configDept
|
|
|
+ } from "@/api/event";
|
|
|
+ import {
|
|
|
+ treeselectAll
|
|
|
+ } from '@/api/system/dept'
|
|
|
export default {
|
|
|
name: 'MyChart',
|
|
|
components: {
|
|
|
- supermap
|
|
|
+ supermap,
|
|
|
+ },
|
|
|
+ watch: {
|
|
|
+ filterText(val) {
|
|
|
+ this.$refs.LiandongDept.filter(val)
|
|
|
+ }
|
|
|
},
|
|
|
metaInfo() {
|
|
|
return {
|
|
@@ -205,14 +239,27 @@
|
|
|
eventDetails:{}, // 事件详情信息
|
|
|
dialogVisible: false, // 事件日志显隐框
|
|
|
activities:[], // 事件日志信息
|
|
|
+
|
|
|
+ deptOptionsLiandong: [], //联动部门
|
|
|
+ defaultProps: {
|
|
|
+ children: "children",
|
|
|
+ label: "label",
|
|
|
+ },
|
|
|
+
|
|
|
+ reviewStatus:true,
|
|
|
+ reviewStatusList:[
|
|
|
+ {name:'通过',value:true},
|
|
|
+ {name:'不通过',value:false},
|
|
|
+ ],
|
|
|
+ reviewDescription:'',
|
|
|
}
|
|
|
},
|
|
|
created() {
|
|
|
-
|
|
|
+ this.getDeptTreeselect();
|
|
|
},
|
|
|
mounted() {
|
|
|
- // 初始定向到驾驶舱
|
|
|
- this.$router.push({
|
|
|
+ // 初始定向到驾驶舱
|
|
|
+ this.$router.push({
|
|
|
path:'/SentryCockpit'
|
|
|
})
|
|
|
// 初始化地图数据
|
|
@@ -447,6 +494,114 @@
|
|
|
handleClose(done) {
|
|
|
done();
|
|
|
},
|
|
|
+ getDescriptionById(eventId){
|
|
|
+ getDescriptionById(eventId).then(req => {
|
|
|
+ this.eventDetails = req.data;
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 添加日志信息
|
|
|
+ addEventLogDescription(params){
|
|
|
+ addEventLogDescription({eventId:params.eventId,reviewDescription:this.reviewDescription}).then(req => {
|
|
|
+ if(req.code == 200){
|
|
|
+ this.$modal.msgSuccess('保存成功');
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+
|
|
|
+ // 获取部门列表树
|
|
|
+ getDeptTreeselect(){
|
|
|
+ treeselectAll().then((response) => {
|
|
|
+ let deptId=Cookies.get("deptId")
|
|
|
+ this.recursiveChildren(response.data,deptId)
|
|
|
+ this.deptOptionsLiandong = response.data;
|
|
|
+ });
|
|
|
+ },
|
|
|
+ //设置联动部门不可选择本部门
|
|
|
+ recursiveChildren(arrayList,deptId) {
|
|
|
+ arrayList.forEach((item, index) => {
|
|
|
+ if(item.id==deptId){
|
|
|
+ item.disabled="true";
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if(item.children){
|
|
|
+ this.recursiveChildren(item.children,deptId)
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
+ // 签收
|
|
|
+ eventSignature(params){
|
|
|
+ const qsParams = {};
|
|
|
+ const deptList = [];
|
|
|
+ let array = this.$refs.LiandongDept.getCheckedNodes();
|
|
|
+ if(array!=null && array.length!=0){
|
|
|
+ for(let item of array){
|
|
|
+ deptList.push({mapDeptId:item.id,mapDeptName:item.label});
|
|
|
+ }
|
|
|
+ qsParams.deptList = deptList;
|
|
|
+ }
|
|
|
+ qsParams.eventId = params.eventId;
|
|
|
+ eventSignature(qsParams).then(req => {
|
|
|
+ if(req.code == 200){
|
|
|
+ this.$modal.msgSuccess( '签收成功')
|
|
|
+ this.getDescriptionById(params.eventId);
|
|
|
+ this.$refs.senEventCenter.getSupermapEvent();
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 联动
|
|
|
+ configDept(params){
|
|
|
+ const qsParams = {};
|
|
|
+ const deptList = [];
|
|
|
+ let array = this.$refs.LiandongDept.getCheckedNodes();
|
|
|
+ if(array!=null && array.length!=0){
|
|
|
+ for(let item of array){
|
|
|
+ deptList.push({mapDeptId:item.id,mapDeptName:item.label});
|
|
|
+ }
|
|
|
+ qsParams.deptList = deptList;
|
|
|
+ }
|
|
|
+ qsParams.eventId = params.eventId;
|
|
|
+ configDept(qsParams).then(req => {
|
|
|
+ if(req.code == 200){
|
|
|
+ this.$modal.msgSuccess( '签收成功')
|
|
|
+ this.getDescriptionById(params.eventId);
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 办结
|
|
|
+ eventCompletion(eventDetails){
|
|
|
+ eventCompletion(eventDetails.eventId).then(req => {
|
|
|
+ if(req.code == 200){
|
|
|
+ this.$modal.msgSuccess( '办结成功')
|
|
|
+ this.getDescriptionById(eventDetails.eventId);
|
|
|
+ this.$refs.senEventCenter.getSupermapEvent();
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 审核
|
|
|
+ eventReview(eventDetails){
|
|
|
+ if(!this.reviewStatus&&this.reviewDescription==''){
|
|
|
+ this.$modal.loading( '请填写不通过审核意见!!!')
|
|
|
+ }
|
|
|
+ const param = {eventId:eventDetails.eventId,reviewStatus:this.reviewStatus,reviewDescription:this.reviewDescription}
|
|
|
+ eventReview(param).then(req => {
|
|
|
+ if(req.code == 200){
|
|
|
+ this.$modal.msgSuccess( '审核操作成功')
|
|
|
+ this.getDescriptionById(eventDetails.eventId);
|
|
|
+ this.$refs.senEventCenter.getSupermapEvent();
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 归档
|
|
|
+ eventArchiving(params){
|
|
|
+ eventArchiving(params.eventId).then(req => {
|
|
|
+ if(req.code == 200){
|
|
|
+ this.$modal.msgSuccess( '归档成功')
|
|
|
+ this.getDescriptionById(params.eventId);
|
|
|
+ this.$refs.senEventCenter.getSupermapEvent();
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
}
|
|
|
}
|
|
|
</script>
|