From 70424639a03f43e1eb6ed4b6edbae2a632545f50 Mon Sep 17 00:00:00 2001 From: Lucas Bickel Date: Sun, 18 Aug 2019 19:03:55 +0200 Subject: [PATCH] :recycle: (js) use proper date.format call --- .../js/airtime/schedule/full-calendar-functions.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/airtime_mvc/public/js/airtime/schedule/full-calendar-functions.js b/airtime_mvc/public/js/airtime/schedule/full-calendar-functions.js index ad20162e0..72aefa04e 100644 --- a/airtime_mvc/public/js/airtime/schedule/full-calendar-functions.js +++ b/airtime_mvc/public/js/airtime/schedule/full-calendar-functions.js @@ -20,16 +20,7 @@ function scheduleRefetchEvents(json) { } function makeTimeStamp(date) { - var sy, sm, sd, h, m, s, timestamp; - sy = date.getFullYear(); - sm = date.getMonth() + 1; - sd = date.getDate(); - h = date.getHours(); - m = date.getMinutes(); - s = date.getSeconds(); - - timestamp = sy + "-" + pad(sm, 2) + "-" + pad(sd, 2) + " " + pad(h, 2) + ":" + pad(m, 2) + ":" + pad(s, 2); - return timestamp; + return date.format('YYYY-MM-DD HH:mm:ss'); } function dayClick(date, allDay, jsEvent, view) {