[PATCH 6 of 6] pullrequest overview: show age rather than date

Thomas De Schampheleire patrickdepinguin at gmail.com
Tue Mar 3 16:40:33 EST 2015


# HG changeset patch
# User Thomas De Schampheleire <thomas.de.schampheleire at gmail.com>
# Date 1425418426 -3600
#      Tue Mar 03 22:33:46 2015 +0100
# Node ID 297d798bd5b22ea562d0813bed7e5eb6bc646c1b
# Parent  02c4f6d5f95731f75ddbf196b79100da8d80d46c
pullrequest overview: show age rather than date

Since pullrequests are supposed to be short-lived, the age is more relevant
than the actual date (which is still shown in a tooltip).

diff --git a/kallithea/templates/pullrequests/pullrequest_data.html b/kallithea/templates/pullrequests/pullrequest_data.html
--- a/kallithea/templates/pullrequests/pullrequest_data.html
+++ b/kallithea/templates/pullrequests/pullrequest_data.html
@@ -14,7 +14,7 @@
         <th></th>
         <th class="left">${_('Title')}</th>
         <th class="left">${_('Author')}</th>
-        <th class="left">${_('Date')}</th>
+        <th class="left">${_('Age')}</th>
         <th class="left">${_('From')}</th>
         <th class="left">${_('To')}</th>
       </tr>
@@ -54,7 +54,9 @@
         ${pr.author.username_and_name}
       </td>
       <td>
-        ${h.fmt_date(pr.created_on)}
+        <span class="tooltip" title="${h.tooltip(h.fmt_date(pr.created_on))}">
+          ${h.age(pr.created_on)}
+        </span>
       </td>
       <td>
         <% org_ref_name=pr.org_ref.rsplit(':', 2)[-2] %>


More information about the kallithea-general mailing list