Create the party name using the registration name of the legal entity from UBL first

Closes #14514
This commit is contained in:
Cédric Krier
2026-01-19 11:34:14 +01:00
parent b211b58884
commit 451a5b9fc7
3 changed files with 7 additions and 5 deletions
+3 -1
View File
@@ -644,7 +644,9 @@ class Invoice(Model):
pool = Pool()
Party = pool.get('party.party')
party = Party()
party.name = party_el.findtext('./{*}PartyName/{*}Name')
party.name = (
party_el.findtext('./{*}PartyLegalEntity/{*}RegistrationName')
or party_el.findtext('./{*}PartyName/{*}Name'))
identifiers = []
for identifier in party_el.iterfind('./{*}PartyIdentification/{*}ID'):
if identifier.text: