当前位置: 代码迷 >> JavaScript >> ExtJS替combobox增加tip
  详细解决方案

ExtJS替combobox增加tip

热度:99   发布时间:2012-11-07 09:56:10.0
ExtJS为combobox增加tip

话不多说 直接上代码??

//select the domain for add or modify the common
 var domainNameInput = new Ext.form.ComboBox({
  x:185, y:60,
  xtype:'combo',
  width:200,
  allowBlank:false,
  triggerAction:'all',
  store: new Ext.data.JsonStore({
   data:domainSelect,
   fields:["domainID","domainName"]      
  }),     
//关键代码开始
  tpl:'<tpl for="."><div class="x-combo-list-item" ext:qtitle="值" ext:qtip="{domainName}">{domainName}</div></tpl>',  
//关键代码结束
  hiddenName:'domainID',
  valueField:"domainID",//valueField
  displayField:"domainName",//displayField
  editable:false,
  id:'domainIDObj',
  mode:'local' 
 }); 

??

效果如下

?

?

  相关解决方案