Commit 3f523e98 authored by Rafael Monnerat's avatar Rafael Monnerat

slapos_accounting&jio: Scripts moved to slapos_accounting

parent 4b42a061
...@@ -2,15 +2,18 @@ ...@@ -2,15 +2,18 @@
if web_site is None: if web_site is None:
web_site = context.getWebSiteValue() web_site = context.getWebSiteValue()
if web_site is None:
raise ValueError("This script must be called from a web site")
base_url = web_site.absolute_url() base_url = web_site.absolute_url()
payment_transaction_url = context.getRelativeUrl() payment_transaction_url = context.getRelativeUrl()
base = web_site.getLayoutProperty("configuration_payment_url_template", base = web_site.getLayoutProperty("configuration_payment_url_template",
"%(url)s/#/%(payment)s?page=slap_payment_result&result=%(result)s") "%(url)s/#/%(payment_transaction_url)s?page=slap_payment_result&result=%(result)s")
base_substitution_dict = { base_substitution_dict = {
"url" : base_url, "url" : base_url,
"payment": payment_transaction_url, "payment_transaction_url": payment_transaction_url,
"result": "__RESULT__" "result": "__RESULT__"
} }
......
...@@ -10,11 +10,11 @@ base_url = web_site.absolute_url() ...@@ -10,11 +10,11 @@ base_url = web_site.absolute_url()
payment_transaction_url = context.getRelativeUrl() payment_transaction_url = context.getRelativeUrl()
base = web_site.getLayoutProperty("configuration_payment_url_template", base = web_site.getLayoutProperty("configuration_payment_url_template",
"%(url)s/#/%(payment)s?page=slap_payment_result&result=%(result)s") "%(url)s/#/%(payment_transaction_url)s?page=slap_payment_result&result=%(result)s")
base_substitution_dict = { base_substitution_dict = {
"url" : base_url, "url" : base_url,
"payment": payment_transaction_url, "payment_transaction_url": payment_transaction_url,
"result": "free" "result": "free"
} }
......
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