| | |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | mounted() { |
| | | // this.entityCopy = this.HaveJson(this.componentData.entity); |
| | | this.getList() |
| | | }, |
| | | methods: { |
| | | // 权限分配 |
| | | getPower() { |
| | | let power = JSON.parse(sessionStorage.getItem('power')) |
| | | let up = false |
| | | let del = false |
| | | let add = false |
| | | let out = false |
| | | for (var i = 0; i < power.length; i++) { |
| | | if (power[i].menuMethod == 'doProcessComplain') { |
| | | up = true |
| | | } |
| | | if (power[i].menuMethod == 'addProcessComplain') { |
| | | add = true |
| | | } |
| | | if (power[i].menuMethod == 'delProcessComplain') { |
| | | del = true |
| | | } |
| | | if (power[i].menuMethod == 'exportProcessComplain') { |
| | | out = true |
| | | } |
| | | } |
| | | if (!up) { |
| | | this.componentData.do.splice(2, 1) |
| | | } |
| | | if (!del) { |
| | | this.componentData.do.splice(1, 1) |
| | | } |
| | | this.outPower = out |
| | | this.addPower = add |
| | | }, |
| | | openAdd() { |
| | | this.addInfo = {} |
| | | this.addDialogVisible = true |
| | |
| | | this.addLoading = true |
| | | addProcessComplain(this.addInfo).then((res) => { |
| | | this.addLoading = false |
| | | if (res.code == 201) { |
| | | this.$message({ |
| | | type: 'error', |
| | | message: '新增失败' |
| | | }) |
| | | return |
| | | } |
| | | this.$message({ |
| | | type: 'success', |
| | | message: '新增成功' |
| | |
| | | } |
| | | doProcessComplain(this.currentInfo0).then((res) => { |
| | | this.addLoading = false |
| | | if (res.code == 201) { |
| | | this.$message({ |
| | | type: 'error', |
| | | message: '提交失败' |
| | | }) |
| | | return |
| | | } |
| | | this.$message({ |
| | | type: 'success', |
| | | message: '提交成功' |
| | |
| | | this.outLoading = true |
| | | exportProcessComplain(this.queryParams).then(res => { |
| | | this.outLoading = false |
| | | if (res.code == 201) { |
| | | return |
| | | } |
| | | const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | | this.$download.saveAs(blob, '投诉情况汇总表.xlsx'); |
| | | }) |
| | | }, |
| | | handleOut(row) { |
| | | getProcessComplain({ id: row.id }).then((res) => { |
| | | if (res.code == 201) { |
| | | return |
| | | } |
| | | this.currentInfo = res.data |
| | | this.currentInfo0 = this.HaveJson(res.data) |
| | | this.title = '导出' |
| | |
| | | }) |
| | | .then(() => { |
| | | delProcessComplain({ id: row.id }).then((res) => { |
| | | if (res.code == 201) return; |
| | | this.$message.success("删除成功"); |
| | | this.refresh(); |
| | | }); |
| | |
| | | .user-info { |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: end; |
| | | justify-content: flex-end; |
| | | } |
| | | |
| | | .user-content { |