ZUGFeRD multiple deliveries on one invoice

99 Views Asked by At

we plan to implement ZUGFeRD in our software. So far we have a working solution if only one delivery note is on the invoice. But now a customers wants to use ZUGFeRD also when more than one delivery note is on the invoice.

It would be really helpful if somebody could give me an example XML-File or point me to some documentation that explains how this is done.

I have already found some information that every delivery note should be treated like an invoice position but i'm not quite sure how this should be done.

1

There are 1 best solutions below

0
Vad1mo On

Many details on the invoice can reside on the document level (often referred to as header) and on the line item level (aka positions) .

What you are asking can be achieved by providing the delivery note on the position level. This corresponds to a more exact specification in delimitation to the header.

Here is the example on how you could do it with konik

      Item myItem = new Item().setProduct(new Product().setName("Saddle"))
              .setAgreement(new SpecifiedAgreement().setGrossPrice(new GrossPrice(new Amount(100, EUR)))
                      .setNetPrice(new Price(new Amount(100, EUR))))
              .setSettlement(new SpecifiedSettlement().addTradeTax(itemTax))
              .setDelivery(new SpecifiedDelivery(new Quantity(1, UNIT)))

      myItem.getDelivery().setDeliveryNote(new ReferencedDocumentItem(1,"L123453"));

     trade.addItem(myItem);

from the Domain model you can deduce the xml path that is needed.