You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kibble.apache.org by hu...@apache.org on 2018/02/13 16:12:44 UTC

[kibble] branch master updated: sort newcomers by date

This is an automated email from the ASF dual-hosted git repository.

humbedooh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kibble.git


The following commit(s) were added to refs/heads/master by this push:
     new 5e2d4ac  sort newcomers by date
5e2d4ac is described below

commit 5e2d4acd4b7d77bd6fe7f9fe8198d25f14eed7b1
Author: Daniel Gruno <hu...@apache.org>
AuthorDate: Tue Feb 13 17:12:36 2018 +0100

    sort newcomers by date
---
 ui/js/coffee/widget_comstat.coffee |  2 ++
 ui/js/kibble.v1.js                 | 10 ++++++++++
 2 files changed, 12 insertions(+)

diff --git a/ui/js/coffee/widget_comstat.coffee b/ui/js/coffee/widget_comstat.coffee
index d065f1a..bf67f2f 100644
--- a/ui/js/coffee/widget_comstat.coffee
+++ b/ui/js/coffee/widget_comstat.coffee
@@ -47,6 +47,7 @@ comstat = (json, state) ->
                 ])
             app(tbl, tr)
             tb = new HTML('tbody')
+            json.stats.code.newcomers.sort((a,b) => json.bios[b].code[0] - json.bios[a].code[0])
             for person, i in json.stats.code.newcomers
                 oemail = person
                 hash = json.bios[person].code[1].id.split('/')[1]
@@ -109,6 +110,7 @@ comstat = (json, state) ->
                 ])
             app(tbl, tr)
             tb = new HTML('tbody')
+            json.stats.issues.newcomers.sort((a,b) => json.bios[b].issue[0] - json.bios[a].issue[0])
             for person, i in json.stats.issues.newcomers
                 oemail = person
                 url = json.bios[person].issue[1].url
diff --git a/ui/js/kibble.v1.js b/ui/js/kibble.v1.js
index 42675b3..099e108 100644
--- a/ui/js/kibble.v1.js
+++ b/ui/js/kibble.v1.js
@@ -5353,6 +5353,11 @@ comstat = function(json, state) {
       tr = mk('tr', {}, [mk('th', {}, "Avatar"), mk('th', {}, "Name"), mk('th', {}, "Address"), mk('th', {}, "First commit")]);
       app(tbl, tr);
       tb = new HTML('tbody');
+      json.stats.code.newcomers.sort((function(_this) {
+        return function(a, b) {
+          return json.bios[b].code[0] - json.bios[a].code[0];
+        };
+      })(this));
       ref = json.stats.code.newcomers;
       for (i = q = 0, len = ref.length; q < len; i = ++q) {
         person = ref[i];
@@ -5446,6 +5451,11 @@ comstat = function(json, state) {
       tr = mk('tr', {}, [mk('th', {}, "Avatar"), mk('th', {}, "Name"), mk('th', {}, "Address"), mk('th', {}, "First issue")]);
       app(tbl, tr);
       tb = new HTML('tbody');
+      json.stats.issues.newcomers.sort((function(_this) {
+        return function(a, b) {
+          return json.bios[b].issue[0] - json.bios[a].issue[0];
+        };
+      })(this));
       ref1 = json.stats.issues.newcomers;
       for (i = u = 0, len1 = ref1.length; u < len1; i = ++u) {
         person = ref1[i];

-- 
To stop receiving notification emails like this one, please contact
humbedooh@apache.org.