From 748ad7eb4813f2bb2f273a5e29cadeda1d58c3a1 Mon Sep 17 00:00:00 2001 From: Yohann D'ANELLO Date: Sun, 26 Jul 2020 09:05:44 +0200 Subject: [PATCH] :bug: Don't import only the last remittance... --- management/commands/import_transaction.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/management/commands/import_transaction.py b/management/commands/import_transaction.py index 780451d..2f380db 100644 --- a/management/commands/import_transaction.py +++ b/management/commands/import_transaction.py @@ -284,7 +284,7 @@ class Command(ImportCommand): @transaction.atomic def import_remittances(self, cur, chunk_size): bulk_mgr = BulkCreateManager(chunk_size=chunk_size) - cur.execute("SELECT id, date, commentaire, close FROM remises WHERE id = 105 ORDER BY id;") + cur.execute("SELECT id, date, commentaire, close FROM remises ORDER BY id;") n = cur.rowcount pk_remittance = 1 @@ -309,7 +309,7 @@ class Command(ImportCommand): @timed def import_checks(self, cur): cur.execute("SELECT id, nom, prenom, banque, idtransaction, idremise " - "FROM cheques WHERE idremise = 105 ORDER BY id;") + "FROM cheques ORDER BY id;") n = cur.rowcount for idx, row in enumerate(cur):