From 6aff14e99332ecba3e38cace1f5860d557adcc98 Mon Sep 17 00:00:00 2001 From: Jelte Jansen Date: Tue, 19 Mar 2024 11:44:20 +0100 Subject: [PATCH 1/2] Make country-specific rule NL-R-008 domestic-only (PB3-UBL) As suggested by https://github.com/peppolautoriteit-nl/validation/issues/41, and discussed within the NPa SP tech community, this rule should trigger only for domestic traffic. Therefore, this change adds a check for the customer's country in the rule context, similar to other rules. Test case added as well, but the usual disclaimer applies. --- rules/sch/PEPPOL-EN16931-UBL.sch | 4 +- rules/unit-UBL-NL/NL-R-008.xml | 282 +++++++++++++++++++++++++++++++ 2 files changed, 284 insertions(+), 2 deletions(-) diff --git a/rules/sch/PEPPOL-EN16931-UBL.sch b/rules/sch/PEPPOL-EN16931-UBL.sch index afb328cb..bb1353c0 100644 --- a/rules/sch/PEPPOL-EN16931-UBL.sch +++ b/rules/sch/PEPPOL-EN16931-UBL.sch @@ -640,14 +640,14 @@ Last update: 2023 May release 3.0.15. [NL-R-007] For suppliers in the Netherlands, the supplier MUST provide a means of payment (cac:PaymentMeans) if the payment is from customer to supplier - + [NL-R-008] For suppliers in the Netherlands, the payment means code (cac:PaymentMeans/cbc:PaymentMeansCode) MUST be one of 30, 48, 49, 57, 58 or 59 + normalize-space(cbc:PaymentMeansCode) = '59'" flag="fatal">[NL-R-008] For suppliers in the Netherlands, if the customer is in the Netherlands, the payment means code (cac:PaymentMeans/cbc:PaymentMeansCode) MUST be one of 30, 48, 49, 57, 58 or 59 diff --git a/rules/unit-UBL-NL/NL-R-008.xml b/rules/unit-UBL-NL/NL-R-008.xml index 9c2575e1..e71e47cb 100755 --- a/rules/unit-UBL-NL/NL-R-008.xml +++ b/rules/unit-UBL-NL/NL-R-008.xml @@ -568,4 +568,286 @@ + + + NL-R-008 + + + 2.1 + urn:cen.eu:en16931:2017#compliant#urn:fdc:peppol.eu:2017:poacc:billing:3.0 + urn:fdc:peppol.eu:2017:poacc:billing:01:1.0 + 10000005 + 2021-02-23 + 380 + KIA STONIC PE 1.0 TGDI 100pk MHEV DynamicPlusLine + EUR + + 2021-02-23 + 2021-02-23 + + + Customer PO number + + + attachment.PDF + + BASE64CODEINHERE + + + + + 12345678 + + Leaseme NL B.V. + + + Emma van Laarsomweg 3 + Rotterdam + 3050 DG + + NL + + + + NL123456789B01 + + VAT + + + + Leaseme NL B.V. + 12345678 + + + Supplier contact name + 051-1111111 + supplier@leaseme.com + + + + + + 87654321 + + Customer name + + + Street 2 + City + 1234 AB + + SE + + + + NL987654321B01 + + VAT + + + + Customer name as registered in KvK + 87654321 + + + + + 2021-02-24 + + + 1 + + NL63RABO00000000123 + + INGBNL2A + + + + + Payment according to agreed payment terms + + + true + Kosten afgifte kenteken deel 1A + 53.40 + + Z + 0 + + VAT + + + + + true + BPM + 3410.00 + + Z + 0 + + VAT + + + + + 3595.17 + + 17119.80 + 3595.17 + + S + 21.00 + + VAT + + + + + 3463.40 + 0.00 + + Z + 0.00 + + VAT + + + + + + 17119.80 + 20583.20 + 24178.37 + 3463.40 + 0.00 + 24178.37 + + + 1 + 1 + 15929.32 + + false + Korting 8,5% + 8.5 + 1479.77 + 17409.09 + + + Verkoopprijs personenwagen exclusief bpm en btw + + S + 21.00 + + VAT + + + + + + 17409.09 + + + + 2 + 1 + 449.94 + + false + Totaal korting opties en accessoires + 41.80 + + + Opties en accessoires + + S + 21.00 + + VAT + + + + Kleur + Perennial Grey + + + + 491.74 + + + + 3 + 1 + 600.50 + + Kosten rijklaarmaken + + S + 21.00 + + VAT + + + + + 600.50 + + + + 4 + 1 + 45.00 + + Mattenset, gevarendriehoek en lampenset + + S + 21.00 + + VAT + + + + + 45.00 + + + + 5 + 1 + 61.98 + + Brandstof + + S + 21.00 + + VAT + + + + + 61.98 + + + + 6 + 1 + 33.06 + + Recyclingbijdrage + + S + 21.00 + + VAT + + + + + 33.06 + + + + From 38e4612b4a72c8a8f96db4fce04e6a45ca410b71 Mon Sep 17 00:00:00 2001 From: Jelte Jansen Date: Tue, 19 Mar 2024 12:05:54 +0100 Subject: [PATCH 2/2] Make country-specific rule NL-R-008 domestic-only (PB3-CII) See commit 6aff14e99332ecba3e38cace1f5860d557adcc98, but this time for CII. --- rules/sch/PEPPOL-EN16931-CII.sch | 4 +- rules/unit-CII-NL/NL-R-008.xml | 173 +++++++++++++++++++++++++++++++ 2 files changed, 175 insertions(+), 2 deletions(-) diff --git a/rules/sch/PEPPOL-EN16931-CII.sch b/rules/sch/PEPPOL-EN16931-CII.sch index 515b276c..328ea33a 100644 --- a/rules/sch/PEPPOL-EN16931-CII.sch +++ b/rules/sch/PEPPOL-EN16931-CII.sch @@ -485,14 +485,14 @@ Last update: 2022 May release 3.0.13. [NL-R-007] For suppliers in the Netherlands, the supplier MUST provide a means of payment (ram:SpecifiedTradeSettlementPaymentMeans) if the payment is from customer to supplier - + [NL-R-008] For suppliers in the Netherlands, the payment means code (ram:SpecifiedTradeSettlementPaymentMeans/ram:TypeCode) MUST be one of 30, 48, 49, 57, 58 or 59 + normalize-space(ram:TypeCode) = '59'" flag="fatal">[NL-R-008] For suppliers in the Netherlands, if the customer is in the Netherlands, the payment means code (ram:SpecifiedTradeSettlementPaymentMeans/ram:TypeCode) MUST be one of 30, 48, 49, 57, 58 or 59 diff --git a/rules/unit-CII-NL/NL-R-008.xml b/rules/unit-CII-NL/NL-R-008.xml index 67c3aad0..b70f4949 100755 --- a/rules/unit-CII-NL/NL-R-008.xml +++ b/rules/unit-CII-NL/NL-R-008.xml @@ -401,4 +401,177 @@ + + + + NL-R-008 + + + + + + + + urn:fdc:peppol.eu:2017:poacc:billing:01:1.0 + + + urn:cen.eu:en16931:2017#compliant#urn:fdc:peppol.eu:2017:poacc:billing:3.0 + + + + 1100512149 + 380 + + 20141110 + + + + Periodieke afrekening + U vindt een toelichting op uw factuur via www.energieleverancier.nl/factuur_grootzakelijk + Op alle diensten en overeenkomsten zijn de algemene voorwaarden aansluiting en + transport grootverbruik elektriciteit, respectievelijk gas van toepassing + www.energieleverancier.nl + + + + + + + 1 + + + Getransporteerde kWh’s + + + + 1 + + + 100.00 + 1.00 + + + + 1 + + + + VAT + S + 21 + + + 100.00 + + + + + + Energieleverancier B.V. + + 17131139 + Energieleverancier + + + + klantenservice.zakelijk@energieleverancier.nl + + + + 5223MB + Magistratenlaan 116 + 'S-HERTOGENBOSCH + NL + + + 12345678 + + + NL809561074B01 + + + + 1081119 + Klant + + 13524678 + + + 9999 XX + Bedrijfslaan 4 + ONDERNEMERSTØD + SE + + + 12345678 + + + + PO4711 + + + 871694831000290806 + 130 + + + + + + 9999 XX + Bedrijfslaan 4, + ONDERNEMERSTAD + NL + + + + + 1100512149 + EUR + + 54 + + NL28RBOS0420242228 + + + + 30 + + NL28RBOS0420242228 + + + + 21.00 + VAT + 100.00 + S + 21 + + + + 20140801 + + + 20140831 + + + + + Energieleverancier brengt wettelijke rente in rekening over te laat betaalde + facturen. Kijk voor informatie op www.energieleverancier.nl/rentenota + + + 20141124 + + + + 100.00 + 100.00 + 21.00 + 121.00 + 121.00 + + + + +