master
lion 3 years ago
parent d378008ab8
commit d56033e0da

@ -207,7 +207,7 @@
审核
</div>
</template>
<template v-slot:checkForm v-if="formDataType=='checkrecord'">
<template v-slot:checkForm v-if="formDataType=='checkrecord'&&isCheck">
<el-form-item prop='checkForm.status' style="margin-bottom:20px">
<div class="xy-table-item">
<div class="xy-table-item-label">状态
@ -220,7 +220,7 @@
</div>
</div>
</el-form-item>
<el-form-item prop='checkForm.status' style="margin-bottom:20px">
<!-- <el-form-item prop='checkForm.status' style="margin-bottom:20px">
<div class="xy-table-item">
<div class="xy-table-item-label">审核
</div>
@ -234,7 +234,7 @@
</span>
</div>
</div>
</el-form-item>
</el-form-item> -->
<el-form-item prop='checkForm.reason' style="margin-bottom:20px">
<div class="xy-table-item">
<div class="xy-table-item-label">
@ -247,7 +247,7 @@
</el-form-item>
</template>
<template v-slot:codeForm>
<template v-slot:codeForm v-if="formDataType=='coderecord'">
<div class="xy-table-item">
<div class="xy-table-item-label">
核销码
@ -261,7 +261,7 @@
<template v-slot:footerContent>
<div>
<Button ghost type="primary" @click="reset"></Button>
<Button v-if="formDataType=='checkrecord'" type="primary" @click="checkSubmit"></Button>
<Button v-if="formDataType=='checkrecord'&&isCheck" type="primary" @click="checkSubmit"></Button>
<Button v-if="formDataType=='coderecord'" type="primary" @click="codeSubmit"></Button>
</div>
</template>
@ -278,12 +278,17 @@
import {
cancelCode
} from "@/api/gate"
import {
getInfo
} from '@/api/user.js'
import Cookies from 'js-cookie'
export default {
components: {},
data() {
return {
isShow: false,
id: '',
userId: '',
formDataType: '',
formData: {
visitinfo: "",
@ -353,18 +358,36 @@
value: "驳回"
},
],
isCheck:false
}
},
created() {
// this.getVisitTime()
this.getUserId()
},
watch: {
isShow(newVal) {
if (newVal) {
let that = this
if (this.formDataType == 'checkrecord') {
this.checkForm.visit_id = this.form.id
for (let item of that.form.audit) {
console.log('item', item.audit_admin_id)
if (item.audit_admin_id == that.userId) {
console.log(item.audit_admin_id == that.userId)
that.checkForm.level = item.level
that.checkForm.id = item.id
that.checkForm.audit_admin_id = item.audit_admin_id
that.isCheck = true
return
}
}
}
if (this.formDataType == 'coderecord') {
this.codeForm.type = parseInt(this.codeType)
this.codeForm.admin_id = parseInt(this.gateAdminId)
if(this.formDataType=='coderecord'){
this.$nextTick(() => {
this.$refs.codeInput.focus()
})
@ -385,6 +408,10 @@
}
})
},
async getUserId() {
const res = await getInfo()
this.userId = res.id
},
reset() {
this.formDataType = ''
this.checkForm = {}

Loading…
Cancel
Save