EasyUI Forum
July 17, 2018, 08:07:47 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: tagbox with a dynamic list data  (Read 1352 times)
btgoa
Newbie
*
Posts: 3


View Profile
« on: September 07, 2017, 12:59:05 AM »

Hi,

When using combobox, if the "mode" is set to "remote", then each time I change the value in inputbox, the list will be reloaded from remote url.

I wonder if this method can be applied to tagbox?

Thanks in advance.

Regards,
Logged
stworthy
Administrator
Hero Member
*****
Posts: 3295


View Profile Email
« Reply #1 on: September 08, 2017, 05:44:28 AM »

The tagbox component extends from combobox, it has all the features defined in combobox. You can set the 'mode' property to 'remote' to get this feature.
Logged
btgoa
Newbie
*
Posts: 3


View Profile
« Reply #2 on: September 11, 2017, 07:18:12 AM »

The tagbox component extends from combobox, it has all the features defined in combobox. You can set the 'mode' property to 'remote' to get this feature.

Hi stworthy, I've tried to set the 'mode' property of tagbox to 'remote' but the feature seems not working. However, it is working in combobox.
Logged
btgoa
Newbie
*
Posts: 3


View Profile
« Reply #3 on: September 12, 2017, 05:41:43 PM »

The tagbox component extends from combobox, it has all the features defined in combobox. You can set the 'mode' property to 'remote' to get this feature.

Hi stworthy, it seems that if the limitToList is set to true, the dropdown list will appear when typing. Otherwise the dropdown list will not appear and there's no ajax request fired when typing.
Logged
jega
Jr. Member
**
Posts: 87


View Profile
« Reply #4 on: March 16, 2018, 03:28:34 AM »

This still not working.

       <input id="unitSearch" name="unitSearch" class="easyui-tagbox" style="width:300px" data-options="
          loader: unitsLoader,
          mode: 'remote',
          valueField: 'id',
          textField: 'name',
          formatter: formatUnit,
          hasDownArrow: true,
          label:'Add unitID',
          labelPosition:'top'">

No request to server.

Works fine in combobox
Logged
stworthy
Administrator
Hero Member
*****
Posts: 3295


View Profile Email
« Reply #5 on: March 16, 2018, 08:32:26 AM »

You should set 'limitToList' property to true.
Logged
jega
Jr. Member
**
Posts: 87


View Profile
« Reply #6 on: June 13, 2018, 12:03:18 AM »

Can't get this to work. maybe the tagbox can't be used to this.


       <input id="personSearch" name="personSearch" class="easyui-tagbox" style="width:300px" data-options="
          loader: personLoader,
          mode: 'remote',
          valueField: 'id',
          textField: 'name',
          limitToList:true,
          hasDownArrow: true,
          label:'Add person',
          labelPosition:'top'">

Let's say all persons names in database is Name1, Name2, Name3.........

Typing name will return all records from db. Typing name1 returns only 1 record, just like expected.
Choosing this record, will make a tag with Name1. So far so good.

Typing name, shows all records. Typing name2, it finds name2, but destroys the first tag with name1. Because this is not in list anymore.

So tagbox and remote works not together. If loading the entire records in tagbox, it works fine, but i have maybe 14000 records.

Jesper


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!