source: trunk/skins/toolbox/story_view.pt @ 72

Revision 72, 4.2 KB checked in by meelis, 14 years ago (diff)

references #133 Story content type created has all described functionalities, but some of them has to be modified for better look

  • Property svn:eol-style set to LF
Line 
1<html xmlns="http://www.w3.org/1999/xhtml"
2      xml:lang="en"
3      lang="en"
4      xmlns:tal="http://xml.zope.org/namespaces/tal"
5      xmlns:metal="http://xml.zope.org/namespaces/metal"
6      xmlns:i18n="http://xml.zope.org/namespaces/i18n"
7      metal:use-macro="here/main_template/macros/master"
8      i18n:domain="plone">
9
10  <head><title></title></head>
11
12  <metal:javascript_head fill-slot="javascript_head_slot">
13    <tal:block define="macro here/archetypes_custom_js/macros/javascript_head | nothing"
14               condition="macro">
15      <metal:block use-macro="macro" />
16    </tal:block>
17    <tal:comment replace="nothing">
18      Many of the following defines duplicated from the tal:defines in the
19      main slot. With base_edit, edit_macros could be reused as it was defined
20      for the entire document. base_view uses main_template and thus must
21      create additional defines for each slot it fills.
22    </tal:comment>
23    <tal:js define="fields python:here.Schema().viewableFields(here);
24                    js python:here.getUniqueWidgetAttr(fields, 'helper_js')"
25            condition="js"
26            repeat="item js">
27      <script type="text/javascript"
28              charset="iso-8859-1"
29              tal:condition="python:exists('portal/%s' % item)"
30              tal:attributes="src string:$portal_url/$item">
31      </script>
32    </tal:js>
33    <tal:block define="portal_type python:here.getPortalTypeName().lower().replace(' ', '_');
34                       view_template python:'%s_view' % portal_type;
35                       view_macros python:path('here/%s/macros|nothing' % view_template);
36                       macro view_macros/js | nothing"
37               condition="macro">
38      <metal:block use-macro="macro" />
39    </tal:block>
40  </metal:javascript_head>
41
42  <metal:css fill-slot="css_slot">
43    <tal:comment replace="nothing">
44      Many of the following defines duplicated from the tal:defines in the
45      main slot. With base_edit, edit_macros could be reused as it was defined
46      for the entire document. base_view uses main_template and thus must
47      create additional defines for each slot it fills.
48    </tal:comment>
49    <tal:css define="fields python:here.Schema().viewableFields(here);
50                     css python:here.getUniqueWidgetAttr(fields, 'helper_css')"
51             condition="css"
52             repeat="item css">
53      <style type="text/css"
54             media="all"
55             tal:condition="python:exists('portal/%s' % item)"
56             tal:content="string:@import url($portal_url/$item);">
57      </style>
58    </tal:css>
59    <tal:block define="portal_type python:here.getPortalTypeName().lower().replace(' ', '_');
60                       view_template python:'%s_view' % portal_type;
61                       view_macros python:path('here/%s/macros|nothing' % view_template);
62                       macro view_macros/css | nothing"
63               condition="macro">
64      <metal:block use-macro="macro" />
65    </tal:block>
66  </metal:css>
67
68  <body>
69    <metal:fill fill-slot="main">
70      <metal:main_macro define-macro="main"
71            tal:define="portal_type python:here.getPortalTypeName().lower().replace(' ', '_');
72            base_macros here/base/macros;
73            view_template python:'%s_view' % portal_type;
74            view_macros python:path('here/%s/macros|nothing' % view_template);
75            header_macro view_macros/header | header_macro | base_macros/header;
76            body_macro view_macros/body | body_macro | base_macros/body;
77            folderlisting_macro view_macros/folderlisting | folderlisting | base_macros/folderlisting;
78            footer_macro view_macros/footer | footer_macro | base_macros/footer;
79            errors python:request.get('errors', {})">
80
81        <metal:use_header use-macro="header_macro" />
82        <metal:use_body use-macro="body_macro" />
83
84        <metal:use_body use-macro="folderlisting_macro" />
85        <metal:use_footer use-macro="footer_macro" />
86
87        <div metal:use-macro="here/story_relateditems/macros/relatedItems">
88            show related items if they exist
89        </div>
90
91        <div metal:use-macro="here/wcag/macros/wcag_logo">
92            Show WCAG logo
93        </div>
94
95      </metal:main_macro>
96    </metal:fill>   
97  </body>
98</html>
99
Note: See TracBrowser for help on using the repository browser.