From 49a39f436c871ba8317b7d1812ebcce4a7b87bca Mon Sep 17 00:00:00 2001 From: Simon Vieille Date: Fri, 25 Apr 2025 14:45:54 +0200 Subject: [PATCH] style: formatting --- database/model/transaction_banque_populaire.go | 5 ++++- database/model/transaction_caisse_epargne.go | 5 ++++- database/model/transaction_revolut.go | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/database/model/transaction_banque_populaire.go b/database/model/transaction_banque_populaire.go index 7ccabd6..307fe5c 100644 --- a/database/model/transaction_banque_populaire.go +++ b/database/model/transaction_banque_populaire.go @@ -38,7 +38,10 @@ func ImportBanquePopulaireTransactions(content string, bankAccountID int) ([]Tra var count int64 - db.Model(Transaction{}).Where(Transaction{Reference: ref}).Count(&count) + db.Model(Transaction{}).Where(Transaction{ + Reference: ref, + BankAccountID: bankAccountID, + }).Count(&count) if count > 0 { continue diff --git a/database/model/transaction_caisse_epargne.go b/database/model/transaction_caisse_epargne.go index 2187e3d..de163b3 100644 --- a/database/model/transaction_caisse_epargne.go +++ b/database/model/transaction_caisse_epargne.go @@ -42,7 +42,10 @@ func ImportCaisseEpargneTransactions(content string, bankAccountID int) ([]Trans var count int64 - db.Model(Transaction{}).Where(Transaction{Reference: ref}).Count(&count) + db.Model(Transaction{}).Where(Transaction{ + Reference: ref, + BankAccountID: bankAccountID, + }).Count(&count) if count > 0 { continue diff --git a/database/model/transaction_revolut.go b/database/model/transaction_revolut.go index f78c22d..37575d1 100644 --- a/database/model/transaction_revolut.go +++ b/database/model/transaction_revolut.go @@ -41,7 +41,10 @@ func ImportRevolutTransactions(content string, bankAccountID int) ([]Transaction var count int64 - db.Model(Transaction{}).Where(Transaction{Reference: ref}).Count(&count) + db.Model(Transaction{}).Where(Transaction{ + Reference: ref, + BankAccountID: bankAccountID, + }).Count(&count) if count > 0 { continue