特约商户添加筛选
This commit is contained in:
parent
046bf46262
commit
c6e8e6f2e3
|
@ -1,5 +1,49 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
|
|
||||||
|
<div class="filter-container">
|
||||||
|
<el-input
|
||||||
|
v-model="listQuery.params.name"
|
||||||
|
style="width:200px;margin-right:10px"
|
||||||
|
class="filter-item"
|
||||||
|
placeholder="姓名"
|
||||||
|
clearable
|
||||||
|
/>
|
||||||
|
<el-input
|
||||||
|
v-model="listQuery.params.phone"
|
||||||
|
style="width:200px;margin-right:10px"
|
||||||
|
class="filter-item"
|
||||||
|
placeholder="手机号"
|
||||||
|
clearable
|
||||||
|
/>
|
||||||
|
<el-input
|
||||||
|
v-model="listQuery.params.idCard"
|
||||||
|
style="width:200px;margin-right:10px"
|
||||||
|
class="filter-item"
|
||||||
|
placeholder="身份证号"
|
||||||
|
clearable
|
||||||
|
/>
|
||||||
|
<el-cascader
|
||||||
|
v-model="regionSearchVal"
|
||||||
|
class="filter-item"
|
||||||
|
style="width:240px"
|
||||||
|
:options="regions"
|
||||||
|
:props="{ checkStrictly: true }"
|
||||||
|
placeholder="行政区域"
|
||||||
|
clearable
|
||||||
|
/>
|
||||||
|
<el-checkbox
|
||||||
|
v-model="isStaff"
|
||||||
|
style="margin-left:10px"
|
||||||
|
@change="handleIsStaff"
|
||||||
|
>是否是便民工作人员</el-checkbox>
|
||||||
|
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
style="margin-left:10px"
|
||||||
|
@click="handleSearch"
|
||||||
|
>搜索</el-button>
|
||||||
|
</div>
|
||||||
<!-- <el-button
|
<!-- <el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
size="mini"
|
size="mini"
|
||||||
|
@ -196,8 +240,13 @@ export default {
|
||||||
total: 0,
|
total: 0,
|
||||||
listQuery: {
|
listQuery: {
|
||||||
lastPageIndex: 1,
|
lastPageIndex: 1,
|
||||||
// params: {},
|
size: 10,
|
||||||
size: 10
|
params: {
|
||||||
|
name: undefined,
|
||||||
|
phone: undefined,
|
||||||
|
idCard: undefined,
|
||||||
|
isConvenience: undefined
|
||||||
|
}
|
||||||
},
|
},
|
||||||
list: undefined,
|
list: undefined,
|
||||||
|
|
||||||
|
@ -235,7 +284,10 @@ export default {
|
||||||
value: 'TEMPORARY'
|
value: 'TEMPORARY'
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
regions: []
|
regions: [],
|
||||||
|
|
||||||
|
isStaff: undefined,
|
||||||
|
regionSearchVal: undefined
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
|
@ -285,7 +337,7 @@ export default {
|
||||||
const countyArr = [] // 县,1
|
const countyArr = [] // 县,1
|
||||||
tempData.map(county => {
|
tempData.map(county => {
|
||||||
const countyObj = {
|
const countyObj = {
|
||||||
value: county.root.id,
|
value: county.root.name,
|
||||||
label: county.root.name,
|
label: county.root.name,
|
||||||
disabled: !county.root.check,
|
disabled: !county.root.check,
|
||||||
children: []
|
children: []
|
||||||
|
@ -293,7 +345,7 @@ export default {
|
||||||
countyArr.push(countyObj)
|
countyArr.push(countyObj)
|
||||||
county.node.map(town => {
|
county.node.map(town => {
|
||||||
const townObj = {
|
const townObj = {
|
||||||
value: town.root.id,
|
value: town.root.name,
|
||||||
label: town.root.name,
|
label: town.root.name,
|
||||||
disabled: !town.root.check,
|
disabled: !town.root.check,
|
||||||
children: []
|
children: []
|
||||||
|
@ -301,7 +353,7 @@ export default {
|
||||||
countyObj.children.push(townObj)
|
countyObj.children.push(townObj)
|
||||||
town.node.map(country => {
|
town.node.map(country => {
|
||||||
townObj.children.push({
|
townObj.children.push({
|
||||||
value: country.root.id,
|
value: country.root.name,
|
||||||
label: country.root.name,
|
label: country.root.name,
|
||||||
disabled: !country.root.check
|
disabled: !country.root.check
|
||||||
})
|
})
|
||||||
|
@ -392,6 +444,42 @@ export default {
|
||||||
// },
|
// },
|
||||||
closeDia() {
|
closeDia() {
|
||||||
this.diaVisible = false
|
this.diaVisible = false
|
||||||
|
},
|
||||||
|
handleIsStaff(val) {
|
||||||
|
if (val === false) {
|
||||||
|
this.listQuery.params.isConvenience === undefined
|
||||||
|
const temp = Object.assign({}, this.listQuery)
|
||||||
|
temp.params.isConvenience === undefined
|
||||||
|
this.listQuery = temp
|
||||||
|
}
|
||||||
|
},
|
||||||
|
handleSearch() {
|
||||||
|
this.listQuery.params.isConvenience = this.isStaff ? true : undefined
|
||||||
|
if (this.regionSearchVal) {
|
||||||
|
switch (this.regionSearchVal.length) {
|
||||||
|
case 1:
|
||||||
|
this.listQuery.params.PermanentResidenceRegion = this.regionSearchVal[0]
|
||||||
|
this.listQuery.params.PermanentResidenceTown = undefined
|
||||||
|
this.listQuery.params.PermanentResidenceTownShip = undefined
|
||||||
|
break
|
||||||
|
case 2:
|
||||||
|
this.listQuery.params.PermanentResidenceTown = this.regionSearchVal[1]
|
||||||
|
this.listQuery.params.PermanentResidenceRegion = undefined
|
||||||
|
this.listQuery.params.PermanentResidenceTownShip = undefined
|
||||||
|
break
|
||||||
|
case 3:
|
||||||
|
this.listQuery.params.PermanentResidenceTownShip = this.regionSearchVal[2]
|
||||||
|
this.listQuery.params.PermanentResidenceRegion = undefined
|
||||||
|
this.listQuery.params.PermanentResidenceTown = undefined
|
||||||
|
break
|
||||||
|
default:
|
||||||
|
this.listQuery.params.PermanentResidenceRegion = undefined
|
||||||
|
this.listQuery.params.PermanentResidenceTown = undefined
|
||||||
|
this.listQuery.params.PermanentResidenceTownShip = undefined
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
this.getList()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue