ets-fe-ng-sdk 20.3.17 → 20.3.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/ets-fe-ng-sdk.mjs +25 -11
- package/fesm2022/ets-fe-ng-sdk.mjs.map +1 -1
- package/index.d.ts +11 -11
- package/package.json +1 -1
|
@@ -6763,18 +6763,32 @@ class FilterFormArrayGroupPipe {
|
|
|
6763
6763
|
* @returns Filter function for FormGroups
|
|
6764
6764
|
*/
|
|
6765
6765
|
this.filterFunc = (queryObject, exactMatch) => (group) => {
|
|
6766
|
+
if (!queryObject || queryObject.length === 0)
|
|
6767
|
+
return true;
|
|
6766
6768
|
const formGroupValue = group.getRawValue();
|
|
6767
6769
|
// console.log('formGroupValue', formGroupValue);
|
|
6768
|
-
|
|
6769
|
-
|
|
6770
|
-
|
|
6771
|
-
|
|
6772
|
-
|
|
6773
|
-
|
|
6774
|
-
|
|
6775
|
-
|
|
6776
|
-
|
|
6777
|
-
|
|
6770
|
+
// All conditions must match (AND logic)
|
|
6771
|
+
for (const key of queryObject) {
|
|
6772
|
+
const formValue = formGroupValue[key.key];
|
|
6773
|
+
if (key.type === 'string') {
|
|
6774
|
+
const formValueStr = formValue?.toLowerCase() || '';
|
|
6775
|
+
const keyValueStr = key.value?.toLowerCase() || '';
|
|
6776
|
+
if (exactMatch) {
|
|
6777
|
+
if (formValueStr !== keyValueStr)
|
|
6778
|
+
return false;
|
|
6779
|
+
}
|
|
6780
|
+
else {
|
|
6781
|
+
if (!formValueStr.includes(keyValueStr))
|
|
6782
|
+
return false;
|
|
6783
|
+
}
|
|
6784
|
+
}
|
|
6785
|
+
else {
|
|
6786
|
+
// For non-string types, use strict equality
|
|
6787
|
+
if (formValue !== key.value)
|
|
6788
|
+
return false;
|
|
6789
|
+
}
|
|
6790
|
+
}
|
|
6791
|
+
return true;
|
|
6778
6792
|
};
|
|
6779
6793
|
}
|
|
6780
6794
|
/**
|
|
@@ -20898,7 +20912,7 @@ class TableInputComponent extends FormGeneratorComponent {
|
|
|
20898
20912
|
/** Whether to use partial matching for filters */
|
|
20899
20913
|
this.filterLikeMatch = input(...(ngDevMode ? [undefined, { debugName: "filterLikeMatch" }] : []));
|
|
20900
20914
|
/** Whether to use exact matching for filters (inverse of filterLikeMatch) */
|
|
20901
|
-
this.filterExactMatch = computed(() =>
|
|
20915
|
+
this.filterExactMatch = computed(() => !this.filterLikeMatch(), ...(ngDevMode ? [{ debugName: "filterExactMatch" }] : []));
|
|
20902
20916
|
/** Whether to show the table */
|
|
20903
20917
|
this.isShow = input(...(ngDevMode ? [undefined, { debugName: "isShow" }] : []));
|
|
20904
20918
|
/** The number of items to display per page */
|