DHTMLX / gantt

GPL version of Javascript Gantt Chart
https://dhtmlx.com/docs/products/dhtmlxGantt/
GNU General Public License v2.0
1.48k stars 324 forks source link

start_date and end_date config not working when using scale in month #77

Closed lebesnec closed 2 years ago

lebesnec commented 2 years ago

I want to change the start and end date of my gantt:

gantt.config.start_date = new Date(2010, 1, 1);
gantt.config.end_date = new Date(2015, 1, 1);

it works fine if I only have a scale with unit 'year':

gantt.config.scales = [
  { unit: 'year', step: 1, format: '%Y' }
];

but as soon as I add a scale with 'month' the date are not set correctly:

gantt.config.scales = [
  { unit: 'year', step: 1, format: '%Y' },
  { unit: 'month', step: 1, format: '%M, %Y' }
];

See demo here: https://snippet.dhtmlx.com/5/733d91f5b

lebesnec commented 2 years ago

OK I just have to use the horizontal scrollbar to see the missing date...