0
0
Fork 0

Merge pull request 'fix(VnSelect): setOptions when applyFilter' (!969) from warmFix_vnSelect into test

Reviewed-on: verdnatura/salix-front#969
Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
This commit is contained in:
Alex Moreno 2024-11-19 13:40:21 +00:00
commit 38c2f89fba
1 changed files with 4 additions and 1 deletions

View File

@ -202,7 +202,10 @@ async function fetchFilter(val) {
if (fields) fetchOptions.fields = fields;
if (sortBy) fetchOptions.order = sortBy;
arrayData.reset(['skip', 'filter.skip', 'page']);
return (await arrayData.applyFilter({ filter: fetchOptions }))?.data;
const { data } = await arrayData.applyFilter({ filter: fetchOptions });
setOptions(data);
return data;
}
async function filterHandler(val, update) {