How to add an empty item to ExtJS combobox?

前端 未结 6 688
慢半拍i
慢半拍i 2020-12-16 12:33

I want to add and empty item (display value is blank, item height is kept as normal) to an Ext.form.ComboBox. I refered 2 links below to configure my combobox, but it still

6条回答
  •  南笙
    南笙 (楼主)
    2020-12-16 13:22

    You can add an "empty" record at the beginning:

     listeners: {
         load: function(store, records) {
              store.insert(0, [{
                  fullName: ' ',
                  id: null
              }]);
         }
      }
    

提交回复
热议问题