|
|
|
@ -5,7 +5,7 @@ |
|
|
|
<h3 class="h3-title"><img src="../../../../../assets/images/index/title-icon-zntb.png" width="30px" |
|
|
|
height="30px" alt=""> 新增事件</h3> |
|
|
|
<event-add ref="ref_add" @changeName="changeName" @changeMobile="changeMobile" @changeUserId="changeUserId" |
|
|
|
@changeGridId="changeGridId"></event-add> |
|
|
|
@changeGridId="changeGridId" @changeLevel="changeLevel"></event-add> |
|
|
|
</el-card> |
|
|
|
|
|
|
|
<div class="process-form"> |
|
|
|
@ -104,7 +104,8 @@ |
|
|
|
<template v-if="i.type === 'image'"> |
|
|
|
<div class="detail"> |
|
|
|
<div class="detail-field">图片:</div> |
|
|
|
<div :class="['m-info-prop', { 'm-info-prop-vis': source === 'visiual' },]"> |
|
|
|
<div |
|
|
|
:class="['m-info-prop', { 'm-info-prop-vis': source === 'visiual' },]"> |
|
|
|
<img :src="i.url" :key="i.url" |
|
|
|
style="width: 50px; height: 50px; padding-right: 10px" |
|
|
|
@click="watchImg(i.url)" /> |
|
|
|
@ -114,7 +115,8 @@ |
|
|
|
<template v-if="i.type === 'voice'"> |
|
|
|
<div class="detail"> |
|
|
|
<div class="detail-field">语音:</div> |
|
|
|
<div :class="['m-info-prop', { 'm-info-prop-vis': source === 'visiual' },]"> |
|
|
|
<div |
|
|
|
:class="['m-info-prop', { 'm-info-prop-vis': source === 'visiual' },]"> |
|
|
|
<audio controls> |
|
|
|
<source :src="i.url" type="" :key="i.url" /> |
|
|
|
</audio> |
|
|
|
@ -124,7 +126,8 @@ |
|
|
|
<template v-if="i.type === 'doc'"> |
|
|
|
<div class="detail"> |
|
|
|
<div class="detail-field">附件:</div> |
|
|
|
<div :class="['m-info-prop', { 'm-info-prop-vis': source === 'visiual' },]"> |
|
|
|
<div |
|
|
|
:class="['m-info-prop', { 'm-info-prop-vis': source === 'visiual' },]"> |
|
|
|
<a :href="i.url">{{ i.name }}</a> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
@ -242,6 +245,8 @@ function iniData() { |
|
|
|
issueDetailData: {}, |
|
|
|
|
|
|
|
sourceType: "", |
|
|
|
|
|
|
|
level:'' |
|
|
|
}; |
|
|
|
} |
|
|
|
|
|
|
|
@ -317,6 +322,9 @@ export default { |
|
|
|
changeGridId(val) { |
|
|
|
this.gridId = val; |
|
|
|
}, |
|
|
|
changeLevel(val) { |
|
|
|
this.level = val; |
|
|
|
}, |
|
|
|
watchImg(src) { |
|
|
|
window.open(src); |
|
|
|
}, |
|
|
|
@ -414,113 +422,125 @@ export default { |
|
|
|
|| this.formData.operationType === '6' || this.formData.operationType === '4') { |
|
|
|
const url = "/governance/icEvent/add"; |
|
|
|
const { formData } = this; |
|
|
|
if (Array.isArray(this.formData.gridId) && this.formData.gridId.length) { |
|
|
|
if (this.level == "grid") { |
|
|
|
this.formData.gridId = this.formData.gridId[this.formData.gridId.length - 1]; |
|
|
|
this.formData.agencyId = ""; |
|
|
|
} else { |
|
|
|
this.formData.agencyId = this.formData.gridId[this.formData.gridId.length - 1]; |
|
|
|
this.formData.gridId = ""; |
|
|
|
} |
|
|
|
} else { |
|
|
|
this.formData.agencyId = ""; |
|
|
|
this.formData.gridId = ""; |
|
|
|
} |
|
|
|
const { data, code, msg } = await requestPost(url, { |
|
|
|
...formData, |
|
|
|
}); |
|
|
|
if (code === 0) { |
|
|
|
this.$message.success("操作成功!"); |
|
|
|
if (this.pageTypeCopy === "add") { |
|
|
|
this.eventInfo = this.$refs.ref_add.resetData(); |
|
|
|
} |
|
|
|
this.$emit("handleOk"); |
|
|
|
} else { |
|
|
|
this.$message.error(msg); |
|
|
|
} |
|
|
|
} else if (this.formData.operationType == "") { |
|
|
|
this.$message.error("请选择一种处理方式!"); |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
async handelDispose() { |
|
|
|
this.$refs.ref_processinfo_dispose.getProcessInfo(); |
|
|
|
if (this.$refs.ref_processinfo_dispose.okflag) { |
|
|
|
this.formData.operationType = this.$refs.ref_processinfo_dispose.operationType; |
|
|
|
this.replayInfo = this.$refs.ref_processinfo_dispose.replayInfo; |
|
|
|
this.replayInfo.icEventId = this.eventId; |
|
|
|
await this.submitDispose('/governance/icEvent/reply', this.replayInfo); |
|
|
|
} else { |
|
|
|
return false; |
|
|
|
} |
|
|
|
}, |
|
|
|
async submitDispose(url, params) { |
|
|
|
const { data, code, msg } = await requestPost(url, { |
|
|
|
...formData, |
|
|
|
...params, |
|
|
|
}); |
|
|
|
if (code === 0) { |
|
|
|
this.$message.success("操作成功!"); |
|
|
|
if (this.pageTypeCopy === "add") { |
|
|
|
this.eventInfo = this.$refs.ref_add.resetData(); |
|
|
|
} |
|
|
|
|
|
|
|
this.$emit("handleOk"); |
|
|
|
} else { |
|
|
|
this.$message.error(msg); |
|
|
|
} |
|
|
|
} else if (this.formData.operationType == "") { |
|
|
|
this.$message.error("请选择一种处理方式!"); |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
async handelDispose() { |
|
|
|
this.$refs.ref_processinfo_dispose.getProcessInfo(); |
|
|
|
if (this.$refs.ref_processinfo_dispose.okflag) { |
|
|
|
this.formData.operationType = this.$refs.ref_processinfo_dispose.operationType; |
|
|
|
this.replayInfo = this.$refs.ref_processinfo_dispose.replayInfo; |
|
|
|
this.replayInfo.icEventId = this.eventId; |
|
|
|
await this.submitDispose('/governance/icEvent/reply', this.replayInfo); |
|
|
|
} 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 { |
|
|
|
this.$message.error(msg); |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
handleClose() { |
|
|
|
if (this.pageTypeCopy === "add") { |
|
|
|
this.eventInfo = this.$refs.ref_add.resetData(); |
|
|
|
} |
|
|
|
handleClose() { |
|
|
|
if (this.pageTypeCopy === "add") { |
|
|
|
this.eventInfo = this.$refs.ref_add.resetData(); |
|
|
|
} |
|
|
|
|
|
|
|
this.$emit("handleClose"); |
|
|
|
}, |
|
|
|
handleToProject(type) { |
|
|
|
if (this.eventDetailCopy.status === "processing") { |
|
|
|
this.projectPageType = "edit"; |
|
|
|
} else { |
|
|
|
this.projectPageType = "info"; |
|
|
|
} |
|
|
|
this.sourceType = "event"; |
|
|
|
this.pageTypeCopy = "project"; |
|
|
|
}, |
|
|
|
handleToDemand() { |
|
|
|
// if (this.eventDetailCopy.status === 'processing') { |
|
|
|
// this.projectPageType = 'edit' |
|
|
|
// } else { |
|
|
|
// this.projectPageType = 'info' |
|
|
|
// } |
|
|
|
this.pageTypeCopy = "demand"; |
|
|
|
}, |
|
|
|
this.$emit("handleClose"); |
|
|
|
}, |
|
|
|
handleToProject(type) { |
|
|
|
if (this.eventDetailCopy.status === "processing") { |
|
|
|
this.projectPageType = "edit"; |
|
|
|
} else { |
|
|
|
this.projectPageType = "info"; |
|
|
|
} |
|
|
|
this.sourceType = "event"; |
|
|
|
this.pageTypeCopy = "project"; |
|
|
|
}, |
|
|
|
handleToDemand() { |
|
|
|
// if (this.eventDetailCopy.status === 'processing') { |
|
|
|
// this.projectPageType = 'edit' |
|
|
|
// } else { |
|
|
|
// this.projectPageType = 'info' |
|
|
|
// } |
|
|
|
this.pageTypeCopy = "demand"; |
|
|
|
}, |
|
|
|
async handleToIssue() { |
|
|
|
const url = "/governance/manage/votingissuedetail"; |
|
|
|
const url = "/governance/manage/votingissuedetail"; |
|
|
|
|
|
|
|
const { data, code, msg } = await requestPost(url, { |
|
|
|
issueId: this.eventDetailCopy.operationId, |
|
|
|
}); |
|
|
|
const { data, code, msg } = await requestPost(url, { |
|
|
|
issueId: this.eventDetailCopy.operationId, |
|
|
|
}); |
|
|
|
|
|
|
|
if (code === 0) { |
|
|
|
this.issueDetailData = { ...data }; |
|
|
|
} else { |
|
|
|
this.$message.error(msg); |
|
|
|
} |
|
|
|
if (code === 0) { |
|
|
|
this.issueDetailData = { ...data }; |
|
|
|
} else { |
|
|
|
this.$message.error(msg); |
|
|
|
} |
|
|
|
|
|
|
|
if (this.issueDetailData.issueStatus === "voting") { |
|
|
|
this.issuePageType = "dispose"; |
|
|
|
} else { |
|
|
|
this.issuePageType = "info"; |
|
|
|
} |
|
|
|
this.pageTypeCopy = "issue"; |
|
|
|
}, |
|
|
|
handleCloseProject() { |
|
|
|
this.getProjectProcess(); |
|
|
|
this.pageTypeCopy = "info"; |
|
|
|
}, |
|
|
|
if (this.issueDetailData.issueStatus === "voting") { |
|
|
|
this.issuePageType = "dispose"; |
|
|
|
} else { |
|
|
|
this.issuePageType = "info"; |
|
|
|
} |
|
|
|
this.pageTypeCopy = "issue"; |
|
|
|
}, |
|
|
|
handleCloseProject() { |
|
|
|
this.getProjectProcess(); |
|
|
|
this.pageTypeCopy = "info"; |
|
|
|
}, |
|
|
|
|
|
|
|
// 开启加载动画 |
|
|
|
startLoading() { |
|
|
|
loading = Loading.service({ |
|
|
|
lock: true, // 是否锁定 |
|
|
|
text: "正在加载……", // 加载中需要显示的文字 |
|
|
|
background: "rgba(0,0,0,.7)", // 背景颜色 |
|
|
|
}); |
|
|
|
}, |
|
|
|
// 结束加载动画 |
|
|
|
endLoading() { |
|
|
|
// clearTimeout(timer); |
|
|
|
if (loading) { |
|
|
|
loading.close(); |
|
|
|
} |
|
|
|
// 开启加载动画 |
|
|
|
startLoading() { |
|
|
|
loading = Loading.service({ |
|
|
|
lock: true, // 是否锁定 |
|
|
|
text: "正在加载……", // 加载中需要显示的文字 |
|
|
|
background: "rgba(0,0,0,.7)", // 背景颜色 |
|
|
|
}); |
|
|
|
}, |
|
|
|
// 结束加载动画 |
|
|
|
endLoading() { |
|
|
|
// clearTimeout(timer); |
|
|
|
if (loading) { |
|
|
|
loading.close(); |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}; |
|
|
|
}; |
|
|
|
</script> |
|
|
|
|
|
|
|
<style lang="scss" scoped> |
|
|
|
|