我喜欢这样的 jqxDropDownlist
var source = {
datatype: “json”,
datafields: [{ name: 'title'}, { name: 'id'}],
id: ‘id’,
url: “getOnvaneOrganizations”,
async: true
};
var dataAdapter = new $.jqx.dataAdapter(source);
$(“#slc_onvane_organization_sabt”).jqxDropDownList({
selectedIndex: 0,
source: dataAdapter,
displayMember: “title”,
valueMember: “id”,
theme: ‘darkblue’,
filterable:true,
width:’100%’,
rtl:true
});
$(“#slc_onvane_organization_sabt”).jqxDropDownList(‘val’,’10′);
因为 async 是真的,所以$("#slc_onvane_organization_sabt").jqxDropDownList('val','10');
在 ajax 成功之前运行,并且没有工作。
如何$("#slc_onvane_organization_sabt").jqxDropDownList('val','10');
在 ajax.success 函数中运行?
请帮我