Browse Source

事件管理

shibei_master
jiangyy 3 years ago
parent
commit
21d240a79d
  1. 6
      src/views/modules/shequzhili/event/cpts/event-detail.vue
  2. 277
      src/views/modules/shequzhili/event/cpts/event-info.vue
  3. 38
      src/views/modules/shequzhili/event/cpts/process-form-demand.vue
  4. 20
      src/views/modules/shequzhili/event/cpts/process-form-project.vue
  5. 5
      src/views/modules/shequzhili/event/cpts/process-form.vue
  6. 10
      src/views/modules/shequzhili/event/eventList.vue

6
src/views/modules/shequzhili/event/cpts/event-detail.vue

@ -24,7 +24,7 @@
v-for="src in info.imageList"
@click="watchImg(src)" />
</div>
<div v-if="info.voiceList.length>0"
<div v-if="info.voiceList&&info.voiceList.length>0"
class="info-prop">
<span class="info-title-2">语音</span>
<audio controls>
@ -96,7 +96,9 @@ export default {
computed: {},
watch: {},
watch: {
},
mounted () {
this.getApiData();

277
src/views/modules/shequzhili/event/cpts/event-info.vue

@ -1,4 +1,4 @@
h3<template>
<template>
<div class="">
<div v-if="pageType == 'add'">
<el-card>
@ -9,43 +9,47 @@ h3<template>
@changeUserId="changeUserId"></event-add>
</el-card>
</div>
<div v-if="pageType == 'add'"
class="process-form">
<el-card>
<h3>处理</h3>
<process-form ref="ref_processinfo"
:demandUserId="demandUserId"
:demandUserName="demandUserName"
:demandUserMobile="demandUserMobile"></process-form>
<div class="div-btn ">
<el-button size="small"
@click="handleClose">关闭</el-button>
<el-button style="margin-left:20px"
type="primary"
size="small"
@click="handleComfirm">确定</el-button>
</div>
</el-card>
<div class="process-form">
<el-card>
<h3>处理</h3>
<process-form ref="ref_processinfo_add"
:demandUserId="demandUserId"
:demandUserName="demandUserName"
:demandUserMobile="demandUserMobile"></process-form>
<div class="div-btn ">
<el-button size="small"
@click="handleClose">关闭</el-button>
<el-button style="margin-left:20px"
type="primary"
size="small"
@click="handleComfirm">确定</el-button>
</div>
</el-card>
</div>
</div>
<div class="g-page"
v-if="pageType == 'dispose'">
<div v-if="pageType == 'dispose'||pageType == 'info'"
class="g-page">
<div class="g-left">
<el-card>
<h3>事件详情</h3>
<event-detail ref="ref_detail"
:eventId="eventId"></event-detail>
<div v-if="eventDetailData.operationId"
class="div-btn ">
<el-button size="small"
@click="handleClose">关闭</el-button>
</div>
</el-card>
<div class="process-form">
<div v-if="!eventDetailData.operationId"
class="process-form">
<el-card>
<h3>处理</h3>
<process-form ref="ref_processinfo"
:demandUserId="demandUserId"
:demandUserName="demandUserName"
:demandUserMobile="demandUserMobile"></process-form>
<process-form ref="ref_processinfo_dispose"
:eventId="eventId"></process-form>
<div class="div-btn ">
<el-button size="small"
@ -76,35 +80,98 @@ h3<template>
</div>
</div>
<div class="detail">
<div class="detail-field">处理部门</div>
<div class="detail-value">{{ item.departmentName }}</div>
<div v-if="item.type==='event'">
<div class="detail">
<div class="detail-field">回复人</div>
<div class="detail-value">{{ item.publicReply }}</div>
</div>
<div class="detail">
<div class="detail-field">回复内容</div>
<div class="detail-value">{{ item.departmentName }}</div>
</div>
</div>
<div class="detail"
v-if="item.processName != '转项目' && item.publicReply">
<div class="detail-field"> </div>
<div class="detail-value">
<fold-text :row="3">{{ item.publicReply }}</fold-text>
<div v-if="item.type==='project'">
<div v-if="item.processName==='回复'">
<div class="detail">
<div class="detail-field">回复人</div>
<div class="detail-value">{{ item.publicReply }}</div>
</div>
<div class="detail">
<div class="detail-field">回复内容</div>
<div class="detail-value">{{ item.departmentName }}</div>
</div>
</div>
<div v-else>
<div class="detail">
<div class="detail-field">处理部门</div>
<div class="detail-value">{{ item.departmentName }}</div>
</div>
<div class="detail"
v-if="item.processName == '处理响应' && item.assistanceUnitName">
<div class="detail-field"> </div>
<div class="detail-value">
<fold-text :row="3">{{ item.assistanceUnitName }}</fold-text>
</div>
</div>
<div class="detail"
v-if="item.processName != '转项目' && item.publicReply">
<div class="detail-field"> </div>
<div class="detail-value">
<fold-text :row="3">{{ item.publicReply }}</fold-text>
</div>
</div>
<div class="detail"
v-if="item.processName != '转项目' && item.internalRemark">
<div class="detail-field">内部备注</div>
<div class="detail-value">
<fold-text :row="3">{{ item.internalRemark }}</fold-text>
</div>
</div>
<div v-if="item.internalFile&&item.internalFile.length>0"
class="detail">
<div class="attachement-list">
<a :href="att.url"
target="_blank"
:key="att.url"
v-for="att in item.internalFile">
<i class="el-icon-folder-opened"></i>
{{ att.name }}
</a>
</div>
</div>
</div>
</div>
<div class="detail"
v-if="item.processName != '转项目' && item.internalRemark">
<div class="detail-field">内部备注</div>
<div class="detail-value">
<fold-text :row="3">{{ item.internalRemark }}</fold-text>
<div v-if="item.type==='demand'">
<div v-if="item.processName==='回复'">
<div class="detail">
<div class="detail-field">回复人</div>
<div class="detail-value">{{ item.publicReply }}</div>
</div>
<div class="detail">
<div class="detail-field">回复内容</div>
<div class="detail-value">{{ item.departmentName }}</div>
</div>
</div>
</div>
<div class="detail">
<div class="attachement-list">
<a :href="att.url"
target="_blank"
:key="att.url"
v-for="att in item.internalFile">
<i class="el-icon-folder-opened"></i>
{{ att.name }}
</a>
<div v-if="item.processName==='需求完成'">
<div class="detail">
<div class="detail-field">服务方</div>
<div class="detail-value">{{ item.serviceParty }}</div>
</div>
<div class="detail">
<div class="detail-field">实际服务时间</div>
<div class="detail-value">{{ item.actualServiceTime }}</div>
</div>
</div>
<div v-if="item.processName==='转服务'">
<div class="detail">
<div class="detail-field">服务时间</div>
<div class="detail-value">{{ item.serviceTime }}</div>
</div>
</div>
</div>
</div>
@ -143,10 +210,13 @@ function iniData () {
demand: {},
project: {},
//
demandUserId: '',
demandUserName: '',
demandUserMobile: '',
eventDetailData: {},
projectProcess: [],
};
@ -191,9 +261,29 @@ export default {
if (this.pageType === 'dispose') {
this.getProjectProcess()
}
if (this.eventId) {
this.getEventDetail()
}
},
methods: {
//
async getEventDetail () {
const url = "/gov/project/icEvent/detail";
// const url = "http://yapi.elinkservice.cn/mock/245/gov/project/icEvent/detail";
const { data, code, msg } = await requestPost(url, {
icEventId: this.eventId,
});
if (code === 0) {
this.eventDetailData = { ...data };
} else {
this.$message.error(msg);
}
},
changeName (val) {
this.demandUserName = val
@ -240,8 +330,16 @@ export default {
console.log('eventInfo', this.eventInfoData)
},
handleComfirm () {
if (this.pageType === 'add') {
this.handelAdd()
}
if (this.pageType === 'dispose') {
this.handelDispose()
}
},
handelAdd () {
if (this.pageType === 'add') {
this.$refs.ref_add.getEventInfo()
if (this.$refs.ref_add.okflag) {
@ -254,28 +352,28 @@ export default {
console.log('eventInfo', this.eventInfoData)
}
this.$refs.ref_processinfo.getProcessInfo()
if (this.$refs.ref_processinfo.okflag) {
this.$refs.ref_processinfo_add.getProcessInfo()
if (this.$refs.ref_processinfo_add.okflag) {
this.formData.operationType = this.$refs.ref_processinfo.operationType
this.formData.categoryList = this.$refs.ref_processinfo.categoryList
this.formData.operationType = this.$refs.ref_processinfo_add.operationType
this.formData.categoryList = this.$refs.ref_processinfo_add.categoryList
if (this.formData.operationType === '0') {
this.project = {}
this.demand = {}
this.replayInfo = this.$refs.ref_processinfo.replayInfo
this.replayInfo = this.$refs.ref_processinfo_add.replayInfo
console.log('replayInfo', this.replayInfo)
//
this.eventInfoData.content = this.replayInfo.content
this.eventInfoData.status = this.replayInfo.status
this.eventInfoData.categoryList = this.$refs.ref_processinfo.categoryList
this.eventInfoData.categoryList = this.$refs.ref_processinfo_add.categoryList
} else if (this.formData.operationType === '1') {
this.replayInfo = {}
this.demand = {}
this.project = this.$refs.ref_processinfo.project
this.project = this.$refs.ref_processinfo_add.project
//
this.project.gridId = this.eventInfoData.gridId
console.log('projectInfo', this.project)
@ -283,7 +381,7 @@ export default {
} else if (this.formData.operationType === '2') {
this.replayInfo = {}
this.project = {}
this.demand = this.$refs.ref_processinfo.demand
this.demand = this.$refs.ref_processinfo_add.demand
//
this.demand.gridId = this.eventInfoData.gridId
this.demand.reportUserName = this.eventInfoData.name//
@ -330,6 +428,67 @@ export default {
} else {
}
},
handelDispose () {
this.$refs.ref_processinfo_dispose.getProcessInfo()
if (this.$refs.ref_processinfo_dispose.okflag) {
this.formData.operationType = this.$refs.ref_processinfo_dispose.operationType
this.formData.categoryList = this.$refs.ref_processinfo_dispose.categoryList
if (this.formData.operationType === '0') {
this.project = {}
this.demand = {}
this.replayInfo = this.$refs.ref_processinfo_dispose.replayInfo
this.replayInfo.icEventId = this.eventId
console.log('replayInfo', this.replayInfo)
//
let url = '/gov/project/icEvent/reply'
this.submitDispose(url, this.replayInfo)
} else if (this.formData.operationType === '1') {
this.replayInfo = {}
this.demand = {}
this.project = this.$refs.ref_processinfo_dispose.project
//
this.project.icEventId = this.eventId
console.log('projectInfo', this.project)
let url = '/gov/project/icEvent/icEventToProject'
this.submitDispose(url, this.project)
} else if (this.formData.operationType === '2') {
this.replayInfo = {}
this.project = {}
this.demand = this.$refs.ref_processinfo_dispose.demand
//
this.demand.IcEventId = this.eventId
console.log('demond', this.demand)
let url = '/gov/project/icEvent/icEventToDemand'
this.submitDispose(url, this.demand)
}
} else {
return false
}
},
async submitDispose (url, params) {
const { data, code, msg } = await requestPost(url, {
...params,
});
if (code === 0) {
this.$message.success("操作成功!");
this.$emit("handleOk");
} else {
}
},
handleClose () {
if (this.pageType === 'add') {
this.eventInfo = this.$refs.ref_add.resetData()

38
src/views/modules/shequzhili/event/cpts/process-form-demand.vue

@ -292,6 +292,10 @@ export default {
type: String,
default: "",
},
eventId: {
type: String,
default: "",
},
},
watch: {
@ -318,12 +322,40 @@ export default {
// this.formData = { ...this.formDataTemp }
this.initMap()
this.formData.demandUserName = this.demandUserName
this.formData.demandUserMobile = this.demandUserMobile
this.formData.demandUserId = this.demandUserId
if (this.eventId) {
this.getEventInfo()
} else {
this.formData.demandUserName = this.demandUserName
this.formData.demandUserMobile = this.demandUserMobile
this.formData.demandUserId = this.demandUserId
}
},
methods: {
//
async getEventInfo () {
const url = "/gov/project/icEvent/detail";
// const url = "http://yapi.elinkservice.cn/mock/245/gov/project/icEvent/detail";
const { data, code, msg } = await requestPost(url, {
icEventId: this.eventId,
});
if (code === 0) {
this.formData.demandUserName = data.name
this.formData.demandUserMobile = data.mobile
this.formData.demandUserId = data.reportUserId
this.formData.reportTime = data.createdTime
this.formData.gridId = data.gridId
this.formData.reportUserMobile = data.name
this.formData.reportUserName = data.mobile
} else {
this.$message.error(msg);
}
},
async getDemandOptions () {
const url = "/heart/icresidemanddict/demandoption"
let params = {}

20
src/views/modules/shequzhili/event/cpts/process-form-project.vue

@ -326,6 +326,11 @@ export default {
this.getAssistanceUnitList();
this.getTagList()
this.formData = { ...this.formDataTemp }
if (this.eventId) {
this.getEventInfo()
} else {
}
},
methods: {
@ -404,7 +409,22 @@ export default {
this.visibleTagPanel = false;
},
async getEventInfo () {
const url = "/gov/project/icEvent/detail";
// const url = "http://yapi.elinkservice.cn/mock/245/gov/project/icEvent/detail";
const { data, code, msg } = await requestPost(url, {
icEventId: this.eventId,
});
if (code === 0) {
this.formData.gridId = data.gridId
} else {
this.$message.error(msg);
}
},
async getProjectInfo () {
this.okflag = false
this.$refs["ref_form"].validate((valid, messageObj) => {

5
src/views/modules/shequzhili/event/cpts/process-form.vue

@ -41,6 +41,7 @@
<div v-if="operationType==='2'">
<process-form-demand ref="ref_process_form_demond"
:eventId="eventId"
:demandUserId="demandUserId"
:demandUserName="demandUserName"
:demandUserMobile="demandUserMobile"></process-form-demand>
@ -127,6 +128,10 @@ export default {
type: String,
default: "",
},
eventId: {
type: String,
default: "",
},
},
watch: {

10
src/views/modules/shequzhili/event/eventList.vue

@ -153,11 +153,10 @@
<el-table-column prop="imageList"
align="center"
label="图片"
:show-overflow-tooltip="true">
label="图片">
<template slot-scope="scope">
<el-image v-if="scope.row.imageList&&scope.row.imageList.length>0"
style="width: 100px; height: 100px"
style="width: 40px; height: 40px"
:src="scope.row.imageList[0]"
:preview-src-list="scope.row.imageList">
</el-image>
@ -166,8 +165,7 @@
</el-table-column>
<el-table-column prop="voiceList"
align="center"
label="音频"
:show-overflow-tooltip="true">
label="音频">
<template slot-scope="scope">
<img class="img-voice"
v-if="scope.row.voiceList&&scope.row.voiceList.length>0"
@ -311,7 +309,7 @@ export default {
}
return {
pageType: "list", // list add dispose info issue-info
pageType: "list", // list add dispose info
agencyId: '',
gridList: [],//list--
tableData: [],

Loading…
Cancel
Save