Implementing filter and sort in back

This commit is contained in:
2025-04-01 18:40:45 +02:00
parent 59cc709ed5
commit 56ca5156c4
8 changed files with 53 additions and 91 deletions

View File

@@ -111,7 +111,7 @@ export class ListComponent implements OnInit {
private _search() {
this._loading$.next(true);
let sortBy = new SortBy(this.sortColumn, this.sortDirection)
let filters = this.searchTerm ? [new Filters('fulltext', 'eq', this.searchTerm)] : [];
let filters = this.searchTerm ? [new Filters('label', 'ilike', this.searchTerm)] : [];
for (let f in this.searchFilters) {
if (Array.isArray(this.searchFilters[f])) {
filters.push(new Filters(f, 'in', this.searchFilters[f]))

View File

@@ -142,7 +142,7 @@ export class ForeignkeyTypeComponent extends FieldType<FieldTypeConfig> implemen
1,
10,
[],
[new Filters('fulltext', 'eq', term)]
[new Filters('label', 'ilike', term)]
).pipe(
map((result: any) => result["items"]),
);