박지환

Test time set

...@@ -33,10 +33,11 @@ app.use(static(__dirname)); ...@@ -33,10 +33,11 @@ app.use(static(__dirname));
33 // To get today date by using Date 33 // To get today date by using Date
34 function getTodayDate() { 34 function getTodayDate() {
35 var tempDate = new Date(); 35 var tempDate = new Date();
36 + console.log("[tempDate] " + tempDate);
36 const utc = tempDate.getTime() + tempDate.getTimezoneOffset() * 60 * 1000; 37 const utc = tempDate.getTime() + tempDate.getTimezoneOffset() * 60 * 1000;
37 const KR_TIME_DIFF = 9 * 60 * 60 * 1000; 38 const KR_TIME_DIFF = 9 * 60 * 60 * 1000;
38 const today = new Date(utc + KR_TIME_DIFF); 39 const today = new Date(utc + KR_TIME_DIFF);
39 - console.log(today); 40 + console.log("[today] " + today);
40 var year = today.getFullYear(); 41 var year = today.getFullYear();
41 var month = ("0" + (today.getMonth() + 1)).slice(-2); 42 var month = ("0" + (today.getMonth() + 1)).slice(-2);
42 var day = ("0" + today.getDate()).slice(-2); 43 var day = ("0" + today.getDate()).slice(-2);
......