Commit a32ebfa7 authored by “yiyousong”'s avatar “yiyousong”

perf: 优化应用数据搜索和系统参数列表搜索

parent 43e8fa08
......@@ -255,32 +255,23 @@ export default {
// 获取数据列表
async getDatasetList() {
this.loading = true;
let orConditionList = [
{
fieldCode: this.fieldCode,
fieldValue: `%${this.searchVal}%`,
},
...this.sortSearch,
];
let res = await getDatasetList({
let obj = {};
let orConditionList = [];
let form = {
page: this.current,
size: this.size,
appId: this.appId,
orConditionList,
// fieldCode: this.fieldCode,
// fieldValue: `%${this.searchVal}%`,
// orConditionList: [
// {
// fieldCode: this.fieldCode,
// fieldValue: `%${this.searchVal}%`,
// },
// {
// fieldCode: "top",
// fieldValue: `%%`,
// },
// ],
});
};
if (this.fieldCode) {
obj.fieldCode = this.fieldCode;
obj.fieldValue = `%${this.searchVal}%`;
orConditionList.push(obj);
}
orConditionList = [...orConditionList, ...this.sortSearch];
if (orConditionList.length) {
form.orConditionList = orConditionList;
}
let res = await getDatasetList(form);
this.loading = false;
if (res.data.code === 1) {
let { data, total } = res.data.data;
......
......@@ -14,11 +14,6 @@
v-model="searchForm.name"
allowClear
/>
<a-input
placeholder="请输入二级组织搜索"
v-model="searchForm.secondOrganize"
allowClear
/>
<a-button type="primary" @click="onSearch">搜索</a-button>
<a-button @click="resetSearch">重置</a-button>
</a-space>
......@@ -185,7 +180,6 @@ export default {
searchValue: "", // 搜索
searchForm: {
name: "",
secondOrganize: "",
},
tableData: [],
selectedRowKeys: [],
......@@ -205,7 +199,6 @@ export default {
page: this.current,
size: this.size,
name: `%${this.searchForm.name}%`,
secondOrganize: `%${this.searchForm.secondOrganize}%`,
});
this.loading = false;
if (res.data.code == 1) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment