From 308c067fb65cc22422c8feae1f2e8691255e3f96 Mon Sep 17 00:00:00 2001 From: Benjamin Kellermann Date: Tue, 24 Nov 2009 22:21:04 +0100 Subject: invite implemented --- invite_participants.rb | 25 +++++++------------------ 1 file changed, 7 insertions(+), 18 deletions(-) (limited to 'invite_participants.rb') diff --git a/invite_participants.rb b/invite_participants.rb index 15c7dd1..6c9204a 100755 --- a/invite_participants.rb +++ b/invite_participants.rb @@ -33,26 +33,13 @@ require "html" load "config.rb" require "poll" Dir.chdir(olddir) -# BUGFIX for Time.parse, which handles the zone indeterministically -class << Time - alias_method :old_parse, :parse - def Time.parse(date, now=self.now) - Time.old_parse("2009-10-25 00:30") - Time.old_parse(date) - end -end table = YAML::load_file("data.yaml") -# TODO: move to own tab -#if $cgi.include?("add_participant") -# if $cgi.include?("delete_participant") -# table.delete($cgi["olduser"]) -# else -# table.add_participant($cgi["olduser"],$cgi["add_participant"],{}) -# end -#end +if $cgi.include?("add_participant") + table.add_participant("",$cgi["add_participant"],{}) +end $html = HTML.new("dudle - #{table.name} - Invite Participants") $html.header["Cache-Control"] = "no-cache" @@ -65,8 +52,10 @@ $html << Dudle::tabs("Invite Participants") $html << <

#{table.name}

-

Invite or Delete Participants

- #{table.to_html} +

Invite Participants

+ + #{table.to_html("","invite")} + TABLE $html << "" -- cgit v1.2.3