From 914f6a344bc993d1fbc83e147a2ec8deaf10c79c Mon Sep 17 00:00:00 2001 From: Geno Date: Sun, 29 Oct 2017 11:00:22 +0100 Subject: [PATCH] [TASK] Show last update relativ to now --- lib/legend.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/legend.js b/lib/legend.js index fa8daf6..93da01f 100644 --- a/lib/legend.js +++ b/lib/legend.js @@ -20,7 +20,7 @@ define(['helper'], function (helper) { _.t('sidebar.clients', { smart_count: totalClients }) + ' ' + _.t('sidebar.gateway', { smart_count: totalGateways }); - timestamp.textContent = _.t('sidebar.lastUpdate') + ': ' + d.timestamp.format('DD.MM.Y HH:mm'); + timestamp.textContent = _.t('sidebar.lastUpdate') + ' ' + d.timestamp.fromNow(); }; self.render = function render(el) { @@ -33,7 +33,6 @@ define(['helper'], function (helper) { var p = document.createElement('p'); p.classList.add('legend'); - p.appendChild(document.createElement('br')); p.appendChild(stats); p.appendChild(document.createElement('br')); p.appendChild(timestamp);