fnp
/
wolnelektury.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
a7d1e3c
)
pz fixes
author
Radek Czajka
<rczajka@rczajka.pl>
Thu, 19 May 2022 11:01:16 +0000
(13:01 +0200)
committer
Radek Czajka
<rczajka@rczajka.pl>
Thu, 19 May 2022 11:01:16 +0000
(13:01 +0200)
src/pz/models.py
patch
|
blob
|
history
diff --git
a/src/pz/models.py
b/src/pz/models.py
index
13afcba
..
c466084
100644
(file)
--- a/
src/pz/models.py
+++ b/
src/pz/models.py
@@
-145,7
+145,7
@@
class BankExportFeedback(models.Model):
self.save_export_feedback_items()
def save_payment_items(self):
self.save_export_feedback_items()
def save_payment_items(self):
- for payment_id, booking_date, is_dd, realised, reject_code in parse_payment_feedback(self.csv):
+ for payment_id, booking_date, is_dd, realised, reject_code in parse_payment_feedback(self.csv
.open()
):
debit = DirectDebit.objects.get(payment_id = payment_id)
b, created = self.payment_set.get_or_create(
debit=debit,
debit = DirectDebit.objects.get(payment_id = payment_id)
b, created = self.payment_set.get_or_create(
debit=debit,
@@
-164,7
+164,7
@@
class BankExportFeedback(models.Model):
b.save()
def save_export_feedback_items(self):
b.save()
def save_export_feedback_items(self):
- for payment_id, status, comment in parse_export_feedback(self.csv):
+ for payment_id, status, comment in parse_export_feedback(self.csv
.open()
):
debit = DirectDebit.objects.get(payment_id = payment_id)
b, created = self.bankexportfeedbackline_set.get_or_create(
debit=debit,
debit = DirectDebit.objects.get(payment_id = payment_id)
b, created = self.bankexportfeedbackline_set.get_or_create(
debit=debit,
@@
-179,7
+179,7
@@
class BankExportFeedback(models.Model):
b.save()
if status == 1 and not debit.bank_acceptance_date:
debit.bank_acceptance_date = now().date()
b.save()
if status == 1 and not debit.bank_acceptance_date:
debit.bank_acceptance_date = now().date()
-
debit.save()
+ debit.save()
class BankExportFeedbackLine(models.Model):
class BankExportFeedbackLine(models.Model):