From 5e06efc1b92aebb18a36b1417515edfb5fe410a1 Mon Sep 17 00:00:00 2001 From: "Helmut K. C. Tessarek" Date: Tue, 4 Sep 2018 18:03:21 -0400 Subject: [PATCH] show correct date/time for cli command `ls` closes #729 --- CliClient/app/command-ls.js | 2 +- ReactNativeClient/lib/BaseApplication.js | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CliClient/app/command-ls.js b/CliClient/app/command-ls.js index 91f546bfc..029681a11 100644 --- a/CliClient/app/command-ls.js +++ b/CliClient/app/command-ls.js @@ -93,7 +93,7 @@ class Command extends BaseCommand { row.push(await Folder.noteCount(item.id)); } - row.push(time.unixMsToLocalDateTime(item.user_updated_time)); + row.push(time.formatMsToLocal(item.user_updated_time)); } let title = item.title; diff --git a/ReactNativeClient/lib/BaseApplication.js b/ReactNativeClient/lib/BaseApplication.js index 96500c416..f9ef0b1c4 100644 --- a/ReactNativeClient/lib/BaseApplication.js +++ b/ReactNativeClient/lib/BaseApplication.js @@ -494,6 +494,9 @@ class BaseApplication { setLocale(Setting.value('locale')); } + time.setDateFormat(Setting.value('dateFormat')); + time.setTimeFormat(Setting.value('timeFormat')); + BaseService.logger_ = this.logger_; EncryptionService.instance().setLogger(this.logger_); BaseItem.encryptionService_ = EncryptionService.instance();