|

楼主 |
发表于 2019-5-9 10:02:31
|
显示全部楼层
自己研究解决了,版主请结帖
Model.prototype.gridSelect5ShowOption = function(event){
var id = this.getIDByXID("option5");
var grid1 = this.comp("gridSelect5").grid;
//点击全部取消所有明细
$("#"+id).find("tr:eq(1)").bind("click",function(){
var rows = this.parentNode.rows;
for(var i=2;i<rows.length;i++){
var b = rows[i].innerText.replace(/(^\s*)/g,"");
var c = rows[i].textContent.replace(b,"").replace(/(^\s*)/g,"");
grid1.setRowChecked(c,false);
}
})
//点击明细取消全部
$("#"+id).bind("click",function(event){
var a = event.toElement.parentNode.parentNode.innerText.replace(/(^\s*)/g,"");
if( a != '全部')
{
grid1.setRowChecked('ALL',false);
}
});
}; |
|