Hi,
Given:
How do I populate a combobox (to add cars to the Car_Salesman entity) when I want to show all cars if a the salaesman is a manager and if he/she isnot then only show cars where isOnlyToSellByManager is False?
Regards, Harry
Or, use an If statement, use an appropriate Aggregates for each path of the If, and assign the output to a common List that you use in the combo box.
Hi Harry,
I think you can still have one source for the combobox, rather you add these conditions into your query. You can pass these values as Input parameters in your query. You may use advance query instead.
Shashank...
Thank you. I'll go for Kiian's solution (and will look into Shasank's later on - needs a little more SQL)
hi de Broer:
Find:
Solution:
1. create server action:
with filtering on aggregate GetCarwithSalesmen:
2. assign that function to car widget combobox:
3. Ajaxize when you change the Saleman widget value to both widgets - saleman and car:
For your convenience, i attached the Oml:
regards,
bb
Nice sample and explanation
Thanks BB!
Harry
BB Nice and clear explanation of conditional use of combobox!!