353 lines
12 KiB
XML
353 lines
12 KiB
XML
<!-- content macros -->
|
|
|
|
<metal:block define-macro="content"
|
|
tal:define="bodyMacro item/bodyMacro">
|
|
<metal:body use-macro="views/node_macros/?bodyMacro" />
|
|
<tal:sub define="level python:level+1">
|
|
<tal:items repeat="item item/textItems">
|
|
<metal:content use-macro="views/node_macros/content" />
|
|
</tal:items>
|
|
</tal:sub>
|
|
</metal:block>
|
|
|
|
|
|
<metal:body define-macro="textbody">
|
|
<tal:body define="body item/body;
|
|
itemNum view/itemNum;
|
|
id string:$itemNum.body;">
|
|
<div class="content-1" id="1.body"
|
|
tal:condition="body"
|
|
tal:attributes="class string:content-$level;
|
|
id string:${view/itemNum}.body;
|
|
ondblclick item/openEditWindow"
|
|
tal:content="structure body">
|
|
The body
|
|
</div>
|
|
<div tal:define="target nocall:item/targetObjectView"
|
|
tal:condition="nocall:target">
|
|
<div class="content-1 subcolumn" id="1.body"
|
|
tal:define="node nocall:item;
|
|
item nocall:target"
|
|
tal:attributes="class string:content-$level;
|
|
id id;
|
|
ondblclick python: target.openEditWindow('configure.html')">
|
|
<metal:body use-macro="item/macro">
|
|
The body
|
|
</metal:body>
|
|
</div>
|
|
</div>
|
|
</tal:body>
|
|
</metal:body>
|
|
|
|
|
|
<metal:body define-macro="conceptbody">
|
|
<tal:body define="body item/body;">
|
|
<div class="content-1" id="1"
|
|
tal:attributes="class string:content-$level;
|
|
id string:${view/itemNum}.body;
|
|
ondblclick python: item.openEditWindow('configure.html')">
|
|
<span tal:content="structure body">Node Body</span>
|
|
</div>
|
|
<tal:concepts define="item nocall:item/targetObjectView;
|
|
macro item/macro">
|
|
<div metal:use-macro="macro" />
|
|
</tal:concepts>
|
|
</tal:body>
|
|
</metal:body>
|
|
|
|
|
|
<metal:body define-macro="filebody">
|
|
<tal:body define="body item/body">
|
|
<div class="content-1" id="1"
|
|
tal:attributes="class string:content-$level;
|
|
id string:${view/itemNum}.body;
|
|
ondblclick python: item.openEditWindow('edit_target.html')">
|
|
<a href="#"
|
|
tal:attributes="href string:${item/url}/.target/view"
|
|
tal:content="structure body">The body</a>
|
|
</div>
|
|
</tal:body>
|
|
</metal:body>
|
|
|
|
|
|
<metal:body define-macro="imagebody">
|
|
<tal:body define="body item/body">
|
|
<div class="content-1" style="margin-top: 12px"
|
|
tal:attributes="class string:content-$level;
|
|
id string:${view/itemNum}.body;
|
|
ondblclick python: item.openEditWindow('edit_target.html')">
|
|
<img src="target"
|
|
tal:attributes="src string:${item/url}/.target/view" />
|
|
</div>
|
|
<div class="content-1"
|
|
tal:condition="body"
|
|
tal:attributes="class string:content-$level;
|
|
ondblclick item/openEditWindow"
|
|
tal:content="structure body">
|
|
The body
|
|
</div>
|
|
</tal:body>
|
|
</metal:body>
|
|
|
|
|
|
<!-- named views -->
|
|
|
|
<metal:body define-macro="content_only">
|
|
<tal:nodebody define="body item/body"
|
|
condition="body">
|
|
<div class="content-1"
|
|
tal:content="structure body"
|
|
tal:attributes="id string:${view/itemNum}.body;">
|
|
Body
|
|
</div><br />
|
|
</tal:nodebody>
|
|
<div tal:define="target nocall:item/targetObjectView"
|
|
tal:condition="nocall:target">
|
|
<div class="content-1 subcolumn" id="1.body"
|
|
tal:attributes="class string:content-$level;"
|
|
tal:content="structure target/render">
|
|
The body
|
|
</div>
|
|
</div>
|
|
</metal:body>
|
|
|
|
|
|
<metal:body define-macro="listpages">
|
|
<div class="content-1"
|
|
tal:content="structure item/body"
|
|
tal:attributes="ondblclick view/openEditWindow;
|
|
id string:${view/itemNum}.body;">
|
|
Listing
|
|
</div><br />
|
|
<div tal:repeat="item item/pageItems">
|
|
<a href="#"
|
|
tal:attributes="href item/url;
|
|
title item/description"
|
|
tal:content="item/title">Item</a>
|
|
</div>
|
|
</metal:body>
|
|
|
|
|
|
<metal:resources define-macro="listresources"
|
|
tal:define="target nocall:item/targetObjectView">
|
|
<div class="content-1"
|
|
tal:content="structure item/body"
|
|
tal:attributes="ondblclick python: item.openEditWindow();
|
|
id string:${view/itemNum}.body;">
|
|
Listing
|
|
</div><br />
|
|
<div tal:attributes="ondblclick python: target.openEditWindow('resources.html')"
|
|
tal:define="item nocall:item/targetObjectView"
|
|
tal:condition="nocall:target">
|
|
<div tal:repeat="related item/resources">
|
|
<a href="#"
|
|
tal:attributes="href python:view.getUrlForTarget(related);
|
|
title related/description"
|
|
tal:content="related/title">Resource Title</a>
|
|
</div>
|
|
</div>
|
|
</metal:resources>
|
|
|
|
|
|
<metal:children define-macro="listchildren"
|
|
tal:define="target nocall:item/targetObjectView">
|
|
<div class="content-1"
|
|
tal:content="structure item/body"
|
|
tal:attributes="ondblclick python:
|
|
target and target.openEditWindow('configure.html')
|
|
or item.openEditWindow();
|
|
id string:${view/itemNum}.body;">
|
|
Listing
|
|
</div><br />
|
|
<div tal:attributes="ondblclick python: target.openEditWindow('configure.html')"
|
|
tal:define="item nocall:item/targetObjectView"
|
|
tal:condition="nocall:target">
|
|
<div tal:repeat="related item/children">
|
|
<a href="#"
|
|
tal:attributes="href python:view.getUrlForTarget(related);
|
|
title related/description"
|
|
tal:content="related/title">Concept Title</a>
|
|
</div>
|
|
</div>
|
|
</metal:children>
|
|
|
|
|
|
<metal:subobjects define-macro="listsubobjects"
|
|
tal:define="target nocall:item/targetObjectView">
|
|
<div class="content-1"
|
|
tal:content="structure item/body"
|
|
tal:attributes="ondblclick python:
|
|
target and target.openEditWindow('configure.html')
|
|
or item.openEditWindow();
|
|
id string:${view/itemNum}.body;">
|
|
Listing
|
|
</div>
|
|
<div tal:condition="nocall:target">
|
|
<div tal:attributes="ondblclick python: target.openEditWindow('configure.html')"
|
|
tal:define="children python:list(target.children())"
|
|
tal:condition="children">
|
|
<h3 i18n:translate="">Children</h3>
|
|
<div tal:repeat="related children">
|
|
<a tal:attributes="href python:view.getUrlForTarget(related);
|
|
title related/description"
|
|
tal:content="related/title">Concept Title</a>
|
|
</div>
|
|
</div>
|
|
<div tal:attributes="ondblclick python: target.openEditWindow('resources.html')"
|
|
tal:define="resources python:list(target.resources())"
|
|
tal:condition="resources">
|
|
<h3 i18n:translate="">Resources</h3>
|
|
<div tal:repeat="related resources">
|
|
<a tal:attributes="href python:view.getUrlForTarget(related);
|
|
title related/description"
|
|
tal:content="related/title">Resource Title</a>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</metal:subobjects>
|
|
|
|
|
|
<!-- menu -->
|
|
|
|
<metal:menu define-macro="menu"
|
|
tal:define="item nocall:view/menu | nothing;
|
|
level level|python: 1;"
|
|
tal:condition="nocall:item">
|
|
<metal:sub define-macro="submenu">
|
|
<div class="menu-3"
|
|
tal:attributes="class python: 'content '
|
|
+ (view.selected(item) and 'even' or 'odd')
|
|
+ ' menu-%i' % level">
|
|
<a href="#" class=""
|
|
tal:content="item/context/title"
|
|
tal:attributes="href item/url;
|
|
title item/description">Menu Text</a>
|
|
</div>
|
|
<tal:sub define="level python:level+1"
|
|
condition="python: level < 4 or view.active(item)">
|
|
<tal:items repeat="item item/menuItems">
|
|
<metal:portlet use-macro="views/node_macros/submenu" />
|
|
</tal:items>
|
|
</tal:sub>
|
|
</metal:sub>
|
|
</metal:menu>
|
|
|
|
|
|
<!-- portlets and actions -->
|
|
|
|
<metal:actions define-macro="top_actions">
|
|
blubb
|
|
</metal:actions>
|
|
|
|
|
|
<metal:actions define-macro="view_modes">
|
|
<ul class="view-modes"
|
|
tal:define="viewModes view/viewModes"
|
|
tal:condition="viewModes">
|
|
<li tal:repeat="mode viewModes"
|
|
tal:attributes="class mode/cssClass">
|
|
<a tal:attributes="href mode/url;
|
|
title mode/description"
|
|
tal:content="mode/title"
|
|
i18n:translate="" />
|
|
</li>
|
|
</ul>
|
|
</metal:actions>
|
|
|
|
|
|
<metal:actions define-macro="page_actions">
|
|
<div class="page-actions"
|
|
tal:define="pageActions python:view.globalOptions('action.page') or []"
|
|
tal:condition="python: 'print' in pageActions"
|
|
title="Print this page"
|
|
i18n:attributes="title">
|
|
<a href="javascript:print()">
|
|
<img tal:attributes="src string:$resourceBase/cybertools.icons/printer.png"
|
|
i18n:attributes="alt"
|
|
alt="Print" />
|
|
</a></div>
|
|
</metal:actions>
|
|
|
|
|
|
<metal:actions define-macro="object_actions">
|
|
<div id="object-actions" class="object-actions"
|
|
tal:define="target nocall:target|nothing;">
|
|
<tal:actions repeat="action python:view.getActions('object', target=target)">
|
|
<metal:action use-macro="action/macro" />
|
|
</tal:actions>
|
|
</div>
|
|
</metal:actions>
|
|
|
|
|
|
<metal:actions define-macro="clipboard">
|
|
<div class="menu-2">loops Development</div>
|
|
</metal:actions>
|
|
|
|
|
|
<metal:actions define-macro="actions">
|
|
<tal:actions repeat="action macro/actions">
|
|
<metal:action use-macro="action/macro" />
|
|
</tal:actions>
|
|
</metal:actions>
|
|
|
|
|
|
<metal:login define-macro="login">
|
|
<div><a href="login.html"
|
|
i18n:translate="">Log in</a></div>
|
|
</metal:login>
|
|
|
|
|
|
<metal:actions define-macro="personal">
|
|
<div><a href="logout.html?nextURL=login.html"
|
|
tal:attributes="href string:logout.html?nextURL=${view/menu/url}"
|
|
i18n:translate="">Log out</a></div>
|
|
<tal:actions repeat="action python:view.getActions('personal')">
|
|
<metal:action use-macro="action/macro" />
|
|
</tal:actions>
|
|
</metal:actions>
|
|
|
|
|
|
<metal:actions define-macro="presence">
|
|
<tal:user repeat="user view/usersPresent">
|
|
<div>
|
|
<a tal:omit-tag="not:user/url"
|
|
tal:attributes="href user/url"
|
|
tal:content="user/title" /></div>
|
|
</tal:user>
|
|
</metal:actions>
|
|
|
|
|
|
<!-- inner HTML macros -->
|
|
|
|
<div metal:define-macro="inline_edit"
|
|
class="content-1" id="1.body">
|
|
<form action="." method="post" id="1.form">
|
|
<div dojoType="Editor"
|
|
tal:content="structure view/body">
|
|
The body
|
|
</div>
|
|
</form>
|
|
</div>
|
|
|
|
|
|
<!-- edit and other links -->
|
|
|
|
<metal:xedit define-macro="external_edit"
|
|
tal:define="url action/url">
|
|
<a href="#" title="Edit with External Editor"
|
|
tal:attributes="href string:$url/external_edit"
|
|
i18n:attributes="title"
|
|
><img src="edit.gif" alt="External Editor"
|
|
tal:attributes="src context/++resource++edit.gif" /></a>
|
|
</metal:xedit>
|
|
|
|
|
|
<metal:editlink define-macro="editlink">
|
|
<a target="zmi"
|
|
tal:define="url string:${item/url}/@@edit.html'"
|
|
tal:attributes="href url;
|
|
onclick item/openEditWindow;">
|
|
<img src="edit.gif"
|
|
tal:attributes="src context/++resource++edit.gif" border="0" />
|
|
</a>
|
|
</metal:editlink>
|