From: Art Cancro Date: Sat, 28 Sep 2002 04:01:30 +0000 (+0000) Subject: * started fleshing out the calendar day view X-Git-Tag: v7.86~6208 X-Git-Url: https://code.citadel.org/?a=commitdiff_plain;h=4628a145ad3028b396c0c8ab547492bfbd60a6e6;p=citadel.git * started fleshing out the calendar day view --- diff --git a/webcit/ChangeLog b/webcit/ChangeLog index 8f8d3cfb6..6c5e38b10 100644 --- a/webcit/ChangeLog +++ b/webcit/ChangeLog @@ -1,4 +1,7 @@ $Log$ +Revision 400.30 2002/09/28 04:01:30 ajc +* started fleshing out the calendar day view + Revision 400.29 2002/09/27 21:19:28 ajc * Add new event @@ -1040,4 +1043,3 @@ Sun Dec 6 19:50:55 EST 1998 Art Cancro 1998-12-03 Nathan Bryant * webserver.c: warning fix - diff --git a/webcit/calendar_view.c b/webcit/calendar_view.c index 8c6936bff..ed5fd34e8 100644 --- a/webcit/calendar_view.c +++ b/webcit/calendar_view.c @@ -128,7 +128,13 @@ void calendar_month_view(int year, int month, int day) { wprintf("
\n"); - wprintf("

"); + wprintf("" + "\n"); + + wprintf("
" + " " + "Add new calendar event" + "

"); tm = localtime(&previous_month); wprintf("", @@ -146,7 +152,9 @@ void calendar_month_view(int year, int month, int day) { (int)(tm->tm_year)+1900, tm->tm_mon + 1); wprintf("\n"); - wprintf("

"); + wprintf("
" + "Click on any date for day view " + "
\n"); /* Inner table (the real one) */ wprintf("

%s %d, %d

\n", + +/**********************************************************************/ + + /* Outer table (to get the background color) */ + wprintf("
\n"); + + /* Inner table (the real one) */ + wprintf("\n"); + + wprintf(""); /* end stuff-on-the-left */ + + /* Innermost table (contains hours etc.) */ + wprintf("
"); /* begin stuff-on-the-left */ + + wprintf("

" + "%s %d, %d" + "

\n", months[month-1], day, year); - /* put the data here, stupid */ - calendar_month_view_display_events(thetime); + wprintf("
" + " " + "Add new calendar event" + "

\n"); wprintf("" - "Back to month view
\n", year, month); + "Back to month view\n", year, month); + + wprintf("
\n"); + + wprintf("
" + "\n"); + + /* Now do 7 hours */ + for (i = 0; i < 7; ++i) { + wprintf("\n"); + } + + wprintf("
"); + + /* put the data here, stupid ... FIXME add hour */ + calendar_month_view_display_events(thetime); + + wprintf("
" /* end of innermost table */ + "
" /* end of inner table */ + "
" /* end of outer table */ + ); + + + } diff --git a/webcit/event.c b/webcit/event.c index 70d9a6403..d9ae239f8 100644 --- a/webcit/event.c +++ b/webcit/event.c @@ -79,7 +79,7 @@ void display_edit_individual_event(icalcomponent *supplied_vevent, long msgnum) } wprintf("\">
\n"); - wprintf("Start date: "); + wprintf("Start date/time: "); p = icalcomponent_get_first_property(vevent, ICAL_DTSTART_PROPERTY); if (p != NULL) { t = icalproperty_get_dtstart(p); @@ -90,6 +90,17 @@ void display_edit_individual_event(icalcomponent *supplied_vevent, long msgnum) display_icaltimetype_as_webform(&t, "dtstart"); wprintf("
\n"); + wprintf("End date/time: "); + p = icalcomponent_get_first_property(vevent, ICAL_DTEND_PROPERTY); + if (p != NULL) { + t = icalproperty_get_dtend(p); + } + else { + t = icaltime_from_timet(now, 0); + } + display_icaltimetype_as_webform(&t, "dtend"); + wprintf("
\n"); + wprintf("