|
|
@ -67,6 +67,7 @@ const typeRef = ref() |
|
|
|
const rowRef = ref() |
|
|
|
const allSchemasRef = ref() |
|
|
|
const multipleBol = ref(false) |
|
|
|
const searchConditionRef = ref() |
|
|
|
const open = (titleName: any, allSchemas: any,getApiPage: any, formField: any, searchField: any,multiple: any, type: any, row: any, searchCondition:any , isCountRequestRe:any ) => { |
|
|
|
searchDialogVisible.value = true |
|
|
|
formFieldRef.value = formField |
|
|
@ -84,6 +85,7 @@ const open = (titleName: any, allSchemas: any,getApiPage: any, formField: any, s |
|
|
|
getListApi: getPage.value // 分页接口 |
|
|
|
}) |
|
|
|
tableObjectRef.value = tableObject |
|
|
|
searchConditionRef.value = searchCondition |
|
|
|
if (searchCondition) tableObjectRef.value.params = searchCondition; |
|
|
|
|
|
|
|
// 获得表格的各种操作 |
|
|
@ -98,16 +100,24 @@ const open = (titleName: any, allSchemas: any,getApiPage: any, formField: any, s |
|
|
|
const searchFormClick = (searchData) => { |
|
|
|
// console.log(99, rowRef.value) |
|
|
|
// console.log(100, searchData) |
|
|
|
// console.log(101, tableObjectRef.value.params) |
|
|
|
|
|
|
|
// console.log(101, searchConditionRef.value) |
|
|
|
// 20240104 修改 判断 当前弹窗 是否有条件 如果有条件 需拼接到 筛选中 searchData.filters |
|
|
|
if (tableObjectRef.value.params) { |
|
|
|
Object.keys(tableObjectRef.value.params).forEach(key => { |
|
|
|
searchData.filters.push({ |
|
|
|
action: "==", |
|
|
|
column: key, |
|
|
|
value: tableObjectRef.value.params[key] |
|
|
|
}) |
|
|
|
if (searchConditionRef.value) { |
|
|
|
Object.keys(searchConditionRef.value).forEach(key => { |
|
|
|
if (searchData.filters) { |
|
|
|
searchData.filters.push({ |
|
|
|
action: "==", |
|
|
|
column: key, |
|
|
|
value: searchConditionRef.value[key] |
|
|
|
}) |
|
|
|
// } |
|
|
|
} else { |
|
|
|
searchData.filters = [{ |
|
|
|
action: "==", |
|
|
|
column: key, |
|
|
|
value: searchConditionRef.value[key] |
|
|
|
}] |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
tableObjectRef.value.params = { |
|
|
|