From 35edce7523b14c8dd7ea5ae4cc57fcba9b168af3 Mon Sep 17 00:00:00 2001 From: azivner Date: Wed, 16 Jan 2019 22:03:30 +0100 Subject: [PATCH] fix crazy clipboard operation on mac setup, closes #348 --- src/public/javascripts/services/utils.js | 3 +++ src/views/setup.ejs | 1 + 2 files changed, 4 insertions(+) diff --git a/src/public/javascripts/services/utils.js b/src/public/javascripts/services/utils.js index dcca082e3..c30e771ba 100644 --- a/src/public/javascripts/services/utils.js +++ b/src/public/javascripts/services/utils.js @@ -23,6 +23,7 @@ function formatTimeWithSeconds(date) { return padNum(date.getHours()) + ":" + padNum(date.getMinutes()) + ":" + padNum(date.getSeconds()); } +// this is producing local time! function formatDate(date) { // return padNum(date.getDate()) + ". " + padNum(date.getMonth() + 1) + ". " + date.getFullYear(); // instead of european format we'll just use ISO as that's pretty unambiguous @@ -30,6 +31,7 @@ function formatDate(date) { return formatDateISO(date); } +// this is producing local time! function formatDateISO(date) { return date.getFullYear() + "-" + padNum(date.getMonth() + 1) + "-" + padNum(date.getDate()); } @@ -143,6 +145,7 @@ function bindShortcut(keyboardShortcut, handler) { } $(document).bind('keydown', keyboardShortcut, e => { + console.log(e); handler(); e.preventDefault(); diff --git a/src/views/setup.ejs b/src/views/setup.ejs index e6447d9ba..5900b9be9 100644 --- a/src/views/setup.ejs +++ b/src/views/setup.ejs @@ -128,6 +128,7 @@ +