Discussion:
[CalendarX-users] CalendarX and Zope3/Five
George Lee
2006-11-11 20:44:38 UTC
Permalink
Hi all,

An update -- I've changed CalendarX to use Zope3/Five to show month.pt and
weekbyday.pt, and it seems to be working well. It would be a few hours to a
day's work to convert the other views as well. I'm asking Lupa if there's a
way to post the code somewhere so people, especially Zope3/Five-minded
folks, could take a look at it and provide feedback!

Below is an excerpt from the new month.pt so you can see the flavor of it
and see how it is simplified a good chunk!

Peace,
George


<!-- iterate through the weeks (rows of the table) -->
<tr class="odd" tal:repeat="week view/weeks">
<tal:block repeat="day week/days">
<td tal:define="events day/events"
tal:attributes="id string:cal${day/ID};
class day/cssClass;">
<!-- the link to the day view -->
<a href="#" tal:attributes="href day/url">
<span class="day" tal:content="day/num">daydate</span>
</a><br/>&nbsp;<br/>
<!-- iterate through the events of the day -->
<tal:block repeat="event events">
<tal:block replace="structure event/display" />
</tal:block>&nbsp;
</td>
</tal:block>
</tr>

Loading...