[Erp5-report] r29617 - in /erp5/trunk/bt5/erp5_commerce: SkinTemplateItem/portal_skins/erp5...
nobody at svn.erp5.org
nobody at svn.erp5.org
Tue Oct 13 21:48:46 CEST 2009
Author: lucas
Date: Tue Oct 13 21:48:45 2009
New Revision: 29617
URL: http://svn.erp5.org?rev=29617&view=rev
Log:
* removed hard coded values.
Added:
erp5/trunk/bt5/erp5_commerce/bt/template_registered_skin_selection_list
Modified:
erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce/WebSection_checkoutProcedure.xml
erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/SaleOrder_viewPaypalForm.xml
erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/WebSite_viewStandardLoginWidgetRenderer.xml
erp5/trunk/bt5/erp5_commerce/bt/revision
Modified: erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce/WebSection_checkoutProcedure.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce/WebSection_checkoutProcedure.xml?rev=29617&r1=29616&r2=29617&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce/WebSection_checkoutProcedure.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce/WebSection_checkoutProcedure.xml [utf8] Tue Oct 13 21:48:45 2009
@@ -60,7 +60,8 @@
\n
if context.request.get(\'plop\', None) is not None:\n
context.REQUEST.set(\'step\', 2)\n
- return context.getWebSectionValue().restrictedTraverse(\'person_module/1\').Person_viewAsWeb(context.REQUEST)\n
+ person_object = context.getWebSiteValue().SaleOrder_getShoppingCartCustomer()\n
+ return context.getWebSectionValue().restrictedTraverse(person_object.getRelativeUrl()).Person_viewAsWeb(context.REQUEST)\n
</string> </value>
</item>
<item>
@@ -101,6 +102,7 @@
<string>context</string>
<string>None</string>
<string>step</string>
+ <string>person_object</string>
</tuple>
</value>
</item>
Modified: erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/SaleOrder_viewPaypalForm.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/SaleOrder_viewPaypalForm.xml?rev=29617&r1=29616&r2=29617&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/SaleOrder_viewPaypalForm.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/SaleOrder_viewPaypalForm.xml [utf8] Tue Oct 13 21:48:45 2009
@@ -41,16 +41,19 @@
<tal:block tal:define="shopping_cart here/SaleOrder_getShoppingCart;\n
shopping_cart_item_list shopping_cart/SaleOrder_getShoppingCartItemList;\n
+ web_site here/getWebSiteValue;\n
+ currency_code web_site/WebSite_getShoppingCartDefaultCurrencyCode;\n
+ customer here/SaleOrder_getShoppingCartCustomer;\n
+ applicable_tax python: customer.Person_getApplicableTaxList().get(\'VAT\');\n
shopping_cart_price python: float(shopping_cart.SaleOrder_getShoppingCartTotalPrice());\n
taxes_amount python: float(shopping_cart.SaleOrder_getShoppingCartTotalPrice(include_taxes=True, include_shipping=True)) -\n
float(shopping_cart.SaleOrder_getShoppingCartTotalPrice(include_shipping=True));\n
shipping here/SaleOrder_getSelectedShippingResource;\n
shipping_price python: here.restrictedTraverse(shipping).getPrice();\n
- customer here/SaleOrder_getShoppingCartCustomer;\n
paypal_method python: \'_express-checkout\';\n
test_env python: True;\n
test_base_url python: \'http://www.dentra.net:9080/erp5\';\n
- base_url python:here.getWebSiteValue().absolute_url();\n
+ base_url python: here.getWebSiteValue().absolute_url();\n
action python: test_env and \'https://www.sandbox.paypal.com/cgi-bin/webscr\'\n
or \'https://www.paypal.com/cgi-bin/webscr\';\n
TPE python: options.get(\'TPE\', \'my_merchant_key_location\');\n
@@ -60,7 +63,7 @@
<tal:block tal:condition="python: paypal_method == \'_express-checkout\'">\n
<tal:block tal:define="token python: here.WebSection_getNewPaypalToken()">\n
<a tal:condition="python: token is not None and token != \'\'"\n
- tal:attributes="href python: \'%s?cmd=_express-checkout&token=%s&AMT=70.0&CURRENCYCODE=EUR\' % (action, token)">\n
+ tal:attributes="href python: \'%s?cmd=_express-checkout&token=%s&AMT=70.0&CURRENCYCODE=%s\' % (action, token, currency_code)">\n
<img src="https://www.paypal.com/en_US/i/btn/btn_xpressCheckout.gif" alt="PayPal - The safer, easier way to pay online!" style="border:none;">\n
</a>\n
<span tal:condition="python: token is None or token == \'\'" tal:content="python: here.Base_translateString(\'Paypal is not available actually.\')"></span>\n
@@ -81,7 +84,7 @@
\n
<tal:block tal:condition="python: paypal_method == \'_cart\'" tal:repeat="item shopping_cart_item_list">\n
<input type="hidden" name="cmd" value="_cart">\n
- <input type="hidden" name="tax_cart" value="20">\n
+ <input type="hidden" name="tax_cart" tal:attributes="value applicable_tax">\n
<tal:block tal:define="resource python: here.restrictedTraverse(item.getResource());\n
quantity python: int(item.getQuantity());\n
price python: resource.getPrice();">\n
@@ -113,7 +116,7 @@
<input type="hidden" name="night_phone_b" tal:attributes="value customer/getDefaultTelephoneText">\n
\n
<input type="hidden" name="shipping" tal:attributes="value shipping_price">\n
- <input type="hidden" name="currency_code" value="EUR">\n
+ <input type="hidden" name="currency_code" tal:attributes="value currency_code">\n
<input type="hidden" name="button_subtype" value="products">\n
<input type="hidden" name="display" value="1">\n
<input type="hidden" name="upload" value="1">\n
Modified: erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/WebSite_viewStandardLoginWidgetRenderer.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/WebSite_viewStandardLoginWidgetRenderer.xml?rev=29617&r1=29616&r2=29617&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/WebSite_viewStandardLoginWidgetRenderer.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_commerce/SkinTemplateItem/portal_skins/erp5_commerce_widget_library/WebSite_viewStandardLoginWidgetRenderer.xml [utf8] Tue Oct 13 21:48:45 2009
@@ -78,7 +78,7 @@
<span><span tal:replace="python: here.Base_translateString(\'You are logged as\')"/> <span tal:replace="customer/getTitle"/></span>\n
</p>\n
<a class="articlelink" \n
- tal:attributes="href python: \'%s/SaleOrderModule_viewAsWebSaleOrderList\' % website.sale_order_module.absolute_url()">\n
+ tal:attributes="href python: \'%s/sale_order_module/SaleOrderModule_viewAsWebSaleOrderList\' % website.absolute_url()">\n
<span tal:replace="python: here.Base_translateString(\'My Orders\')"/>\n
</a> \n
<a class="articlelink" \n
Modified: erp5/trunk/bt5/erp5_commerce/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_commerce/bt/revision?rev=29617&r1=29616&r2=29617&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_commerce/bt/revision [utf8] (original)
+++ erp5/trunk/bt5/erp5_commerce/bt/revision [utf8] Tue Oct 13 21:48:45 2009
@@ -1,1 +1,1 @@
-238
+240
Added: erp5/trunk/bt5/erp5_commerce/bt/template_registered_skin_selection_list
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_commerce/bt/template_registered_skin_selection_list?rev=29617&view=auto
==============================================================================
(empty)
More information about the Erp5-report
mailing list