Hello Community,
Regarding the subject, I would like to create a dynamic filter for the DataGrid to display records that match the parameter entered in the header (or passed to the page when opened). The problem is that the DataGrid can be filtered by fields of type lookup or guid, but I need to use comparison based on string fields.
Do You have any experience or idea how achieve it ?
It seems that eg. crt.LoadDataRequest is not invoking when DataGrid data source is loaded.
Best regards,
Marcin
Like
Problem solved.
request: "crt.HandleViewModelInitRequest", handler: async (request, next) => { const result = await next?.handle(request); request.$context.GridDetail_0vpyjng_PredefinedFilter={"items": {...}}; return result;
Hi Marcin Kott,
How can u throw "items": {..} to PredefinedFilter.
When I try to delete prefined filters:
request.$context.DataGrid_3dbw6vc_PredefinedFilter = { "items": {} };
Got this error: http://localhost:82/0/DataService/json/SyncReply/SelectQuery 500 (Internal Server Error)
Can u show yours example how to throw filters for items:
request.$context.GridDetail_0vpyjng_PredefinedFilter={"items": {...}};
Best regards,
Maksym