Commit 8961d32f authored by Romain Courteaud's avatar Romain Courteaud

2006-08-02 Romain

* Add documentation_view to fix Inspector with xhtml_style.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@8988 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 03d0e961
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.PageTemplates.ZopePageTemplate</string>
<string>ZopePageTemplate</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>__ac_local_roles__</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_owner</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"\n
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">\n
<tal:block metal:define-macro="render_listbox">\n
<tal:block tal:define="field_names field_names | python: ();\n
toggleable_field_name toggleable_field_name | python: nothing;\n
zope_structured_text_field_names zope_structured_text_field_names | python: ();\n
structured_text_field_names structured_text_field_names | python: ();\n
structured_text_field_names python: structured_text_field_names+zope_structured_text_field_names;">\n
<tal:block tal:repeat="field_name field_names">\n
<tal:block tal:condition="python: form.has_field(field_name)">\n
<tal:block tal:define="listbox python: form.get_field(field_name);\n
listboxline_list python: listbox.get_value(\'default\', render_format=\'list\', REQUEST=request);">\n
\n
<tal:block tal:define="field listbox;\n
template python: here.developper_shortcut_render">\n
<tal:block metal:use-macro="template/macros/field"/>\n
</tal:block>\n
<div class="frame">\n
<div tal:attributes="class listbox/css_class">\n
<div class="frame_title" tal:content="listbox/title"></div>\n
<div class="listbox_description" tal:content="python: listbox.get_value(\'description\')"></div>\n
<tal:block tal:condition="python: len(listboxline_list) > 1">\n
<tal:block tal:repeat="listboxline python: listboxline_list">\n
<tal:block tal:define="lineid python: \'%s_%s\' % (listbox.id,repeat[\'listboxline\'].index)">\n
<div class="listbox_titleline" tal:condition="python: listboxline.isTitleLine()">\n
<tal:block tal:repeat="column_id python: listboxline.getColumnItemList()">\n
<div tal:content="python: column_id[1]"\n
tal:attributes="class python: column_id[0]"/>\n
</tal:block>\n
</div>\n
<div class="listbox_dataline" tal:condition="python: listboxline.isDataLine()"\n
tal:attributes="onclick python: toggleable_field_name and \'toggle(\\\'%s\\\')\' % (lineid) or nothing;\n
id python: \'toggle_%s_%s\' % (listbox.id, repeat[\'listboxline\'].index);">\n
<tal:block tal:repeat="column_id python: listboxline.getColumnItemList()">\n
<tal:block tal:define="is_structured_text python: column_id[0] in structured_text_field_names;\n
is_toggleable python: column_id[0] == toggleable_field_name;\n
content python: (column_id[1] is None) and (\' \') or (column_id[1]);\n
content python: column_id[0] in zope_structured_text_field_names and modules[\'Products\'].PythonScripts.standard.structured_text(content) or content;">\n
<div tal:attributes="class python: column_id[0]; id python: is_toggleable and lineid or None; name python: is_toggleable and \'toggleable\' or None"><tal:block tal:condition="is_structured_text"><a tal:condition="repeat/column_id/start" class="anchor" tal:content="structure content" tal:attributes="id python: \'a_%s_%s\' % (listbox.id, repeat[\'listboxline\'].index)"></a><tal:block tal:condition="not: repeat/column_id/start" tal:replace="structure content"/></tal:block><tal:block tal:condition="not: is_structured_text"><a tal:condition="repeat/column_id/start" class="anchor" tal:content="content" tal:attributes="id python: \'a_%s_%s\' % (listbox.id, repeat[\'listboxline\'].index)"></a><tal:block tal:condition="not: repeat/column_id/start" tal:replace="content"/></tal:block></div>\n
</tal:block>\n
</tal:block>\n
</div>\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
</div>\n
</div>\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
<tal:block tal:replace="nothing">\n
<!--\n
Copyright (c) 2006 Nexedi SARL and Contributors. All Rights Reserved.\n
Vincent Pelletier <vincent@nexedi.com>\n
\n
This program is Free Software; you can redistribute it and/or\n
modify it under the terms of the GNU General Public License\n
as published by the Free Software Foundation; either version 2\n
of the License, or (at your option) any later version.\n
\n
This program is distributed in the hope that it will be useful,\n
but WITHOUT ANY WARRANTY; without even the implied warranty of\n
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n
GNU General Public License for more details.\n
\n
You should have received a copy of the GNU General Public License\n
along with this program; if not, write to the Free Software\n
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n
-->\n
</tal:block>\n
<html>\n
<head>\n
<title></title>\n
<style type="text/css">\n
a img {\n
border: none;\n
}\n
\n
ul {\n
margin: 0;\n
}\n
\n
p, li {\n
margin: 0;\n
padding: 0;\n
}\n
\n
span.toggle {\n
border: 1px solid #000;\n
}\n
\n
span.toggle:hover {\n
background: #0F0;\n
}\n
\n
div.frame {\n
margin-bottom : 1em;\n
border: 1px solid #000;\n
}\n
\n
div.frame_title {\n
text-align: center;\n
width: 100%;\n
background: #555;\n
color: #FFF;\n
border-bottom: 1px solid #000;\n
}\n
\n
div.quick_links_group {\n
display: table-row;\n
}\n
\n
div.quick_links_group div,\n
div.quick_links_group ul {\n
display: table-cell;\n
}\n
\n
div.quick_links_group div {\n
white-space: nowrap;\n
}\n
\n
div.quick_links_group ul {\n
list-style: none;\n
padding-left: 1em;\n
}\n
\n
div.quick_links_group li {\n
display: inline;\n
}\n
\n
/* Table mode */\n
\n
div.table div.listbox_dataline,\n
div.table div.listbox_titleline {\n
display: table-row;\n
margin-left: 0.5em;\n
margin-right: 0.5em;\n
}\n
\n
div.table div.listbox_titleline div {\n
text-align: center;\n
}\n
\n
div.table div.listbox_dataline div,\n
div.table div.listbox_titleline div {\n
display: table-cell;\n
padding: 2px;\n
}\n
\n
div.table div.listbox_titleline div {\n
font-weight: bold;\n
}\n
\n
/* List mode */\n
\n
div.list div.listbox_titleline {\n
display: none;\n
}\n
\n
div.accessors div,\n
div.list div.listbox_dataline div {\n
margin-left: 0.5em;\n
margin-right: 0.5em;\n
}\n
\n
div.accessors div.title,\n
div.list div.listbox_dataline div.title {\n
margin-left: 0;\n
margin-right: 0;\n
font-weight: bold;\n
display: inline;\n
}\n
\n
div.list div.listbox_dataline div.argument {\n
display: inline;\n
margin-left: 0;\n
}\n
\n
div.list div.listbox_dataline div.type {\n
display: inline;\n
font-style: italic;\n
}\n
\n
/* Global styles (that apply both to list and table modes) */\n
\n
table div.description,\n
table div.source_path,\n
div.listbox_dataline div.description,\n
div.listbox_dataline div.source_path,\n
div.listbox_dataline div.source_code,\n
div.listbox_dataline div.content {\n
font-family: fixed, "Courier New", Courier, monospace;\n
white-space: pre;\n
overflow: auto;\n
}\n
\n
div.listbox_dataline div.source_code {\n
border-left: 1px dotted #000;\n
background: #FFF;\n
}\n
\n
div.listbox_description {\n
margin: 0.5em;\n
font-size: 70%;\n
white-space: pre;\n
color: #555;\n
}\n
\n
div.listbox_dataline {\n
margin: 0.5em;\n
/* margin-bottom: 1em; */\n
padding-left: 0.5em;\n
padding-right: 0.5em;\n
border: 1px solid #FFF;\n
}\n
\n
div.listbox_dataline:hover {\n
background: #EEE;\n
border-color: #999;\n
}\n
</style>\n
</head>\n
<body onload="toggle_all()">\n
<script type="text/javascript">\n
function toggle_all() {\n
my_elements = document.getElementsByName("toggleable");\n
for(i=0; i<my_elements.length; i++) {\n
toggle(my_elements[i].id);\n
}\n
}\n
function toggle(id) {\n
with(document.getElementById(id).style) {\n
if (display == "") {\n
display = "none";\n
with(document.getElementById("toggle_"+id).style) {\n
backgroundColor = "";\n
borderColor = "";\n
}\n
} else {\n
display = "";\n
with(document.getElementById("toggle_"+id).style) {\n
backgroundColor = "#EEE";\n
borderColor = "#999";\n
}\n
}\n
}\n
}\n
</script>\n
<span class="toggle" onclick="toggle_all()">Toggle all</span>\n
<tal:block tal:define="field_errors python: request.get(\'field_errors\',{});\n
dummy python: request.set(\'here\',here)">\n
<div class="frame">\n
<div class="frame_title">General information</div>\n
<table>\n
<tal:block tal:repeat="field_name python: (\'my_title\', \'argument_list\', \'inheritance_list\', \'my_type\', \'my_source_path\', \'my_description\')">\n
<tal:block tal:condition="python: form.has_field(field_name)">\n
<tal:block tal:define="field python: form.get_field(field_name)">\n
<tal:block metal:use-macro="here/field_render/macros/field_render"/>\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
</table>\n
</div>\n
<div class="frame">\n
<div class="frame_title">Quick links</div>\n
<tal:block tal:repeat="field_name python: (\'my_static_property_list\', \'my_dynamic_property_list\', \'my_dynamic_category_list\', \'my_static_method_list\', \'my_dynamic_method_list\', \'my_dynamic_accessor_list\')">\n
<tal:block tal:condition="python: form.has_field(field_name)">\n
<div class="quick_links_group" tal:define="field python: form.get_field(field_name)">\n
<div tal:content="field/title"></div>\n
<ul>\n
<li tal:repeat="item python: field.get_value(\'list_method\')()">\n
<a tal:attributes="href python: \'#a_%s_%s\' % (field_name,repeat[\'item\'].index+1)"\n
tal:content="item/getTitle"></a>\n
</li>\n
</ul>\n
</div>\n
</tal:block>\n
</tal:block>\n
</div>\n
<tal:block tal:define="field_names python: (\'my_static_property_list\',);\n
structured_text_field_names python: (\'title\',);">\n
<tal:block metal:use-macro="here/documentation_view/macros/render_listbox"/>\n
</tal:block>\n
<tal:block tal:define="field_names python: (\'my_dynamic_property_list\',);\n
structured_text_field_names python: (\'title\',);">\n
<tal:block metal:use-macro="here/documentation_view/macros/render_listbox"/>\n
</tal:block>\n
<tal:block tal:define="field_names python: (\'my_dynamic_category_list\',)">\n
<tal:block metal:use-macro="here/documentation_view/macros/render_listbox"/>\n
</tal:block>\n
<tal:block tal:define="field_names python: (\'my_static_method_list\',);\n
structured_text_field_names python: (\'title\',);\n
zope_structured_text_field_names python: (\'description\',);\n
toggleable_field_name python: \'source_code\';">\n
<tal:block metal:use-macro="here/documentation_view/macros/render_listbox"/>\n
</tal:block>\n
<tal:block tal:define="field_names python: (\'my_dynamic_method_list\',);\n
structured_text_field_names python: (\'title\',);\n
zope_structured_text_field_names python: (\'description\',);">\n
<tal:block metal:use-macro="here/documentation_view/macros/render_listbox"/>\n
</tal:block>\n
<tal:block tal:define="field_names python: (\'my_dynamic_accessor_list\',);\n
structured_text_field_names python: (\'accessors\',);\n
toggleable_field_name python: \'accessors\';">\n
<tal:block metal:use-macro="here/documentation_view/macros/render_listbox"/>\n
</tal:block>\n
</tal:block>\n
</body>\n
</html>
]]></string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>documentation_view</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
2006-08-02 Romain
* Add documentation_view to fix Inspector with xhtml_style.
2006-07-24 vincent
* Re-implement parameters propagation. Allows to remove most of the previously hardcoded value names from the style.
* Keep parameters when going through a workflow transition (ex : "follow bug" in bug module)
......
55
\ No newline at end of file
57
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment