I have gallery with SharePoint as the datasource. Outside the gallery I have a searchbox and a filter pane which includes 4 buttons named "Electrical Stuffs", "Home Appliances", "Drinks", "Perfumes"
The search functionality works fine without any issues. Below is the formula for Items property of Gallery
Filter(
DataSource,
(TextInput1.Text in 'Name' || TextInput1.Text in Description || TextInput1.Text in 'Unit Price' || TextInput1.Text in 'Category')
)
However when i try to add the filter buttons in above formula, gallery doesnt filter appropriately.
On each of the 4 buttons OnSelect, I used below formula
UpdateContext({varSelection:"Electrical Stuffs"})
UpdateContext({varSelection:"Home Appliances"})
UpdateContext({varSelection:"Drinks"})
UpdateContext({varSelection:"Perfumes"})
Amended Items property of gallery to below formula
Filter(
DataSource,
(TextInput1.Text in 'Name' || TextInput1.Text in Description || TextInput1.Text in 'Unit Price' || TextInput1.Text in 'Category')&&varSelection=Category
)
Any where I am going wrong?

Report
All responses (
Answers (