|
|
|
@ -199,71 +199,71 @@
|
|
|
|
{{form.accept_goods_admin?form.accept_goods_admin.name:''}}
|
|
|
|
{{form.accept_goods_admin?form.accept_goods_admin.name:''}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 审核 -->
|
|
|
|
<!-- 审核 -->
|
|
|
|
<template v-slot:checkRecord v-if="formDataType=='checkrecord'">
|
|
|
|
<template v-slot:checkRecord v-if="formDataType=='checkrecord'">
|
|
|
|
<div style="width:600px">
|
|
|
|
<div style="width:600px">
|
|
|
|
审核
|
|
|
|
审核
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</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">
|
|
|
|
<el-form-item prop='checkForm.status' style="margin-bottom:20px">
|
|
|
|
<div class="xy-table-item">
|
|
|
|
<div class="xy-table-item">
|
|
|
|
<div class="xy-table-item-label">状态:
|
|
|
|
<div class="xy-table-item-label">状态:
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<el-select v-model="checkForm.status" placeholder="请选择" style="width:200px">
|
|
|
|
<el-select v-model="checkForm.status" placeholder="请选择" style="width:200px">
|
|
|
|
<el-option v-for="item in statusList" :key="item.id" :label="item.value" :value="item.id">
|
|
|
|
<el-option v-for="item in statusList" :key="item.id" :label="item.value" :value="item.id">
|
|
|
|
</el-option>
|
|
|
|
</el-option>
|
|
|
|
</el-select>
|
|
|
|
</el-select>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</el-form-item>
|
|
|
|
</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">
|
|
|
|
<div class="xy-table-item-label">审核:
|
|
|
|
<div class="xy-table-item-label">审核:
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<el-select v-model="checkForm.level" @change="selectLevel" placeholder="请选择" style="width:200px;margin-right:10px">
|
|
|
|
<el-select v-model="checkForm.level" @change="selectLevel" placeholder="请选择" style="width:200px;margin-right:10px">
|
|
|
|
<el-option v-for="(item,index) in form.visit_area.audit_admin" :key="item.level" :label="item.type_name" :value="item.level">
|
|
|
|
<el-option v-for="(item,index) in form.visit_area.audit_admin" :key="item.level" :label="item.type_name" :value="item.level">
|
|
|
|
</el-option>
|
|
|
|
</el-option>
|
|
|
|
</el-select>
|
|
|
|
</el-select>
|
|
|
|
<span>
|
|
|
|
<span>
|
|
|
|
{{check_admin_name}}
|
|
|
|
{{check_admin_name}}
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item> -->
|
|
|
|
<el-form-item prop='checkForm.reason' style="margin-bottom:20px">
|
|
|
|
<el-form-item prop='checkForm.reason' style="margin-bottom:20px">
|
|
|
|
<div class="xy-table-item">
|
|
|
|
<div class="xy-table-item">
|
|
|
|
<div class="xy-table-item-label">
|
|
|
|
<div class="xy-table-item-label">
|
|
|
|
备注:
|
|
|
|
备注:
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<el-input type="textarea" v-model="checkForm.reason" placeholder="请输入备注" style="width:300px"></el-input>
|
|
|
|
<el-input type="textarea" v-model="checkForm.reason" placeholder="请输入备注" style="width:300px"></el-input>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<template v-slot:codeForm>
|
|
|
|
<template v-slot:codeForm v-if="formDataType=='coderecord'">
|
|
|
|
<div class="xy-table-item">
|
|
|
|
<div class="xy-table-item">
|
|
|
|
<div class="xy-table-item-label">
|
|
|
|
<div class="xy-table-item-label">
|
|
|
|
核销码:
|
|
|
|
核销码:
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<div class="xy-table-item-content">
|
|
|
|
<el-input v-model="codeForm.code" ref="codeInput" placeholder="请输入核销码或扫码" style="width:300px"></el-input>
|
|
|
|
<el-input v-model="codeForm.code" ref="codeInput" placeholder="请输入核销码或扫码" style="width:300px"></el-input>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<template v-slot:footerContent>
|
|
|
|
<template v-slot:footerContent>
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
<Button ghost type="primary" @click="reset">取消</Button>
|
|
|
|
<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>
|
|
|
|
<Button v-if="formDataType=='coderecord'" type="primary" @click="codeSubmit">确认</Button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</xy-dialog>
|
|
|
|
</xy-dialog>
|
|
|
|
|
|
|
|
|
|
|
|
@ -271,20 +271,25 @@
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
<script>
|
|
|
|
import {
|
|
|
|
import {
|
|
|
|
save
|
|
|
|
save
|
|
|
|
} from "@/api/visit/check.js"
|
|
|
|
} from "@/api/visit/check.js"
|
|
|
|
import {
|
|
|
|
import {
|
|
|
|
cancelCode
|
|
|
|
cancelCode
|
|
|
|
} from "@/api/gate"
|
|
|
|
} from "@/api/gate"
|
|
|
|
|
|
|
|
import {
|
|
|
|
|
|
|
|
getInfo
|
|
|
|
|
|
|
|
} from '@/api/user.js'
|
|
|
|
|
|
|
|
import Cookies from 'js-cookie'
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
components: {},
|
|
|
|
components: {},
|
|
|
|
data() {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
isShow: false,
|
|
|
|
isShow: false,
|
|
|
|
id: '',
|
|
|
|
id: '',
|
|
|
|
formDataType:'',
|
|
|
|
userId: '',
|
|
|
|
|
|
|
|
formDataType: '',
|
|
|
|
formData: {
|
|
|
|
formData: {
|
|
|
|
visitinfo: "",
|
|
|
|
visitinfo: "",
|
|
|
|
date: "",
|
|
|
|
date: "",
|
|
|
|
@ -307,19 +312,19 @@
|
|
|
|
visitorinfos: "",
|
|
|
|
visitorinfos: "",
|
|
|
|
accpet_department_id: "",
|
|
|
|
accpet_department_id: "",
|
|
|
|
accept_admin_id: "",
|
|
|
|
accept_admin_id: "",
|
|
|
|
accept_goods_admin_id: "",
|
|
|
|
accept_goods_admin_id: "",
|
|
|
|
|
|
|
|
|
|
|
|
checkRecord:'',
|
|
|
|
checkRecord: '',
|
|
|
|
checkForm:{},
|
|
|
|
checkForm: {},
|
|
|
|
codeForm:{}
|
|
|
|
codeForm: {}
|
|
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
form: {},
|
|
|
|
form: {},
|
|
|
|
checkForm:{},//审核
|
|
|
|
checkForm: {}, //审核
|
|
|
|
codeForm:{},// 核验
|
|
|
|
codeForm: {}, // 核验
|
|
|
|
codeType:'',
|
|
|
|
codeType: '',
|
|
|
|
gateAdminId:'',
|
|
|
|
gateAdminId: '',
|
|
|
|
check_admin_name:"",
|
|
|
|
check_admin_name: "",
|
|
|
|
followTable: [{
|
|
|
|
followTable: [{
|
|
|
|
label: "姓名",
|
|
|
|
label: "姓名",
|
|
|
|
prop: "name",
|
|
|
|
prop: "name",
|
|
|
|
@ -339,35 +344,53 @@
|
|
|
|
prop: "idcard",
|
|
|
|
prop: "idcard",
|
|
|
|
width: 200
|
|
|
|
width: 200
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
|
|
|
|
statusList: [{
|
|
|
|
|
|
|
|
id: 0,
|
|
|
|
|
|
|
|
value: "待审核"
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
id: 1,
|
|
|
|
|
|
|
|
value: "通过"
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
id: 2,
|
|
|
|
|
|
|
|
value: "驳回"
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
],
|
|
|
|
],
|
|
|
|
|
|
|
|
statusList: [{
|
|
|
|
|
|
|
|
id: 0,
|
|
|
|
|
|
|
|
value: "待审核"
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
id: 1,
|
|
|
|
|
|
|
|
value: "通过"
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
id: 2,
|
|
|
|
|
|
|
|
value: "驳回"
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
isCheck:false
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
created() {
|
|
|
|
created() {
|
|
|
|
// this.getVisitTime()
|
|
|
|
// this.getVisitTime()
|
|
|
|
|
|
|
|
this.getUserId()
|
|
|
|
},
|
|
|
|
},
|
|
|
|
watch: {
|
|
|
|
watch: {
|
|
|
|
isShow(newVal) {
|
|
|
|
isShow(newVal) {
|
|
|
|
if (newVal) {
|
|
|
|
if (newVal) {
|
|
|
|
this.checkForm.visit_id = this.form.id
|
|
|
|
let that = this
|
|
|
|
this.codeForm.type = parseInt(this.codeType)
|
|
|
|
if (this.formDataType == 'checkrecord') {
|
|
|
|
this.codeForm.admin_id = parseInt(this.gateAdminId)
|
|
|
|
this.checkForm.visit_id = this.form.id
|
|
|
|
if(this.formDataType=='coderecord'){
|
|
|
|
for (let item of that.form.audit) {
|
|
|
|
this.$nextTick(() => {
|
|
|
|
console.log('item', item.audit_admin_id)
|
|
|
|
this.$refs.codeInput.focus()
|
|
|
|
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)
|
|
|
|
|
|
|
|
this.$nextTick(() => {
|
|
|
|
|
|
|
|
this.$refs.codeInput.focus()
|
|
|
|
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
this.reset()
|
|
|
|
this.reset()
|
|
|
|
@ -375,49 +398,53 @@
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
selectLevel(val){
|
|
|
|
selectLevel(val) {
|
|
|
|
this.form.audit.map(item=>{
|
|
|
|
this.form.audit.map(item => {
|
|
|
|
if(item.level==val){
|
|
|
|
if (item.level == val) {
|
|
|
|
this.checkForm.level = item.level
|
|
|
|
this.checkForm.level = item.level
|
|
|
|
this.checkForm.id = item.id
|
|
|
|
this.checkForm.id = item.id
|
|
|
|
this.checkForm.audit_admin_id = item.audit_admin_id
|
|
|
|
this.checkForm.audit_admin_id = item.audit_admin_id
|
|
|
|
this.check_admin_name = item.audit_admin?item.audit_admin.name:''
|
|
|
|
this.check_admin_name = item.audit_admin ? item.audit_admin.name : ''
|
|
|
|
}
|
|
|
|
}
|
|
|
|
})
|
|
|
|
})
|
|
|
|
},
|
|
|
|
},
|
|
|
|
reset(){
|
|
|
|
async getUserId() {
|
|
|
|
this.formDataType=''
|
|
|
|
const res = await getInfo()
|
|
|
|
this.checkForm = {}
|
|
|
|
this.userId = res.id
|
|
|
|
this.check_admin_name = ''
|
|
|
|
},
|
|
|
|
this.codeForm={}
|
|
|
|
reset() {
|
|
|
|
this.codeType = ''
|
|
|
|
this.formDataType = ''
|
|
|
|
this.gateAdminId=''
|
|
|
|
this.checkForm = {}
|
|
|
|
this.isShow = false
|
|
|
|
this.check_admin_name = ''
|
|
|
|
this.$refs['dialog'].reset()
|
|
|
|
this.codeForm = {}
|
|
|
|
},
|
|
|
|
this.codeType = ''
|
|
|
|
checkSubmit(){
|
|
|
|
this.gateAdminId = ''
|
|
|
|
console.log(this.checkForm)
|
|
|
|
this.isShow = false
|
|
|
|
// return
|
|
|
|
this.$refs['dialog'].reset()
|
|
|
|
let that = this
|
|
|
|
},
|
|
|
|
// this.form.id = this.id
|
|
|
|
checkSubmit() {
|
|
|
|
save({
|
|
|
|
console.log(this.checkForm)
|
|
|
|
...that.checkForm
|
|
|
|
// return
|
|
|
|
}).then(res => {
|
|
|
|
let that = this
|
|
|
|
this.$successMessage('审核成功')
|
|
|
|
// this.form.id = this.id
|
|
|
|
this.isShow = false
|
|
|
|
save({
|
|
|
|
this.$emit('refresh')
|
|
|
|
...that.checkForm
|
|
|
|
})
|
|
|
|
}).then(res => {
|
|
|
|
},
|
|
|
|
this.$successMessage('审核成功')
|
|
|
|
codeSubmit(){
|
|
|
|
this.isShow = false
|
|
|
|
let that = this
|
|
|
|
this.$emit('refresh')
|
|
|
|
console.log(this.codeForm)
|
|
|
|
})
|
|
|
|
cancelCode({
|
|
|
|
},
|
|
|
|
...that.codeForm
|
|
|
|
codeSubmit() {
|
|
|
|
}).then(res => {
|
|
|
|
let that = this
|
|
|
|
this.$successMessage('核销成功')
|
|
|
|
console.log(this.codeForm)
|
|
|
|
this.isShow = false
|
|
|
|
cancelCode({
|
|
|
|
this.$emit('refresh')
|
|
|
|
...that.codeForm
|
|
|
|
})
|
|
|
|
}).then(res => {
|
|
|
|
|
|
|
|
this.$successMessage('核销成功')
|
|
|
|
|
|
|
|
this.isShow = false
|
|
|
|
|
|
|
|
this.$emit('refresh')
|
|
|
|
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|