年月日によって全部の日数と判断する週次
590 ワード
//
getDaysInMonth(year, month) {
month = parseInt(month, 10);
var temp = new Date(year, month, 0);
return temp.getDate();
},
//
getWeek(year,month,day){
month = parseInt(month, 10);
day = parseInt(day, 10);
let week = new Date(year+"/"+month+"/"+day).getDay();
return week
}
//week:0=>
//week:1=>
//week:2=>
//week:3=>
//week:4=>
//week:5=>
//week:6=>