Multiple-Dates-Picker-for-jQuery-UI icon indicating copy to clipboard operation
Multiple-Dates-Picker-for-jQuery-UI copied to clipboard

How to get first and last displayed dates from multiDatesPicker?

Open romanbannikov opened this issue 10 years ago • 1 comments

Can I get first and last << displayed >> (not selected) dates from multiDatesPicker in numberOfMonths: [1, 4] mode?

Many thanks!

romanbannikov avatar Oct 08 '14 08:10 romanbannikov

In case somebody search a solution :

 onChangeMonthYear : function(dateText, inst, dateob) {
                var navidatedMonth = new Date(dateob.selectedYear, dateob.selectedMonth,  dateob.selectedDay);

                var firstDay = new Date(navidatedMonth.getFullYear(), navidatedMonth.getMonth(), 1);
                console.log(firstDay);
                var lastDay = new Date(navidatedMonth.getFullYear(), navidatedMonth.getMonth() + (dateob.settings.numberOfMonths[0] * dateob.settings.numberOfMonths[1]), 0);
                console.log(lastDay);
            }

Yeah legacy code ... !

YannikFirre avatar Aug 28 '19 15:08 YannikFirre