Commit f9f53031 authored by Vincent Desmares's avatar Vincent Desmares

# vincentd

Allow alternative url for testing purpose

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@28180 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 65b9e097
......@@ -60,7 +60,7 @@ security_parameter_dict[\'TOKEN\'] = token\n
security_parameter_dict[\'METHOD\'] = \'GetExpressCheckoutDetails\'\n
\n
response_parameter_dict = context.ERP5Base_submitPaypalNVPRequest(parameter_dict=security_parameter_dict,\n
nvp_url=context.WebSite_getPaypalUrl(api=\'nvp\'))\n
nvp_url=context.WebSite_getPaypalUrl(api=\'nvp\', alternative_url=alternative_url))\n
return response_parameter_dict\n
</string> </value>
</item>
......@@ -72,7 +72,7 @@ return response_parameter_dict\n
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>token</string> </value>
<value> <string>token, alternative_url=None</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
......@@ -92,13 +92,14 @@ return response_parameter_dict\n
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>1</int> </value>
<value> <int>2</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>token</string>
<string>alternative_url</string>
<string>_getattr_</string>
<string>context</string>
<string>security_parameter_dict</string>
......@@ -116,7 +117,9 @@ return response_parameter_dict\n
<item>
<key> <string>func_defaults</string> </key>
<value>
<none/>
<tuple>
<none/>
</tuple>
</value>
</item>
<item>
......
......@@ -54,7 +54,7 @@
<item>
<key> <string>_body</string> </key>
<value> <string>response_parameter_dict = context.ERP5Base_submitPaypalNVPRequest(parameter_dict=context.WebSite_getPaypalOrderParameterDict(),\n
nvp_url=context.WebSite_getPaypalUrl(api=\'nvp\'))\n
nvp_url=context.WebSite_getPaypalUrl(api=\'nvp\', alternative_url=alternative_url))\n
\n
if response_parameter_dict is None:\n
return None\n
......@@ -72,7 +72,7 @@ return \'\'\n
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
<value> <string>alternative_url=None</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
......@@ -92,12 +92,13 @@ return \'\'\n
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>0</int> </value>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>alternative_url</string>
<string>_getattr_</string>
<string>context</string>
<string>response_parameter_dict</string>
......@@ -114,7 +115,9 @@ return \'\'\n
<item>
<key> <string>func_defaults</string> </key>
<value>
<none/>
<tuple>
<none/>
</tuple>
</value>
</item>
<item>
......
......@@ -53,7 +53,10 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>test_environement = context.getLayoutProperty(\'ecommerce_test_environment_enabled\', None)\n
<value> <string>if alternative_url is not None:\n
return alternative_url\n
\n
test_environement = context.getLayoutProperty(\'ecommerce_test_environment_enabled\', None)\n
\n
if test_environement is not None and test_environement == 1:\n
if api == \'nvp\':\n
......@@ -73,7 +76,7 @@ return \'https://www.paypal.com/cgi-bin/webscr\'\n
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>api=None</string> </value>
<value> <string>api=None, alternative_url=None</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
......@@ -93,16 +96,17 @@ return \'https://www.paypal.com/cgi-bin/webscr\'\n
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>1</int> </value>
<value> <int>2</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>api</string>
<string>alternative_url</string>
<string>None</string>
<string>_getattr_</string>
<string>context</string>
<string>None</string>
<string>test_environement</string>
</tuple>
</value>
......@@ -117,6 +121,7 @@ return \'https://www.paypal.com/cgi-bin/webscr\'\n
<value>
<tuple>
<none/>
<none/>
</tuple>
</value>
</item>
......
140
\ No newline at end of file
142
\ 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