whimsical-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@apache.org
Subject [whimsy] branch master updated: further streamline for non-directors
Date Tue, 12 Apr 2016 01:58:03 GMT
This is an automated email from the ASF dual-hosted git repository.

rubys pushed a commit to branch master
in repository https://git-dual.apache.org/repos/asf/whimsy.git

The following commit(s) were added to refs/heads/master by this push:
       new  6ec2c49   further streamline for non-directors
6ec2c49 is described below

commit 6ec2c49ae9d10045e1e7231dff18e55866fb23a4
Author: Sam Ruby <rubys@intertwingly.net>
AuthorDate: Mon Apr 11 21:57:32 2016 -0400

    further streamline for non-directors
---
 lib/whimsy/asf/agenda/special.rb         |  2 +-
 www/board/agenda/views/pages/queue.js.rb | 36 +++++++++++++++++---------------
 www/board/agenda/views/router.js.rb      |  1 +
 3 files changed, 21 insertions(+), 18 deletions(-)

diff --git a/lib/whimsy/asf/agenda/special.rb b/lib/whimsy/asf/agenda/special.rb
index df6ded7..4b865f3 100644
--- a/lib/whimsy/asf/agenda/special.rb
+++ b/lib/whimsy/asf/agenda/special.rb
@@ -23,7 +23,7 @@ class ASF::Board::Agenda
       title.sub! /\sthe\s/, ' '
       title.sub! /\sApache\s/, ' '
       title.sub! /\sCommittee\s/, ' '
-      title.sub! /\sProject(\s|$)/, '\1'
+      title.sub! /\sProject(\s|$)/i, '\1'
       title.sub! /\sPMC(\s|$)/, '\1'
       title.sub! /\s\(.*\)$/, ''
 
diff --git a/www/board/agenda/views/pages/queue.js.rb b/www/board/agenda/views/pages/queue.js.rb
index 0fa2366..df10e3f 100644
--- a/www/board/agenda/views/pages/queue.js.rb
+++ b/www/board/agenda/views/pages/queue.js.rb
@@ -13,25 +13,27 @@ class Queue < React
   def render
     _div.col_xs_12 do
 
-      # Approvals
-      _h4 'Approvals'
-      _p.col_xs_12 do
-        @approvals.each_with_index do |item, index|
-          _span ', ' if index > 0
-          _Link text: item.title, href: "queue/#{item.href}"
+      if Server.role == :director
+        # Approvals
+        _h4 'Approvals'
+        _p.col_xs_12 do
+          @approvals.each_with_index do |item, index|
+            _span ', ' if index > 0
+            _Link text: item.title, href: "queue/#{item.href}"
+          end
+          _em 'None.' if @approvals.empty?
         end
-        _em 'None.' if @approvals.empty?
-      end
 
-      # Unapproved
-      %w(Unapprovals Flagged Unflagged).each do |section|
-        list = self.state[section.downcase()]
-        unless list.empty?
-          _h4 section
-          _p.col_xs_12 do
-            list.each_with_index do |item, index|
-              _span ', ' if index > 0
-              _Link text: item.title, href: item.href
+        # Unapproved
+        %w(Unapprovals Flagged Unflagged).each do |section|
+          list = self.state[section.downcase()]
+          unless list.empty?
+            _h4 section
+            _p.col_xs_12 do
+              list.each_with_index do |item, index|
+                _span ', ' if index > 0
+                _Link text: item.title, href: item.href
+              end
             end
           end
         end
diff --git a/www/board/agenda/views/router.js.rb b/www/board/agenda/views/router.js.rb
index 1ca0fba..ced0034 100644
--- a/www/board/agenda/views/router.js.rb
+++ b/www/board/agenda/views/router.js.rb
@@ -27,6 +27,7 @@ class Router
 
     elsif path == 'queue'
       item = {view: Queue, title: 'Queued approvals and comments'}
+      item.title = 'Queued comments' unless Server.role == :director
 
     elsif path == 'flagged'
       item = {view: Flagged, title: 'Flagged reports'}

-- 
To stop receiving notification emails like this one, please contact
['"commits@whimsical.apache.org" <commits@whimsical.apache.org>'].

Mime
View raw message