StephenChou1017 / react-big-scheduler

A scheduler and resource planning component built for React and made for modern browsers (IE10+)
https://stephenchou1017.github.io/scheduler/#/
MIT License
746 stars 415 forks source link

React Big Scheduler - Antd date picker changes #209

Open Ramesraina opened 4 years ago

Ramesraina commented 4 years ago

Hi,

Is there any possible way to change antd date picker week day starts from "Monday" in react big scheduler????

desarrolladorProm commented 3 years ago

Hi,

I needed the same thing a while ago, I did it in the following way: in the configuration of "moment" I call the property of the week and define the day on which the calendar begins, in your case the day number 1 which is Monday, already that the array starts on Sunday with 0. For example: moment.locale('en', { week: { dow: 1, doy: 1, }, });

After set objet calendar: let schedulerData = new SchedulerData(date, ViewTypes.Week, false, false, { resourceName: "Name", schedulerWidth : dimensions, views: [], },{ isNonWorkingTimeFunc: this.isNonWorkingTime });

And finally: schedulerData.setLocaleMoment(moment);