Commit 89335dff authored by Vincent Desmares's avatar Vincent Desmares

vincentd : improve the rendering of product list

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@27636 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 5cbb2a55
from Products.ERP5Type.UnrestrictedMethod import UnrestrictedMethod
def getProductPrice(product):
getPrice = UnrestrictedMethod(product.getPrice)
return getPrice()
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ExternalMethod" module="Products.ExternalMethod.ExternalMethod"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_function</string> </key>
<value> <string>getProductPrice</string> </value>
</item>
<item>
<key> <string>_module</string> </key>
<value> <string>Ecommerce</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ERP5Site_unrestrictedGetPrice</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Unrestricted getPrice</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<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>_body</string> </key>
<value> <string>""" \n
Return default currency used in shopping_cart.\n
Please update accordingly relative path. \n
XXX: there must be an way to do this better?\n
"""\n
return context.getPortalObject().SaleOrder_getShoppingCartDefaultCurrency().getReference()\n
</string> </value>
</item>
<item>
<key> <string>_code</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>errors</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>func_code</string> </key>
<value>
<object>
<klass>
<global name="FuncCode" module="Shared.DC.Scripts.Signature"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>_getattr_</string>
<string>context</string>
</tuple>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>func_defaults</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SaleOrder_getShoppingCartDefaultCurrencyCode</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Get default currency symbole for shop</string> </value>
</item>
<item>
<key> <string>warnings</string> </key>
<value>
<tuple/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<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>_body</string> </key>
<value> <string>""" \n
Return default currency used in shopping_cart.\n
Please update accordingly relative path. \n
XXX: there must be an way to do this better?\n
"""\n
return context.getPortalObject().SaleOrder_getShoppingCartDefaultCurrency().getShortTitle()\n
</string> </value>
</item>
<item>
<key> <string>_code</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>errors</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>func_code</string> </key>
<value>
<object>
<klass>
<global name="FuncCode" module="Shared.DC.Scripts.Signature"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>_getattr_</string>
<string>context</string>
</tuple>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>func_defaults</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SaleOrder_getShoppingCartDefaultCurrencySymbole</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Get default currency symbole for shop</string> </value>
</item>
<item>
<key> <string>warnings</string> </key>
<value>
<tuple/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<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>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[
<tal:block\n
xmlns:tal="http://xml.zope.org/namespaces/tal"\n
xmlns:metal="http://xml.zope.org/namespaces/metal"\n
xmlns:i18n="http://xml.zope.org/namespaces/i18n"\n
tal:define="field_id here/getId;\n
form_id python: here.getForm().id;\n
selection_name here/getSelectionName;\n
selection here/getSelection;\n
portal_url_string here/getPortalUrlString;\n
real_context here/getContext;\n
context_url real_context/absolute_url;\n
md5_string here/getMD5Checksum;\n
line_list here/query;\n
is_domain_tree_mode here/isDomainTreeMode;\n
is_report_tree_mode here/isReportTreeMode;\n
is_domain_tree_supported here/isDomainTreeSupported;\n
is_report_tree_supported here/isReportTreeSupported;\n
show_select_column here/showSelectColumn;\n
show_anchor_column here/showAnchorColumn;\n
show_search_line here/showSearchLine;\n
is_web_mode request/is_web_mode | nothing;\n
list_style python:request.get(\'list_style\', is_web_mode and \'table\' or None);\n
is_gadget_mode request/is_gadget_mode | nothing;\n
">\n
<!-- ListBox starts here. -->\n
<input type="hidden" name="list_selection_name" value="default" tal:attributes="value selection_name" />\n
<input type="hidden" name="list_selection_name" value="default"\n
tal:attributes="value selection_name;\n
name string:${field_id}_list_selection_name" />\n
<input tal:condition="md5_string" type="hidden" name="md5_object_uid_list" value="checksum" tal:attributes="value md5_string" />\n
\n
<tal:block tal:condition="is_gadget_mode">\n
<tal:block tal:define="global box_relative_url python: request.get(\'box_relative_url\', \'\');\n
global box python: real_context.restrictedTraverse(box_relative_url); \n
global box_id python: \'visual_%s\' %box_relative_url.split(\'/\')[-1];\n
global dom_id python: request.get(\'dom_id\',None) or box_id;">\n
<input tal:condition="python:form_id" \n
type="hidden" name="gadget_form_id"\n
tal:attributes="value form_id" />\n
</tal:block>\n
</tal:block>\n
\n
<tal:replace tal:content="nothing">\n
Because TAL cannot accept unbalanced tags, the support for a domain tree is realized by a macro.\n
The macro ListBoxContainer is a no-op, if not in domain tree mode. Otherwise, the macro constructs\n
a domain tree and extracts the body in an extra table.\n
</tal:replace>\n
\n
<tal:block tal:define="expand python: 0">\n
<tal:block metal:define-macro="ListBoxContainer">\n
<tal:block tal:condition="expand">\n
<table tal:condition="is_domain_tree_mode"\n
style="width: 100%;" cellpadding="0" cellspacing="0"\n
summary="This table contains the domain tree with the switch button"\n
tal:define="selected_domain_path here/getSelectedDomainPath">\n
<tr>\n
<td valign="top">\n
<select name="domain_root_url"\n
tal:attributes="onChange string:submitAction(this.form, \'${context_url}/setDomainRoot\')">\n
<tal:block tal:repeat="c here/getDomainRootList">\n
<option value="base_domain"\n
tal:define="path python: c[0]; title python: c[1]"\n
tal:attributes="selected python: path == selected_domain_path; value path"\n
tal:content="title"\n
i18n:translate="" i18n:domain="ui">Base Domain</option>\n
</tal:block>\n
</select>\n
<table id="listbox_domain_tree_table" cellpadding="0"\n
summary="This table contains the domain tree"\n
class="listbox_domain_tree_table"\n
tal:attributes="id string:${field_id}_domain_tree_table"\n
tal:define="report_tree_list python: here.makeReportTreeList(report_path = selected_domain_path, unfolded_list = selection.getDomainList(), is_report_opened = False);\n
total_depth python: max([report_tree.depth for report_tree in report_tree_list] + [-1])">\n
<tr tal:repeat="report_tree report_tree_list">\n
<tal:block tal:repeat="i python: range(report_tree.depth)">\n
<td width="12" nowrap="nowrap">&nbsp;</td>\n
</tal:block>\n
\t\t <td colspan="1" style="text-align: left; vertical-align: top; white-space: nowrap;"\n
tal:attributes="colspan python: total_depth - report_tree.depth + 1">\n
<a href="method" class="tree_open"\n
tal:condition="report_tree/is_open"\n
tal:attributes="href string:foldDomain?domain_url=${report_tree/domain_url}&form_id=${form_id}&list_selection_name=${selection_name}&domain_depth:int=${report_tree/depth}">\n
<b tal:content="report_tree/obj/getTranslatedTitleOrId">Domain</b></a>\n
<a href="method" class="tree_closed"\n
tal:condition="not: report_tree/is_open"\n
tal:attributes="href string:unfoldDomain?domain_url=${report_tree/domain_url}&form_id=${form_id}&list_selection_name=${selection_name}&domain_depth:int=${report_tree/depth}">\n
<tal:block tal:content="report_tree/obj/getTranslatedTitleOrId">Domain</tal:block></a>\n
</td>\n
</tr>\n
</table>\n
</td>\n
<td style="vertical-align: top">\n
<tal:block metal:define-slot="ListBoxBody" />\n
</td>\n
</tr>\n
</table>\n
<tal:block tal:condition="not: is_domain_tree_mode">\n
<tal:block metal:define-slot="ListBoxBody" />\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
<tal:block tal:condition="python: list_style == \'search\'">\n
<span metal:use-macro="real_context/ListBox_asSearchStyleHTML/macros/main"/>\n
</tal:block>\n
<tal:block tal:condition="python: list_style == \'table\'">\n
<span metal:use-macro="real_context/ListBox_asMf54TableStyleHTML/macros/main"/>\n
</tal:block>\n
<tal:block tal:condition="python: list_style not in (\'search\', \'table\')">\n
<span metal:use-macro="real_context/ListBox_asStandardHTML/macros/main"/>\n
</tal:block>\n
</tal:block>\n
]]></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>ListBox_asMf54HTML</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<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>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[
<tal:block metal:define-macro="main"\n
xmlns:tal="http://xml.zope.org/namespaces/tal"\n
xmlns:metal="http://xml.zope.org/namespaces/metal"\n
xmlns:i18n="http://xml.zope.org/namespaces/i18n">\n
\n
<!-- ListBox (table mode) starts here -->\n
\n
<input tal:replace="nothing" type="hidden" name="form_id" tal:attributes="value form_id" tal:condition="form_id"/>\n
\n
<!--<input type="hidden" name="selection_name" tal:attributes="value selection_name" tal:condition="selection_name"/>\n
<input type="hidden" name="selection_index" tal:attributes="value selection_index" tal:condition="selection_index"/>-->\n
\n
<!--<input type="hidden" name="listbox_uid:list" value="" tal:attributes="name string:${field_id}_uid:list"/>\n
<input type="hidden" name="total_size" value="" tal:attributes="value here/total_size"/> -->\n
<input id="listbox_select" tal:attributes="id string:${field_id}_select"\n
title="Filter" alt="Filter" name="Base_doSelect:method"\n
type="submit" style="display: none"/>\n
\n
<tal:block tal:define="expand python: 1;\n
table_form_id request/current_form_id | form_id;\n
your_search_text python:here.getParamDict().get(\'your_search_text\', None)">\n
<tal:block metal:use-macro="template/macros/ListBoxContainer">\n
<tal:block metal:fill-slot="ListBoxBody">\n
\n
<input tal:condition="python:is_gadget_mode" type="hidden" name="dom_id" tal:attributes="value dom_id" />\n
\n
<table class="listbox table">\n
\n
<caption>\n
<span class="left">\n
<button tal:condition="is_gadget_mode"\n
tal:define = "params python: {\'list_style\':\'search\'}"\n
type="button"\n
title="Search mode"\n
tal:attributes="onclick python: real_context.KnowledgePad_generateAjaxCall(context_url+\'/\'+form_id,box,dom_id,params);"\n
i18n:domain="ui" i18n:attributes="title">\n
<img id="style_toggle_icon"\n
alt="Search mode"\n
src="erp5/images/table_style_icon.png"\n
height="16"/></button>\n
<a tal:attributes="id string:${field_id}_title; href string:${context_url}?reset=1"\n
tal:condition="python: here.field.get_value(\'list_action\')">\n
<em i18n:translate="" \n
i18n:domain="ui" tal:content="python: \'Reset search\'"/>\n
</a>\n
<tal:block tal:condition="python: not here.field.get_value(\'list_action\')">\n
<em i18n:translate="" \n
i18n:domain="ui" tal:content="here/getTitle" tal:condition="here/getTitle"/>\n
</tal:block>\n
<!-- supporting domain tree mode for gadget mode (disabled)-->\n
<!--\n
<br tal:condition="is_gadget_mode"/>\n
<button tal:condition="python: is_gadget_mode and (is_domain_tree_supported or is_report_tree_supported)"\n
tal:define = "params python: {\'setFlatListMode:method\':1}"\n
id="listbox_flat_list_mode"\n
type="button"\n
title="Flat List"\n
alt="Flat List"\n
tal:attributes="id string:${field_id}_flat_list_mode;\n
onclick python: real_context.KnowledgePad_generateAjaxCall(context_url+\'/\'+form_id,box,dom_id,params);"\n
i18n:domain="ui" i18n:attributes="title">\n
<img src="text_block.png"\n
tal:attributes="src string:${portal_url_string}/images/text_block.png;"/></button>\n
\n
<button tal:condition="python: is_gadget_mode and is_report_tree_supported"\n
tal:define = "params python: {\'setReportTreeMode:method\':1}"\n
style="cursor:pointer;" id="listbox_report_tree_mode"\n
type="button"\n
title="Report Tree"\n
alt="Report Tree"\n
tal:attributes="id string:${field_id}_report_tree_mode;\n
onclick python: real_context.KnowledgePad_generateAjaxCall(context_url+\'/\'+form_id,box,dom_id,params);"\n
i18n:domain="ui" i18n:attributes="title">\n
<img src="view_tree.png"\n
tal:attributes="src string:${portal_url_string}/images/view_tree.png;"/></button>\n
\n
<button tal:condition="python: is_gadget_mode and is_domain_tree_supported"\n
tal:define = "params python: {\'setDomainTreeMode:method\':\'1\'}"\n
style="cursor:pointer;" id="listbox_domain_tree_mode"\n
type="button"\n
title="Domain Tree"\n
alt="Domain Tree"\n
tal:attributes="id string:${field_id}_domain_tree_mode;\n
onclick python: real_context.KnowledgePad_generateAjaxCall(context_url+\'/\'+form_id,box,dom_id,params);"\n
i18n:domain="ui" i18n:attributes="title">\n
<img src="view_choose.png"\n
tal:attributes="src string:${portal_url_string}/images/view_choose.png;"/></button>\n
-->\n
</span>\n
\n
<span class="right"\n
tal:define="listbox_max_lines python: int(here.getMaxLineNumber());\n
total_line python: int(here.total_size);\n
current_page python: int(here.current_page) + 1;\n
current_page_max python: listbox_max_lines * current_page;\n
current_page_start python: (listbox_max_lines * (current_page - 1)) + 1;\n
current_page_stop python: (total_line < current_page_max) and total_line or current_page_max;">\n
<tal:block condition="python: total_line > 0"\n
tal:replace="structure python: real_context.Base_translateString(\'Results <em>${start} - ${stop}</em> of <em>${total}</em>.\', mapping=dict(start=current_page_start, stop=current_page_stop, total=total_line))"/>\n
<span class="warning" tal:condition="python: here.total_size >= 1000"> - </span><span tal:condition="python: here.total_size >= 1000" class="warning" i18n:translate="" i18n:domain="ui">There is too much result for your search, please specify what you want.</span>\n
<span tal:condition="python: total_line == 0" class="warning" i18n:translate="" i18n:domain="ui">No result !</span>\n
</span>\n
</caption>\n
\n
<tr class ="thead thead_top">\n
<td tal:condition="python:not is_gadget_mode and show_select_column"\n
class="td_check_all Data" style="width: 50px; text-align: center; vertical-align: middle;float:left;">\n
<input id="listbox_check_all" type="image"\n
name="checkAll:method" value="1"\n
src="checkall.png" alt="Check All" title="Check All"\n
tal:attributes="id string:${field_id}_check_all;\n
name string:${field_id}_checkAll:method;\n
src string:${portal_url_string}/images/checkall.png"\n
i18n:domain="ui" i18n:attributes="title" />&nbsp;<input id="listbox_uncheck_all"\n
type="image" name="uncheckAll:method" value="1"\n
src="%(portal_url_string)s/images/decheckall.png"\n
style="border: 0" alt="Uncheck All" title="Uncheck All"\n
tal:attributes="id string:${field_id}_uncheck_all;\n
src string:${portal_url_string}/images/decheckall.png;\n
name string:${field_id}_uncheckAll:method;"\n
i18n:domain="ui" i18n:attributes="title" />\n
</td>\n
\n
<tal:block tal:repeat="value here/getLabelValueList">\n
<tal:block tal:define="sql python: value[0];\n
title python: value[1];\n
sort_order python: value[2]">\n
<th tal:condition="sql">\n
\n
<button tal:condition="not:is_gadget_mode" type="submit" class="sort_button"\n
name="setSelectionQuickSortOrder:method"\n
tal:attributes="title string:${title}; \n
value string:${field_id}.${sql}"\n
i18n:domain="ui" i18n:attributes="title">\n
<span tal:content="title" i18n:domain="ui" i18n:translate="">ID</span>\n
</button>\n
\n
<!-- Sort for gadget mode -->\n
<button tal:condition="is_gadget_mode" \n
tal:define ="params python: {\'setSelectionQuickSortOrder:method\':field_id+\'.\'+sql};"\n
type="button" \n
class="sort_button"\n
tal:attributes="title string:${title}; \n
onclick python: real_context.KnowledgePad_generateAjaxCall(context_url+\'/\'+form_id,box,dom_id,params);"\n
i18n:domain="ui" i18n:attributes="title">\n
<span tal:content="title" i18n:domain="ui" i18n:translate="">ID</span>\n
</button>\n
\n
<img tal:condition="python: sort_order == \'ascending\'"\n
src="1bottomarrow.png" alt="Ascending Display" title="Ascending Display"\n
tal:attributes="src string:${portal_url_string}/images/1bottomarrow.png"\n
style="float:left"\n
i18n:domain="ui" i18n:attributes="title"/>\n
<img tal:condition="python: sort_order == \'descending\'"\n
src="1toparrow.png" alt="Descending Display" title="Descending Display"\n
tal:attributes="src string:${portal_url_string}/images/1toparrow.png"\n
style="float:left"\n
i18n:domain="ui" i18n:attributes="title"/>\n
</th>\n
<th tal:condition="not: sql" tal:content="title" i18n:domain="ui" i18n:translate=""/>\n
</tal:block>\n
</tal:block>\n
</tr>\n
<tr class="thead thead_bottom" tal:condition="show_search_line">\n
<td tal:condition="python: show_select_column and show_search_line and not is_gadget_mode"\n
class="Data" style="width: 50px; text-align: center; vertical-align: middle">\n
<input id="listbox_select" type="image" src="exec16.png"\n
title="Action" alt="Action" name="Base_doSelect:method"\n
tal:attributes="id string:${field_id}_select;\n
src string:${portal_url_string}/images/exec16.png"\n
i18n:domain="ui" i18n:attributes="title" />\n
\n
</td>\n
<td tal:repeat="value here/getSearchValueList">\n
<tal:block tal:define="alias python: value[0];\n
param python: value[1];\n
search_field python: value[2]"\n
tal:condition="alias">\n
<tal:block\n
tal:condition="python: search_field is not None"\n
tal:replace="structure python: search_field.render(value=param, key=alias)"/>\n
\n
<input tal:condition="python: not is_gadget_mode and search_field is None" \n
name="id" size="5" value=""\n
type="text" tal:attributes="name alias; value param"\n
onkeypress="submitFormOnEnter(event, this.form, \'Base_doSelect\');"/>\n
\n
<!-- Search for gadget mode -->\n
<input tal:condition="python: is_gadget_mode and search_field is None" \n
tal:define ="params python: {alias:\'this.value\'};"\n
size="8"\n
type="textarea" \n
tal:attributes=\'value python: selection.getParams().get(alias,"");\n
onkeypress python:"if(event.keyCode==13){" + real_context.KnowledgePad_generateAjaxCall(context_url+"/"+form_id,box,dom_id,params).replace("\\"this.value\\"","this.value")+ "return false;;}"\'/>\n
\n
</tal:block>\n
</td>\n
</tr>\n
\n
<tal:replace tal:content="nothing">\n
TODO: Move pagination pre-calcultion higher in that code.\n
</tal:replace>\n
<tr class="tbody" tal:condition="line_list"\n
tal:repeat="line line_list" tal:define="checked_uid_set here/getCheckedUidSet">\n
<td tal:condition="python: show_select_column and not is_gadget_mode"\n
class="DataA" style="width: 50px; text-align: center; vertical-align: middle"\n
>\n
<input tal:condition="python: not line.isSummary() and line.getObject() is not None"\n
type="checkbox" value="checked" id="listbox_cb_1" name="uids:list"\n
tal:attributes="checked python: line.getUid() in checked_uid_set;\n
value line/getUid;\n
id string:${field_id}_cb_${line/getUid}" />\n
<tal:block tal:condition="python: line.isSummary() or line.getObject() is None"></tal:block>\n
</td>\n
\n
<tal:block tal:repeat="value line/render">\n
<td tal:define="html python: value[0];\n
original_value python: value[1];\n
error python: value[2];\n
editable_field python: value[3];\n
editable_field_css python: editable_field != None and editable_field.get_value(\'css_class\');\n
empty python: original_value in (\'\', None) and not request.get(\'editable_mode\')"\n
tal:attributes="class python: empty and \'emptyCell\' or nothing">\n
<tal:block tal:condition="empty"><span tal:attributes="class editable_field_css">-</span></tal:block>\n
<input tal:condition="not: repeat/value/index"\n
type="hidden" value="1" name="listbox_uid:list"\n
tal:attributes="value python: line.getUid() or \'\';\n
name string:${field_id}_uid:list" />\n
<tal:block tal:condition="not: empty" tal:replace="structure html">value</tal:block>\n
</td>\n
</tal:block>\n
</tr>\n
<tr tal:condition="python: int(here.total_size) > int(here.getMaxLineNumber())"\n
class="tfoot">\n
<td class="pageNavigation" style="text-align: right; vertical-align:middle;"\n
tal:attributes="colspan python: len(here.getSelectedColumnList()) + bool(show_select_column)">\n
<tal:block metal:use-macro="real_context/page_navigation_render/macros/page_navigation" />\n
</td>\n
</tr>\n
</table>\n
\n
<!-- Advanced Search footer -->\n
<div class="centeredInner extendedSearchBar"\n
tal:condition="python:not is_gadget_mode and show_search_line and your_search_text is not None">\n
<input name="bottom_your_search_text" size="40" value=""\n
type="text" tal:attributes="value your_search_text"\n
onkeypress="submitFormOnEnter(event, this.form, \'ERP5Site_processAdvancedSearchBottom\');"/>\n
<input class="button" value="Search" name="ERP5Site_processAdvancedSearchBottom:method" type="submit" />\n
</div>\n
\n
<!-- Copy / Paste buttons -->\n
<div class="bottom_actions" \n
tal:condition="python:not is_gadget_mode and show_select_column">\n
\n
<button type="submit" class="compare_button" title="Compare"\n
name="Folder_compare:method"\n
i18n:attributes="title" i18n:domain="ui">\n
<span class="image"></span>\n
<span class="description" i18n:translate="" i18n:domain="ui">Compare</span>\n
</button>\n
</div>\n
</tal:block>\n
</tal:block>\n
</tal:block>\n
<!-- ListBox ends here -->\n
\n
</tal:block>\n
]]></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>ListBox_asMf54TableStyleHTML</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Listbox as tables renderer</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -66,10 +66,12 @@ ...@@ -66,10 +66,12 @@
<string>header header-bottom</string> <string>header header-bottom</string>
<string>navbar navbar-left</string> <string>navbar navbar-left</string>
<string>headline</string> <string>headline</string>
<string>product_list (Product List)</string>
<string>footer</string> <string>footer</string>
<string>subcontent subcontent-box loginbox (My Account)</string> <string>subcontent subcontent-box loginbox (My Account)</string>
<string>subcontent subcontent-box cartbox (My Cart)</string> <string>subcontent subcontent-box cartbox (My Cart)</string>
<string>subcontent subcontent-box sidemenu1 (Subsections)</string> <string>subcontent subcontent-box sidemenu1 (Subsections)</string>
<string>hidden</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -110,7 +112,15 @@ ...@@ -110,7 +112,15 @@
<value> <value>
<list> <list>
<string>page_title_box</string> <string>page_title_box</string>
<string>selected_product_box</string> </list>
</value>
</item>
<item>
<key> <string>hidden</string> </key>
<value>
<list>
<string>product_list_thumbnail</string>
<string>product_list_decoratedPrice</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -122,6 +132,14 @@ ...@@ -122,6 +132,14 @@
</list> </list>
</value> </value>
</item> </item>
<item>
<key> <string>product_list (Product List)</string> </key>
<value>
<list>
<string>product_list</string>
</list>
</value>
</item>
<item> <item>
<key> <string>subcontent subcontent-box cartbox (My Cart)</string> </key> <key> <string>subcontent subcontent-box cartbox (My Cart)</string> </key>
<value> <value>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ListBox" module="Products.ERP5Form.ListBox"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>product_list</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>all_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>anchor</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>count_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>domain_root_list</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>domain_tree</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>global_attributes</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>lines</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>list_action</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>list_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>meta_types</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>page_template</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>portal_types</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>report_root_list</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>report_tree</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>row_css_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>search</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>search_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>select</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>selection_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>sort</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>sort_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>stat_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>stat_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>untranslatable_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>url_columns</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>all_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>anchor</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>count_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>domain_root_list</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>domain_tree</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>global_attributes</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>lines</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>list_action</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>list_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>meta_types</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>page_template</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>portal_types</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>report_root_list</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>report_tree</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>row_css_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>search</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>search_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>select</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>selection_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>sort</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>sort_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>stat_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>stat_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>untranslatable_columns</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>url_columns</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>all_columns</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>anchor</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>columns</string> </key>
<value>
<list>
<tuple>
<string>thumbnail</string>
<string>Thumbnail</string>
</tuple>
<tuple>
<string>title</string>
<string>Title</string>
</tuple>
<tuple>
<string>decoratedPrice</string>
<string>Price</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>count_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string>hiddenLabel</string> </value>
</item>
<item>
<key> <string>default_params</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>domain_root_list</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>domain_tree</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>editable_columns</string> </key>
<value>
<list>
<tuple>
<string>thumbnail</string>
<string>Thumbnail</string>
</tuple>
<tuple>
<string>decoratedPrice</string>
<string>Price</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>global_attributes</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>lines</string> </key>
<value> <int>20</int> </value>
</item>
<item>
<key> <string>list_action</string> </key>
<value> <string>list</string> </value>
</item>
<item>
<key> <string>list_method</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>meta_types</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>page_template</string> </key>
<value> <string>ListBox_asMf54HTML</string> </value>
</item>
<item>
<key> <string>portal_types</string> </key>
<value>
<list>
<tuple>
<string>Product</string>
<string>Product</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>report_root_list</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>report_tree</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>row_css_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>search</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>search_columns</string> </key>
<value>
<list>
<tuple>
<string>title</string>
<string>Title</string>
</tuple>
<tuple>
<string>decoratedPrice</string>
<string>Price</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>select</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>selection_name</string> </key>
<value> <string>product_selection</string> </value>
</item>
<item>
<key> <string>sort</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>sort_columns</string> </key>
<value>
<list>
<tuple>
<string>title</string>
<string>Title</string>
</tuple>
<tuple>
<string>decoratedPrice</string>
<string>Price</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>stat_columns</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>stat_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>product_list</string> </value>
</item>
<item>
<key> <string>untranslatable_columns</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>url_columns</string> </key>
<value>
<list/>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<global name="Method" module="Products.Formulator.MethodField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>method_name</string> </key>
<value> <string>WebSection_getProductList</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="StringField" module="Products.Formulator.StandardFields"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>product_list_decoratedPrice</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
<item>
<key> <string>required_not_found</string> </key>
<value> <string>Input is required but no input given.</string> </value>
</item>
<item>
<key> <string>too_long</string> </key>
<value> <string>Too much input was given.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_maxwidth</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_width</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>extra</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>max_length</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>required</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>truncate</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>unicode</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>whitespace_preserve</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_maxwidth</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_width</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>extra</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>max_length</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>required</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>truncate</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>unicode</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>whitespace_preserve</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_maxwidth</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_width</string> </key>
<value> <int>20</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>extra</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>max_length</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>required</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Product List Decorated Price</string> </value>
</item>
<item>
<key> <string>truncate</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>unicode</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>whitespace_preserve</string> </key>
<value> <int>0</int> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: \'%s %s\' % (here.ERP5Site_unrestrictedGetPrice(cell), cell.SaleOrder_getShoppingCartDefaultCurrencyCode())</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>cell/getPrice</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -13,19 +13,16 @@ ...@@ -13,19 +13,16 @@
<key> <string>delegated_list</string> </key> <key> <string>delegated_list</string> </key>
<value> <value>
<list> <list>
<string>title</string>
<string>default</string> <string>default</string>
<string>width</string>
<string>height</string>
<string>text_editor</string>
<string>enabled</string> <string>enabled</string>
<string>whitespace_preserve</string> <string>image_display</string>
<string>image_resolution</string>
</list> </list>
</value> </value>
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>selected_product_box</string> </value> <value> <string>product_list_thumbnail</string> </value>
</item> </item>
<item> <item>
<key> <string>message_values</string> </key> <key> <string>message_values</string> </key>
...@@ -69,7 +66,9 @@ ...@@ -69,7 +66,9 @@
</item> </item>
<item> <item>
<key> <string>enabled</string> </key> <key> <string>enabled</string> </key>
<value> <string></string> </value> <value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item> </item>
<item> <item>
<key> <string>field_id</string> </key> <key> <string>field_id</string> </key>
...@@ -80,27 +79,15 @@ ...@@ -80,27 +79,15 @@
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>height</string> </key> <key> <string>image_display</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>text_editor</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>image_resolution</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>whitespace_preserve</string> </key> <key> <string>target</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>width</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
</dictionary> </dictionary>
...@@ -120,35 +107,23 @@ ...@@ -120,35 +107,23 @@
</item> </item>
<item> <item>
<key> <string>field_id</string> </key> <key> <string>field_id</string> </key>
<value> <string>my_text_content</string> </value> <value> <string>listbox_thumbnail</string> </value>
</item> </item>
<item> <item>
<key> <string>form_id</string> </key> <key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value> <value> <string>DocumentModule_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>height</string> </key>
<value> <int>5</int> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>text_editor</string> </key>
<value> <string>text_area</string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>image_display</string> </key>
<value> <string>selected_product_box</string> </value> <value> <string>micro</string> </value>
</item> </item>
<item> <item>
<key> <string>whitespace_preserve</string> </key> <key> <string>image_resolution</string> </key>
<value> <int>0</int> </value> <value> <int>75</int> </value>
</item> </item>
<item> <item>
<key> <string>width</string> </key> <key> <string>target</string> </key>
<value> <int>40</int> </value> <value> <string>Click to edit the target</string> </value>
</item> </item>
</dictionary> </dictionary>
</value> </value>
...@@ -167,7 +142,23 @@ ...@@ -167,7 +142,23 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>_text</string> </key> <key> <string>_text</string> </key>
<value> <string>here/WebSection_viewSelectedProductWidget</string> </value> <value> <string>python: cell.getDefaultImageValue().getData() and cell.getDefaultImageAbsoluteUrl()</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: (cell.getPortalType() == \'Product\') and cell.getDefaultImageValue() is not None and cell.getDefaultImageValue().getData() is not None</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -52,6 +52,7 @@ ...@@ -52,6 +52,7 @@
secondary_color python:here.getLayoutProperty(\'layout_secondary_color\', \'rgb(225,225,225)\');\n secondary_color python:here.getLayoutProperty(\'layout_secondary_color\', \'rgb(225,225,225)\');\n
header_color python:here.getLayoutProperty(\'layout_header_color\', \'rgb(218,218,218)\');\n header_color python:here.getLayoutProperty(\'layout_header_color\', \'rgb(218,218,218)\');\n
menu_color python:here.getLayoutProperty(\'layout_menu_color\', \'rgb(235,235,235)\');\n menu_color python:here.getLayoutProperty(\'layout_menu_color\', \'rgb(235,235,235)\');\n
font_list python:here.getLayoutProperty(\'layout_font_list\', \'Century Gothic, verdana, arial, sans-serif\');\n
container_width python:here.getLayoutProperty(\'layout_container_width\', 978);\n container_width python:here.getLayoutProperty(\'layout_container_width\', 978);\n
border_width python:here.getLayoutProperty(\'layout_border_width\', 10);\n border_width python:here.getLayoutProperty(\'layout_border_width\', 10);\n
main_width python:container_width - 2 * border_width;\n main_width python:container_width - 2 * border_width;\n
...@@ -96,10 +97,10 @@ div.subcontent-box.cartbox fieldset.widget div.field table tr td.cart_bottom div ...@@ -96,10 +97,10 @@ div.subcontent-box.cartbox fieldset.widget div.field table tr td.cart_bottom div
\n \n
div.selected-product {height : 110px; width:<tal:block tal:replace="main_content_width"/>px; padding-left:25px; margin-bottom:10px;}\n div.selected-product {height : 110px; width:<tal:block tal:replace="main_content_width"/>px; padding-left:25px; margin-bottom:10px;}\n
div.selected-product div {float:left; width:100px; height:100px; text-align:center; padding-right: 25px;}\n div.selected-product div {float:left; width:100px; height:100px; text-align:center; padding-right: 25px;}\n
div.selected-product img {border:solid 1px #000; padding:0px; margin-left:10px; margin-right:10px; margin-top:5px; margin-bottom:2px;}\n div.selected-product img {border:solid 1px <tal:block tal:replace="primary_color"/>; padding:0px; margin-left:10px; margin-right:10px; margin-top:5px; margin-bottom:2px;}\n
div.selected-product img:hover {border:solid 1px #000; padding:0px; margin:0px; margin-left:10px; margin-right:10px;}\n div.selected-product img:hover {border:solid 2px <tal:block tal:replace="primary_color"/>; padding:0px; margin-top:4px; margin-left:9px; margin-right:9px; margin-bottom:1px;}\n
.cart_item_name {width:180px;}\n .cart_item_name {width:180px;}\n
.headline {float:left; width:<tal:block tal:replace="main_content_width"/>px;}\n .headline {float:left; width:<tal:block tal:replace="main_width"/>px;}\n
\n \n
\n \n
.resource_left {float:left; width:<tal:block tal:replace="python: (main_content_width / 3) * 2"/>px;}\n .resource_left {float:left; width:<tal:block tal:replace="python: (main_content_width / 3) * 2"/>px;}\n
...@@ -108,17 +109,17 @@ div.selected-product img:hover {border:solid 1px #000; padding:0px; margin:0px; ...@@ -108,17 +109,17 @@ div.selected-product img:hover {border:solid 1px #000; padding:0px; margin:0px;
div.resource_image {float:left;}\n div.resource_image {float:left;}\n
div.resource_image img {border:none; margin-left:5px;}\n div.resource_image img {border:none; margin-left:5px;}\n
fieldset.resource_left div.hiddenLabel label {display:none;}\n fieldset.resource_left div.hiddenLabel label {display:none;}\n
fieldset.resource_left div.hiddenLabel div.input {float:left; width:<tal:block tal:replace="python: main_content_width / 3"/>px}\n fieldset.resource_left div.hiddenLabel div.input {float:left; width:<tal:block tal:replace="python: main_content_width / 3"/>px; padding:0px}\n
fieldset.resource_left div.hiddenLabel div.input span.hiddenLabel {font: 20px bold Verdana,sans-serif; padding-top:10px;}\n fieldset.resource_left div.hiddenLabel div.input span.hiddenLabel {font: 20px bold Verdana,sans-serif; padding-top:10px;}\n
div.resource_image label {display:none;}\n div.resource_image label {display:none;}\n
.resource_right div.hidden label {display:none;}\n .resource_right div.hidden label {display:none;}\n
.resource_right div.field label a {display:none;}\n .resource_right div.field label a {display:none;}\n
.resource_right div.field label {height:20px; width:100px; float:left;}\n .resource_right div.field label {height:20px; width:100px; float:left; padding:0px;}\n
.resource_right div.field div.input {height:20px; width:100px; float:right;}\n .resource_right div.field div.input {height:20px; width:100px; float:right; padding:0px}\n
.resource_right div.field {margin:5px}\n .resource_right div.field {margin:5px}\n
.resource_center div.hiddenLabel div.input input {}\n .resource_center div.hiddenLabel div.input input {}\n
.resource_center div.field label a {display:none;}\n .resource_center div.field label a {display:none;}\n
.resource_center div.hiddenLabel label {margin-left:15px;}\n .resource_center div.hiddenLabel label {margin-left:15px;padding:0px;}\n
.product_description_header {margin: 5px; margin-left:15px;}\n .product_description_header {margin: 5px; margin-left:15px;}\n
.product_description {display:none;}\n .product_description {display:none;}\n
.product_description_close {margin: 5px; margin-left:15px;}\n .product_description_close {margin: 5px; margin-left:15px;}\n
...@@ -133,6 +134,8 @@ div.resource_image label {display:none;}\n ...@@ -133,6 +134,8 @@ div.resource_image label {display:none;}\n
.product_list:hover {border-top: 1px solid <tal:block tal:replace="primary_color"/>; border-bottom: 1px solid <tal:block tal:replace="primary_color"/>; background-color:<tal:block tal:replace="secondary_color"/>;}\n .product_list:hover {border-top: 1px solid <tal:block tal:replace="primary_color"/>; border-bottom: 1px solid <tal:block tal:replace="primary_color"/>; background-color:<tal:block tal:replace="secondary_color"/>;}\n
.product_list_bis:hover {border-top: 1px solid <tal:block tal:replace="primary_color"/>;border-bottom: 1px solid <tal:block tal:replace="primary_color"/>; background-color:<tal:block tal:replace="secondary_color"/>;}\n .product_list_bis:hover {border-top: 1px solid <tal:block tal:replace="primary_color"/>;border-bottom: 1px solid <tal:block tal:replace="primary_color"/>; background-color:<tal:block tal:replace="secondary_color"/>;}\n
\n \n
div.shopping_cart_renderer div.input {padding:0px;}\n
\n
.shopping_cart_renderer_title {float:left; margin-top:8px;}\n .shopping_cart_renderer_title {float:left; margin-top:8px;}\n
.shopping_cart_renderer_remove {float:right; margin-top:3px;}\n .shopping_cart_renderer_remove {float:right; margin-top:3px;}\n
.shopping_cart_renderer_remove a img {border:none;}\n .shopping_cart_renderer_remove a img {border:none;}\n
...@@ -141,13 +144,34 @@ div.resource_image label {display:none;}\n ...@@ -141,13 +144,34 @@ div.resource_image label {display:none;}\n
.shopping_cart_renderer_shipping label a {display:none;}\n .shopping_cart_renderer_shipping label a {display:none;}\n
.shopping_cart_renderer_submit label a {display:none;}\n .shopping_cart_renderer_submit label a {display:none;}\n
\n \n
div.shopping_cart_renderer_shipping {width: <tal:block tal:replace="python: main_content_width - 40"/>px; height:20px; margin-bottom:20px; margin-top:20px; padding-left:20px; padding-right:20px; padding-top:3px;background-color:<tal:block tal:replace="body_color"/>;}\n div.shopping_cart_renderer_shipping {width: <tal:block tal:replace="python: main_content_width - 40"/>px; height:20px; margin-bottom:20px; margin-top:20px; padding-left:20px; padding-right:20px; padding-top:3px; padding-bottom:3px; background-color:<tal:block tal:replace="body_color"/>;}\n
.shopping_cart_renderer_shipping label {float:left; width: <tal:block tal:replace="python: main_content_width / 4"/>px; height:20px;}\n .shopping_cart_renderer_shipping label {float:left; width: <tal:block tal:replace="python: main_content_width / 4"/>px; height:20px;padding:0px;}\n
.shopping_cart_renderer_shipping div {float:right; height:20px;}\n .shopping_cart_renderer_shipping div {float:right; height:20px; padding:0px}\n
div.shopping_cart_renderer_submit {width: <tal:block tal:replace="python: main_content_width - 40"/>px; height:20px; margin-bottom:20px; padding-left:20px; padding-right:20px; padding-top:3px; background-color:<tal:block tal:replace="body_color"/>;}\n div.shopping_cart_renderer_submit {width: <tal:block tal:replace="python: main_content_width - 40"/>px; height:20px; margin-bottom:20px; padding-left:20px; padding-right:20px; padding-top:3px; padding-bottom:3px; background-color:<tal:block tal:replace="body_color"/>;}\n
.shopping_cart_renderer_submit label {float:left; width: <tal:block tal:replace="python: main_content_width / 8"/>px; height:20px;}\n .shopping_cart_renderer_submit label {float:left; width: <tal:block tal:replace="python: main_content_width / 8"/>px; height:20px;padding:0px;}\n
.shopping_cart_renderer_submit div {float:right; height:20px;}\n .shopping_cart_renderer_submit div {float:right; height:20px; padding:0px}\n
\n
.mf_commerce_text {font: 12px <tal:block tal:replace="python: \',\'.join(font_list)"/>}\n
.mf_commerce_text_bold {font: bold 12px <tal:block tal:replace="python: \',\'.join(font_list)"/>;}\n
.mf_commerce_text_small {font: 8px <tal:block tal:replace="python: \',\'.join(font_list)"/>;}\n
.mf_commerce_text_description {font: 10px <tal:block tal:replace="python: \',\'.join(font_list)"/>;}\n
\n
div.hiddenLabel label {display:none;}\n
fieldset.editable div.input {padding:0px;}\n
\n \n
.main_content table {border-top: solid 1px <tal:block tal:replace="primary_color"/>;}\n
.main_content table th {border:none; background-color:<tal:block tal:replace="body_color"/>;}\n
.main_content table tr {border:none; border-bottom:dashed 1px <tal:block tal:replace="menu_color"/>; background-color:#FFF;}\n
.main_content table td {border:none; background-color:#FFF;}\n
.main_content table tr.thead_bottom {border:none; background-color:<tal:block tal:replace="menu_color"/>;}\n
.main_content table tr.thead_top {border:none; background-color:<tal:block tal:replace="secondary_color"/>;}\n
.main_content table tr.thead_bottom td {border: solid 1px <tal:block tal:replace="primary_color"/>;border-width: 1px 0px 1px 0px;}\n
.main_content table tr.tfoot {border:none;}\n
.main_content table caption {margin-top:10px; text-align:center; padding-bottom:10px;}\n
.main_content button.sort_button {float:left;}\n
.main_content th img {clear:none; border:none; margin-left:5px;}\n
.main_content .pageNavigation input {vertical-align:middle;}\n
.main_content table td.td_check_all {background-color:<tal:block tal:replace="body_color"/>;}\n
</tal:block> </tal:block>
]]></string> </value> ]]></string> </value>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<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>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[
<tal:block metal:define-macro="large_widget">\n
<a id="anchor-sidemenu-4" tal:attributes="id gid"></a>\n
<div class="corner-content-1col-top" tal:condition="python:len(field_list)"></div>\n
<div tal:attributes="class python: gid.lstrip(aggregate_name) + \' content-1col-nobox\';"\n
tal:condition="python:len(field_list)">\n
<h1 class="group_title" i18n:translate="" i18n:domain="ui" tal:content="python: gtitle">4-01a. Side menu 1</h1>\n
<fieldset class="widget">\n
<!-- <legend i18n:translate="" i18n:domain="ui" tal:content="python: gtitle" class="group_title"/> -->\n
<tal:block tal:repeat="field field_list">\n
<tal:block metal:use-macro="here/field_render/macros/field_render"/>\n
</tal:block>\n
</fieldset>\n
</div>\n
<div class="corner-content-1col-bottom" tal:condition="python:len(field_list)"></div>\n
</tal:block>\n
]]></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>multiflex5_large_box_renderer</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -89,12 +89,13 @@ ...@@ -89,12 +89,13 @@
dummy python: request.set(\'dialog_mode\', dialog_mode);\n dummy python: request.set(\'dialog_mode\', dialog_mode);\n
dummy python: request.set(\'list_mode\', list_mode);\n dummy python: request.set(\'list_mode\', list_mode);\n
aggregate python: has_no_layout or layout_form.Form_getGroupList(\n aggregate python: has_no_layout or layout_form.Form_getGroupList(\n
[\'header\', \'navbar\', \'headline\', \'subcontent\', \'footer\']);\n [\'header\', \'navbar\', \'headline\', \'subcontent\', \'product_list\', \'footer\']);\n
aggregate python: ((aggregate is not has_no_layout) and dict(aggregate)) or {};\n aggregate python: ((aggregate is not has_no_layout) and dict(aggregate)) or {};\n
header_area python:aggregate.get(\'header\', []);\n header_area python:aggregate.get(\'header\', []);\n
navbar_area python:aggregate.get(\'navbar\', []);\n navbar_area python:aggregate.get(\'navbar\', []);\n
headline_area python:aggregate.get(\'headline\', []);\n headline_area python:aggregate.get(\'headline\', []);\n
subcontent_area python:aggregate.get(\'subcontent\', []);\n subcontent_area python:aggregate.get(\'subcontent\', []);\n
product_list_area python:aggregate.get(\'product_list\', []);\n
footer_area python:aggregate.get(\'footer\', []);\n footer_area python:aggregate.get(\'footer\', []);\n
global css_list_template python:[\n global css_list_template python:[\n
\'%s/mf54_reset.css\' % portal_path,\n \'%s/mf54_reset.css\' % portal_path,\n
...@@ -139,17 +140,10 @@ ...@@ -139,17 +140,10 @@
<div class="headline">\n <div class="headline">\n
<!-- Layout form rendering -->\n <!-- Layout form rendering -->\n
<tal:block tal:condition="python: layout_form is not None">\n <tal:block tal:condition="python: layout_form is not None">\n
<tal:block tal:repeat="aggregate python: [(\'headlibe\', headline_area)]">\n <tal:block tal:repeat="aggregate python: [(\'headline\', headline_area)]">\n
<tal:block metal:use-macro="here/aggregate_render/macros/aggregate_render"/>\n <tal:block metal:use-macro="here/aggregate_render/macros/aggregate_render"/>\n
</tal:block>\n </tal:block>\n
</tal:block> \n </tal:block>\n
<div class="main_content">\n
<div class="corner-content-1col-top"></div> \n
<div class="content-1col-nobox">\n
<tal:block tal:content="structure here/WebSection_viewSelectedProductWidget"/>\n
</div>\n
<div class="corner-content-1col-bottom"></div> \n
</div>\n
</div>\n </div>\n
\n \n
<!-- SUBCONTENT -->\n <!-- SUBCONTENT -->\n
...@@ -166,24 +160,34 @@ ...@@ -166,24 +160,34 @@
</div> \n </div> \n
\n \n
<!-- CONTENT -->\n <!-- CONTENT -->\n
<div class="main_content">\n
<div class="main_content">\n <div class="main_content">\n
<div class="corner-content-1col-top"></div> \n <div class="corner-content-1col-top"></div> \n
<div class="content-1col-nobox">\n <div class="content-1col-nobox">\n
<tal:block metal:define-slot="main"/>\n <tal:block tal:content="structure here/WebSection_viewSelectedProductWidget"/>\n
</div>\n </div>\n
<div class="corner-content-1col-bottom"></div> \n <div class="corner-content-1col-bottom"></div> \n
</div>\n </div>\n
\n <tal:block tal:condition="python: here.REQUEST.get(\'current_form_id\') != \'WebPage_viewAsWeb\' and here.REQUEST.get(\'current_form_id\') != \'WebSection_viewAsWeb\'">\n
<tal:block tal:condition="python: here.REQUEST.get(\'current_form_id\') == \'WebPage_viewAsWeb\' or here.REQUEST.get(\'current_form_id\') == \'WebSection_viewAsWeb\'">\n
<div class="main_content">\n <div class="main_content">\n
<div class="corner-content-1col-top"></div> \n <div class="corner-content-1col-top"></div> \n
<div class="content-1col-nobox">\n <div class="content-1col-nobox">\n
<tal:block tal:content="structure here/WebSection_viewProductList"/>\n <tal:block metal:define-slot="main"/>\n
</div>\n </div>\n
<div class="corner-content-1col-bottom"></div> \n <div class="corner-content-1col-bottom"></div>\n
</tal:block>\n
<tal:block tal:condition="python: here.REQUEST.get(\'current_form_id\') == \'WebPage_viewAsWeb\' or here.REQUEST.get(\'current_form_id\') == \'WebSection_viewAsWeb\'">\n
<div class="main_content">\n
<tal:block tal:condition="python: layout_form is not None"\n
tal:define="widget_renderer here/multiflex5_large_box_renderer/macros/large_widget">\n
<tal:block tal:repeat="aggregate python: [(\'product_list\', product_list_area)]">\n
<tal:block metal:use-macro="here/aggregate_render/macros/aggregate_render"/>\n
</tal:block>\n
</tal:block> \n
</div>\n </div>\n
</tal:block> \n </tal:block> \n
</div> \n </div> \n
</div> \n
\n \n
<!-- FOOTER --> \n <!-- FOOTER --> \n
<div class="footer">\n <div class="footer">\n
......
...@@ -3,11 +3,8 @@ ...@@ -3,11 +3,8 @@
<record id="1" aka="AAAAAAAAAAE="> <record id="1" aka="AAAAAAAAAAE=">
<pickle> <pickle>
<tuple> <tuple>
<tuple> <global name="EditorField" module="Products.ERP5Form.EditorField"/>
<string>Products.ERP5Form.EditorField</string> <tuple/>
<string>EditorField</string>
</tuple>
<none/>
</tuple> </tuple>
</pickle> </pickle>
<pickle> <pickle>
...@@ -213,7 +210,7 @@ ...@@ -213,7 +210,7 @@
</item> </item>
<item> <item>
<key> <string>css_class</string> </key> <key> <string>css_class</string> </key>
<value> <string>hiddenLabel</string> </value> <value> <string>hiddenLabel shopping_cart_renderer</string> </value>
</item> </item>
<item> <item>
<key> <string>default</string> </key> <key> <string>default</string> </key>
...@@ -263,6 +260,10 @@ ...@@ -263,6 +260,10 @@
<key> <string>required</string> </key> <key> <string>required</string> </key>
<value> <int>0</int> </value> <value> <int>0</int> </value>
</item> </item>
<item>
<key> <string>text_editor</string> </key>
<value> <string>text_area</string> </value>
</item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Shopping Cart</string> </value> <value> <string>Shopping Cart</string> </value>
......
...@@ -3,11 +3,8 @@ ...@@ -3,11 +3,8 @@
<record id="1" aka="AAAAAAAAAAE="> <record id="1" aka="AAAAAAAAAAE=">
<pickle> <pickle>
<tuple> <tuple>
<tuple> <global name="LabelField" module="Products.Formulator.StandardFields"/>
<string>Products.Formulator.StandardFields</string> <tuple/>
<string>LabelField</string>
</tuple>
<none/>
</tuple> </tuple>
</pickle> </pickle>
<pickle> <pickle>
...@@ -122,7 +119,7 @@ ...@@ -122,7 +119,7 @@
</item> </item>
<item> <item>
<key> <string>editable</string> </key> <key> <string>editable</string> </key>
<value> <int>1</int> </value> <value> <int>0</int> </value>
</item> </item>
<item> <item>
<key> <string>enabled</string> </key> <key> <string>enabled</string> </key>
......
...@@ -65,7 +65,7 @@ ...@@ -65,7 +65,7 @@
quantity python: int(order_line.getQuantity());\n quantity python: int(order_line.getQuantity());\n
price python: resource.getPrice();\n price python: resource.getPrice();\n
order_line_id python: order_line.getId();\n order_line_id python: order_line.getId();\n
currency python: here.restrictedTraverse(shopping_cart.getPriceCurrency());\n currency python: here.SaleOrder_getShoppingCartDefaultCurrency();\n
currency_title python: currency.getTitle(); \n currency_title python: currency.getTitle(); \n
currency_symbole python: currency.getShortTitle();">\n currency_symbole python: currency.getShortTitle();">\n
<td>\n <td>\n
......
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
<td tal:define="resource python: website.restrictedTraverse(order_line.getResource());\n <td tal:define="resource python: website.restrictedTraverse(order_line.getResource());\n
quantity python: int(order_line.getQuantity());\n quantity python: int(order_line.getQuantity());\n
price python: resource.getPrice();\n price python: resource.getPrice();\n
currency python: shopping_cart.getPriceCurrencyTitle();\n currency python: shopping_cart.SaleOrder_getShoppingCartDefaultCurrency();\n
currency_symbole python: context.getPortalObject().restrictedTraverse(shopping_cart.getPriceCurrency()).getShortTitle();"\n currency_symbole python: context.getPortalObject().restrictedTraverse(shopping_cart.getPriceCurrency()).getShortTitle();"\n
class="cart_top"> \n class="cart_top"> \n
\n \n
......
...@@ -56,17 +56,19 @@ ...@@ -56,17 +56,19 @@
<value> <string>#TODO : USE CACHE\n <value> <string>#TODO : USE CACHE\n
#the goal of this script is to get all the related product of this section\n #the goal of this script is to get all the related product of this section\n
\n \n
current_web_section = context.REQUEST.get(\'current_web_section\')\n if (context.getPortalType() != \'Web Section\'):\n
current_web_section = context.REQUEST.get(\'current_web_section\')\n
else:\n
current_web_section = context\n
product_list = []\n product_list = []\n
if limit != 0:\n kw[\'portal_type\'] = \'Product\'\n
product_list = current_web_section.WebSection_getDocumentValueListBase(all_versions=1,\n kw[\'limit\'] = limit\n
product_list = current_web_section.WebSection_getDocumentValueListBase(all_versions=1,\n
all_languages=1,\n all_languages=1,\n
limit=limit,\n **kw\n
)\n )\n
else:\n \n
product_list = current_web_section.WebSection_getDocumentValueListBase(all_versions=1,\n #raise \'\'.join([x.getObject() for x in product_list])\n
all_languages=1,\n
) \n
product_list = [x.getObject() for x in product_list if x.getPortalType() == \'Product\']\n product_list = [x.getObject() for x in product_list if x.getPortalType() == \'Product\']\n
\n \n
# this step will be remove after have find a good way to improve WebSection_getDocumentValueListBase\n # this step will be remove after have find a good way to improve WebSection_getDocumentValueListBase\n
...@@ -83,7 +85,24 @@ return product_list\n ...@@ -83,7 +85,24 @@ return product_list\n
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>limit=0</string> </value> <value> <string>limit=1000, **kw</string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Authenticated</string>
<string>Author</string>
<string>Manager</string>
<string>Member</string>
<string>Owner</string>
<string>Reviewer</string>
</tuple>
</value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -110,10 +129,13 @@ return product_list\n ...@@ -110,10 +129,13 @@ return product_list\n
<value> <value>
<tuple> <tuple>
<string>limit</string> <string>limit</string>
<string>kw</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>current_web_section</string> <string>current_web_section</string>
<string>product_list</string> <string>product_list</string>
<string>_write_</string>
<string>_apply_</string>
<string>append</string> <string>append</string>
<string>$append0</string> <string>$append0</string>
<string>_getiter_</string> <string>_getiter_</string>
...@@ -130,7 +152,7 @@ return product_list\n ...@@ -130,7 +152,7 @@ return product_list\n
<key> <string>func_defaults</string> </key> <key> <string>func_defaults</string> </key>
<value> <value>
<tuple> <tuple>
<int>0</int> <int>1000</int>
</tuple> </tuple>
</value> </value>
</item> </item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<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>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[
<div tal:repeat="product python: here.WebSection_getProductList()">\n
<div tal:condition="python: product is not None"\n
tal:define="shopping_cart here/SaleOrder_getShoppingCart;\n
site_url python:here.getWebSiteValue().absolute_url();\n
product_href python: \'%s/product_module/%s/%s\' % (site_url, product.getId(), \'Resource_viewAsShop\');\n
currency_symbole python: context.SaleOrder_getShoppingCartDefaultCurrency().getShortTitle();"\n
tal:attributes="class python: repeat[\'product\'].index % 2 and \'product_list_bis\' or \'product_list\'">\n
<div class="product_list_left">\n
<a tal:attributes="href product_href">\n
<img tal:attributes="src python: product.getDefaultImageAbsoluteUrl() + \'?display=thumbnail\'" width="75" height="75">\n
</a>\n
<p tal:content="python: product.getTranslatedTitle()">Title of the product</p>\n
<p tal:content="python: \'%s ...\' % product.getDescription()[0:80]">Description of the product</p>\n
</div>\n
<div class="product_list_right">\n
<tal:block tal:define="price product/getPrice">\n
<tal:block tal:condition="python: price is not None">\n
<span>Price : </span><span tal:content="python: \'%s %s\' % (product.getPrice(), currency_symbole)">0 euros</span><br />\n
</tal:block>\n
<tal:block tal:condition="python: price is None">\n
<span>The price is not setted yet.</span><br />\n
</tal:block>\n
</tal:block>\n
<a tal:attributes="href product_href">More informations</a>\n
</div>\n
</div>\n
</div>
]]></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>WebSection_viewProductListTemplate</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -57,12 +57,12 @@ ...@@ -57,12 +57,12 @@
<div tal:define="site_url python:here.getWebSiteValue().absolute_url();\n <div tal:define="site_url python:here.getWebSiteValue().absolute_url();\n
current_web_section python:request.get(\'current_web_section\', here);\n current_web_section python:request.get(\'current_web_section\', here);\n
shopping_cart here/SaleOrder_getShoppingCart;\n shopping_cart here/SaleOrder_getShoppingCart;\n
currency_symbole python: context.getPortalObject().restrictedTraverse(shopping_cart.getPriceCurrency()).getShortTitle();"\n currency_symbole python: shopping_cart.SaleOrder_getShoppingCartDefaultCurrencySymbole();"\n
i18n:translate="" i18n:domain="ui" i18n:attributes="title"\n i18n:translate="" i18n:domain="ui" i18n:attributes="title"\n
title="Sections accessible from here." class="selected-product">\n title="Sections accessible from here." class="selected-product">\n
<tal:block tal:repeat="product python: here.WebSection_getProductList()">\n <tal:block tal:repeat="product python: here.WebSection_getProductList(limit=5)">\n
<div tal:define="product_href python: \'%s/product_module/%s/%s\' % (site_url, product.getId(), \'Resource_viewAsShop\');\n <div tal:define="product_href python: \'%s/product_module/%s/%s\' % (site_url, product.getId(), \'Resource_viewAsShop\');\n
price product/getPrice">\n price python: here.ERP5Site_unrestrictedGetPrice(product)">\n
<a href="#" tal:attributes="href product_href">\n <a href="#" tal:attributes="href product_href">\n
<img tal:condition="python: product.getDefaultImage() is not None"\n <img tal:condition="python: product.getDefaultImage() is not None"\n
tal:attributes="src python: product.getDefaultImageAbsoluteUrl() + \'?display=thumbnail\'" width="75" height="75"/>\n tal:attributes="src python: product.getDefaultImageAbsoluteUrl() + \'?display=thumbnail\'" width="75" height="75"/>\n
......
...@@ -69,7 +69,8 @@ ...@@ -69,7 +69,8 @@
</tal:block>\n </tal:block>\n
\n \n
<tal:block tal:condition="not: isAnon"\n <tal:block tal:condition="not: isAnon"\n
tal:define="customer here/SaleOrder_getShoppingCartCustomer;\n tal:define="shopping_cart here/SaleOrder_getShoppingCart;\n
customer shopping_cart/SaleOrder_getShoppingCartCustomer;\n
website here/getWebSiteValue">\n website here/getWebSiteValue">\n
\n \n
<p class="article">\n <p class="article">\n
......
126 128
\ No newline at end of file \ No newline at end of file
Person Module
Sale Order Module
\ 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