diff --git a/src/game/lib/string_util.js b/src/game/lib/string_util.js index 8128a26..c59dd42 100644 --- a/src/game/lib/string_util.js +++ b/src/game/lib/string_util.js @@ -3,7 +3,13 @@ function StringUtil() { StringUtil.printMonthDay = function(date) { console.log(date); - let dateTime = new Date(date); + // let dateTime = new Date(date); + var a = date.split(" "); + var d = a[0].split("-"); + var t = "0:0:0".split(":"); + if(a.count > 0) + var t = a[1].split(":"); + var dateTime = new Date(d[0],(d[1]-1),d[2],t[0],t[1],t[2]); console.log(dateTime); console.log("month : " + dateTime.getMonth()); console.log("date : " + dateTime.getDate());