global keyboard shortcuts for quick creating sub-notes under day note

This commit is contained in:
azivner
2018-02-12 23:53:00 -05:00
parent 7bbfef7af3
commit 0e9473119e
5 changed files with 109 additions and 38 deletions

View File

@@ -43,6 +43,14 @@ function nowDate() {
return dateStr(new Date());
}
function localDate() {
const date = new Date();
return date.getFullYear() + "-"
+ (date.getMonth() < 9 ? "0" : "") + (date.getMonth() + 1) + "-"
+ (date.getDate() < 10 ? "0" : "") + date.getDate();
}
function dateStr(date) {
return date.toISOString();
}
@@ -125,6 +133,7 @@ module.exports = {
randomSecureToken,
randomString,
nowDate,
localDate,
dateStr,
parseDate,
parseDateTime,