restrict combobox value

restrict combobox value

  

Hi,

I have an Entity 'Medewerker' with attributes Id, Name, ManagerId and IsManager. The ManagerId attribute is of Type 'Medewerker Identifier'. The scaffolded detailscreen shows a combobox for the ManagerId with the names of the Medewerkers, but I want to restrict that to only Medewerkers with IsManager = True, and the Medewerkers own name must also not be shown. What is the proper way to restrict the values in the combobox?

Regards, Harry 

Solution

Hi Harry

You can add an aggregate to the preparation, to filter the Medewerker entity according your filter (IsManager = True plus the filter to not show the logged user) and provide this aggregate list as the source to the combo box in the form. Use the Source Record List instead of the Source Entity.

Cheers,
Eduardo Jauch

Solution

Thanks Eduardo, 

Got it working, 

Regards, Harry



Glad to hear :)

Cheers,
Eduardo Jauch