calcms.js: fix last day of month
This commit is contained in:
@@ -123,9 +123,13 @@ var calcms = (function($) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (field == 'month') {
|
if (field == 'month') {
|
||||||
if (month != '') {
|
if (month != null && month != '') {
|
||||||
from_date = month;
|
let date = month;
|
||||||
till_date = month.substring(0, month.length - 2) + "31";
|
let year = date.substring(0,4);
|
||||||
|
let mon = date.substring(5,7);
|
||||||
|
from_date = date;
|
||||||
|
till_date = date.substring(0, date.length - 2) +
|
||||||
|
new Date(year, mon , 0).getDate();
|
||||||
}
|
}
|
||||||
weekday = '';
|
weekday = '';
|
||||||
date = '';
|
date = '';
|
||||||
|
|||||||
Reference in New Issue
Block a user