2009-10-18 07:52:27 -05:00
|
|
|
<tal:block metal:define-macro="master"
|
|
|
|
define="contextObj python:context.getParentNode();
|
|
|
|
errors request/errors | python:{};
|
|
|
|
Iterator python:modules['Products.Archetypes'].IndexIterator;
|
|
|
|
schematas contextObj/Schemata;
|
2009-12-17 14:14:52 -06:00
|
|
|
fieldsets python:[key for key in schematas.keys() if (key != 'metadata') and (schematas[key].editableFields(contextObj, visible_only=True))];
|
2009-10-18 07:52:27 -05:00
|
|
|
default_fieldset python:(not schematas or schematas.has_key('default')) and 'default' or fieldsets[0];
|
|
|
|
fieldset request/fieldset|options/fieldset|default_fieldset;
|
2009-12-17 14:14:52 -06:00
|
|
|
fields python:schematas[fieldset].editableFields(contextObj);
|
|
|
|
lockable python:hasattr(contextObj, 'wl_isLocked');
|
|
|
|
isLocked python:lockable and contextObj.wl_isLocked();
|
2009-10-18 07:52:27 -05:00
|
|
|
isEdit python:True;
|
|
|
|
tool contextObj/getTool;
|
|
|
|
flavour python: tool.getFlavour(contextObj);
|
|
|
|
appFolder tool/getAppFolder;
|
|
|
|
appName appFolder/id;
|
2009-12-17 14:14:52 -06:00
|
|
|
css python:contextObj.getUniqueWidgetAttr(fields, 'helper_css');
|
|
|
|
js python:contextObj.getUniqueWidgetAttr(fields, 'helper_js');
|
2009-10-18 07:52:27 -05:00
|
|
|
phaseInfo python: contextObj.getAppyPhases(fieldset=fieldset, forPlone=True);
|
|
|
|
phase request/phase|phaseInfo/name;
|
|
|
|
pageName python: contextObj.getAppyPage(isEdit, phaseInfo);">
|
|
|
|
|
|
|
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"
|
|
|
|
xmlns:tal="http://xml.zope.org/namespaces/tal"
|
|
|
|
xmlns:metal="http://xml.zope.org/namespaces/metal"
|
|
|
|
xmlns:i18n="http://xml.zope.org/namespaces/i18n"
|
|
|
|
metal:use-macro="here/main_template/macros/master">
|
|
|
|
|
|
|
|
<tal:comment replace="nothing">Disable the Standard Plone green tab</tal:comment>
|
|
|
|
<div metal:fill-slot="top_slot">
|
|
|
|
<metal:block metal:use-macro="here/global_defines/macros/defines" />
|
|
|
|
<div tal:define="dummy python:request.set('disable_border', 1)" />
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<tal:comment replace="nothing">Archetypes stuff for managing Javascript and CSS.
|
|
|
|
If I remove this stuff, Javascript popup for dates does not work anyore.</tal:comment>
|
|
|
|
<metal:javascript_head fill-slot="javascript_head_slot">
|
|
|
|
<tal:block define="macro here/archetypes_custom_js/macros/javascript_head | nothing"
|
|
|
|
condition="macro">
|
|
|
|
<metal:block use-macro="macro" />
|
|
|
|
</tal:block>
|
|
|
|
<tal:js condition="js" repeat="item js">
|
|
|
|
<script type="text/javascript" charset="iso-8859-1"
|
|
|
|
tal:condition="python:exists('portal/%s' % item)"
|
|
|
|
tal:attributes="src string:$portal_url/$item">
|
|
|
|
</script>
|
|
|
|
</tal:js>
|
|
|
|
<tal:block define="macro edit_macros/javascript_head | nothing" condition="macro">
|
|
|
|
<metal:block use-macro="macro" />
|
|
|
|
</tal:block>
|
|
|
|
</metal:javascript_head>
|
|
|
|
|
|
|
|
<metal:css fill-slot="css_slot">
|
|
|
|
<tal:css condition="css" repeat="item css">
|
|
|
|
<style type="text/css" media="all"
|
|
|
|
tal:condition="python:exists('portal/%s' % item)"
|
|
|
|
tal:content="structure string:<!-- @import url($portal_url/$item); -->">
|
|
|
|
</style>
|
|
|
|
</tal:css>
|
|
|
|
<tal:block define="macro edit_macros/css | nothing" condition="macro">
|
|
|
|
<metal:block use-macro="macro" />
|
|
|
|
</tal:block>
|
|
|
|
</metal:css>
|
|
|
|
|
|
|
|
<body>
|
|
|
|
<metal:fill fill-slot="main">
|
2009-10-20 09:57:00 -05:00
|
|
|
<div metal:use-macro="here/skyn/macros/macros/pagePrologue"/>
|
2009-10-18 07:52:27 -05:00
|
|
|
<div metal:use-macro="here/skyn/macros/macros/showPageHeader"/>
|
|
|
|
|
|
|
|
<form name="edit_form" method="post" enctype="multipart/form-data"
|
|
|
|
class="enableUnloadProtection atBaseEditForm"
|
|
|
|
tal:attributes="action python: contextObj.absolute_url()+'/skyn/do'">
|
2009-10-25 15:42:08 -05:00
|
|
|
<div metal:use-macro="here/skyn/macros/macros/listFields" /><br/>
|
2009-10-20 09:57:00 -05:00
|
|
|
<input type="hidden" name="action" value="Update"/>
|
2009-10-18 07:52:27 -05:00
|
|
|
<input type="hidden" name="fieldset" tal:attributes="value fieldset"/>
|
|
|
|
<input type="hidden" name="pageName" tal:attributes="value pageName"/>
|
|
|
|
<input type="hidden" name="phase" tal:attributes="value phase"/>
|
|
|
|
<input type="hidden" name="is_new"
|
|
|
|
tal:attributes="value python: '/portal_factory/' in contextObj.absolute_url()"/>
|
|
|
|
|
|
|
|
<tal:comment replace="nothing">Buttons (Previous, Next, Save, etc)</tal:comment>
|
|
|
|
<metal:block define-slot="buttons"
|
|
|
|
tal:define="pages phaseInfo/pages;
|
|
|
|
pageIndex python:pages.index(fieldset);
|
|
|
|
numberOfPages python:len(pages)">
|
|
|
|
|
|
|
|
<tal:previousButton condition="python: pageIndex > 0">
|
|
|
|
<input class="context" type="submit" name="buttonPrevious"
|
|
|
|
i18n:attributes="value label_previous;" i18n:domain="plone"
|
2009-12-17 14:14:52 -06:00
|
|
|
tal:attributes="disabled python:test(isLocked, 'disabled', None);"/>
|
2009-10-18 07:52:27 -05:00
|
|
|
<input type="hidden" name="previousPage" tal:attributes="value python: pages[pageIndex-1]"/>
|
|
|
|
</tal:previousButton>
|
|
|
|
<tal:nextButton condition="python: pageIndex < numberOfPages - 1">
|
|
|
|
<input class="context" type="submit" name="buttonNext" value="Next"
|
|
|
|
i18n:attributes="value label_next;" i18n:domain="plone"
|
2009-12-17 14:14:52 -06:00
|
|
|
tal:attributes="disabled python:test(isLocked, 'disabled', None);"/>
|
2009-10-18 07:52:27 -05:00
|
|
|
<input type="hidden" name="nextPage" tal:attributes="value python: pages[pageIndex+1]"/>
|
|
|
|
</tal:nextButton>
|
|
|
|
<input class="context" type="submit" name="buttonOk"
|
|
|
|
i18n:attributes="value label_save;" i18n:domain="plone"
|
2009-12-17 14:14:52 -06:00
|
|
|
tal:attributes="disabled python:test(isLocked, 'disabled', None);"/>
|
2009-10-18 07:52:27 -05:00
|
|
|
<input class="standalone" type="submit" name="buttonCancel"
|
2009-12-17 14:14:52 -06:00
|
|
|
i18n:attributes="value label_cancel;" i18n:domain="plone"/>
|
2009-10-18 07:52:27 -05:00
|
|
|
</metal:block>
|
|
|
|
</form>
|
|
|
|
<div metal:use-macro="here/skyn/macros/macros/showPageFooter"/>
|
|
|
|
</metal:fill>
|
|
|
|
</body>
|
|
|
|
</html>
|
|
|
|
</tal:block>
|