+2004-06-18 Marcus Mueller <znek@mulle-kybernetik.com>
+
+ * Implemented proper calendar in week overview. Highlighting isn't
+ enabled, yet.
+
2004-06-18 Marcus Mueller <znek@mulle-kybernetik.com>
* Common/OGoComponent.[hm]: new component which serves as a base
.date_label {
color: #06348b;
- font-family: Arial, Helvetica, Verdana, Geneva, Tahoma, sans-serif;
+ font-family: Arial, Helvetica, Verdana, Geneva, Tahoma, sans-serif;
font-size: 12pt;
font-weight: bold;
}
.weekoverview_title {
- font-size: 8pt;
- font-family: Arial, Helvetica, Verdana, Geneva, Tahoma, sans-serif;
- letter-spacing: 0pt;
- color: #ff0000;
+ font-size: 10pt;
+ font-family: Arial, Helvetica, Verdana, Geneva, Tahoma, sans-serif;
+ letter-spacing: 0pt;
+ color: #000000;
background-color: #d2d2cc;
}
+.weekoverview_title a {
+ color: #0033cc;
+ text-decoration: none;
+}
+
+.weekoverview_title_hilite {
+ font-weight: bold;
+}
+
+.weekoverview_title_daylink {
+ font-size: 12pt;
+ color: #0033cc;
+ font-weight: bold;
+}
+
+.weekoverview_title_newlink {
+ font-size: 8pt;
+}
+
.weekoverview_content {
color: #FFFFFF;
background-color: #e8e8e0;
}
+.weekoverview_content_hilite {
+ background-color: #f5f5e9;
+}
+
.weekoverview_content a {
color: #0000FF;
font-family: Arial, Helvetica, Verdana, Geneva, Tahoma, sans-serif;
@interface OGoCalWeekOverview : OGoCalWeekView
{
+ int dayIndex;
+ NSCalendarDate *currentDay;
}
@end
return [self fetchCoreInfos];
}
+- (void)setCurrentDay:(NSCalendarDate *)_day {
+ ASSIGN(self->currentDay, _day);
+}
+
+- (NSCalendarDate *)currentDay {
+ return self->currentDay;
+}
+
+- (NSString *)currentDayName {
+ return [self->currentDay descriptionWithCalendarFormat:@"%A"];
+}
+
+- (void)setDayIndex:(char)_idx {
+ NSCalendarDate *d;
+
+ if ((self->dayIndex == _idx) && (self->currentDay != nil))
+ return;
+
+ self->dayIndex = _idx;
+
+ if (_idx > 0) {
+ d = [[self startDate]
+ dateByAddingYears:0 months:0 days:_idx
+ hours:0 minutes:0 seconds:0];
+ }
+ else
+ d = [self startDate];
+
+ [self setCurrentDay:d];
+}
+
+- (int)dayIndex {
+ return self->dayIndex;
+}
+
+- (NSDictionary *)currentDayQueryParameters {
+ return [self queryParametersBySettingSelectedDate:self->currentDay];
+}
+
@end /* OGoCalWeekOverview */
</tr>
</table>
- <var:week-overview list="appointments" item="appointment" weekStart="startDate" const:startDateKey="startDate" const:endDateKey="endDate" const:titleStyle="weekoverview_title" const:contentStyle="weekoverview_content">
+ <var:week-overview list="appointments"
+ item="appointment"
+ weekStart="startDate"
+ dayIndex="dayIndex"
+ const:startDateKey="startDate"
+ const:endDateKey="endDate"
+ const:titleStyle="weekoverview_title"
+ const:contentStyle="weekoverview_content"
+ >
+ <var:week-title>
+ <table cellpadding="0" width="100%" border="0" cellspacing="0" class="weekoverview_title">
+ <tr>
+ <td align="left" valign="top">
+ <a href="dayoverview"
+ var:queryDictionary="currentDayQueryParameters"
+ class="weekoverview_title_daylink"
+ ><var:string value="currentDay.dayOfMonth" /></a>
+ </td>
+ <td align="center" valign="top" width="97%">
+ <var:string value="currentDayName" /><br />
+ [<a href="proposal"
+ var:queryDictionary="currentDayQueryParameters"
+ class="weekoverview_title_newlink"
+ >new</a>]
+ </td>
+ </tr>
+ </table>
+ </var:week-title>
<var:week>
<a var:href="appointmentViewURL"><var:string value="appointment.title"/></a>
</var:week>