Commit 649a070b authored by Ivan Tyagov's avatar Ivan Tyagov

Switched from tempory OrderLine storage to plain pickable dictionary for...

Switched from tempory OrderLine storage to plain pickable dictionary for shopping cart items. Implemented various cart widgets and customer forms.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@12122 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 788aff48
...@@ -70,36 +70,40 @@ ...@@ -70,36 +70,40 @@
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
from Products.ERP5Type.Document import newTempOrderLine\n quantity = int(context.REQUEST.get(\'field_my_buy_quantity\', 1))\n
\n
request = context.REQUEST\n
product = context\n
quantity = request.get(\'field_my_buy_quantity\', 1)\n
shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n
\n \n
if product is None:\n
product = context\n
\n
## check if we don\'t have already such a product in cart\n ## check if we don\'t have already such a product in cart\n
line_found=False\n line_found=False\n
for order_line in shopping_cart.objectValues():\n for order_line in shopping_cart:\n
if order_line.getObject().getResource() == product.getRelativeUrl():\n if order_line[\'resource\'] == product.getRelativeUrl():\n
new_quantity = order_line.getQuantity()+int(quantity)\n new_quantity = order_line[\'quantity\'] + int(quantity)\n
if new_quantity<=0:\n if new_quantity<=0:\n
shopping_cart.deleteContent(order_line.getId())\n ## remove items with zero quantity\n
del shopping_cart[indexof(order_line)]\n
else:\n else:\n
order_line.setQuantity(new_quantity)\n order_line[\'quantity\'] = new_quantity\n
line_found=True\n line_found=True\n
break\n break\n
\n \n
if line_found == False:\n if line_found == False:\n
## new Product, add to shopping cart\n ## new Product, add to shopping cart\n
my_orderline= shopping_cart.newContent(portal_type=\'Sale Order Line\', \\\n tmp = {}\n
title = product.getTitle(), \\\n tmp[\'resource\'] = product.getRelativeUrl()\n
resource = product.getRelativeUrl(), \\\n tmp[\'quantity\'] = quantity\n
quantity=quantity)\n shopping_cart.append(tmp)\n
\n
## update back cache so we have consistent results between cache plugins\n
context.ERP5Ecommerce_getShoppingCart(action=\'update\', \\\n
new_shopping_cart = shopping_cart)\n
\n \n
redirect_url = request.get(\'HTTP_REFERER\', context.absolute_url())\n translateString = context.Base_translateString\n
redirect_url = redirect_url.split(\'?\')[0]\n context.Base_redirect(\'view\', \\\n
#redirect_url = context.getWebSectionValue().absolute_url()\n editable_mode=True, \\\n
request.RESPONSE.redirect("%s?portal_status_message=Added to cart." %redirect_url)\n keep_items={\'portal_status_message\': translateString("Added to cart.", mapping = dict())})\n
]]></string> </value> ]]></string> </value>
...@@ -118,7 +122,7 @@ request.RESPONSE.redirect("%s?portal_status_message=Added to cart." %redirect_ur ...@@ -118,7 +122,7 @@ request.RESPONSE.redirect("%s?portal_status_message=Added to cart." %redirect_ur
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string></string> </value> <value> <string>product=None</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -138,30 +142,31 @@ request.RESPONSE.redirect("%s?portal_status_message=Added to cart." %redirect_ur ...@@ -138,30 +142,31 @@ request.RESPONSE.redirect("%s?portal_status_message=Added to cart." %redirect_ur
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>0</int> </value> <value> <int>1</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
<value> <value>
<tuple> <tuple>
<string>Products.ERP5Type.Document</string> <string>product</string>
<string>newTempOrderLine</string> <string>int</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>request</string>
<string>product</string>
<string>quantity</string> <string>quantity</string>
<string>shopping_cart</string> <string>shopping_cart</string>
<string>None</string>
<string>False</string> <string>False</string>
<string>line_found</string> <string>line_found</string>
<string>_getiter_</string> <string>_getiter_</string>
<string>order_line</string> <string>order_line</string>
<string>int</string> <string>_getitem_</string>
<string>new_quantity</string> <string>new_quantity</string>
<string>_write_</string>
<string>indexof</string>
<string>True</string> <string>True</string>
<string>my_orderline</string> <string>tmp</string>
<string>redirect_url</string> <string>translateString</string>
<string>_getitem_</string> <string>dict</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -173,16 +178,18 @@ request.RESPONSE.redirect("%s?portal_status_message=Added to cart." %redirect_ur ...@@ -173,16 +178,18 @@ request.RESPONSE.redirect("%s?portal_status_message=Added to cart." %redirect_ur
<item> <item>
<key> <string>func_defaults</string> </key> <key> <string>func_defaults</string> </key>
<value> <value>
<tuple>
<none/> <none/>
</tuple>
</value> </value>
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>Product_addToShoppingCart</string> </value> <value> <string>ERP5Ecommerce_addToShoppingCart</string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Add product to shopping cart</string> </value> <value> <string>Add resource to shopping cart</string> </value>
</item> </item>
<item> <item>
<key> <string>warnings</string> </key> <key> <string>warnings</string> </key>
......
<?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>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[
<form action="">\n
<select name="field_my_buy_quantity">\n
<tal:block tal:repeat="index python: range(1,31)">\n
<option tal:content="index" tal:attributes="value index"/>\n
</tal:block>\n
</select>\n
\n
<input type="submit"\n
class="save"\n
name="ERP5Ecommerce_addToShoppingCart:method" \n
value="Add to Shopping Cart"/>\n
</form>
]]></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>ERP5Ecommerce_addToShoppingCartWidget</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Add to cart button widget</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -70,18 +70,27 @@ ...@@ -70,18 +70,27 @@
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>from Products.Formulator.Errors import FormValidationError\n <value> <string>from Products.Formulator.Errors import FormValidationError\n
\n \n
form = context.getWebSectionValue().ERP5Ecommerce_newCustomerAccountForm\n form = context.ERP5Ecommerce_newCustomerAccountForm\n
request = context.REQUEST\n request = context.REQUEST\n
form_kw = request.form\n form_kw = request.form\n
person_kw = {}\n person_kw = {}\n
field_prefix = \'field_my_\'\n field_prefix = \'field_my_\'\n
translateString = context.Base_translateString\n
\n \n
for key in form_kw.keys():\n for key in form_kw.keys():\n
if key.startswith(field_prefix):\n if key.startswith(field_prefix):\n
person_kw[key.replace(field_prefix, \'\')] = form_kw[key]\n person_kw[key.replace(field_prefix, \'\')] = form_kw[key]\n
person_kw[\'career_role\'] = \'internal\'\n
\n \n
## get credit card account details\n
bank_kw = {}\n
for key in (\'bank_code\', \'bank_account_holder_name\', \'bank_account_number\',):\n
bank_kw[key] = person_kw.pop(key)\n
bank_kw[\'stop_date\'] = \'%s/%s/%s\' %(request.get(\'subfield_field_my_stop_date_year\', \'\'), \\\n
request.get(\'subfield_field_my_stop_date_month\', \'\'), \\\n
request.get(\'subfield_field_my_stop_date_month\', \'\') )\n
try:\n try:\n
form.validate_all_to_request(request)\n kw = form.validate_all_to_request(request)\n
validated = True\n validated = True\n
except FormValidationError, validation_errors:\n except FormValidationError, validation_errors:\n
validated = False\n validated = False\n
...@@ -94,10 +103,18 @@ person_module = context.person_module\n ...@@ -94,10 +103,18 @@ person_module = context.person_module\n
person = person_module.newContent(portal_type=\'Person\', **person_kw)\n person = person_module.newContent(portal_type=\'Person\', **person_kw)\n
person.validate()\n person.validate()\n
\n \n
## TODO: create an assignment\n ## save credit card information\n
return \n credit_card = person.newContent(portal_type=\'Credit Card\')\n
credit_card.edit(**bank_kw)\n
\n \n
context.REQUEST.RESPONSE.redirect(context.WebSite_getDocumentUrl()+"/person-created")\n person.immediateReindexObject()\n
\n
context.Base_redirect(\'ERP5Ecommerce_logged_in\', \\\n
editable_mode=False, \\\n
keep_items={\'portal_status_message\': translateString("Your account was created.", mapping = dict()),\n
\'came_from\': context.absolute_url(),\n
\'__ac_name\': person_kw[\'reference\'],\n
\'__ac_password\': person_kw[\'password\']})\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
...@@ -158,10 +175,13 @@ context.REQUEST.RESPONSE.redirect(context.WebSite_getDocumentUrl()+"/person-crea ...@@ -158,10 +175,13 @@ context.REQUEST.RESPONSE.redirect(context.WebSite_getDocumentUrl()+"/person-crea
<string>form_kw</string> <string>form_kw</string>
<string>person_kw</string> <string>person_kw</string>
<string>field_prefix</string> <string>field_prefix</string>
<string>translateString</string>
<string>_getiter_</string> <string>_getiter_</string>
<string>key</string> <string>key</string>
<string>_getitem_</string> <string>_getitem_</string>
<string>_write_</string> <string>_write_</string>
<string>bank_kw</string>
<string>kw</string>
<string>True</string> <string>True</string>
<string>validated</string> <string>validated</string>
<string>validation_errors</string> <string>validation_errors</string>
...@@ -169,6 +189,8 @@ context.REQUEST.RESPONSE.redirect(context.WebSite_getDocumentUrl()+"/person-crea ...@@ -169,6 +189,8 @@ context.REQUEST.RESPONSE.redirect(context.WebSite_getDocumentUrl()+"/person-crea
<string>person_module</string> <string>person_module</string>
<string>_apply_</string> <string>_apply_</string>
<string>person</string> <string>person</string>
<string>credit_card</string>
<string>dict</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -68,15 +68,22 @@ ...@@ -68,15 +68,22 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>order_module = context.getDefaultModule(\'Sale Order\')\n <value> <string>user_id = context.portal_membership.getAuthenticatedMember().getId()\n
user_list = context.person_module.portal_catalog(reference=user_id, \\\n
portal_type="Person")\n
user_object = user_list[0].getObject()\n
\n
order_module = context.getPortalObject().sale_order_module\n
sale_order = order_module.newContent(portal_type=\'Sale Order\')\n sale_order = order_module.newContent(portal_type=\'Sale Order\')\n
sale_order.setDestination(user_object.getRelativeUrl())\n
\n \n
for order_line in shopping_cart.objectValues():\n for order_line in shopping_cart:\n
resource = context.restrictedTraverse(order_line[\'resource\'])\n
sale_order.newContent(portal_type = \'Sale Order Line\',\n sale_order.newContent(portal_type = \'Sale Order Line\',\n
resource = order_line.getResource(),\n resource = order_line[\'resource\'],\n
quantity = order_line.getQuantity(),\n quantity = order_line[\'quantity\'],\n
title = order_line.getTitle())\n price = resource.getPrice(),\n
\n title = resource.getTitle())\n
return sale_order\n return sale_order\n
</string> </value> </string> </value>
</item> </item>
...@@ -100,6 +107,7 @@ return sale_order\n ...@@ -100,6 +107,7 @@ return sale_order\n
<key> <string>_proxy_roles</string> </key> <key> <string>_proxy_roles</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignor</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
...@@ -131,10 +139,15 @@ return sale_order\n ...@@ -131,10 +139,15 @@ return sale_order\n
<string>shopping_cart</string> <string>shopping_cart</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>user_id</string>
<string>user_list</string>
<string>_getitem_</string>
<string>user_object</string>
<string>order_module</string> <string>order_module</string>
<string>sale_order</string> <string>sale_order</string>
<string>_getiter_</string> <string>_getiter_</string>
<string>order_line</string> <string>order_line</string>
<string>resource</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -204,17 +204,24 @@ ...@@ -204,17 +204,24 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>request = context.REQUEST\n <value> <string>translateString = context.Base_translateString\n
website = context.getWebSiteValue()\n shopping_cart_items = context.ERP5Ecommerce_getShoppingCartItemList()\n
shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n shopping_cart = shopping_cart_items\n
order_line_id = int(field_my_order_line_id)\n
\n
if field_my_order_line_id is not None:\n if field_my_order_line_id is not None:\n
shopping_cart.manage_delObjects(field_my_order_line_id)\n del shopping_cart_items[order_line_id]\n
portal_status_message = "Successfully removed from shopping cart."\n portal_status_message = "Successfully removed from shopping cart."\n
else:\n else:\n
portal_status_message = "Please select an item."\n portal_status_message = "Please select an item."\n
\n \n
redirect_url = website.SaleOrder_viewAsWeb.absolute_url()\n ## update back cache so we have consistent results between cache plugins\n
request.RESPONSE.redirect(redirect_url + \'?portal_status_message=%s\' %portal_status_message)\n context.ERP5Ecommerce_getShoppingCart(action=\'update\', \\\n
new_shopping_cart = shopping_cart)\n
\n
context.Base_redirect(\'SaleOrder_viewAsWeb\', \\\n
editable_mode=True, \\\n
keep_items={\'portal_status_message\': translateString(portal_status_message, mapping = dict())})\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
...@@ -269,12 +276,16 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=%s\' %portal_s ...@@ -269,12 +276,16 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=%s\' %portal_s
<string>field_my_order_line_id</string> <string>field_my_order_line_id</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>request</string> <string>translateString</string>
<string>website</string> <string>shopping_cart_items</string>
<string>shopping_cart</string> <string>shopping_cart</string>
<string>int</string>
<string>order_line_id</string>
<string>None</string> <string>None</string>
<string>_write_</string>
<string>portal_status_message</string> <string>portal_status_message</string>
<string>redirect_url</string> <string>True</string>
<string>dict</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -293,7 +304,7 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=%s\' %portal_s ...@@ -293,7 +304,7 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=%s\' %portal_s
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>SaleOrder_deleteShoppingCartItem</string> </value> <value> <string>ERP5Ecommerce_deleteShoppingCartItem</string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
......
...@@ -73,26 +73,29 @@ from DateTime import DateTime\n ...@@ -73,26 +73,29 @@ from DateTime import DateTime\n
\n \n
now = DateTime()\n now = DateTime()\n
request = context.REQUEST\n request = context.REQUEST\n
session_id = request.get(\'session_id\', None)\n expire_timeout_days = 90\n
expire_timeout_days = 7\n
cache_factory = \'erp5_session_cache\'\n cache_factory = \'erp5_session_cache\'\n
session_id = request.get(\'session_id\', None)\n
\n \n
if session_id is None:\n if session_id is None:\n
## first call so generate session_id and send back via cookie\n ## first call so generate session_id and send back via cookie\n
session_id = context.ERP5Ecommerce_generateSessionID(max_long=10)\n session_id = context.ERP5Ecommerce_generateSessionID(max_long=20)\n
request.RESPONSE.setCookie(\'session_id\', session_id, expires=(now +expire_timeout_days).fCommon(), path=\'/\')\n request.RESPONSE.setCookie(\'session_id\', session_id, expires=(now +expire_timeout_days).fCommon(), path=\'/\')\n
\n \n
\n
cache_method = CachingMethod(callable_object = context.ERP5Ecommerce_newShoppingCart, \\\n cache_method = CachingMethod(callable_object = context.ERP5Ecommerce_newShoppingCart, \\\n
id = session_id, \\\n id = session_id, \\\n
cache_factory=cache_factory)\n cache_factory=cache_factory)\n
if reset:\n if action==\'reset\':\n
## reset cart \n ## reset cart \n
cache_method.delete(id=session_id, cache_factory=cache_factory)\n cache_method.delete(id=session_id, cache_factory=cache_factory)\n
return \n elif action==\'update\':\n
## update back to cache\n
pass\n
#cache_method.delete(id=session_id, cache_factory=cache_factory)\n
#cache_method(value=new_shopping_cart)\n
else:\n else:\n
## take order for this session\n ## take order for this session\n
shopping_cart = cache_method()\n shopping_cart = cache_method(value=[])\n
return shopping_cart\n return shopping_cart\n
</string> </value> </string> </value>
</item> </item>
...@@ -110,7 +113,7 @@ else:\n ...@@ -110,7 +113,7 @@ else:\n
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>reset = False</string> </value> <value> <string>action = \'\', new_shopping_cart=None</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -130,13 +133,14 @@ else:\n ...@@ -130,13 +133,14 @@ else:\n
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>1</int> </value> <value> <int>2</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
<value> <value>
<tuple> <tuple>
<string>reset</string> <string>action</string>
<string>new_shopping_cart</string>
<string>Products.ERP5Type.Cache</string> <string>Products.ERP5Type.Cache</string>
<string>CachingMethod</string> <string>CachingMethod</string>
<string>DateTime</string> <string>DateTime</string>
...@@ -144,10 +148,10 @@ else:\n ...@@ -144,10 +148,10 @@ else:\n
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>request</string> <string>request</string>
<string>None</string>
<string>session_id</string>
<string>expire_timeout_days</string> <string>expire_timeout_days</string>
<string>cache_factory</string> <string>cache_factory</string>
<string>None</string>
<string>session_id</string>
<string>cache_method</string> <string>cache_method</string>
<string>shopping_cart</string> <string>shopping_cart</string>
</tuple> </tuple>
...@@ -162,7 +166,8 @@ else:\n ...@@ -162,7 +166,8 @@ else:\n
<key> <string>func_defaults</string> </key> <key> <string>func_defaults</string> </key>
<value> <value>
<tuple> <tuple>
<int>0</int> <string></string>
<none/>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -68,8 +68,7 @@ ...@@ -68,8 +68,7 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n <value> <string>return context.ERP5Ecommerce_getShoppingCart()\n
return shopping_cart.objectValues(\'ERP5 Order Line\')\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
...@@ -115,7 +114,6 @@ return shopping_cart.objectValues(\'ERP5 Order Line\')\n ...@@ -115,7 +114,6 @@ return shopping_cart.objectValues(\'ERP5 Order Line\')\n
<string>kw</string> <string>kw</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>shopping_cart</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -136,7 +134,7 @@ return shopping_cart.objectValues(\'ERP5 Order Line\')\n ...@@ -136,7 +134,7 @@ return shopping_cart.objectValues(\'ERP5 Order Line\')\n
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Getshopping cart items</string> </value> <value> <string>Get shopping cart items</string> </value>
</item> </item>
<item> <item>
<key> <string>warnings</string> </key> <key> <string>warnings</string> </key>
......
...@@ -68,15 +68,11 @@ ...@@ -68,15 +68,11 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>""" Why can\'t we use getTotalPrice on temporary Order object? """\n <value> <string>total = 0.0\n
total = 0.0\n
shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n
for order_line in shopping_cart.objectValues():\n for order_line in shopping_cart:\n
try:\n resource = context.restrictedTraverse(order_line[\'resource\'])\n
total += order_line.getPrice() * order_line.getTotalQuantity()\n total += resource.getPrice() * order_line[\'quantity\']\n
except RuntimeError:\n
## why this happens is a mistery ?\n
pass\n
return str(total)\n return str(total)\n
</string> </value> </string> </value>
</item> </item>
...@@ -134,7 +130,8 @@ return str(total)\n ...@@ -134,7 +130,8 @@ return str(total)\n
<string>shopping_cart</string> <string>shopping_cart</string>
<string>_getiter_</string> <string>_getiter_</string>
<string>order_line</string> <string>order_line</string>
<string>RuntimeError</string> <string>_getitem_</string>
<string>resource</string>
<string>str</string> <string>str</string>
</tuple> </tuple>
</value> </value>
...@@ -156,7 +153,7 @@ return str(total)\n ...@@ -156,7 +153,7 @@ return str(total)\n
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Calculate total price of items in shopping cart</string> </value> <value> <string>Calculate total price for items in shopping cart</string> </value>
</item> </item>
<item> <item>
<key> <string>warnings</string> </key> <key> <string>warnings</string> </key>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.PythonScripts.PythonScript</string>
<string>PythonScript</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Python_magic</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<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_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>credit_card = request.get(\'field_my_bank_account_number\', \'\')\n
if credit_card == \'\':\n
return False\n
else:\n
## validate it to an external system, using also card holder name\n
return True\n
</string> </value>
</item>
<item>
<key> <string>_code</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_filepath</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_owner</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>editor, request</string> </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>2</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>editor</string>
<string>request</string>
<string>_getattr_</string>
<string>credit_card</string>
<string>False</string>
<string>True</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>ERP5Ecommerce_isValidCreditCardNumber</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Is valid credit card number specified?</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>
<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[
<tal:block tal:condition="here/portal_skins/updateSkinCookie | nothing"\n
tal:define="dummy here/setupCurrentSkin;" />\n
<tal:block tal:define="response request/RESPONSE;\n
mtool here/portal_membership;\n
isAnon mtool/isAnonymousUser|nothing;">\n
<tal:block tal:condition="isAnon">\n
<tal:block tal:define="dummy python: response.expireCookie(\'__ac\', path=\'/\');\n
url python: \'%s?portal_status_message=%s\' % (request.get(\'came_from\'), here.getPortalObject().Localizer.translate(\'ui\', \'Login+and/or+password+is+incorrect.\'));\n
dummy python: response.redirect(url);"/>\n
</tal:block>\n
<tal:block tal:condition="not: isAnon">\n
<tal:block tal:define="came_from python: request.get(\'came_from\') or here.portal_url() + \'/view\';\n
dummy python: response.redirect(came_from);" />\n
</tal:block>\n
</tal:block>
]]></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>ERP5Ecommerce_logged_in</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Login Handler</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -48,10 +48,41 @@ ...@@ -48,10 +48,41 @@
<key> <string>_text</string> </key> <key> <string>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
<legend>\n <tal:block tal:define="isAnon here/portal_membership/isAnonymousUser">\n
<span tal:content="here/portal_membership/getAuthenticatedMember"/> \n \n
</legend>\n <tal:block tal:condition="isAnon">\n
<h4>You\'re not logged in.</h4>\n
I have an account:\n
<form action="">\n
<table>\n
<tr>\n
<td>Username:</td>\n
<td><input name="__ac_name" size="10" tal:attributes="value python: request.get(\'__ac_name\') or \'\'"/></td>\n
</tr>\n
<tr>\n
<td>Password:</td>\n
<td><input type="password" name="__ac_password" size="10"/></td>\n
</tr>\n
<tr>\n
<td><input type="hidden" name="came_from" tal:attributes="value here/absolute_url"/>\n
<input type="hidden" name="__ac_persistent" value="1"/>\n
<input type="submit" value="Login" name="ERP5Ecommerce_logged_in:method"/>\n
</td>\n
</tr>\n
</table>\n
</form>\n
\n
<a href="ERP5Ecommerce_newCustomerAccountForm?editable_mode=1"> I want to create an account</a>\n
<br/>\n
\n
</tal:block>\n
\n
<tal:block tal:condition="not: isAnon">\n
<h4>Hello, <span tal:replace="here/portal_membership/getAuthenticatedMember"/></h4>\n
<a href="ERP5Ecommerce_logout"> Log out</a><br/>\n
</tal:block>\n
\n
</tal:block>
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -69,7 +100,7 @@ ...@@ -69,7 +100,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Render login status</string> </value> <value> <string>Login status widget</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.PythonScripts.PythonScript</string>
<string>PythonScript</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Python_magic</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_Access_contents_information_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Change_bindings_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Change_cache_settings_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Change_permissions_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Copy_or_Move_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Delete_objects_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Manage_WebDAV_Locks_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Manage_properties_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Take_ownership_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_Undo_changes_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_View_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_View_management_screens_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_WebDAV_Lock_items_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_WebDAV_Unlock_items_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<item>
<key> <string>_WebDAV_access_Permission</string> </key>
<value>
<list>
<string>Manager</string>
</list>
</value>
</item>
<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_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>REQUEST = context.REQUEST\n
if REQUEST.has_key(\'portal_skin\'):\n
context.portal_skins.clearSkinCookie()\n
\n
REQUEST.RESPONSE.expireCookie(\'__ac\', path=\'/\')\n
\n
translateString = context.Base_translateString\n
context.Base_redirect(\'view\', \\\n
editable_mode=False, \\\n
keep_items={\'portal_status_message\': translateString("You have been logged out.", mapping = dict())})\n
</string> </value>
</item>
<item>
<key> <string>_code</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_filepath</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/>
</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>
<string>REQUEST</string>
<string>translateString</string>
<string>False</string>
<string>dict</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>ERP5Ecommerce_logout</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Logout handler</string> </value>
</item>
<item>
<key> <string>warnings</string> </key>
<value>
<tuple/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -65,7 +65,6 @@ ...@@ -65,7 +65,6 @@
<string>right</string> <string>right</string>
<string>center</string> <string>center</string>
<string>bottom</string> <string>bottom</string>
<string>hidden</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -82,13 +81,13 @@ ...@@ -82,13 +81,13 @@
<item> <item>
<key> <string>center</string> </key> <key> <string>center</string> </key>
<value> <value>
<list/> <list>
</value> <string>my_bank_account_holder_name</string>
</item> <string>my_bank_account_number</string>
<item> <string>my_bank_code</string>
<key> <string>hidden</string> </key> <string>my_stop_date</string>
<value> <string>submit_register</string>
<list/> </list>
</value> </value>
</item> </item>
<item> <item>
...@@ -108,7 +107,6 @@ ...@@ -108,7 +107,6 @@
<string>my_reference</string> <string>my_reference</string>
<string>my_password</string> <string>my_password</string>
<string>password_confirm</string> <string>password_confirm</string>
<string>submit_register</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -147,7 +145,7 @@ ...@@ -147,7 +145,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Register new customer account</string> </value> <value> <string>New customer account</string> </value>
</item> </item>
<item> <item>
<key> <string>unicode_mode</string> </key> <key> <string>unicode_mode</string> </key>
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<tuple> <tuple>
<tuple> <tuple>
<string>Products.Formulator.StandardFields</string> <string>Products.Formulator.StandardFields</string>
<string>IntegerField</string> <string>StringField</string>
</tuple> </tuple>
<none/> <none/>
</tuple> </tuple>
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>my_buy_quantity</string> </value> <value> <string>my_bank_account_holder_name</string> </value>
</item> </item>
<item> <item>
<key> <string>message_values</string> </key> <key> <string>message_values</string> </key>
...@@ -24,18 +24,14 @@ ...@@ -24,18 +24,14 @@
<key> <string>external_validator_failed</string> </key> <key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value> <value> <string>The input failed the external validator.</string> </value>
</item> </item>
<item>
<key> <string>integer_out_of_range</string> </key>
<value> <string>The integer you entered was out of range.</string> </value>
</item>
<item>
<key> <string>not_integer</string> </key>
<value> <string>You did not enter an integer.</string> </value>
</item>
<item> <item>
<key> <string>required_not_found</string> </key> <key> <string>required_not_found</string> </key>
<value> <string>Input is required but no input given.</string> </value> <value> <string>Input is required but no input given.</string> </value>
</item> </item>
<item>
<key> <string>too_long</string> </key>
<value> <string>Too much input was given.</string> </value>
</item>
</dictionary> </dictionary>
</value> </value>
</item> </item>
...@@ -75,10 +71,6 @@ ...@@ -75,10 +71,6 @@
<key> <string>enabled</string> </key> <key> <string>enabled</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item>
<key> <string>end</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>external_validator</string> </key> <key> <string>external_validator</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -92,17 +84,25 @@ ...@@ -92,17 +84,25 @@
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>required</string> </key> <key> <string>max_length</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>start</string> </key> <key> <string>required</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item>
<key> <string>truncate</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>unicode</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>whitespace_preserve</string> </key> <key> <string>whitespace_preserve</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -146,10 +146,6 @@ ...@@ -146,10 +146,6 @@
<key> <string>enabled</string> </key> <key> <string>enabled</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item>
<key> <string>end</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>external_validator</string> </key> <key> <string>external_validator</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -163,17 +159,25 @@ ...@@ -163,17 +159,25 @@
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>required</string> </key> <key> <string>max_length</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>start</string> </key> <key> <string>required</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item>
<key> <string>truncate</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>unicode</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>whitespace_preserve</string> </key> <key> <string>whitespace_preserve</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -195,7 +199,7 @@ ...@@ -195,7 +199,7 @@
</item> </item>
<item> <item>
<key> <string>default</string> </key> <key> <string>default</string> </key>
<value> <string>1</string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
...@@ -207,7 +211,7 @@ ...@@ -207,7 +211,7 @@
</item> </item>
<item> <item>
<key> <string>display_width</string> </key> <key> <string>display_width</string> </key>
<value> <int>3</int> </value> <value> <int>20</int> </value>
</item> </item>
<item> <item>
<key> <string>editable</string> </key> <key> <string>editable</string> </key>
...@@ -215,11 +219,7 @@ ...@@ -215,11 +219,7 @@
</item> </item>
<item> <item>
<key> <string>enabled</string> </key> <key> <string>enabled</string> </key>
<value> <int>0</int> </value> <value> <int>1</int> </value>
</item>
<item>
<key> <string>end</string> </key>
<value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>external_validator</string> </key> <key> <string>external_validator</string> </key>
...@@ -234,16 +234,24 @@ ...@@ -234,16 +234,24 @@
<value> <int>0</int> </value> <value> <int>0</int> </value>
</item> </item>
<item> <item>
<key> <string>required</string> </key> <key> <string>max_length</string> </key>
<value> <int>0</int> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>start</string> </key> <key> <string>required</string> </key>
<value> <string></string> </value> <value> <int>1</int> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Quantity</string> </value> <value> <string>Cardholder Name</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>
<item> <item>
<key> <string>whitespace_preserve</string> </key> <key> <string>whitespace_preserve</string> </key>
......
...@@ -243,7 +243,7 @@ ...@@ -243,7 +243,7 @@
</item> </item>
<item> <item>
<key> <string>required</string> </key> <key> <string>required</string> </key>
<value> <int>0</int> </value> <value> <int>1</int> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
......
...@@ -68,12 +68,7 @@ ...@@ -68,12 +68,7 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>from Products.ERP5Type.Document import newTempOrder\n <value> <string>return value\n
request = context.REQUEST\n
session_id = request.get(\'session_id\', None)\n
\n
order = newTempOrder(context.getPortalObject(), id = session_id, title = \'order\')\n
return order\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
...@@ -90,7 +85,15 @@ return order\n ...@@ -90,7 +85,15 @@ return order\n
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string></string> </value> <value> <string>value</string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -110,20 +113,13 @@ return order\n ...@@ -110,20 +113,13 @@ return order\n
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>0</int> </value> <value> <int>1</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
<value> <value>
<tuple> <tuple>
<string>Products.ERP5Type.Document</string> <string>value</string>
<string>newTempOrder</string>
<string>_getattr_</string>
<string>context</string>
<string>request</string>
<string>None</string>
<string>session_id</string>
<string>order</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -48,12 +48,14 @@ ...@@ -48,12 +48,14 @@
<key> <string>_text</string> </key> <key> <string>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
<div>\n
<tal:block tal:define="shopping_cart_items here/ERP5Ecommerce_getShoppingCartItemList;\n <tal:block tal:define="shopping_cart_items here/ERP5Ecommerce_getShoppingCartItemList;\n
empty_cart python: len(shopping_cart_items)==0;\n empty_cart python: len(shopping_cart_items)==0;\n
website here/getWebSiteValue;">\n website here/getWebSiteValue;\n
\n confirm_mode python: bool(options.get(\'confirm_mode\', False))">\n
<p tal:condition = "empty_cart"> Your shopping cart is empty. </p>\n \n
<tal:block tal:condition = "empty_cart"> \n
<h3>Your shopping cart is empty.</h3>\n
</tal:block>\n
\n \n
<form action="" tal:condition = "not: empty_cart">\n <form action="" tal:condition = "not: empty_cart">\n
<table>\n <table>\n
...@@ -64,16 +66,17 @@ ...@@ -64,16 +66,17 @@
</thead>\n </thead>\n
<tbody> \n <tbody> \n
<tal:block tal:repeat="order_line shopping_cart_items">\n <tal:block tal:repeat="order_line shopping_cart_items">\n
<tr tal:define="resource python: website.restrictedTraverse(order_line.getResource());\n <tr tal:define="resource python: website.restrictedTraverse(order_line[\'resource\']);\n
quantity python: int(order_line.getTotalQuantity());\n quantity python: int(order_line[\'quantity\']);\n
price python: resource.getPrice();\n price python: resource.getPrice();\n
order_line_id order_line/getId;\n order_line_id python: shopping_cart_items.index(order_line);\n
global currency python: here.restrictedTraverse(resource.getSupplyLinePriceCurrency()).getTitle()"> \n global currency python: here.restrictedTraverse(resource.getSupplyLinePriceCurrency()).getTitle()"> \n
<td>\n <td>\n
<a href="" tal:attributes="href resource/absolute_url">\n <a href="" tal:attributes="href resource/absolute_url">\n
<b tal:content="order_line/getTitle"/> <br/>\n <b tal:content="resource/getTitle"/> <br/>\n
<a tal:attributes="href python: \'%s?field_my_order_line_id=%s\' \n <a tal:condition="not: confirm_mode"\n
%(website.SaleOrder_deleteShoppingCartItem.absolute_url(), \n tal:attributes="href python: \'%s?field_my_order_line_id=%s\' \n
%(website.ERP5Ecommerce_deleteShoppingCartItem.absolute_url(), \n
order_line_id)"> \n order_line_id)"> \n
Delete \n Delete \n
</a>\n </a>\n
...@@ -83,36 +86,27 @@ ...@@ -83,36 +86,27 @@
<span tal:replace="price"/> <span tal:replace="currency"/>\n <span tal:replace="price"/> <span tal:replace="currency"/>\n
</td>\n </td>\n
<td>\n <td>\n
<input type="input" \n <input tal:condition="not: confirm_mode"\n
type="input" \n
name="field_my_buy_quantity"\n name="field_my_buy_quantity"\n
size="2"\n size="2"\n
tal:attributes ="value quantity"/>\n tal:attributes ="value quantity"/>\n
<span tal:condition="confirm_mode" tal:content="quantity"/>\n
</td>\n </td>\n
</tr>\n </tr>\n
</tal:block>\n </tal:block>\n
<tr>\n
<td></td>\n
<td></td>\n
<td>\n
<br/>\n
<input type="submit" name="SaleOrder_update:method" value="Update"/>\n
</td>\n
</tbody>\n </tbody>\n
</table>\n </table>\n
</form>\n </form>\n
\n \n
<tal:block tal:condition = "not: empty_cart">\n <tal:block tal:condition = "not: empty_cart">\n
<br/><br/>\n <br/>\n
<b>Total price: <span tal:replace="python: here.ERP5Ecommerce_getTotalPriceForShoppingCart()"/> \n <b>Total price: <span tal:replace="python: here.ERP5Ecommerce_getTotalPriceForShoppingCart()"/> \n
<span tal:replace="currency"/>\n <span tal:replace="currency"/>\n
</b> <br/>\n </b> \n
<form action="">\n <br/>\n
<input type="submit" value="Proceed to checkout" name="SaleOrder_confirmShopping:method">\n
</form> \n
\n
</tal:block>\n </tal:block>\n
</tal:block>\n </tal:block>
</div>
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -130,7 +124,7 @@ ...@@ -130,7 +124,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Render custom cart content</string> </value> <value> <string>Soppingcart content widget</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -48,21 +48,18 @@ ...@@ -48,21 +48,18 @@
<key> <string>_text</string> </key> <key> <string>_text</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
<div>\n
<tal:block tal:define="shopping_cart_items here/ERP5Ecommerce_getShoppingCartItemList;\n <tal:block tal:define="shopping_cart_items here/ERP5Ecommerce_getShoppingCartItemList;\n
empty_cart python: len(shopping_cart_items)==0;\n empty_cart python: len(shopping_cart_items)==0;\n
website here/getWebSiteValue;">\n website here/getWebSiteValue;">\n
\n
<legend>My shopping cart</legend>\n
\n \n
<ul tal:repeat="order_line shopping_cart_items">\n <ul tal:repeat="order_line shopping_cart_items">\n
<li tal:define="resource python: website.restrictedTraverse(order_line.getResource());\n <li tal:define="resource python: website.restrictedTraverse(order_line[\'resource\']);\n
quantity python: int(order_line.getTotalQuantity());\n quantity python: int(order_line[\'quantity\']);\n
price python: resource.getPrice();\n price python: resource.getPrice();\n
global currency python: here.restrictedTraverse(resource.getSupplyLinePriceCurrency()).getTitle()"> \n global currency python: here.restrictedTraverse(resource.getSupplyLinePriceCurrency()).getTitle()"> \n
\n \n
<a href="" tal:attributes="href resource/absolute_url">\n <a href="" tal:attributes="href resource/absolute_url">\n
<b tal:content="order_line/getTitle"/> \n <b tal:content="resource/getTitle"/> \n
</a>\n </a>\n
<br/>\n <br/>\n
Price: <span tal:replace="price"/> <span tal:replace="currency"/>\n Price: <span tal:replace="price"/> <span tal:replace="currency"/>\n
...@@ -75,15 +72,12 @@ ...@@ -75,15 +72,12 @@
<br/>\n <br/>\n
<b>Total price: <span tal:replace="python: here.ERP5Ecommerce_getTotalPriceForShoppingCart()"/> \n <b>Total price: <span tal:replace="python: here.ERP5Ecommerce_getTotalPriceForShoppingCart()"/> \n
<span tal:replace="currency"/>\n <span tal:replace="currency"/>\n
</b>\n </b><br/>\n
\n <a href="SaleOrder_viewAsWeb?editable_mode=1">Edit Shopping Cart</a><br/>\n
<input type="submit" value="View Shopping Cart" name="SaleOrder_viewAsWeb:method"/>\n <a href="SaleOrder_confirmShopping?editable_mode=1">Proceed to checkout</a>\n
\n
<input type="submit" value="Proceed to checkout" name="SaleOrder_confirmShopping:method"/>\n
\n
</tal:block>\n </tal:block>\n
</tal:block>\n \n
</div> </tal:block>
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -101,7 +95,7 @@ ...@@ -101,7 +95,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Render cart portlet</string> </value> <value> <string>Mini shopping cart widget</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -65,7 +65,6 @@ ...@@ -65,7 +65,6 @@
<string>right</string> <string>right</string>
<string>center</string> <string>center</string>
<string>bottom</string> <string>bottom</string>
<string>hidden</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -85,29 +84,11 @@ ...@@ -85,29 +84,11 @@
<list/> <list/>
</value> </value>
</item> </item>
<item>
<key> <string>hidden</string> </key>
<value>
<list/>
</value>
</item>
<item> <item>
<key> <string>left</string> </key> <key> <string>left</string> </key>
<value> <value>
<list> <list>
<string>Title</string> <string>my_thankyou</string>
<string>first_name</string>
<string>last_name</string>
<string>email</string>
<string>telephone</string>
<string>fax</string>
<string>address</string>
<string>zip</string>
<string>city</string>
<string>country</string>
<string>password</string>
<string>repeat_password</string>
<string>submit_register</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -122,7 +103,7 @@ ...@@ -122,7 +103,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>ERP5Ecommerce_newCustomerForm</string> </value> <value> <string>ERP5Ecommerce_thankyou</string> </value>
</item> </item>
<item> <item>
<key> <string>method</string> </key> <key> <string>method</string> </key>
...@@ -130,7 +111,7 @@ ...@@ -130,7 +111,7 @@
</item> </item>
<item> <item>
<key> <string>name</string> </key> <key> <string>name</string> </key>
<value> <string>newCustomerForm</string> </value> <value> <string>Product_view</string> </value>
</item> </item>
<item> <item>
<key> <string>pt</string> </key> <key> <string>pt</string> </key>
...@@ -146,7 +127,7 @@ ...@@ -146,7 +127,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Register New Customer</string> </value> <value> <string>Thank you</string> </value>
</item> </item>
<item> <item>
<key> <string>unicode_mode</string> </key> <key> <string>unicode_mode</string> </key>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.Formulator.StandardFields</string>
<string>LabelField</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>my_thankyou</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary/>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<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>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</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>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<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>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</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>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value> <string encoding="cdata"><![CDATA[
<h3>Thank you for using our online shop! Your order will be processed now.</h3>
]]></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </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>title</string> </key>
<value> <string>Thank you</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -206,11 +206,10 @@ ...@@ -206,11 +206,10 @@
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
request = context.REQUEST\n translateString = context.Base_translateString\n
website = context.getWebSiteValue()\n
\n
shopping_cart_items = context.ERP5Ecommerce_getShoppingCartItemList()\n shopping_cart_items = context.ERP5Ecommerce_getShoppingCartItemList()\n
quantity = request.get(\'field_my_buy_quantity\', None)\n shopping_cart = shopping_cart_items\n
quantity = field_my_buy_quantity \n
\n \n
## when we have one item in shoppping cart we get \n ## when we have one item in shoppping cart we get \n
## quantity as a string rather as a list\n ## quantity as a string rather as a list\n
...@@ -221,15 +220,19 @@ counter = 0\n ...@@ -221,15 +220,19 @@ counter = 0\n
for order_line in shopping_cart_items:\n for order_line in shopping_cart_items:\n
new_quantity = int(quantity[counter])\n new_quantity = int(quantity[counter])\n
if new_quantity>=1:\n if new_quantity>=1:\n
order_line.setQuantity(new_quantity)\n order_line[\'quantity\'] = new_quantity\n
else:\n else:\n
## remove it from shopping cart\n ## remove it from shopping cart\n
shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n del shopping_cart_items[counter]\n
shopping_cart.manage_delObjects(order_line.getId())\n
counter += 1\n counter += 1\n
\n \n
redirect_url = website.SaleOrder_viewAsWeb.absolute_url()\n ## update back cache so we have consistent results between cache plugins\n
request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart content was updated.\')\n context.ERP5Ecommerce_getShoppingCart(action=\'update\', \\\n
new_shopping_cart = shopping_cart)\n
\n
context.Base_redirect(\'SaleOrder_viewAsWeb\', \\\n
editable_mode=True, \\\n
keep_items={\'portal_status_message\': translateString("Your cart content updated.", mapping = dict())})\n
]]></string> </value> ]]></string> </value>
...@@ -248,7 +251,7 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont ...@@ -248,7 +251,7 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string></string> </value> <value> <string>field_my_buy_quantity=None</string> </value>
</item> </item>
<item> <item>
<key> <string>_proxy_roles</string> </key> <key> <string>_proxy_roles</string> </key>
...@@ -277,18 +280,18 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont ...@@ -277,18 +280,18 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>0</int> </value> <value> <int>1</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
<value> <value>
<tuple> <tuple>
<string>field_my_buy_quantity</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>request</string> <string>translateString</string>
<string>website</string>
<string>shopping_cart_items</string> <string>shopping_cart_items</string>
<string>None</string> <string>shopping_cart</string>
<string>quantity</string> <string>quantity</string>
<string>isinstance</string> <string>isinstance</string>
<string>str</string> <string>str</string>
...@@ -298,8 +301,9 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont ...@@ -298,8 +301,9 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont
<string>int</string> <string>int</string>
<string>_getitem_</string> <string>_getitem_</string>
<string>new_quantity</string> <string>new_quantity</string>
<string>shopping_cart</string> <string>_write_</string>
<string>redirect_url</string> <string>True</string>
<string>dict</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -311,16 +315,18 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont ...@@ -311,16 +315,18 @@ request.RESPONSE.redirect(redirect_url + \'?portal_status_message=Your cart cont
<item> <item>
<key> <string>func_defaults</string> </key> <key> <string>func_defaults</string> </key>
<value> <value>
<tuple>
<none/> <none/>
</tuple>
</value> </value>
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>SaleOrder_update</string> </value> <value> <string>ERP5Ecommerce_updateShoppingCart</string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Update Sale Order</string> </value> <value> <string>Update shopping cart</string> </value>
</item> </item>
<item> <item>
<key> <string>warnings</string> </key> <key> <string>warnings</string> </key>
......
...@@ -90,8 +90,8 @@ ...@@ -90,8 +90,8 @@
<list> <list>
<string>my_title</string> <string>my_title</string>
<string>my_description</string> <string>my_description</string>
<string>my_price</string>
<string>my_buy_button</string> <string>my_buy_button</string>
<string>my_buy_quantity</string>
</list> </list>
</value> </value>
</item> </item>
......
...@@ -204,41 +204,21 @@ ...@@ -204,41 +204,21 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string>request = context.REQUEST\n
isAnon = context.portal_membership.isAnonymousUser()\n
user_id = context.portal_membership.getAuthenticatedMember().getId()\n translateString = context.Base_translateString\n
request = context.REQUEST\n
website = context.getWebSiteValue()\n
\n \n
## determine customer if not such create an account\n if isAnon:\n
if context.portal_membership.isAnonymousUser():\n ## create first an account for user\n
redirect_url = website.ERP5Ecommerce_newCustomerAccountForm.absolute_url()\n context.Base_redirect(\'ERP5Ecommerce_newCustomerAccountForm\', \\\n
request.RESPONSE.redirect(redirect_url + \'?editable_mode=1&portal_status_message=You need to create an account.\')\n editable_mode=True, \\\n
keep_items={\'portal_status_message\': translateString("You need to create an account. If you already have please use it to login.", mapping = dict())})\n
return\n return\n
\n else:\n
#context.debug(context.portal_membership.isAnonymousUser())\n ## redirect to final confirmation form\n
\n context.Base_redirect(\'SaleOrder_viewAsWebConfirm\',\n
shopping_cart = context.ERP5Ecommerce_getShoppingCart()\n editable_mode=True)\n
\n </string> </value>
sale_order = context.ERP5Ecommerce_createSaleOrderFromShoppingCart(shopping_cart)\n
context.debug("aaaaaaaaaaaaaaaa")\n
\n
## clean up shopping cart\n
context.ERP5Ecommerce_getShoppingCart(reset=True)\n
\n
return \n
\n
## set as sale order owner\n
shopping_cart_persistent.setDestination("person_module/"+user_id_number)\n
\n
\n
## redirect\n
redirect_url=context.REQUEST[\'HTTP_REFERER\']\n
redirect_url=redirect_url[:redirect_url.index("/portal_sessions/shoppingcart")]+"/thank-you"\n
context.REQUEST.RESPONSE.redirect(redirect_url)\n
]]></string> </value>
</item> </item>
<item> <item>
<key> <string>_code</string> </key> <key> <string>_code</string> </key>
...@@ -291,16 +271,11 @@ context.REQUEST.RESPONSE.redirect(redirect_url)\n ...@@ -291,16 +271,11 @@ context.REQUEST.RESPONSE.redirect(redirect_url)\n
<tuple> <tuple>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>user_id</string>
<string>request</string> <string>request</string>
<string>website</string> <string>isAnon</string>
<string>redirect_url</string> <string>translateString</string>
<string>shopping_cart</string>
<string>sale_order</string>
<string>True</string> <string>True</string>
<string>shopping_cart_persistent</string> <string>dict</string>
<string>user_id_number</string>
<string>_getitem_</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -89,7 +89,7 @@ ...@@ -89,7 +89,7 @@
<value> <value>
<list> <list>
<string>shopping_cart</string> <string>shopping_cart</string>
<string>shopping_item_list</string> <string>submit</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -128,7 +128,7 @@ ...@@ -128,7 +128,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Shopping cart details</string> </value> <value> <string>Edit shopping cart</string> </value>
</item> </item>
<item> <item>
<key> <string>unicode_mode</string> </key> <key> <string>unicode_mode</string> </key>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.ERP5Form.InputButtonField</string>
<string>InputButtonField</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>submit</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<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>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</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>name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</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> <string></string> </value>
</item>
<item>
<key> <string>description</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>extra</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</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>hiddenLabel</string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value> <string>Update</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </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>name</string> </key>
<value> <string>ERP5Ecommerce_updateShoppingCart:method</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Submit</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
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