cybertools/reporter/browser/macros.pt
helmutm c89e8d6293 minor improvements on cybertools.reporter
git-svn-id: svn://svn.cy55.de/Zope3/src/cybertools/trunk@1764 fd906abe-77d9-0310-91a1-e0d9ade77398
2007-05-23 10:10:53 +00:00

51 lines
1.7 KiB
XML

<!-- $Id$ -->
<metal:detail define-macro="detail"
tal:define="result item/resultSet">
<h2 tal:content="item/title">Something</h2><br />
<table>
<tr tal:repeat="cell item/cells">
<td width="20%">
<span tal:content="cell/field/title"
i18n:translate="">Fieldname</span>:
</td>
<td>
<a href="#"
tal:omit-tag="not:cell/url"
tal:attributes="href cell/url;
title cell/urlTitle">
<span tal:content="cell/text">Value</span>
</a>
</td>
</tr>
</table>
</metal:detail>
<metal:listing define-macro="listing"
tal:define="result item/resultSet">
<h2 tal:content="item/title">Something</h2><br />
<table class="listing">
<tr>
<th tal:repeat="field result/schema/fields"
tal:content="field/title"
i18n:translate="">Fieldname</th>
</tr>
<tal:items repeat="row result/rows">
<tal:item define="class python: repeat['row'].odd() and 'even' or 'odd'">
<tr tal:attributes="class class">
<td valign="top" style="white-space: normal"
tal:repeat="cell row/cells">
<a href="#"
tal:omit-tag="not:cell/url"
tal:attributes="href cell/url;
title cell/urlTitle">
<span tal:replace="cell/text">Value</span>
</a>
</td>
</tr>
</tal:item>
</tal:items>
</table>
</metal:listing>