scale_row_class

specifies the CSS class that will be applied to the time scale

Parameters

scaleobjectthe scale's configuration object

Example

<style>
 .day_scale{ background-color: #C3C7D4;}
 .week_scale{ background-color: #E5DFE8;}
 .month_scale{ background-color: #DFE8DF;}
</style>
gantt.templates.scale_row_class = function(scale){
    switch(scale.unit){
        case "day":
        return "day_scale";
 
        case "month":
        return "month_scale";
 
        default:// "week"
        return "week_scale";
    }
}

See also
Back to top