Skip to content

Commit

Permalink
fix setTradeParty (#215)
Browse files Browse the repository at this point in the history
  • Loading branch information
rsoika committed Dec 27, 2024
1 parent e246a91 commit bfed18a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion imixs-archive-documents/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ The Adapter class `org.imixs.workflow.documents.EInvoiceAutoAdapter` is an ext
| cdtr.name | text | Creditor name | //ram:ApplicableHeaderTradeAgreement/ram:SellerTradeParty/ram:Name/text()



You can use the [Online eInvoice Validator](https://www.itb.ec.europa.eu/invoice/upload) to test a e-invoice document.


## The PDF XML Plugin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -502,10 +502,17 @@ public void setTradeParty(TradeParty newParty) {
}

// Update address details

// <ram:PostalTradeAddress>
// <ram:PostcodeCode>12345</ram:PostcodeCode>
// <ram:LineOne>Musterstraße 123</ram:LineOne>
// <ram:CityName>Muster</ram:CityName>
// <ram:CountryID>DE</ram:CountryID>
// </ram:PostalTradeAddress>
updateElementValue(postalAddress, EInvoiceNS.RAM, "PostcodeCode", newParty.getPostcodeCode());
updateElementValue(postalAddress, EInvoiceNS.RAM, "LineOne", newParty.getStreetAddress());
updateElementValue(postalAddress, EInvoiceNS.RAM, "CityName", newParty.getCityName());
updateElementValue(postalAddress, EInvoiceNS.RAM, "CountryID", newParty.getCountryId());
updateElementValue(postalAddress, EInvoiceNS.RAM, "LineOne", newParty.getStreetAddress());

// Update VAT registration if available
if (newParty.getVatNumber() != null && !newParty.getVatNumber().isEmpty()) {
Expand Down

0 comments on commit bfed18a

Please sign in to comment.