summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xintegration-tests/test-ebics.py6
-rw-r--r--sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt9
-rw-r--r--sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt4
3 files changed, 9 insertions, 10 deletions
diff --git a/integration-tests/test-ebics.py b/integration-tests/test-ebics.py
index cc960ccb..d6d72ec6 100755
--- a/integration-tests/test-ebics.py
+++ b/integration-tests/test-ebics.py
@@ -120,7 +120,7 @@ for i in range(10):
#0.a
assertResponse(
post(
- "http://localhost:5000/admin/ebics-host",
+ "http://localhost:5000/admin/ebics/host",
json=dict(
hostID=HOST_ID,
ebicsVersion=EBICS_VERSION
@@ -131,7 +131,7 @@ assertResponse(
#0.b
assertResponse(
post(
- "http://localhost:5000/admin/ebics-subscriber",
+ "http://localhost:5000/admin/ebics/subscribers",
json=dict(
hostID=HOST_ID,
partnerID=PARTNER_ID,
@@ -143,7 +143,7 @@ assertResponse(
#0.c
assertResponse(
post(
- "http://localhost:5000/admin/ebics-subscriber/bank-account",
+ "http://localhost:5000/admin/ebics/bank-accounts",
json=dict(
subscriber=dict(
hostID=HOST_ID,
diff --git a/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt b/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt
index bde80cd9..eadde89a 100644
--- a/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt
+++ b/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt
@@ -201,7 +201,6 @@ fun buildCamtString(type: Int, history: MutableList<RawPayment>): MutableList<St
element("CreDtTm") {
text(zonedDateTime)
}
-
element("Acct") {
// mandatory account identifier
element("Id/IBAN") {
@@ -408,14 +407,16 @@ private fun constructCamtResponse(
val dateRange = (header.static.orderDetails?.orderParams as EbicsRequest.StandardOrderParams).dateRange
val (start: DateTime, end: DateTime) = if (dateRange != null) {
Pair(DateTime(dateRange.start.toGregorianCalendar().time), DateTime(dateRange.end.toGregorianCalendar().time))
- } else Pair(DateTime(0), DateTime.now())
+ } else Pair(parseDashedDate("1970-01-01"), DateTime.now())
val history = mutableListOf<RawPayment>()
val bankAccount = getBankAccountFromSubscriber(subscriber)
transaction {
PaymentEntity.find {
PaymentsTable.creditorIban eq bankAccount.iban or
- (PaymentsTable.debitorIban eq bankAccount.iban) and
- (PaymentsTable.date.between(start.millis, end.millis))
+ (PaymentsTable.debitorIban eq bankAccount.iban) /**
+ FIXME!
+ and (PaymentsTable.date.between(start.millis, end.millis))
+ */
}.forEach {
history.add(
RawPayment(
diff --git a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
index 35e59286..e435d8ce 100644
--- a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
+++ b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
@@ -181,9 +181,7 @@ fun main() {
label = body.label
}
}
- call.respondText(
- "Bank account created, and associated to the subscriber"
- )
+ call.respondText("Bank account created")
return@post
}
/**