From 7d068c7bb9e44ec4208838bb2a44fdc55ab72335 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gregor=20D=C3=BCster?= Date: Fri, 20 Oct 2023 15:36:28 +0200 Subject: [PATCH] fixup! Enable submission of repayment requests --- pycroft/lib/finance/repayment/fields.py | 2 +- web/api/v0/__init__.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/pycroft/lib/finance/repayment/fields.py b/pycroft/lib/finance/repayment/fields.py index 5c9aecc7e..e890ecabd 100644 --- a/pycroft/lib/finance/repayment/fields.py +++ b/pycroft/lib/finance/repayment/fields.py @@ -7,7 +7,7 @@ class IBANField(fields.Field): to a string. """ - def _deserialize(self, value, attr, data, **kwargs) -> IBAN: + def _deserialize(self, value, attr, data, **kwargs): try: return IBAN(value, validate_bban=True) except ValueError as error: diff --git a/web/api/v0/__init__.py b/web/api/v0/__init__.py index 9cf535174..6e3ceccca 100644 --- a/web/api/v0/__init__.py +++ b/web/api/v0/__init__.py @@ -812,7 +812,9 @@ def get(self, user_id: int) -> Response: }, location="form", ) - def post(self, user_id: int, beneficiary: str, iban: str, amount: Decimal) -> Response: + def post( + self, user_id: int, beneficiary: str, iban: str, amount: Decimal + ) -> Response: current_app.logger.warning({beneficiary, iban, amount}) return jsonify({"success": True})