2

I want to filter the content of a control to relevant values based on a filter applied to the dashboard. The filter is based on a parameter passed in via the JS SDK.

If I have a control (Control X) setting a parameter used by a filter then it appears a further control (Control Y) can have the displayed values pre filtered to those now applicable. This is done by enabling "Show relevant values only" on Control Y, checking Control X when prmoted and selecting the relevant field from the drop down.

However we have no intention on showing Control X to the user. What if anything can be done to get the intended behaviour?

Example Setup

Data:

|Type  |Item  |Price|
|------|------|-----|
|Fruit |Apple |0.50 |
|Fruit |Orange|0.60 |
|Fruit |Pear  |0.20 |
|Veg   |Potato|0.15 |
|Veg   |Onion |0.29 |
|Veg   |Carrot|0.08 |

Filter: On Field "Type", Filter Type "custom filter, equals" use parameters: YES, Parameter "TypeInput"

Controls: Filter: Item, Display name "Item equals", Style "Dropdown - muliselect", Values: "Filter" n.b. "Show relevant values" only greyed out ... will only appear when another control is added.

Intended Behaviour: When TypeInput is set to Fruit then Control Y should have Apple, Orange and Pear. When TypeInput is set to Veg then Control Y should have Potato, Onion and Carrot.

Actual Behaviour: Control Y shows Apple, Orange, Pear, Potato, Onion and Carrot regardless of TypeInput.

n.b If Control X added as text box the "Show relevant values" no longer greyed out in Control Y. When selected Control X is checkable and the filed "Type" can be selected from the drop down. Then when value is inputted (e.g. "Veg") into control X the values in Control Y are filtered as expected.

Christopher Hackett
  • 6,042
  • 2
  • 31
  • 41

1 Answers1

1

Don't know if you've figured this out yet, but I'm leaving this here for anybody who might need it...

enabling "Show relevant values only" on Control Y, checking Control X when prmoted and selecting the relevant field from the drop down.

However we have no intention on showing Control X to the user.

We got around this by adding the control to the sheet at the bottom, and in the options, you set the control to be hidden by default, so when anyone is looking at the dashboard, that control won't even be visible, however, once Control X is on the sheet (and linked to the same dataset as the other control), you can use it for "Show relevant values only" for Control Y

user1687580
  • 115
  • 5