I have an Interactive Range Slider Filter Widget that is used in a component to allow the user to filter results on a column through the interactive view. The widget works generally fine but in some limit cases the column can contain a constant value and in those cases the Interactive Range Slider Filter Widget blocks the interactive view to be executed (and with that it blocks the whole workflow). (Please, see the uploaded example workflow where the filtered column is called “Ligand count”).
In order to solve this problem I have tried a modified version of the component where the Interactive Range Slider Filter Widget is placed inside a switch branch that is active only if the filtering column is not constant. In general this should be a solution because it makes no sense to apply a range filter to a constant column but unfortunately it seems that, if the filter widget node is placed inside such a branched switch, the component loses interactivity capabilities and other possible interactive filters connected stop to work.
How can I use the Interactive Range Slider Filter Widget in such a case? Am I missing something?
Any help is appreciated.
interactive_range_slider_filter_with_constant_columns.knwf (225.5 KB)
Maybe you could enable legacy mode on the component layout and conditionally hide the slider via custom CSS based on a true false column that tests for constant values? Not a simple task, but might provide a path if no simpler one exists.
not sure if the css trick will work, as the widget would technical still be there and validated. That would depend on the slider library we used for the legacy slider and if that can handle constant values.
Another trick would be to use the hideInWizard flow variable field you can set in the flow variable tab. This will result in the same thing you tried to achieve. The problem with your approach is, that the if switch will create a new table at the end of the switch. This table has a new tableID and therefore the filter events won’t be handled anymore.
I hope the attached workflow helps.
interactive_range_slider_filter_with_constant_columns.knar.knwf (83.7 KB)
Thank you for the solution! That works perfectly. I hope this thread will help also other people with the same issue.
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.