I'm trying to implement a new feature in my workshop application and I get trouble with filters. I would like to have either a default value coming from another object (multiple select table) or event a map widget, but I did not manage to implement it.
The objective is to display a chart related to a selected object,n then allow the user to select other objects to add their details to the first one to be able to compare.
What I tried so far is to define 2 filters :
On top of that, If I manually select my default value, then add values to the second filter, nothing is displayed because the default behavior seems to be a king of AND rather than an expected OR.
What would you propose to manage this ?
Is there a way to pass a default value to a common filter (and how)? Or is there a possibility to implement a OR between filters, rather than AND, and make the second filter returning nothing if no values are selected?
Is it possible to define a default value that is selected when the page is loaded?. Yes! In short, setting a default value for the Object Set Filter variable that is output by the Filter List widget will result in those default property filters being applied within the Filter list when this module is initially loaded. This is described in more detail in the documentation for Workshop's Filter List widget that should be accessible at https://www.palantir.com/docs/foundry/workshop/widgets-filter-list/ .
Is it possible to define precisely AND/OR conditions between filters (and how)? Within a single Filter List widget, property filters within a single property type are applied as OR filters (e.g., filter when Alert Type == "Flight Delay" OR "Maintenance Issue"
) and filters between property types are applied as AND filters (e.g., filter when Alert Type == "Flight Delay" AND Alert Status == "Open"
). For more complex behavior, two options are (1) using a Function-backed object set where you can define custom filtering logic in Typescript or (2) using multiple Filter List widgets and then building a new Object Set in the front-end that combines their output as desired. For example of (2), please see the screenshot below where Object Set C == (Object Set A + Object Set Filter A) OR (Object Set B + Object Set Filter B)
.
Object Set definition panel combination options