EasyUI Forum

General Category => Bug Report => Topic started by: y.bykov on August 23, 2016, 01:07:15 PM



Title: Small bug with combobox id type
Post by: y.bykov on August 23, 2016, 01:07:15 PM
EasyUI 1.5

When I want to select value in combobox I do
Code:
$('#vendor_id').combobox('setValues', vendor_id);
where vendor_id is integer, but I get error
Quote
jquery.easyui.min.js:13621 Uncaught TypeError: _a49.split is not a function
if(!$.isArray(_a49)){
_a49=_a49.split(opts.separator);
}
Integer doesn't have split function.


Title: Re: Small bug with combobox id type
Post by: jarry on August 23, 2016, 03:48:34 PM
The setValues method allows you to set multiple values, it requires an array as its parameter. Please call this code instead.
Code:
$('#vendor_id').combobox('setValues', [vendor_id]);


Title: Re: Small bug with combobox id type
Post by: y.bykov on August 24, 2016, 07:58:50 AM
Thank you!
Now, it works fine!