JS获取格式为YYYY-MM-DD的当前日期
var date = new Date();
var mon = date.getMonth() + 1;
var day = date.getDate();
var currDate = date.getFullYear() + "-"+ (mon<10?"0"+mon:mon) + "-"+(day<10?"0"+day:day);
JS获取格式为YYYY-MM-DD的当前日期
var date = new Date();
var mon = date.getMonth() + 1;
var day = date.getDate();
var currDate = date.getFullYear() + "-"+ (mon<10?"0"+mon:mon) + "-"+(day<10?"0"+day:day);