EasyUI Forum
April 27, 2024, 05:50:55 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Icons in combobox selection and selected.  (Read 2431 times)
fonzie
Newbie
*
Posts: 9


View Profile
« on: June 01, 2019, 08:57:59 AM »

I'd like to have icons show in the combobox both when it's been selected and when choosing (eg in the dropdown choice).

If I hard code it like this it's possible

data: [
        {value:'RAL1001',text:'Green Beige',iconCls:'RAL1001'},
     {value:'RAL1002',text:'Sand Yellow',iconCls:'RAL1001'}
   ]

There's dozens of choices and they can change (depending upon stock levels), therefore i'd like to load the data from a datatbase or .json file, but whilst the Value and text fields are easy to populate, the "icon", doesn't work.

I've used the formatter function but this only works in the "drop down" choice, the icon isn't displayed after you've made a choice.

Can anyone help ?
Logged
jarry
Administrator
Hero Member
*****
Posts: 2262


View Profile Email
« Reply #1 on: June 03, 2019, 06:31:32 PM »

Please refer to this topic https://www.jeasyui.com/forum/index.php?topic=4234.0
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!