|  |  |  | 
|---|
|  |  |  | <el-form-item label="身份证号" prop="idcardNo"> | 
|---|
|  |  |  | <el-input v-model="searchForm.idcardNo" placeholder="请输入身份证号" @keypress.enter.native="search"></el-input> | 
|---|
|  |  |  | </el-form-item> | 
|---|
|  |  |  | <el-form-item label="公司名称" prop="companyName"> | 
|---|
|  |  |  | <el-input v-model="searchForm.companyName" placeholder="请输入公司名称" @keypress.enter.native="search"></el-input> | 
|---|
|  |  |  | <el-form-item label="组织名称" prop="companyName"> | 
|---|
|  |  |  | <el-input v-model="searchForm.companyName" placeholder="请输入组织名称" @keypress.enter.native="search"></el-input> | 
|---|
|  |  |  | </el-form-item> | 
|---|
|  |  |  | <el-form-item label="审批状态" prop="status"> | 
|---|
|  |  |  | <el-select v-model="searchForm.status" placeholder="请选择"> | 
|---|
|  |  |  | 
|---|
|  |  |  | <el-table-column type="selection" width="55"></el-table-column> | 
|---|
|  |  |  | <el-table-column prop="name" label="访客姓名" min-width="100px"></el-table-column> | 
|---|
|  |  |  | <el-table-column prop="phone" label="手机号" min-width="100px"></el-table-column> | 
|---|
|  |  |  | <el-table-column prop="companyName" label="公司名称" min-width="100px"></el-table-column> | 
|---|
|  |  |  | <el-table-column prop="companyName" label="组织名称" min-width="100px"></el-table-column> | 
|---|
|  |  |  | <el-table-column prop="receptMemberName" label="被访人" min-width="100px"></el-table-column> | 
|---|
|  |  |  | <el-table-column prop="reason" label="拜访事由" min-width="100px"></el-table-column> | 
|---|
|  |  |  | <el-table-column label="预约时间" min-width="170px"> | 
|---|
|  |  |  | 
|---|
|  |  |  | fixed="right" | 
|---|
|  |  |  | > | 
|---|
|  |  |  | <template slot-scope="{row}"> | 
|---|
|  |  |  | <el-button type="text" @click="$refs.OperaVisitsDesWindow.open('详情', row.id)" v-permissions="['business:visits:update']">查看详情</el-button> | 
|---|
|  |  |  | <el-button type="text" @click="departure(row.id)" v-permissions="['business:visits:level']" icon="el-icon-delete" style="color: red" v-if="row.status == 7">离厂</el-button> | 
|---|
|  |  |  | <el-button type="text" @click="cancel(row.id)" v-permissions="['business:visits:cancel']" icon="el-icon-delete"   style="color: red" v-if="row.status == 5">取消预约</el-button> | 
|---|
|  |  |  | <el-button type="text" @click="$refs.OperaVisitsDesWindow.open('详情', row.id)" icon="el-icon-view">详情</el-button> | 
|---|
|  |  |  | <!--                        <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:visits:delete']">查询审批结果</el-button>--> | 
|---|
|  |  |  | </template> | 
|---|
|  |  |  | </el-table-column> | 
|---|
|  |  |  | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | this.search() | 
|---|
|  |  |  | }, | 
|---|
|  |  |  | methods: { | 
|---|
|  |  |  | departure(id) { | 
|---|
|  |  |  | this.$confirm('确定离场吗, 是否继续?', '提示', { | 
|---|
|  |  |  | confirmButtonText: '确定', | 
|---|
|  |  |  | cancelButtonText: '取消', | 
|---|
|  |  |  | type: 'warning' | 
|---|
|  |  |  | }).then(() => { | 
|---|
|  |  |  | level(id) | 
|---|
|  |  |  | .then(res => { | 
|---|
|  |  |  | this.page = 1 | 
|---|
|  |  |  | this.getData() | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | }).catch(() => { | 
|---|
|  |  |  |  | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | }, | 
|---|
|  |  |  | cancel(id) { | 
|---|
|  |  |  | this.$confirm('确定取消预约吗, 是否继续?', '提示', { | 
|---|
|  |  |  | confirmButtonText: '确定', | 
|---|
|  |  |  | cancelButtonText: '取消', | 
|---|
|  |  |  | type: 'warning' | 
|---|
|  |  |  | }).then(() => { | 
|---|
|  |  |  | visitCancel(id) | 
|---|
|  |  |  | .then(res => { | 
|---|
|  |  |  | this.page = 1 | 
|---|
|  |  |  | this.getData() | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | }).catch(() => { | 
|---|
|  |  |  |  | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | }, | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | </script> | 
|---|