How to allow removing a single filter indicator when using `indicateUsing`
When working with a custom filter I want to allow removing a single filter option, so I customized the generator indicators using
indicateUsing
, but when I click the remove button on a single filter all filters are removed. Did I misunderstand the removeField
option?
4 Replies
Is the rule name alphanumeric without spaces? And your data is keyed by the same name as you pass in
removeField()
?It might contain spaces
Does it also reset all fields? I think
->removeField()
is for clearing the fields in the filter form. I guess the indicators are built based on the fields with values, but I am not sure about the inner workings.Yeah I think the removeField actually is used for the form if I read the docs more closesely:
"f you have different fields associated with different indicators, you should set the field using the removeField() method on the Indicator object to ensure that the correct field is reset when the filter is removed"
So I guess it is currently not supported