Volk65 Posted June 27, 2018 Share Posted June 27, 2018 UniDBLookupComboBox can I change the color / background of the rows in the drop-down list? For example, as in UniDBGrid there is an ondrawcolumncell event. Quote Link to comment Share on other sites More sharing options...
mhmda Posted June 27, 2018 Share Posted June 27, 2018 Use tpl: function beforeInit(sender, config) { config.listConfig={ getInnerTpl: function() { var tpl = '<div style="background-color:#f00">'+ '{val}'+ '</div>'; return tpl; } }; } Inside the tpl you may use function to do a check and change the background color. Quote Link to comment Share on other sites More sharing options...
Volk65 Posted June 27, 2018 Author Share Posted June 27, 2018 Thanks mohammad! Is it possible to redirect the function "getInnerTpl: function()" to OnAjaxEvent and return "<div style=..../div>? Sorry, I'm not good at JS. Quote Link to comment Share on other sites More sharing options...
Sanyi Posted February 4, 2020 Share Posted February 4, 2020 Hi! I have got the same problem. This code works, but I want not all items in red. My ListField is: ORG_KUERZEL;ORG_NAME;AKTIV I want to show red the items, where AKTIV=0 How can I do that. Regards Sándor Quote Link to comment Share on other sites More sharing options...
picyka Posted February 24, 2020 Share Posted February 24, 2020 How would it look if you had a rule if campo.constain ('Active') verder else red Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.