if (this.islayoutChanged) {
var renderdate = this.scheduleObj.activeView.getRenderDates();
this.scheduleObj.resetWorkHours();
for (var i = 0; i < renderdate.length; i++) {
var dayindex = renderdate[i].getDay();
if(dayindex !== 0 && dayindex !== 6){
//first resource
this.scheduleObj.setWorkHours([renderdate[i]],this.workHours1[dayindex].startHour,this.workHours1[dayindex].endHour,0);
//second resource
this.scheduleObj.setWorkHours([renderdate[i]],this.workHours2[dayindex].startHour,this.workHours2[dayindex].endHour,1);
}
}
}
|