commit da518381200aa4088f61ff607e0782c679be5480
parent 8d43dc4f7c475301b6961afb8dff657713ede24f
Author: Florian Dold <florian.dold@gmail.com>
Date: Mon, 1 Feb 2016 11:01:09 +0100
put contract restoration info in URL
Diffstat:
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/src/frontend/generate_taler_contract.php b/src/frontend/generate_taler_contract.php
@@ -51,9 +51,19 @@ $teatax = array('value' => 1,
// Take a timestamp
$now = new DateTime('now');
+
+// Include all information so we can
+// restore the contract without storing it
+$fulfillment_url = url_rel("fulfillment.php")
+ . '?uuid=${H_contract}'
+ . '&receiver=' . urlencode($receiver)
+ . '&aval=' . urlencode($amount_value)
+ . '&afrac=' . urlencode($amount_fraction)
+ . '&acurr=' . urlencode($currency);
+
// pack the JSON for the contract
$contract = array(
- 'fulfillment_url' => (url_rel("fulfillment.php") . '?uuid=${H_contract}'),
+ 'fulfillment_url' => fulfillment_url,
'amount' => array(
'value' => $amount_value,
'fraction' => $amount_fraction,