From 6afd16cfb93ca1cf943b7f304bf4b1ab781179b6 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Thu, 8 Jun 2017 23:27:19 +0300 Subject: Change timestamp display format on builds page --- mod/mod-builds.cxx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/mod/mod-builds.cxx b/mod/mod-builds.cxx index 757ddca..8bd6f88 100644 --- a/mod/mod-builds.cxx +++ b/mod/mod-builds.cxx @@ -352,6 +352,8 @@ handle (request& rq, response& rs) else s << DIV_COUNTER (count, "Build", "Builds"); + timestamp now (timestamp::clock::now ()); + // Enclose the subsequent tables to be able to use nth-child CSS selector. // s << DIV; @@ -364,9 +366,10 @@ handle (request& rq, response& rs) assert (b.machine); string ts (butl::to_string (b.timestamp, - "%Y-%m-%d %H:%M:%S%[.N] %Z", + "%Y-%m-%d %H:%M:%S %Z", true, - true)); + true) + + " (" + butl::to_string (now - b.timestamp, false) + " ago)"); s << TABLE(CLASS="proplist build") << TBODY -- cgit v1.1