0
0
Fork 0

Merge pull request 'Solucion comentario' (#51) from fixes/issuecomment_37214 into branch-PR-2

Reviewed-on: hyervoni/salix-front-mindshore#51
This commit is contained in:
Carlos Fonseca 2024-01-02 15:30:32 +00:00
commit 3118d64d5d
1 changed files with 10 additions and 15 deletions

View File

@ -67,24 +67,19 @@ function exprBuilder(param, value) {
return { [param]: value }; return { [param]: value };
} }
} }
const setCategoryList = (data) => {
categoryList.value = (data || [])
.filter((category) => category.display)
.map((category) => ({
...category,
icon: `vn:${(category.icon || '').split('-')[1]}`,
}));
};
</script> </script>
<template> <template>
<FetchData <FetchData url="ItemCategories" limit="30" auto-load @on-fetch="setCategoryList" />
url="ItemCategories"
limit="30"
auto-load
@on-fetch="
(data) => {
categoryList = (data || [])
.filter((category) => category.display)
.map((category) => ({
...category,
icon: `vn:${(category.icon || '').split('-')[1]}`,
}));
}
"
/>
<VnFilterPanel <VnFilterPanel
:data-key="props.dataKey" :data-key="props.dataKey"
:search-button="true" :search-button="true"