commit f3123fb68b973292a1e0d196367951d9128bdabf
parent 722f2c9e2a8867935e7dde9e6c8635734599683a
Author: Florian Dold <florian.dold@gmail.com>
Date: Wed, 22 Jul 2020 20:25:11 +0530
include execution_time in refund response
Diffstat:
1 file changed, 11 insertions(+), 6 deletions(-)
diff --git a/src/backend/taler-merchant-httpd_get-orders-ID.c b/src/backend/taler-merchant-httpd_get-orders-ID.c
@@ -997,7 +997,7 @@ TMH_get_orders_ID (const struct TMH_RequestHandler *rh,
{
if (NULL == cr->exchange_reply)
{
- refund = json_pack ("{s:b, s:I,s:I,s:o,s:o}"
+ refund = json_pack ("{s:b, s:I,s:I,s:o,s:o,s:o}"
"success",
false,
"exchange_status",
@@ -1007,11 +1007,13 @@ TMH_get_orders_ID (const struct TMH_RequestHandler *rh,
"coin_pub",
GNUNET_JSON_from_data_auto (&cr->coin_pub),
"refund_amount",
- TALER_JSON_from_amount (&cr->refund_amount));
+ TALER_JSON_from_amount (&cr->refund_amount),
+ "execution_time",
+ GNUNET_JSON_from_time_abs (cr->execution_time));
}
else
{
- refund = json_pack ("{s:b,s:I,s:I,s:o,s:I,s:o,s:o}"
+ refund = json_pack ("{s:b,s:I,s:I,s:o,s:I,s:o,s:o,s:o}"
"success",
true,
"exchange_status",
@@ -1025,12 +1027,14 @@ TMH_get_orders_ID (const struct TMH_RequestHandler *rh,
"coin_pub",
GNUNET_JSON_from_data_auto (&cr->coin_pub),
"refund_amount",
- TALER_JSON_from_amount (&cr->refund_amount));
+ TALER_JSON_from_amount (&cr->refund_amount),
+ "execution_time",
+ GNUNET_JSON_from_time_abs (cr->execution_time));
}
}
else
{
- refund = json_pack ("{s:b,s:I,s:o,s:o,s:I,s:o,s:o}",
+ refund = json_pack ("{s:b,s:I,s:o,s:o,s:I,s:o,s:o,s:o}",
"success",
false,
"exchange_status",
@@ -1045,7 +1049,8 @@ TMH_get_orders_ID (const struct TMH_RequestHandler *rh,
GNUNET_JSON_from_data_auto (&cr->coin_pub),
"refund_amount",
TALER_JSON_from_amount (&cr->refund_amount),
- "exchange_http_status");
+ "execution_time",
+ GNUNET_JSON_from_time_abs (cr->execution_time));
}
GNUNET_assert (
0 ==