gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libeufin] branch master updated: Update all instances from PaymentsTabl


From: gnunet
Subject: [libeufin] branch master updated: Update all instances from PaymentsTable to BankAccountTransactionsTable
Date: Fri, 14 Aug 2020 11:11:16 +0200

This is an automated email from the git hooks/post-receive script.

heng-yeow pushed a commit to branch master
in repository libeufin.

The following commit(s) were added to refs/heads/master by this push:
     new b226e1f  Update all instances from PaymentsTable to 
BankAccountTransactionsTable
b226e1f is described below

commit b226e1f6da70b776ed9c90addf52408f6f683b50
Author: tanhengyeow <E0032242@u.nus.edu>
AuthorDate: Fri Aug 14 17:11:09 2020 +0800

    Update all instances from PaymentsTable to BankAccountTransactionsTable
---
 .../src/main/kotlin/tech/libeufin/sandbox/Main.kt  | 26 +++++++++++-----------
 sandbox/src/test/kotlin/DBTest.kt                  | 14 ++++++------
 2 files changed, 20 insertions(+), 20 deletions(-)

diff --git a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt 
b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
index b17d66d..7cf2d2c 100644
--- a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
+++ b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
@@ -62,16 +62,16 @@ import com.github.ajalt.clikt.core.subcommands
 import com.github.ajalt.clikt.parameters.options.default
 import com.github.ajalt.clikt.parameters.options.option
 import io.ktor.util.AttributeKey
-import tech.libeufin.sandbox.PaymentsTable
-import tech.libeufin.sandbox.PaymentsTable.amount
-import tech.libeufin.sandbox.PaymentsTable.creditorBic
-import tech.libeufin.sandbox.PaymentsTable.creditorIban
-import tech.libeufin.sandbox.PaymentsTable.creditorName
-import tech.libeufin.sandbox.PaymentsTable.currency
-import tech.libeufin.sandbox.PaymentsTable.date
-import tech.libeufin.sandbox.PaymentsTable.debitorBic
-import tech.libeufin.sandbox.PaymentsTable.debitorIban
-import tech.libeufin.sandbox.PaymentsTable.debitorName
+import tech.libeufin.sandbox.BankAccountTransactionsTable
+import tech.libeufin.sandbox.BankAccountTransactionsTable.amount
+import tech.libeufin.sandbox.BankAccountTransactionsTable.creditorBic
+import tech.libeufin.sandbox.BankAccountTransactionsTable.creditorIban
+import tech.libeufin.sandbox.BankAccountTransactionsTable.creditorName
+import tech.libeufin.sandbox.BankAccountTransactionsTable.currency
+import tech.libeufin.sandbox.BankAccountTransactionsTable.date
+import tech.libeufin.sandbox.BankAccountTransactionsTable.debitorBic
+import tech.libeufin.sandbox.BankAccountTransactionsTable.debitorIban
+import tech.libeufin.sandbox.BankAccountTransactionsTable.debitorName
 import tech.libeufin.util.*
 import tech.libeufin.util.ebics_h004.EbicsResponse
 import tech.libeufin.util.ebics_h004.EbicsTypes
@@ -236,12 +236,12 @@ fun serverMain(dbName: String) {
             get("/admin/payments") {
                 val ret = PaymentsResponse()
                 transaction {
-                    PaymentsTable.selectAll().forEach {
+                    BankAccountTransactionsTable.selectAll().forEach {
                         ret.payments.add(
                             RawPayment(
                                 creditorIban = it[creditorIban],
                                 debitorIban = it[debitorIban],
-                                subject = it[PaymentsTable.subject],
+                                subject = 
it[BankAccountTransactionsTable.subject],
                                 date = it[date].toHttpDateString(),
                                 amount = it[amount],
                                 creditorBic = it[creditorBic],
@@ -263,7 +263,7 @@ fun serverMain(dbName: String) {
             post("/admin/payments") {
                 val body = call.receive<RawPayment>()
                 transaction {
-                   PaymentsTable.insert {
+                   BankAccountTransactionsTable.insert {
                        it[creditorIban] = body.creditorIban
                        it[creditorBic] = body.creditorBic
                        it[creditorName] = body.creditorName
diff --git a/sandbox/src/test/kotlin/DBTest.kt 
b/sandbox/src/test/kotlin/DBTest.kt
index 2de42b6..0628660 100644
--- a/sandbox/src/test/kotlin/DBTest.kt
+++ b/sandbox/src/test/kotlin/DBTest.kt
@@ -21,9 +21,9 @@ import org.jetbrains.exposed.sql.*
 import org.jetbrains.exposed.sql.transactions.TransactionManager
 import org.jetbrains.exposed.sql.transactions.transaction
 import org.junit.Test
-import tech.libeufin.sandbox.PaymentsTable
-import tech.libeufin.sandbox.PaymentsTable.msgId
-import tech.libeufin.sandbox.PaymentsTable.pmtInfId
+import tech.libeufin.sandbox.BankAccountTransactionsTable
+import tech.libeufin.sandbox.BankAccountTransactionsTable.msgId
+import tech.libeufin.sandbox.BankAccountTransactionsTable.pmtInfId
 import tech.libeufin.util.millis
 import tech.libeufin.util.parseDashedDate
 import java.io.File
@@ -65,8 +65,8 @@ class DBTest {
     fun betweenDates() {
         withTestDatabase {
             transaction {
-                SchemaUtils.create(PaymentsTable)
-                PaymentsTable.insert {
+                SchemaUtils.create(BankAccountTransactionsTable)
+                BankAccountTransactionsTable.insert {
                     it[creditorIban] = "earns"
                     it[creditorBic] = "BIC"
                     it[creditorName] = "Creditor Name"
@@ -83,8 +83,8 @@ class DBTest {
             }
             val result = transaction {
                 addLogger(StdOutSqlLogger)
-                PaymentsTable.select {
-                    PaymentsTable.date.between(
+                BankAccountTransactionsTable.select {
+                    BankAccountTransactionsTable.date.between(
                         parseDashedDate(
                             "1970-01-01"
                         ).millis(),

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]