var d = new Date();var str = d.getFullYear() + "-0" + (d.getMonth() + 1) + (d.getDate() < 10 ? "-0" : "-") + d.getDate(); ...
var d = new Date();
var str = d.getFullYear() + "-0" + (d.getMonth() + 1) + (d.getDate() < 10 ? "-0" : "-") + d.getDate();
new Date(+new Date()+8*3600*1000).toISOString().replace(/T/g,' ').replace(/\.[\d]{3}Z/,'')