You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by ru...@apache.org on 2017/04/20 00:40:01 UTC

[whimsy] branch master updated: add "(tabled)" to published minutes summary for tabled special orders

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

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

The following commit(s) were added to refs/heads/master by this push:
       new  c8164ec   add "(tabled)" to published minutes summary for tabled special orders
c8164ec is described below

commit c8164ece494646b63f23f4336612fe1b08f775e3
Author: Sam Ruby <ru...@intertwingly.net>
AuthorDate: Wed Apr 19 20:39:10 2017 -0400

    add "(tabled)" to published minutes summary for tabled special orders
---
 www/board/agenda/routes.rb                           | 11 +++++++++++
 www/board/agenda/views/buttons/publish-minutes.js.rb |  6 +++++-
 2 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/www/board/agenda/routes.rb b/www/board/agenda/routes.rb
index 709ad17..18e0aec 100755
--- a/www/board/agenda/routes.rb
+++ b/www/board/agenda/routes.rb
@@ -172,6 +172,17 @@ get %r{(\d\d\d\d-\d\d-\d\d).json} do |file|
   begin
     _json do
       last_modified Agenda[file][:mtime]
+      minutes = AGENDA_WORK + '/' + file.sub('_agenda_', '_minutes_').
+        sub('.txt', '.yml')
+
+      # merge in minutes, if available
+      if File.exists? minutes
+        minutes = YAML.load_file(minutes)
+        Agenda[file][:parsed].each do |item|
+          item[:minutes] = minutes[item['title']] if minutes[item['title']]
+        end
+      end
+
       Agenda[file][:parsed]
     end
   ensure
diff --git a/www/board/agenda/views/buttons/publish-minutes.js.rb b/www/board/agenda/views/buttons/publish-minutes.js.rb
index 0c3d27a..0fc3919 100644
--- a/www/board/agenda/views/buttons/publish-minutes.js.rb
+++ b/www/board/agenda/views/buttons/publish-minutes.js.rb
@@ -69,7 +69,11 @@ class PublishMinutes < React
 
     agenda.each do |item|
       if item.attach =~ /^7\w$/
-        summary += "    * #{item.title.trim()}\n"
+        if item.minutes and item.minutes.include? 'tabled'
+          summary += "    * #{item.title.trim()} (tabled)\n"
+        else
+          summary += "    * #{item.title.trim()}\n"
+        end
       end
     end
 

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