]> git.ipfire.org Git - thirdparty/python-fints.git/commitdiff
Also give information about supported SEPA PAIN formats
authorHenryk Plötz <henryk@ploetzli.ch>
Tue, 28 Aug 2018 13:58:07 +0000 (15:58 +0200)
committerRaphael Michel <mail@raphaelmichel.de>
Mon, 3 Dec 2018 18:34:29 +0000 (19:34 +0100)
fints/client.py
fints/formals.py
fints/segments/accounts.py

index 48d021dba07b87bc2a3af07cc18dd7344f0286d4..279649f020e8e9abc80e9b0668a754b10a0ad5f8 100644 (file)
@@ -274,6 +274,9 @@ class FinTS3Client:
                 op: any(self.bpd.find_segment_first(cmd[0]+'I'+cmd[2:]+'S') for cmd in op.value)
                 for op in FinTSOperations
             }
+            hispas = self.bpd.find_segment_first('HISPAS')
+            if hispas:
+                retval['bank']['supported_sepa_formats'] = list(hispas.parameter.supported_sepa_formats)
         if self.upd.segments:
             for upd in self.upd.find_segments('HIUPD'):
                 acc = {}
index d72095719ca219c2b8458a44663d9d8c910bbaf3..6ba9672105c277df7167e3bb706f7cb0c967ff78 100644 (file)
@@ -811,3 +811,12 @@ class StatusSEPATask1(RepresentableEnum):
     IN_PROGRESS = '3' #: in Bearbeitung
     PROCESSED = '4' #: Creditoren-seitig verarbeitet, Buchung veranlasst
     REVOKED = '5' #: R-Transaktion wurde veranlasst
+
+class GetSEPAAccountParameter1(DataElementGroup):
+    """Parameter SEPA-Kontoverbindung anfordern, version 1
+
+    Source: FinTS Financial Transaction Services, Schnittstellenspezifikation, Messages -- Multibankfähige Geschäftsvorfälle """
+    single_account_query_allowed = DataElementField(type='jn', _d="Einzelkontenabruf erlaubt")
+    national_account_allowed = DataElementField(type='jn', _d="Nationale Kontoverbindung erlaubt")
+    structured_purpose_allowed = DataElementField(type='jn', _d="Strukturierter Verwendungszweck erlaubt")
+    supported_sepa_formats = DataElementField(type='an', max_length=256, max_count=9, required=False, _d="Unterstützte SEPA-Datenformate")
index 8c5d3cbd5add14bf70dea0540671845aafac3d1e..fad213d18da2dec30220dc9aa7c436a524680a78 100644 (file)
@@ -1,6 +1,6 @@
-from . import FinTS3Segment
+from . import FinTS3Segment, ParameterSegment
 from ..fields import DataElementGroupField
-from ..formals import KTZ1, Account3
+from ..formals import KTZ1, Account3, GetSEPAAccountParameter1
 
 class HKSPA1(FinTS3Segment):
     """SEPA-Kontoverbindung anfordern, version 1
@@ -15,3 +15,9 @@ class HISPA1(FinTS3Segment):
     Source: FinTS Financial Transaction Services, Schnittstellenspezifikation, Messages -- Multibankfähige Geschäftsvorfälle 
     """
     accounts = DataElementGroupField(type=KTZ1, max_count=999, required=False, _d="SEPA-Kontoverbindung")
+
+class HISPAS1(ParameterSegment):
+    """SEPA-Kontoverbindung anfordern, Parameter, version 1
+
+    Source: FinTS Financial Transaction Services, Schnittstellenspezifikation, Messages -- Multibankfähige Geschäftsvorfälle"""
+    parameter = DataElementGroupField(type=GetSEPAAccountParameter1, _d="Parameter SEPA-Kontoverbindung anfordern")