Fix bindings

This commit is contained in:
Adria Navarro 2024-04-12 09:07:10 +02:00
parent 03589292d5
commit 173debd403
1 changed files with 18 additions and 11 deletions

View File

@ -68,15 +68,22 @@
{allowBindings} {allowBindings}
> >
<div slot="filteringHeroContent" /> <div slot="filteringHeroContent" />
<div slot="binding" let:filter>
<DrawerBindableInput <DrawerBindableInput
disabled={filter.noValue} let:filter
title={filter.field} slot="binding"
value={filter.value} disabled={filter.noValue}
placeholder="Value" title={filter.field}
{panel} value={filter.value}
{bindings} placeholder="Value"
on:change={event => (filter.value = event.detail)} {panel}
/> {bindings}
</div> on:change={event => {
const indexToUpdate = rawFilters.findIndex(f => f.id === filter.id)
rawFilters[indexToUpdate] = {
...rawFilters[indexToUpdate],
value: event.detail,
}
}}
/>
</FilterBuilder> </FilterBuilder>