labs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fa...@apache.org
Subject svn commit: r832279 - /labs/consite/trunk/conferences/lib/schedule_tags.rb
Date Tue, 03 Nov 2009 02:42:06 GMT
Author: farra
Date: Tue Nov  3 02:42:06 2009
New Revision: 832279

URL: http://svn.apache.org/viewvc?rev=832279&view=rev
Log:
adding support for outputting start and end times in utc

Modified:
    labs/consite/trunk/conferences/lib/schedule_tags.rb

Modified: labs/consite/trunk/conferences/lib/schedule_tags.rb
URL: http://svn.apache.org/viewvc/labs/consite/trunk/conferences/lib/schedule_tags.rb?rev=832279&r1=832278&r2=832279&view=diff
==============================================================================
--- labs/consite/trunk/conferences/lib/schedule_tags.rb (original)
+++ labs/consite/trunk/conferences/lib/schedule_tags.rb Tue Nov  3 02:42:06 2009
@@ -225,6 +225,18 @@
     end
   end
 
+  [:start_time_utc, :end_time_utc].each do | column |
+    tag "tracks:session:#{column}" do |tag|
+      if tag.attr['datefmt']
+        tz = ActiveSupport::TimeZone[tag.locals.conference.time_zone]
+        time = tag.locals.session[column]
+        time.strftime(tag.attr['datefmt'])
+      else
+        tag.locals.session[column]
+      end
+    end
+  end
+
 
   tag "tracks:if_session_in_slot" do |tag|
     output = ""



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@labs.apache.org
For additional commands, e-mail: commits-help@labs.apache.org


Mime
View raw message