Skip to content

Commit

Permalink
Added specific support for XRechnung Extension
Browse files Browse the repository at this point in the history
  • Loading branch information
phax committed Jan 8, 2025
1 parent 76e47dc commit b19cc33
Show file tree
Hide file tree
Showing 9 changed files with 2,657 additions and 43 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,9 @@ As OpenPeppol is only changing the "micro" version part (3.0.x), whereas I start
I hope that with the introduction of PINT, the versioning problem will be solved.

# News and noteworthy


* v3.2.4 - 2025-01-08
* Added specific support for XRechnung Extension (for versions 3.0.0, 3.0.1 and 3.0.2)
* v3.2.3 - 2025-01-03
* Fixed Factur-X VES display name to include the profile name as well
* Added Peppol A-NZ-PEPPOL 1.0.12 rules
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,10 @@ public static ICommonsList <PhiveTestFile> getAllTestFiles ()
{
final ICommonsList <PhiveTestFile> ret = new CommonsArrayList <> ();
for (final DVRCoordinate aESID : new DVRCoordinate [] { XRechnungValidation.VID_XRECHNUNG_CII_302,
XRechnungValidation.VID_XRECHNUNG_EXTENSION_CII_302,
XRechnungValidation.VID_XRECHNUNG_UBL_CREDITNOTE_302,
XRechnungValidation.VID_XRECHNUNG_UBL_INVOICE_302,
XRechnungValidation.VID_XRECHNUNG_EXTENSION_UBL_INVOICE_302,

XRechnungValidation.VID_XRECHNUNG_CII_301,
XRechnungValidation.VID_XRECHNUNG_UBL_CREDITNOTE_301,
Expand Down Expand Up @@ -882,40 +884,58 @@ public static ICommonsList <? extends IReadableResource> getAllMatchingTestFiles
ret.add (new ClassPathResource (sPrefix + s));
}
else
if (aVESID.equals (XRechnungValidation.VID_XRECHNUNG_UBL_CREDITNOTE_302))
if (aVESID.equals (XRechnungValidation.VID_XRECHNUNG_EXTENSION_CII_302))
{
// None atm
final String sPrefix = sPrefix0 + "3.0.2/cii-ext/";
for (final String s : new String [] { "04.05a-INVOICE_uncefact.xml" })
ret.add (new ClassPathResource (sPrefix + s));
}
else
if (aVESID.equals (XRechnungValidation.VID_XRECHNUNG_UBL_INVOICE_302))
if (aVESID.equals (XRechnungValidation.VID_XRECHNUNG_UBL_CREDITNOTE_302))
{
final String sPrefix = sPrefix0 + "3.0.2/ubl-inv/";
for (final String s : new String [] { "01.01a-INVOICE_ubl.xml",
"01.02a-INVOICE_ubl.xml",
"01.03a-INVOICE_ubl.xml",
"01.04a-INVOICE_ubl.xml",
"01.05a-INVOICE_ubl.xml",
"01.06a-INVOICE_ubl.xml",
"01.07a-INVOICE_ubl.xml",
"01.08a-INVOICE_ubl.xml",
"01.09a-INVOICE_ubl.xml",
"01.10a-INVOICE_ubl.xml",
"01.11a-INVOICE_ubl.xml",
"01.12a-INVOICE_ubl.xml",
"01.13a-INVOICE_ubl.xml",
"01.14a-INVOICE_ubl.xml",
"01.17a-INVOICE_ubl.xml",
"01.18a-INVOICE_ubl.xml",
"01.19a-INVOICE_ubl.xml",
"01.20a-INVOICE_ubl.xml",
"01.21a-INVOICE_ubl.xml",
"02.01a-INVOICE_ubl.xml",
"02.02a-INVOICE_ubl.xml",
"03.01a-INVOICE_ubl.xml",
"03.02a-INVOICE_ubl.xml",
"03.06a-INVOICE_ubl.xml" })
ret.add (new ClassPathResource (sPrefix + s));
// None atm
}
else
if (aVESID.equals (XRechnungValidation.VID_XRECHNUNG_UBL_INVOICE_302))
{
final String sPrefix = sPrefix0 + "3.0.2/ubl-inv/";
for (final String s : new String [] { "01.01a-INVOICE_ubl.xml",
"01.02a-INVOICE_ubl.xml",
"01.03a-INVOICE_ubl.xml",
"01.04a-INVOICE_ubl.xml",
"01.05a-INVOICE_ubl.xml",
"01.06a-INVOICE_ubl.xml",
"01.07a-INVOICE_ubl.xml",
"01.08a-INVOICE_ubl.xml",
"01.09a-INVOICE_ubl.xml",
"01.10a-INVOICE_ubl.xml",
"01.11a-INVOICE_ubl.xml",
"01.12a-INVOICE_ubl.xml",
"01.13a-INVOICE_ubl.xml",
"01.14a-INVOICE_ubl.xml",
"01.17a-INVOICE_ubl.xml",
"01.18a-INVOICE_ubl.xml",
"01.19a-INVOICE_ubl.xml",
"01.20a-INVOICE_ubl.xml",
"01.21a-INVOICE_ubl.xml",
"02.01a-INVOICE_ubl.xml",
"02.02a-INVOICE_ubl.xml",
"03.01a-INVOICE_ubl.xml",
"03.02a-INVOICE_ubl.xml",
"03.06a-INVOICE_ubl.xml" })
ret.add (new ClassPathResource (sPrefix + s));
}
else
if (aVESID.equals (XRechnungValidation.VID_XRECHNUNG_EXTENSION_UBL_INVOICE_302))
{
final String sPrefix = sPrefix0 + "3.0.2/ubl-inv-ext/";
for (final String s : new String [] { "04.01a-INVOICE_ubl.xml",
"04.02a-INVOICE_ubl.xml",
"04.03a-INVOICE_ubl.xml",
"04.04a-INVOICE_ubl.xml",
"05.01a-INVOICE_ubl.xml" })
ret.add (new ClassPathResource (sPrefix + s));
}
return ret;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,173 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
- Copyright © 2020 BITMARCK Service GmbH
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-->
<rsm:CrossIndustryInvoice xmlns:rsm="urn:un:unece:uncefact:data:standard:CrossIndustryInvoice:100"
xmlns:ram="urn:un:unece:uncefact:data:standard:ReusableAggregateBusinessInformationEntity:100"
xmlns:udt="urn:un:unece:uncefact:data:standard:UnqualifiedDataType:100">
<rsm:ExchangedDocumentContext>
<ram:BusinessProcessSpecifiedDocumentContextParameter>
<ram:ID>urn:fdc:peppol.eu:2017:poacc:billing:01:1.0</ram:ID>
</ram:BusinessProcessSpecifiedDocumentContextParameter>
<ram:GuidelineSpecifiedDocumentContextParameter>
<ram:ID>urn:cen.eu:en16931:2017#compliant#urn:xeinkauf.de:kosit:xrechnung_3.0#conformant#urn:xeinkauf.de:kosit:extension:xrechnung_3.0</ram:ID>
</ram:GuidelineSpecifiedDocumentContextParameter>
</rsm:ExchangedDocumentContext>
<rsm:ExchangedDocument>
<ram:ID>2020-1</ram:ID>
<ram:TypeCode>380</ram:TypeCode>
<ram:IssueDateTime>
<udt:DateTimeString format="102">20200103</udt:DateTimeString>
</ram:IssueDateTime>
<ram:IncludedNote>
<ram:Content>Eine Testrechnung für das Projekt DiGA-Rechnung.</ram:Content>
</ram:IncludedNote>
</rsm:ExchangedDocument>
<rsm:SupplyChainTradeTransaction>
<ram:IncludedSupplyChainTradeLineItem>
<ram:AssociatedDocumentLineDocument>
<ram:LineID>TEST_POSITION_01</ram:LineID>
</ram:AssociatedDocumentLineDocument>
<ram:SpecifiedTradeProduct>
<!-- DiGA-VE-ID: -->
<ram:GlobalID schemeID="XR01">12345678</ram:GlobalID>
<!-- Freischaltcode: -->
<ram:BuyerAssignedID>ABCDEFGHIJKLMNOP</ram:BuyerAssignedID>
<!-- DiGA-Name: -->
<ram:Name>Tinnitus Rex</ram:Name>
<ram:Description>Ein Artikel für Testrechnungen.</ram:Description>
<!--
<ram:IndividualTradeProductInstance>
<ram:SellByDateTime>
&lt;!&ndash; Tag der Leistungserbringung &ndash;&gt;
<udt:DateTimeString format="102">20200102</udt:DateTimeString>
</ram:SellByDateTime>
</ram:IndividualTradeProductInstance>
-->
</ram:SpecifiedTradeProduct>
<ram:SpecifiedLineTradeAgreement>
<ram:NetPriceProductTradePrice>
<ram:ChargeAmount>100.00</ram:ChargeAmount>
</ram:NetPriceProductTradePrice>
</ram:SpecifiedLineTradeAgreement>
<ram:SpecifiedLineTradeDelivery>
<!-- Eine Packungseinheit: -->
<ram:BilledQuantity unitCode="C62">1</ram:BilledQuantity>
</ram:SpecifiedLineTradeDelivery>
<ram:SpecifiedLineTradeSettlement>
<ram:ApplicableTradeTax>
<ram:TypeCode>VAT</ram:TypeCode>
<ram:CategoryCode>S</ram:CategoryCode>
<ram:RateApplicablePercent>19.00</ram:RateApplicablePercent>
</ram:ApplicableTradeTax>
<ram:SpecifiedTradeSettlementLineMonetarySummation>
<ram:LineTotalAmount>100.00</ram:LineTotalAmount>
</ram:SpecifiedTradeSettlementLineMonetarySummation>
</ram:SpecifiedLineTradeSettlement>
</ram:IncludedSupplyChainTradeLineItem>
<ram:ApplicableHeaderTradeAgreement>
<ram:BuyerReference>Leitweg-ID</ram:BuyerReference>
<ram:SellerTradeParty>
<ram:ID>TEST_RECHNUNGSSTELLER</ram:ID>
<!-- IK des DiGA-Herstellers als "Seller Identifier" (BT-29) [BR-CO-26]: -->
<ram:GlobalID schemeID="XR03">987654321</ram:GlobalID>
<ram:Name>Rechnungssteller</ram:Name>
<ram:DefinedTradeContact>
<ram:PersonName>Max Mustermann</ram:PersonName>
<ram:TelephoneUniversalCommunication>
<ram:CompleteNumber>+49 000 001 0001</ram:CompleteNumber>
</ram:TelephoneUniversalCommunication>
<ram:EmailURIUniversalCommunication>
<ram:URIID>max.mustermann@rechnungssteller.de</ram:URIID>
</ram:EmailURIUniversalCommunication>
</ram:DefinedTradeContact>
<ram:PostalTradeAddress>
<ram:PostcodeCode>01234</ram:PostcodeCode>
<ram:LineOne>Musterstraße 1</ram:LineOne>
<ram:CityName>Berlin</ram:CityName>
<ram:CountryID>DE</ram:CountryID>
</ram:PostalTradeAddress>
<ram:URIUniversalCommunication>
<ram:URIID schemeID="EM">seller@email.de</ram:URIID>
</ram:URIUniversalCommunication>
<ram:SpecifiedTaxRegistration>
<ram:ID schemeID="VA">DE 123 456 789</ram:ID>
</ram:SpecifiedTaxRegistration>
</ram:SellerTradeParty>
<ram:BuyerTradeParty>
<!-- IK der Krankenkasse als "Buyer Identifier" (BT-46): -->
<ram:GlobalID schemeID="XR03">123456789</ram:GlobalID>
<ram:Name>Rechnungsempfänger</ram:Name>
<ram:PostalTradeAddress>
<ram:PostcodeCode>01234</ram:PostcodeCode>
<ram:LineOne>Musterstraße 2</ram:LineOne>
<ram:CityName>Berlin</ram:CityName>
<ram:CountryID>DE</ram:CountryID>
</ram:PostalTradeAddress>
<ram:URIUniversalCommunication>
<ram:URIID schemeID="EM">buyer@info.de</ram:URIID>
</ram:URIUniversalCommunication>
</ram:BuyerTradeParty>
</ram:ApplicableHeaderTradeAgreement>
<ram:ApplicableHeaderTradeDelivery>
<ram:ActualDeliverySupplyChainEvent>
<ram:OccurrenceDateTime>
<!-- Tag der Leistungserbringung -->
<udt:DateTimeString format="102">20200102</udt:DateTimeString>
</ram:OccurrenceDateTime>
</ram:ActualDeliverySupplyChainEvent>
</ram:ApplicableHeaderTradeDelivery>
<ram:ApplicableHeaderTradeSettlement>
<!-- IK des Zahlungsempfängers als "Payee Identifier" (BT-60): -->
<!--<ram:CreditorReferenceID schemeID="IK">987654322</ram:CreditorReferenceID>-->
<!--
<ram:TaxCurrencyCode>EUR</ram:TaxCurrencyCode>
-->
<ram:InvoiceCurrencyCode>EUR</ram:InvoiceCurrencyCode>
<ram:PayeeTradeParty>
<!-- IK des Zahlungsempfängers als "Payee Identifier" (BT-60): -->
<ram:GlobalID schemeID="XR03">987654322</ram:GlobalID>
<ram:Name>Payee</ram:Name>
</ram:PayeeTradeParty>

<ram:SpecifiedTradeSettlementPaymentMeans>
<ram:TypeCode>30</ram:TypeCode>
<ram:PayeePartyCreditorFinancialAccount>
<!-- IBAN -->
<ram:IBANID>DE75512108001245126199</ram:IBANID>
</ram:PayeePartyCreditorFinancialAccount>
</ram:SpecifiedTradeSettlementPaymentMeans>
<ram:ApplicableTradeTax>
<ram:CalculatedAmount>19.00</ram:CalculatedAmount>
<ram:TypeCode>VAT</ram:TypeCode>
<ram:BasisAmount>100.00</ram:BasisAmount>
<ram:CategoryCode>S</ram:CategoryCode>
<ram:RateApplicablePercent>19.00</ram:RateApplicablePercent>
</ram:ApplicableTradeTax>
<ram:SpecifiedTradePaymentTerms>
<ram:DueDateDateTime>
<udt:DateTimeString format="102">20200117</udt:DateTimeString>
</ram:DueDateDateTime>
</ram:SpecifiedTradePaymentTerms>
<ram:SpecifiedTradeSettlementHeaderMonetarySummation>
<ram:LineTotalAmount>100.00</ram:LineTotalAmount>
<ram:TaxBasisTotalAmount>100.00</ram:TaxBasisTotalAmount>
<ram:TaxTotalAmount currencyID="EUR">19.00</ram:TaxTotalAmount>
<ram:GrandTotalAmount>119.00</ram:GrandTotalAmount>
<ram:DuePayableAmount>119.00</ram:DuePayableAmount>
</ram:SpecifiedTradeSettlementHeaderMonetarySummation>
</ram:ApplicableHeaderTradeSettlement>
</rsm:SupplyChainTradeTransaction>
</rsm:CrossIndustryInvoice>
Loading

0 comments on commit b19cc33

Please sign in to comment.