|
|
@ -27,8 +27,7 @@ |
|
|
|
<el-select class="item_width_1" |
|
|
|
v-model="personItem.itemGroupId" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in groupList" |
|
|
|
@click.native="handleSelGroup(personIndex,item)" |
|
|
|
:key="item.id" |
|
|
@ -39,8 +38,7 @@ |
|
|
|
<el-select class="item_width_1" |
|
|
|
v-model="personItem.itemId" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in personItem.itemList" |
|
|
|
@click.native="handleSelGroupItem(personIndex,item)" |
|
|
|
:key="item.itemId" |
|
|
@ -51,9 +49,9 @@ |
|
|
|
<el-select class="item_width_1" |
|
|
|
v-model="personItem.queryType" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in queryList" |
|
|
|
@click.native="handleSelPersonQuery(personIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -65,9 +63,9 @@ |
|
|
|
class="item_width_1" |
|
|
|
v-model="personItem.colVal" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in personItem.colOption" |
|
|
|
@click.native="handleSelPersonValue(personIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -100,9 +98,9 @@ |
|
|
|
class="item_width_1" |
|
|
|
v-model="personItem.nextLogicalRel" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in logicalList" |
|
|
|
@click.native="handleSelPersonLogical(personIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -131,8 +129,7 @@ |
|
|
|
<el-select class="item_width_1" |
|
|
|
v-model="houseItem.colKey" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in houseItemList" |
|
|
|
@click.native="handleSelHouseItem(houseIndex,item)" |
|
|
|
:key="item.colKey" |
|
|
@ -143,9 +140,9 @@ |
|
|
|
<el-select class="item_width_1" |
|
|
|
v-model="houseItem.queryType" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in queryList" |
|
|
|
@click.native="handleSelHouseQuery(houseIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -157,9 +154,9 @@ |
|
|
|
class="item_width_1" |
|
|
|
v-model="houseItem.colVal" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in houseItem.colOption" |
|
|
|
@click.native="handleSelHouseValue(houseIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -192,9 +189,9 @@ |
|
|
|
class="item_width_1" |
|
|
|
v-model="houseItem.nextLogicalRel" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in logicalList" |
|
|
|
@click.native="handleSelHouseLogical(houseIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -223,8 +220,7 @@ |
|
|
|
<el-select class="item_width_1" |
|
|
|
v-model="staticItem.colKey" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in staticItemList" |
|
|
|
@click.native="handleSelStaticItem(staticIndex,item)" |
|
|
|
:key="item.colKey" |
|
|
@ -235,9 +231,9 @@ |
|
|
|
<el-select class="item_width_1" |
|
|
|
v-model="staticItem.queryType" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in queryList" |
|
|
|
@click.native="handleSelStaticQuery(staticIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -249,9 +245,9 @@ |
|
|
|
class="item_width_1" |
|
|
|
v-model="staticItem.colVal" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in staticItem.colOption" |
|
|
|
@click.native="handleSelStaticValue(staticIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -283,9 +279,9 @@ |
|
|
|
class="item_width_1" |
|
|
|
v-model="staticItem.nextLogicalRel" |
|
|
|
size="mini" |
|
|
|
placeholder="全部" |
|
|
|
clearable> |
|
|
|
placeholder="全部"> |
|
|
|
<el-option v-for="item in logicalList" |
|
|
|
@click.native="handleSelStaticLogical(houseIndex,item)" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value"> |
|
|
@ -368,6 +364,11 @@ export default { |
|
|
|
itemList: [], |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
itemGroupName: '', |
|
|
|
itemLabel: '', |
|
|
|
queryTypeName: '', |
|
|
|
colValLabel: '', |
|
|
|
nextLogicalRelName: '', |
|
|
|
|
|
|
|
} |
|
|
|
], |
|
|
@ -384,6 +385,11 @@ export default { |
|
|
|
titleName: '房屋信息', |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
itemGroupName: '房屋信息', |
|
|
|
itemLabel: '', |
|
|
|
queryTypeName: '', |
|
|
|
colValLabel: '', |
|
|
|
nextLogicalRelName: '', |
|
|
|
} |
|
|
|
], |
|
|
|
statRuleList: [], |
|
|
@ -399,13 +405,18 @@ export default { |
|
|
|
titleName: '统计信息', |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
itemGroupName: '统计信息', |
|
|
|
itemLabel: '', |
|
|
|
queryTypeName: '', |
|
|
|
colValLabel: '', |
|
|
|
nextLogicalRelName: '', |
|
|
|
|
|
|
|
} |
|
|
|
], |
|
|
|
okflag: false, |
|
|
|
|
|
|
|
showPersonList: false, |
|
|
|
ruleList: [] |
|
|
|
ruleList: {} |
|
|
|
|
|
|
|
} |
|
|
|
}, |
|
|
@ -414,59 +425,80 @@ export default { |
|
|
|
|
|
|
|
}, |
|
|
|
components: { personListItem }, |
|
|
|
async mounted () { |
|
|
|
this.loadPersonGroup() |
|
|
|
this.loadHouseItem() |
|
|
|
this.loadStaticItem() |
|
|
|
this.loadDicOption() |
|
|
|
async created () { |
|
|
|
this.startLoading() |
|
|
|
await this.loadPersonGroup() |
|
|
|
await this.loadHouseItem() |
|
|
|
await this.loadStaticItem() |
|
|
|
await this.loadDicOption() |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
methods: { |
|
|
|
async setRule (resiRuleList, houseRuleList, statRuleList) { |
|
|
|
// this.startLoading() |
|
|
|
if (this.groupList.length == 0 || this.houseItemList.length === 0 || this.staticItemList.length === 0) { |
|
|
|
setTimeout(() => { |
|
|
|
this.setRule(resiRuleList, houseRuleList, statRuleList); |
|
|
|
}, 500); |
|
|
|
return false |
|
|
|
} |
|
|
|
this.resiRuleList = resiRuleList |
|
|
|
if (this.resiRuleList && this.resiRuleList.length > 0) { |
|
|
|
for (let i = 0; i < this.resiRuleList.length; i++) { |
|
|
|
let element = this.resiRuleList[i] |
|
|
|
|
|
|
|
let selGroup = this.groupList.filter((item) => |
|
|
|
element.itemGroupId === item.id |
|
|
|
); |
|
|
|
console.log(selGroup) |
|
|
|
|
|
|
|
this.resiRuleList.forEach((element, index) => { |
|
|
|
if (selGroup.length > 0) { |
|
|
|
await this.handleSelGroup(i, selGroup[0], true) |
|
|
|
|
|
|
|
let selGroup = this.groupList.filter((item) => |
|
|
|
element.itemGroupId === item.id |
|
|
|
); |
|
|
|
|
|
|
|
if (selGroup.length > 0) { |
|
|
|
this.handleSelGroup(index, selGroup[0], true) |
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
let selItem = element.itemList.filter((item) => |
|
|
|
element.itemId === item.itemId); |
|
|
|
if (selItem.length > 0) { |
|
|
|
await this.handleSelGroupItem(i, selItem[0], true) |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
this.houseRuleList = houseRuleList |
|
|
|
if (this.houseRuleList && this.houseRuleList.length > 0) { |
|
|
|
this.houseRuleList.forEach((element, index) => { |
|
|
|
|
|
|
|
this.houseRuleList.forEach((element, index) => { |
|
|
|
let selHouseItem = this.houseItemList.filter((item) => |
|
|
|
element.colKey === item.colKey |
|
|
|
); |
|
|
|
|
|
|
|
let selHouseItem = this.houseItemList.filter((item) => |
|
|
|
element.colKey === item.colKey |
|
|
|
); |
|
|
|
|
|
|
|
if (selHouseItem.length > 0) { |
|
|
|
this.handleSelHouseItem(index, selHouseItem[0], true) |
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
if (selHouseItem.length > 0) { |
|
|
|
this.handleSelHouseItem(index, selHouseItem[0], true) |
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
} |
|
|
|
this.statRuleList = statRuleList |
|
|
|
if (this.statRuleList && this.statRuleList.length > 0) { |
|
|
|
this.statRuleList.forEach((element, index) => { |
|
|
|
|
|
|
|
this.statRuleList.forEach((element, index) => { |
|
|
|
let selStaticItem = this.staticItemList.filter((item) => |
|
|
|
element.colKey === item.colKey |
|
|
|
); |
|
|
|
|
|
|
|
let selStaticItem = this.staticItemList.filter((item) => |
|
|
|
element.colKey === item.colKey |
|
|
|
); |
|
|
|
if (selStaticItem.length > 0) { |
|
|
|
this.handleSelStaticItem(index, selStaticItem[0], true) |
|
|
|
} |
|
|
|
|
|
|
|
if (selStaticItem.length > 0) { |
|
|
|
this.handleSelStaticItem(index, selStaticItem[0], true) |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
this.endLoading() |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
@ -474,9 +506,9 @@ export default { |
|
|
|
this.okflag = false |
|
|
|
let messageObj = this.validateRule() |
|
|
|
|
|
|
|
console.log('resiRuleList', this.resiRuleList) |
|
|
|
console.log('houseRuleList', this.houseRuleList) |
|
|
|
console.log('statRuleList', this.statRuleList) |
|
|
|
// console.log('resiRuleList', this.resiRuleList) |
|
|
|
// console.log('houseRuleList', this.houseRuleList) |
|
|
|
// console.log('statRuleList', this.statRuleList) |
|
|
|
|
|
|
|
if (messageObj) { |
|
|
|
this.$message.error(messageObj) |
|
|
@ -507,9 +539,7 @@ export default { |
|
|
|
this.resiRuleList.forEach((item, index) => { |
|
|
|
|
|
|
|
if (index === this.resiRuleList.length - 1) { |
|
|
|
if ( |
|
|
|
item.ruleDesc === '' || |
|
|
|
item.itemGroupId === '' || |
|
|
|
if (item.itemGroupId === '' || |
|
|
|
item.itemId === '' || |
|
|
|
item.queryType === '' || |
|
|
|
item.colKey === '' || |
|
|
@ -520,7 +550,6 @@ export default { |
|
|
|
} |
|
|
|
} else { |
|
|
|
if (item.nextLogicalRel === '' || |
|
|
|
item.ruleDesc === '' || |
|
|
|
item.itemGroupId === '' || |
|
|
|
item.itemId === '' || |
|
|
|
item.queryType === '' || |
|
|
@ -538,10 +567,7 @@ export default { |
|
|
|
|
|
|
|
if (index === this.houseRuleList.length - 1) { |
|
|
|
|
|
|
|
if ( |
|
|
|
|
|
|
|
item.ruleDesc === '' || |
|
|
|
item.queryType === '' || |
|
|
|
if (item.queryType === '' || |
|
|
|
item.colKey === '' || |
|
|
|
item.colVal === '') { |
|
|
|
|
|
|
@ -550,7 +576,6 @@ export default { |
|
|
|
} |
|
|
|
} else { |
|
|
|
if (item.nextLogicalRel === '' || |
|
|
|
item.ruleDesc === '' || |
|
|
|
item.queryType === '' || |
|
|
|
item.colKey === '' || |
|
|
|
item.colVal === '') { |
|
|
@ -563,10 +588,7 @@ export default { |
|
|
|
|
|
|
|
this.statRuleList.forEach((item, index) => { |
|
|
|
if (index === this.statRuleList.length - 1) { |
|
|
|
if ( |
|
|
|
|
|
|
|
item.ruleDesc === '' || |
|
|
|
item.queryType === '' || |
|
|
|
if (item.queryType === '' || |
|
|
|
item.colKey === '' || |
|
|
|
item.colVal === '') { |
|
|
|
|
|
|
@ -574,9 +596,7 @@ export default { |
|
|
|
return message |
|
|
|
} |
|
|
|
} else { |
|
|
|
if ( |
|
|
|
item.nextLogicalRel === '' || |
|
|
|
item.ruleDesc === '' || |
|
|
|
if (item.nextLogicalRel === '' || |
|
|
|
item.queryType === '' || |
|
|
|
item.colKey === '' || |
|
|
|
item.colVal === '') { |
|
|
@ -594,118 +614,32 @@ export default { |
|
|
|
handlePreview () { |
|
|
|
this.ruleList = {} |
|
|
|
this.ruleList = { |
|
|
|
resiRuleList: this.resiRuleList, |
|
|
|
houseRuleList: this.houseRuleList, |
|
|
|
statRuleList: this.statRuleList, |
|
|
|
} |
|
|
|
|
|
|
|
this.showPersonList = true |
|
|
|
}, |
|
|
|
|
|
|
|
handleClose () { |
|
|
|
this.showPersonList = false |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
clickTab (type) { |
|
|
|
if (type === 'person') { |
|
|
|
this.personSel = true |
|
|
|
this.houseSel = false |
|
|
|
this.staticSel = false |
|
|
|
} |
|
|
|
if (type === 'house') { |
|
|
|
this.personSel = false |
|
|
|
this.houseSel = true |
|
|
|
this.staticSel = false |
|
|
|
} |
|
|
|
if (type === 'static') { |
|
|
|
this.personSel = false |
|
|
|
this.houseSel = false |
|
|
|
this.staticSel = true |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
addRule () { |
|
|
|
if (this.personSel) { |
|
|
|
this.addPerson() |
|
|
|
resiRuleList: [], |
|
|
|
houseRuleList: [], |
|
|
|
statRuleList: [], |
|
|
|
} |
|
|
|
|
|
|
|
if (this.houseSel) { |
|
|
|
this.addHouse() |
|
|
|
if (this.personChecked) { |
|
|
|
this.ruleList.resiRuleList = this.resiRuleList |
|
|
|
} |
|
|
|
|
|
|
|
if (this.staticSel) { |
|
|
|
this.addStatic() |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
addPerson () { |
|
|
|
let obj = { |
|
|
|
ruleDesc: '',//规则描述文字,例如:基础信息性别等于女 |
|
|
|
nextLogicalRel: 'and',//与上一条的关系;and、or |
|
|
|
itemGroupId: '', |
|
|
|
itemId: '', |
|
|
|
queryType: '', |
|
|
|
colTable: '', |
|
|
|
colKey: '', |
|
|
|
colVal: '', |
|
|
|
|
|
|
|
itemList: [], |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
if (this.houseChecked) { |
|
|
|
this.ruleList.houseRuleList = this.houseRuleList |
|
|
|
} |
|
|
|
|
|
|
|
this.resiRuleList.push(obj) |
|
|
|
}, |
|
|
|
|
|
|
|
delPerson (index) { |
|
|
|
this.resiRuleList.splice(index, 1); |
|
|
|
}, |
|
|
|
|
|
|
|
addHouse () { |
|
|
|
let obj = { |
|
|
|
ruleDesc: '房屋信息', |
|
|
|
nextLogicalRel: 'and',//与上一条的关系;and、or |
|
|
|
queryType: '', |
|
|
|
colTable: '', |
|
|
|
colKey: '', |
|
|
|
colVal: '', |
|
|
|
|
|
|
|
titleName: '房屋信息', |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
if (this.staticChecked) { |
|
|
|
this.ruleList.statRuleList = this.statRuleList |
|
|
|
} |
|
|
|
|
|
|
|
this.houseRuleList.push(obj) |
|
|
|
}, |
|
|
|
|
|
|
|
delHouse (index) { |
|
|
|
this.houseRuleList.splice(index, 1); |
|
|
|
this.showPersonList = true |
|
|
|
}, |
|
|
|
|
|
|
|
addStatic () { |
|
|
|
let obj = { |
|
|
|
ruleDesc: '统计信息', |
|
|
|
nextLogicalRel: 'and',//与上一条的关系;and、or |
|
|
|
queryType: '', |
|
|
|
colTable: '', |
|
|
|
colKey: '', |
|
|
|
colVal: '', |
|
|
|
|
|
|
|
titleName: '统计信息', |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
} |
|
|
|
handleClose () { |
|
|
|
this.showPersonList = false |
|
|
|
|
|
|
|
this.statRuleList.push(obj) |
|
|
|
}, |
|
|
|
|
|
|
|
delStatic (index) { |
|
|
|
this.statRuleList.splice(index, 1); |
|
|
|
}, |
|
|
|
|
|
|
|
//选择人员信息第一列下拉框 |
|
|
|
async handleSelGroup (personIndex, item, isEdit) { |
|
|
|
async handleSelGroup (personIndex, item, isSet) { |
|
|
|
const url = '/oper/customize/icformitem/getItemListV2' |
|
|
|
// const url = 'http://yapi.elinkservice.cn/mock/245/gov/org/isServiceProject/service/serviceScopeTree' |
|
|
|
let params = { |
|
|
@ -717,34 +651,41 @@ export default { |
|
|
|
const { data, code, msg } = await requestPost(url, params) |
|
|
|
|
|
|
|
if (code === 0) { |
|
|
|
|
|
|
|
let oneData = this.resiRuleList[personIndex] |
|
|
|
oneData.ruleDesc = item.label |
|
|
|
oneData.itemGroupName = item.label |
|
|
|
oneData.itemList = data |
|
|
|
oneData.colTable = item.tableName |
|
|
|
this.$set(this.resiRuleList, personIndex, oneData) |
|
|
|
|
|
|
|
if (isEdit) { |
|
|
|
let selItem = oneData.itemList.filter((item) => |
|
|
|
oneData.itemId === item.itemId); |
|
|
|
if (selItem.length > 0) { |
|
|
|
this.handleSelGroupItem(personIndex, selItem[0]) |
|
|
|
} |
|
|
|
if (!isSet) {//如果是详情,赋值,不需要置空 |
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
oneData.itemId = '' |
|
|
|
oneData.queryType = '' |
|
|
|
oneData.colKey = '' |
|
|
|
oneData.colVal = '' |
|
|
|
} |
|
|
|
|
|
|
|
this.$set(this.resiRuleList, personIndex, oneData) |
|
|
|
|
|
|
|
} else { |
|
|
|
this.$message.error(msg) |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
//选择人员信息第二列下拉框 |
|
|
|
async handleSelGroupItem (personIndex, item) { |
|
|
|
async handleSelGroupItem (personIndex, item, isSet) { |
|
|
|
|
|
|
|
let oneData = this.resiRuleList[personIndex] |
|
|
|
|
|
|
|
oneData.colKey = item.columnName |
|
|
|
oneData.colType = item.itemType |
|
|
|
oneData.itemLabel = item.label |
|
|
|
|
|
|
|
oneData.ruleDesc = oneData.ruleDesc + item.label |
|
|
|
|
|
|
|
if (!isSet) {//如果是详情,赋值,不需要置空 |
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
oneData.queryType = '' |
|
|
|
oneData.colVal = '' |
|
|
|
} |
|
|
|
|
|
|
|
if (item.optionSourceType === 'remote') { |
|
|
|
const url = item.optionSourceValue |
|
|
@ -767,14 +708,49 @@ export default { |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
//选择人员信息第三列 |
|
|
|
handleSelPersonQuery (personIndex, item) { |
|
|
|
let oneData = this.resiRuleList[personIndex] |
|
|
|
oneData.queryTypeName = item.label |
|
|
|
|
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
oneData.colVal = '' |
|
|
|
oneData.colValLabel = '' |
|
|
|
|
|
|
|
this.$set(this.resiRuleList, personIndex, oneData) |
|
|
|
}, |
|
|
|
//选择人员信息第四列 |
|
|
|
handleSelPersonValue (personIndex, item) { |
|
|
|
let oneData = this.resiRuleList[personIndex] |
|
|
|
|
|
|
|
oneData.colValLabel = item.label |
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
|
|
|
|
this.$set(this.resiRuleList, personIndex, oneData) |
|
|
|
}, |
|
|
|
//选择人员信息第五列 |
|
|
|
handleSelPersonLogical (personIndex, item) { |
|
|
|
let oneData = this.resiRuleList[personIndex] |
|
|
|
|
|
|
|
oneData.nextLogicalRelName = item.label |
|
|
|
|
|
|
|
this.$set(this.resiRuleList, personIndex, oneData) |
|
|
|
}, |
|
|
|
|
|
|
|
//选择房屋信息第二列下拉框 |
|
|
|
async handleSelHouseItem (houseIndex, item) { |
|
|
|
async handleSelHouseItem (houseIndex, item, isSet) { |
|
|
|
|
|
|
|
let oneData = this.houseRuleList[houseIndex] |
|
|
|
|
|
|
|
oneData.colTable = item.tableName |
|
|
|
oneData.colType = item.itemType |
|
|
|
oneData.ruleDesc = oneData.ruleDesc + item.label |
|
|
|
oneData.itemLabel = item.label |
|
|
|
|
|
|
|
if (!isSet) {//如果是详情,赋值,不需要置空 |
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
oneData.queryType = '' |
|
|
|
oneData.colVal = '' |
|
|
|
} |
|
|
|
|
|
|
|
if (item.optionSourceType === 'remote') { |
|
|
|
const url = item.optionSourceUrl |
|
|
@ -796,18 +772,50 @@ export default { |
|
|
|
oneData.colOption = [] |
|
|
|
} |
|
|
|
|
|
|
|
this.$set(this.houseRuleList, houseIndex, oneData) |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
//选择房屋第三列 |
|
|
|
handleSelHouseQuery (houseIndex, item) { |
|
|
|
let oneData = this.houseRuleList[houseIndex] |
|
|
|
oneData.queryTypeName = item.label |
|
|
|
|
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
oneData.colVal = '' |
|
|
|
oneData.colValLabel = '' |
|
|
|
|
|
|
|
this.$set(this.houseRuleList, houseIndex, oneData) |
|
|
|
}, |
|
|
|
//选择房屋第四列 |
|
|
|
handleSelHouseValue (houseIndex, item) { |
|
|
|
let oneData = this.houseRuleList[houseIndex] |
|
|
|
oneData.colValLabel = item.label |
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
|
|
|
|
this.$set(this.houseRuleList, houseIndex, oneData) |
|
|
|
}, |
|
|
|
//选择房屋第五列 |
|
|
|
handleSelHouseLogical (houseIndex, item) { |
|
|
|
let oneData = this.houseRuleList[houseIndex] |
|
|
|
oneData.nextLogicalRelName = item.label |
|
|
|
|
|
|
|
this.$set(this.houseRuleList, houseIndex, oneData) |
|
|
|
}, |
|
|
|
//选择统计信息第二列下拉框 |
|
|
|
async handleSelStaticItem (staticIndex, item) { |
|
|
|
async handleSelStaticItem (staticIndex, item, isSet) { |
|
|
|
|
|
|
|
let oneData = this.statRuleList[staticIndex] |
|
|
|
|
|
|
|
oneData.colTable = item.tableName |
|
|
|
oneData.colType = item.itemType |
|
|
|
oneData.ruleDesc = oneData.ruleDesc + item.label |
|
|
|
oneData.itemLabel = item.label |
|
|
|
|
|
|
|
if (!isSet) {//如果是详情,赋值,不需要置空 |
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
oneData.queryType = '' |
|
|
|
oneData.colVal = '' |
|
|
|
} |
|
|
|
|
|
|
|
if (item.optionSourceType === 'remote') { |
|
|
|
const url = item.optionSourceUrl |
|
|
@ -834,6 +842,145 @@ export default { |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
//选择统计信息第三列 |
|
|
|
handleSelStaticQuery (staticIndex, item) { |
|
|
|
let oneData = this.statRuleList[staticIndex] |
|
|
|
oneData.queryTypeName = item.label |
|
|
|
|
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
oneData.colVal = '' |
|
|
|
oneData.colValLabel = '' |
|
|
|
|
|
|
|
this.$set(this.statRuleList, staticIndex, oneData) |
|
|
|
}, |
|
|
|
//选择统计信息第四列 |
|
|
|
handleSelStaticValue (staticIndex, item) { |
|
|
|
let oneData = this.statRuleList[staticIndex] |
|
|
|
oneData.colValLabel = item.label |
|
|
|
oneData.nextLogicalRel = '' |
|
|
|
|
|
|
|
this.$set(this.statRuleList, staticIndex, oneData) |
|
|
|
}, |
|
|
|
//选择统计信息第五列 |
|
|
|
handleSelStaticLogical (staticIndex, item) { |
|
|
|
let oneData = this.statRuleList[staticIndex] |
|
|
|
oneData.nextLogicalRelName = item.label |
|
|
|
|
|
|
|
this.$set(this.statRuleList, staticIndex, oneData) |
|
|
|
}, |
|
|
|
|
|
|
|
clickTab (type) { |
|
|
|
if (type === 'person') { |
|
|
|
this.personSel = true |
|
|
|
this.houseSel = false |
|
|
|
this.staticSel = false |
|
|
|
} |
|
|
|
if (type === 'house') { |
|
|
|
this.personSel = false |
|
|
|
this.houseSel = true |
|
|
|
this.staticSel = false |
|
|
|
} |
|
|
|
if (type === 'static') { |
|
|
|
this.personSel = false |
|
|
|
this.houseSel = false |
|
|
|
this.staticSel = true |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
addRule () { |
|
|
|
if (this.personSel) { |
|
|
|
this.addPerson() |
|
|
|
} |
|
|
|
|
|
|
|
if (this.houseSel) { |
|
|
|
this.addHouse() |
|
|
|
} |
|
|
|
|
|
|
|
if (this.staticSel) { |
|
|
|
this.addStatic() |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
addPerson () { |
|
|
|
let obj = { |
|
|
|
ruleDesc: '',//规则描述文字,例如:基础信息性别等于女 |
|
|
|
nextLogicalRel: 'and',//与上一条的关系;and、or |
|
|
|
itemGroupId: '', |
|
|
|
itemId: '', |
|
|
|
queryType: '', |
|
|
|
colTable: '', |
|
|
|
colKey: '', |
|
|
|
colVal: '', |
|
|
|
|
|
|
|
itemList: [], |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
itemGroupName: '', |
|
|
|
itemLabel: '', |
|
|
|
queryTypeName: '', |
|
|
|
colValLabel: '', |
|
|
|
nextLogicalRelName: '', |
|
|
|
} |
|
|
|
|
|
|
|
this.resiRuleList.push(obj) |
|
|
|
}, |
|
|
|
|
|
|
|
delPerson (index) { |
|
|
|
this.resiRuleList.splice(index, 1); |
|
|
|
}, |
|
|
|
|
|
|
|
addHouse () { |
|
|
|
let obj = { |
|
|
|
ruleDesc: '', |
|
|
|
nextLogicalRel: 'and',//与上一条的关系;and、or |
|
|
|
queryType: '', |
|
|
|
colTable: '', |
|
|
|
colKey: '', |
|
|
|
colVal: '', |
|
|
|
|
|
|
|
titleName: '房屋信息', |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
itemGroupName: '房屋信息', |
|
|
|
itemLabel: '', |
|
|
|
queryTypeName: '', |
|
|
|
colValLabel: '', |
|
|
|
nextLogicalRelName: '', |
|
|
|
} |
|
|
|
|
|
|
|
this.houseRuleList.push(obj) |
|
|
|
}, |
|
|
|
|
|
|
|
delHouse (index) { |
|
|
|
this.houseRuleList.splice(index, 1); |
|
|
|
}, |
|
|
|
|
|
|
|
addStatic () { |
|
|
|
let obj = { |
|
|
|
ruleDesc: '', |
|
|
|
nextLogicalRel: 'and',//与上一条的关系;and、or |
|
|
|
queryType: '', |
|
|
|
colTable: '', |
|
|
|
colKey: '', |
|
|
|
colVal: '', |
|
|
|
|
|
|
|
titleName: '统计信息', |
|
|
|
colType: '',//详细参数的组件类型 |
|
|
|
colOption: [], |
|
|
|
itemGroupName: '统计信息', |
|
|
|
itemLabel: '', |
|
|
|
queryTypeName: '', |
|
|
|
colValLabel: '', |
|
|
|
nextLogicalRelName: '', |
|
|
|
} |
|
|
|
|
|
|
|
this.statRuleList.push(obj) |
|
|
|
}, |
|
|
|
|
|
|
|
delStatic (index) { |
|
|
|
this.statRuleList.splice(index, 1); |
|
|
|
}, |
|
|
|
|
|
|
|
// 获取人员信息---第一列 |
|
|
|
async loadPersonGroup () { |
|
|
|
const url = '/oper/customize/icformitemgroup/list' |
|
|
|