若干bug修改
parent
cdf082b956
commit
bc89c09958
|
@ -42,7 +42,7 @@
|
|||
<el-table-column label="操作" align="center" width="250">
|
||||
<template slot-scope="{row}">
|
||||
<el-button type="primary" icon="el-icon-edit" size="mini" @click="handleShow(row)">详情</el-button>
|
||||
<el-button type="primary" icon="el-icon-s-claim" size="mini" @click="approve([row])">审批</el-button>
|
||||
<el-button v-if="row.power_flag === '1'" type="primary" icon="el-icon-s-claim" size="mini" @click="approve([row])">审批</el-button>
|
||||
<el-button v-if="false" type="success" icon="el-icon-edit" size="mini" @click="getUserInfo(row)">电子合格证</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
<template>
|
||||
<div>
|
||||
<el-dialog v-loading = "loading" :visible.sync="visible" :append-to-body="appendToBody" :before-close="beforeClose" title="审批" width="1200px" destroy-on-close>
|
||||
<el-form label-width="200px" label-position="right" type="flex">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="200px" label-position="right" type="flex">
|
||||
<el-row :gutter="12">
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="TERRITORIALITY" label="是否通过: ">
|
||||
<el-form-item prop="STATUS" label="是否通过: ">
|
||||
<el-select v-model="form.STATUS" style="width: 300px" placeholder="请选择">
|
||||
<el-option label="是" value="1"/>
|
||||
<el-option label="否" value="0"/>
|
||||
|
@ -12,7 +12,7 @@
|
|||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="TERRITORIALITY" label="指定监管部门:">
|
||||
<el-form-item v-if="form.STATUS === '1'" prop="APPOINT_DEPARTMENT_ID" label="指定监管部门:">
|
||||
<Treeselect
|
||||
:options="departmentTree"
|
||||
:normalizer="normalizer"
|
||||
|
@ -27,8 +27,13 @@
|
|||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="TERRITORIALITY" label="指定监管部门审批人:">
|
||||
<el-col v-if="form.STATUS === '0'" :span="12">
|
||||
<el-form-item v-if="form.STATUS === '0'" prop="OPINION" label="打回原因:">
|
||||
<el-input v-model="form.OPINION" :rows="2" type="textarea" placeholder="填写审批意见"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-if="form.STATUS === '1'" :span="12">
|
||||
<el-form-item v-if="form.STATUS === '1'" prop="APPOINT_USER_ID" label="指定监管部门审批人:">
|
||||
<el-select v-model="form.user" style="width: 300px" placeholder="请选择" @change="chooseUser">
|
||||
<el-option v-for="item in peopleList" :key="item.USER_ID" :value="JSON.stringify(item)" :label="item.NAME"/>
|
||||
</el-select>
|
||||
|
@ -39,7 +44,7 @@
|
|||
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="handleClose">关 闭</el-button>
|
||||
<el-button type="primary" @click="sendMessage()">确 定</el-button>
|
||||
<el-button type="primary" @click="sendMessage('1')">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
|
@ -70,10 +75,25 @@ export default {
|
|||
APPOINT_DEPARTMENT_NAME: '',
|
||||
APPOINT_USER_ID: null,
|
||||
APPOINT_USER_NAME: '',
|
||||
OPINION: '',
|
||||
user: '',
|
||||
tm: new Date().getTime(),
|
||||
list: []
|
||||
},
|
||||
rules: {
|
||||
STATUS: [
|
||||
{ required: true, message: '请选择是否通过', trigger: 'change' }
|
||||
],
|
||||
APPOINT_DEPARTMENT_ID: [
|
||||
{ required: true, message: '请选择指定监管部门', trigger: 'change' }
|
||||
],
|
||||
APPOINT_USER_ID: [
|
||||
{ required: true, message: '请选择指定监管部门审批人', trigger: 'change' }
|
||||
],
|
||||
OPINION: [
|
||||
{ required: true, message: '请填写打回原因', trigger: 'change' }
|
||||
]
|
||||
},
|
||||
heirloom: {},
|
||||
|
||||
normalizer(node) {
|
||||
|
@ -98,13 +118,22 @@ export default {
|
|||
await this.getDepartmentTree()
|
||||
this.loading = false
|
||||
},
|
||||
sendMessage() {
|
||||
requestFN('/xgf/user/approve', this.form)
|
||||
.then((data) => {
|
||||
this.$message.success('推送成功')
|
||||
this.visible = false
|
||||
this.$emit('refresh', '')
|
||||
})
|
||||
sendMessage(e) {
|
||||
this.$refs.form.validate((valid) => {
|
||||
if (!valid) {
|
||||
this.$message.error('请填写完整信息')
|
||||
} else {
|
||||
requestFN('/xgf/user/approve', this.form)
|
||||
.then((data) => {
|
||||
this.$message.success('推送成功')
|
||||
this.visible = false
|
||||
this.$emit('refresh', '')
|
||||
})
|
||||
.catch((e) => {
|
||||
console.log(e)
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
getDepartmentTree() {
|
||||
return new Promise(resolve => {
|
||||
|
@ -140,7 +169,7 @@ export default {
|
|||
handleClose() {
|
||||
this.form = {
|
||||
STATUS: '',
|
||||
APPOINT_DEPARTMENT_ID: '',
|
||||
APPOINT_DEPARTMENT_ID: null,
|
||||
APPOINT_DEPARTMENT_NAME: '',
|
||||
APPOINT_USER_ID: '',
|
||||
APPOINT_USER_NAME: '',
|
||||
|
@ -154,7 +183,7 @@ export default {
|
|||
this.visible = false
|
||||
this.form = {
|
||||
STATUS: '',
|
||||
APPOINT_DEPARTMENT_ID: '',
|
||||
APPOINT_DEPARTMENT_ID: null,
|
||||
APPOINT_DEPARTMENT_NAME: '',
|
||||
APPOINT_USER_ID: '',
|
||||
APPOINT_USER_NAME: '',
|
||||
|
|
Loading…
Reference in New Issue