@@ -172,10 +172,9 @@ layout("/layouts/platform.html"){
-
-
+
查看
- 删除
@@ -209,8 +208,8 @@ layout("/layouts/platform.html"){
{title: "待受理", prop: "waitAcceptCount", tip: "委员会待审核", icon: "el-icon-time", className: "stat-wait"},
{title: "待执行", prop: "waitExecuteCount", tip: "单位待反馈", icon: "el-icon-s-operation", className: "stat-execute"},
{title: "已办结", prop: "finishCount", tip: "流程已结束", icon: "el-icon-finished", className: "stat-finish"},
- {title: "维持决定", prop: "maintainCount", tip: "维持原处理", icon: "el-icon-circle-check", className: "stat-maintain"},
- {title: "重新处理", prop: "reprocessCount", tip: "需重新处理", icon: "el-icon-refresh", className: "stat-reprocess"}
+ /*{title: "维持决定", prop: "maintainCount", tip: "维持原处理", icon: "el-icon-circle-check", className: "stat-maintain"},
+ {title: "重新处理", prop: "reprocessCount", tip: "需重新处理", icon: "el-icon-refresh", className: "stat-reprocess"}*/
],
statistics: {}
}
@@ -219,6 +218,9 @@ layout("/layouts/platform.html"){
statisticValue(prop) {
return (this.statistics && this.statistics[prop]) || 0
},
+ typeOptionLabel(item) {
+ return item.enabled === false || item.enabled === 0 ? item.name + "(已停用)" : item.name
+ },
stateTagType(state) {
const map = {
"待受理": "warning",
@@ -247,19 +249,8 @@ layout("/layouts/platform.html"){
this.pageData()
this.loadStatistics()
},
- onDelete(row) {
- this.$confirm("您确定删除该申诉吗?", "提示", {type: "warning"}).then(() => {
- this.$axios.post("/platform/appeal/query/delete", {id: row.id}).then((res) => {
- if (res.code === 0) {
- this.$message.success(res.msg)
- this.pageData()
- this.loadStatistics()
- }
- })
- })
- },
loadOptions() {
- this.$axios.post("/platform/appeal/common/typeOptions").then((res) => {
+ this.$axios.post("/platform/appeal/common/queryTypeOptions").then((res) => {
if (res.code === 0) this.typeOptions = res.data || []
})
this.$businessTool.listUnit().then((res) => {
diff --git a/src/main/resources/views/platform/zhgh/democratic/appeal/type/index.html b/src/main/resources/views/platform/zhgh/democratic/appeal/type/index.html
index 85ac1b4..671d1af 100644
--- a/src/main/resources/views/platform/zhgh/democratic/appeal/type/index.html
+++ b/src/main/resources/views/platform/zhgh/democratic/appeal/type/index.html
@@ -22,11 +22,16 @@ layout("/layouts/platform.html"){
- 是
- 否
+ {onEnabledChange(row, val)}">
+
-
+
编辑
删除
@@ -89,12 +94,36 @@ layout("/layouts/platform.html"){
})
})
},
+ onEnabledChange(row, enabled) {
+ const oldEnabled = !enabled
+ const actionName = enabled ? "启用" : "禁用"
+ this.$confirm("您确定要" + actionName + "申诉类型“" + row.name + "”吗?", "提示", {type: "warning"}).then(() => {
+ this.$set(row, "enabledLoading", true)
+ this.$axios.post("/platform/appeal/type/statusChange", {id: row.id, enabled: enabled}).then((res) => {
+ if (res.code === 0) {
+ this.$message.success(res.msg)
+ this.pageData()
+ } else {
+ row.enabled = oldEnabled
+ this.$message.error(res.msg)
+ }
+ this.$set(row, "enabledLoading", false)
+ }).catch(() => {
+ row.enabled = oldEnabled
+ this.$set(row, "enabledLoading", false)
+ })
+ }).catch(() => {
+ row.enabled = oldEnabled
+ })
+ },
onDelete(row) {
- this.$confirm("您确定删除该申诉类型吗?", "提示", {type: "warning"}).then(() => {
+ this.$confirm("您确定删除申诉类型“" + row.name + "”吗?", "提示", {type: "warning"}).then(() => {
this.$axios.post("/platform/appeal/type/delete", {id: row.id}).then((res) => {
if (res.code === 0) {
this.$message.success(res.msg)
this.pageData()
+ } else {
+ this.$message.error(res.msg)
}
})
})