Commit 435dd9d1 authored by Xiaowu Zhang's avatar Xiaowu Zhang

erp5_advanced_ecommerce: return useless calls

parent 7a2c616e
...@@ -63,9 +63,7 @@ ...@@ -63,9 +63,7 @@
</item> </item>
<item> <item>
<key> <string>enabled</string> </key> <key> <string>enabled</string> </key>
<value> <value> <string></string> </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>
...@@ -149,17 +147,4 @@ ...@@ -149,17 +147,4 @@
</dictionary> </dictionary>
</pickle> </pickle>
</record> </record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: cell.Resource_getWebShopImageURL()</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData> </ZopeData>
...@@ -3,25 +3,31 @@ DRESSING DAILS<br />By TOM TAYLOR<br /> ...@@ -3,25 +3,31 @@ DRESSING DAILS<br />By TOM TAYLOR<br />
<span class="price">14,89 &euro;</span> <span class="price">14,89 &euro;</span>
<span class="old_price">29,95 &euro;</span> <span class="old_price">29,95 &euro;</span>
""" """
if not context.getWebSiteValue():
return
clean = 0 clean = 0
if context.REQUEST.get("variation", None) is None: if context.REQUEST.get("variation", None) is None:
context.REQUEST.set("variation", context.REQUEST.get("default_displayed_variation")) context.REQUEST.set("variation", context.REQUEST.get("default_displayed_variation"))
clean = 1 clean = 1
price = cell.Resource_getShopPrice() price = cell.Resource_getShopPrice()
old_price = cell.getDefaultSaleSupplyLineBasePrice() #old_price = cell.getDefaultSaleSupplyLineBasePrice()
currency = here.WebSite_getShoppingCartDefaultCurrencyCode() currency = here.WebSite_getShoppingCartDefaultCurrencyCode()
title = cell.getTitle() title = cell.getTitle()
if currency == 'EUR': if currency == 'EUR':
currency = '&euro;' currency = '&euro;'
elif currency == 'CNY':
currency = '¥'
output = """%s<br /><br />""" % (title.upper(),) output = """%s<br /><br />""" % (title.upper(),)
if old_price is not None and price != old_price: #if old_price is not None and price != old_price:
output += """<span class="new_price">%s %s</span>""" % (price, currency) # output += """<span class="new_price">%s %s</span>""" % (price, currency)
output += """<br /><span class="old_price">%s %s</span>""" % (old_price, currency) # output += """<br /><span class="old_price">%s %s</span>""" % (old_price, currency)
else: #else:
output += """<span class="price">%s %s</span>""" % (price, currency) # output += """<span class="price">%s %s</span>""" % (price, currency)
output += """<span class="price">%s %s</span>""" % (price, currency)
if clean: if clean:
context.REQUEST.set("variation", None) context.REQUEST.set("variation", None)
......
...@@ -11,7 +11,6 @@ ...@@ -11,7 +11,6 @@
<value> <value>
<list> <list>
<string>default</string> <string>default</string>
<string>enabled</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -59,12 +58,6 @@ ...@@ -59,12 +58,6 @@
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent> <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value> </value>
</item> </item>
<item>
<key> <string>enabled</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item> <item>
<key> <string>field_id</string> </key> <key> <string>field_id</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -88,10 +81,6 @@ ...@@ -88,10 +81,6 @@
<key> <string>default</string> </key> <key> <string>default</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item>
<key> <string>enabled</string> </key>
<value> <int>0</int> </value>
</item>
<item> <item>
<key> <string>field_id</string> </key> <key> <string>field_id</string> </key>
<value> <string>product_list_thumbnail</string> </value> <value> <string>product_list_thumbnail</string> </value>
...@@ -123,17 +112,4 @@ ...@@ -123,17 +112,4 @@
</dictionary> </dictionary>
</pickle> </pickle>
</record> </record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: cell.Resource_getWebShopImageURL()</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData> </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