精简搜索函数, 添加页面

This commit is contained in:
zhengw
2026-02-06 14:49:13 +08:00
parent 3513a19880
commit 9ce21008a3
64 changed files with 519 additions and 559 deletions

View File

@@ -3,6 +3,7 @@ import {
cloneLite,
getAuthInfo,
getDataSet,
searchValueFormat,
showModal,
sleep,
toArray,
@@ -41,12 +42,7 @@ Page({
},
searchChange(e: any) {
const key = getDataSet(e).key;
this.data.params[key] = e.detail.value;
this.setData({ params: this.data.params });
},
searchChange2(e: any) {
const key = getDataSet(e).key;
const val = `${e.detail.value || ''}`.trim();
const val = searchValueFormat(e.detail.value);
if (val) {
this.data.params[key] = val;
} else {
@@ -54,16 +50,6 @@ Page({
}
this.setData({ params: this.data.params });
},
onOptionChange(e: any) {
const key = getDataSet(e).key;
this.data.params[key] = e.detail.value;
this.setData({ params: this.data.params });
},
datePickerConfirm(e: any) {
const data = getDataSet(e);
this.data.params[data.key] = e.detail.value;
this.setData({ params: this.data.params });
},
searchOk() {
this.getList(1);
},