i'm displaying driver's schedule. Some drivers are on holidays so we display red box for them. And other drivers those are active so we display white block for them. I want to count active and non active driver by the calendar day changes. Hope you will understand my question.enter code here
scheduler.locale.labels.timeline_tab = "Timeline";
scheduler.locale.labels.section_custom="Section";
scheduler.config.details_on_create=true;
scheduler.config.details_on_dblclick=true;
//===============
//Configuration
//===============
var sections=[
{key:1, label:"James Smith"},
{key:2, label:"John Williams"},
{key:3, label:"David Miller"},
{key:4, label:"Linda Brown"}
];
scheduler.createTimelineView({
name: "timeline",
x_unit: "hour",
x_date: "%H:%i",
x_step: 1,
x_size: 24,
x_start: 0,
y_unit: sections,
y_property: "section_id",
render:"bar",
event_dy:"full"
});
//scheduler.date.timeline_start = scheduler.date.week_start;
//===============
//Data loading
//===============
scheduler.config.lightbox.sections=[
{name:"description", height:50, map_to:"text", type:"textarea" , focus:true},
{name:"custom", height:30, type:"select", options:sections, map_to:"section_id" },
{name:"time", height:72, type:"time", map_to:"auto"}
];
scheduler.config.readonly = true;
scheduler.init('scheduler_here',new Date(2021,5,30),"timeline");
scheduler.parse([
{ start_date: "2021-06-30 00:00", end_date: "2021-07-01 23:59", text:"", section_id:1, color:"red"},
{ start_date: "2021-06-30 00:00", end_date: "2021-06-30 23:59", text:"", section_id:2, color:"red"},
{ start_date: "2021-06-30 00:00", end_date: "2021-06-30 23:59", text:"", section_id:3, color:"red"},
{ start_date: "2021-06-30 00:00", end_date: "2021-06-30 23:59", text:"", section_id:4, color:"red"}
]);
<link rel="stylesheet" type="text/css" href="https://docs.dhtmlx.com/scheduler/codebase/dhtmlxscheduler_material.css">
<script src="https://docs.dhtmlx.com/scheduler/codebase/dhtmlxscheduler.js"></script>
<script src="https://docs.dhtmlx.com/scheduler/codebase/ext/dhtmlxscheduler_timeline.js"></script>
<style>
html, body{
padding:0;
margin: 0;
}
</style>
<div id="scheduler_here" class="dhx_cal_container" style="width:100%; height:100%;">
<div class="dhx_cal_navline">
<div class="dhx_cal_prev_button"> </div>
<div class="dhx_cal_next_button"> </div>
<div class="dhx_cal_today_button"></div>
<div class="dhx_cal_date"></div>
</div>
<div class="dhx_cal_header">
</div>
<div class="dhx_cal_data">
</div>
</div>