easyui combogrid 怎样促发 onchange
展开全部
在easyui开发过程中遇到下边两个事儿
combogrid/combotree做级联:
[javascript] view plain copy
$("#" + deptId).combotree(
{
url : urlHeader + '/deptController/allDepts.action',
parentField : 'pid',
lines : true,
onChange : function(now, old) {
$("#" + jobId).combotree(
{
url : urlHeader + '/jobController/allJobs.action?deptid=' + now,
parentField : 'pid',
lines : true
});
}
});
combogrid的onChange获取change的整个对象:
[javascript] view plain copy
onSelect: function (rowIndex, rowData){
$("#" + divID + " input[name='gcBdate']").val(rowData.createdatestr);
$("#" + divID + " textarea[name='gcReason']").val(rowData.reason);
}
combogrid/combotree做级联:
[javascript] view plain copy
$("#" + deptId).combotree(
{
url : urlHeader + '/deptController/allDepts.action',
parentField : 'pid',
lines : true,
onChange : function(now, old) {
$("#" + jobId).combotree(
{
url : urlHeader + '/jobController/allJobs.action?deptid=' + now,
parentField : 'pid',
lines : true
});
}
});
combogrid的onChange获取change的整个对象:
[javascript] view plain copy
onSelect: function (rowIndex, rowData){
$("#" + divID + " input[name='gcBdate']").val(rowData.createdatestr);
$("#" + divID + " textarea[name='gcReason']").val(rowData.reason);
}
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询