[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libeufin] branch master updated: more details in response
From: |
gnunet |
Subject: |
[libeufin] branch master updated: more details in response |
Date: |
Wed, 08 Jul 2020 12:25:01 +0200 |
This is an automated email from the git hooks/post-receive script.
ms pushed a commit to branch master
in repository libeufin.
The following commit(s) were added to refs/heads/master by this push:
new d642a0c more details in response
d642a0c is described below
commit d642a0c618ba8e3c82413b224e931fcc81a2adc1
Author: MS <ms@taler.net>
AuthorDate: Wed Jul 8 12:24:57 2020 +0200
more details in response
---
.../main/kotlin/tech/libeufin/nexus/server/JSON.kt | 2 +-
.../kotlin/tech/libeufin/nexus/server/NexusServer.kt | 19 ++++++++++++++++++-
2 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/server/JSON.kt
b/nexus/src/main/kotlin/tech/libeufin/nexus/server/JSON.kt
index 7a74ef6..76219cd 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/server/JSON.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/server/JSON.kt
@@ -400,5 +400,5 @@ data class AccountEntryItemJson(
)
data class InitiatedPayments(
- val initiatedPayments: MutableList<String> = mutableListOf()
+ val initiatedPayments: MutableList<PaymentStatus> = mutableListOf()
)
diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt
b/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt
index 4267439..98d8e10 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt
@@ -483,7 +483,24 @@ fun serverMain(dbName: String, host: String) {
val bankAccount = requireBankAccount(call, "accountid")
PaymentInitiationEntity.find {
PaymentInitiationsTable.bankAccount eq
bankAccount.id.value
- }.forEach { ret.initiatedPayments.add(it.id.toString()) }
+ }.forEach {
+ val sd = it.submissionDate
+ ret.initiatedPayments.add(
+ PaymentStatus(
+ paymentInitiationId = it.id.value.toString(),
+ submitted = it.submitted,
+ creditorIban = it.creditorIban,
+ creditorName = it.creditorName,
+ creditorBic = it.creditorBic,
+ amount = "${it.currency}:${it.sum}",
+ subject = it.subject,
+ submissionDate = if (sd != null) {
+ importDateFromMillis(sd).toDashedDate()
+ } else null,
+ preparationDate =
importDateFromMillis(it.preparationDate).toDashedDate()
+ )
+ )
+ }
}
call.respond(ret)
return@get
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [libeufin] branch master updated: more details in response,
gnunet <=