summaryrefslogtreecommitdiff
path: root/src/frontend/generate_taler_contract.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/frontend/generate_taler_contract.php')
-rw-r--r--src/frontend/generate_taler_contract.php11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/frontend/generate_taler_contract.php b/src/frontend/generate_taler_contract.php
index c405e818..cd708ad3 100644
--- a/src/frontend/generate_taler_contract.php
+++ b/src/frontend/generate_taler_contract.php
@@ -15,7 +15,7 @@
TALER; see the file COPYING. If not, If not, see <http://www.gnu.org/licenses/>
*/
-include 'util.php';
+include '../frontend_lib/util.php';
session_start();
@@ -26,7 +26,6 @@ if (!isset($_SESSION['receiver']))
}
$receiver = $_SESSION['receiver'];
-$receiver = $_SESSION['receiver'];
$amount_value = intval($_SESSION['amount_value']);
$amount_fraction = intval($_SESSION['amount_fraction']);
$currency = $_SESSION['currency'];
@@ -143,7 +142,13 @@ if ($status_code != 200)
else
{
$got_json = json_decode($resp->body->toString(), true);
- $_SESSION['H_contract'] = $got_json["H_contract"];
+ $hc = $got_json["H_contract"];
+ $payments = get($_SESSION['payments'], array());
+ $payments[$hc] = array(
+ 'receiver' => $receiver,
+ );
+ $_SESSION['payments'] = $payments;
+
echo json_encode ($got_json, JSON_PRETTY_PRINT);
}
?>