EXt의 Grid에서 CheckboxSelectionModel 기본 선택

EXt의 Grid에서 CheckboxSelectionModel 기본 선택
ewqGridStore.addListener("load",function(){ //ewqGridStore grid store
   var records=[];// 
    var roombos = eroomboshid.getValue(); //eroomboshid  
   var roombosstr = [];
   if('undefine' != roombos){
	  if(roombos.indexOf(';')!=-1){
		roombosstr = roombos.split(';');
	  }else{
		roombosstr[0] = roombos;
	  }
   }
   for(var i=0;i<ewqGridStore.getCount();i++){
	var record = ewqGridStore.getAt(i);
	for(var j=0;j<roombosstr.length;j++){
	    if(record.data.bosid==roombosstr[j]){// 
		records.push(record);
            }
	}
   }
   //ewqGridCheckbox  CheckboxSelectionModel 
   ewqGridCheckbox.selectRecords(records);//  
});

 
     
 
      

좋은 웹페이지 즐겨찾기