Hi, is there any way of hiding a SelectItem if a pickList (bound via an optionDataSource) is empty (does not have any pickList results)?
Announcement
Collapse
No announcement yet.
X
-
This doesn't seem like a good idea, as the user would see the pickList appear during data loading, then vanish. Many users would perceive this as broken rather than understanding that there were zero results.
Regardless, if you wanted to achieve this, you'd have to use undocumented, unsupported APIs. Eg, currently, the SelectItem stores it's pickList as the "pickList" property, and you could call "hide()" on it from dataArrived.
Just to emphasize: this is not a supported approach, and will likely cause issues.
Comment