Our state of the art Gantt chart


Post by additout »

Hi team,

Is it possible to hide the weekends (Saturday and Sunday) so Monday can be first?

Attachments
Captura de Pantalla 2022-07-27 a las 13.18.47.png
Captura de Pantalla 2022-07-27 a las 13.18.47.png (21.05 KiB) Viewed 362 times

Post by tasnim »

Check our docs here: https://bryntum.com/docs/gantt/#Scheduler/data/TimeAxis

use https://bryntum.com/docs/gantt/#Scheduler/data/TimeAxis#function-filterBy

Here is a simple code snippet :

gantt.timeAxis.filter(tick => {
    let weekday = true;
    if (tick.startDate.getDay() == 6 || tick.startDate.getDay() == 0) {
        weekday = false;
    }
    return weekday;
});

Post Reply