Kontoinhaber im XML einsetzen
Bernd Wurst

Bernd Wurst commited on 2024-02-14 08:44:25
Zeige 1 geänderte Dateien mit 4 Einfügungen und 1 Löschungen.

... ...
@@ -16,7 +16,8 @@
16 16
 # You should have received a copy of the GNU General Public License
17 17
 # along with Bib2011.  If not, see <http://www.gnu.org/licenses/>.
18 18
 
19
-import os.path, sys
19
+import os.path
20
+import sys
20 21
 from decimal import Decimal
21 22
 
22 23
 # Search for included submodule python-drafthorse
... ...
@@ -197,6 +198,8 @@ def InvoiceToXML(invoice):
197 198
         doc.trade.settlement.payment_means.type_code = invoice.payment_type
198 199
 
199 200
     if invoice.seller_bank_data['iban'] and invoice.payment_type == PAYMENT_UEBERWEISUNG:
201
+        doc.trade.settlement.payment_means.payee_account.account_name = \
202
+            invoice.seller_bank_data['kontoinhaber'] or invoice.seller['trade_name'] or invoice.seller['name']
200 203
         doc.trade.settlement.payment_means.payee_account.iban = invoice.seller_bank_data['iban']
201 204
         if invoice.seller_bank_data['bic']:
202 205
             doc.trade.settlement.payment_means.payee_institution.bic = invoice.seller_bank_data['bic']
203 206