Skip to content

Commit

Permalink
Made C1 country code mandatory as per Peppol SBDH v2.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
aaron-kumar committed Oct 14, 2023
1 parent ef40673 commit a333265
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ public void simple() throws Exception {
"urn:oasis:names:specification:ubl:schema:xsd:Invoice-2::Invoice" +
"##urn:www.cenbii.eu:transaction:biicoretrdm010:ver1.0" +
":#urn:www.peppol.eu:bis:peppol4a:ver1.0::2.0"))
.c1CountryIdentifier(C1CountryIdentifier.of("NO"))
.instanceType(InstanceType.of("urn:oasis:names:specification:ubl:schema:xsd:Invoice-2", "Invoice", "2.0"))
.creationTimestamp(new Date())
.identifier(InstanceIdentifier.generateUUID());
Expand All @@ -63,6 +64,7 @@ public void withProcessScheme() throws Exception {
.process(ProcessIdentifier.of("urn:www.cenbii.eu:profile:bii05:ver2.0", Scheme.of("cenbii-procid-ubl")))
.documentType(DocumentTypeIdentifier.of("urn:oasis:names:specification:ubl:schema:xsd:CreditNote-2::CreditNote" +
"##urn:www.cenbii.eu:transaction:biitrns014:ver2.0:extended:urn:www.peppol.eu:bis:peppol5a:ver2.0::2.1"))
.c1CountryIdentifier(C1CountryIdentifier.of("NO"))
.instanceType(InstanceType.of("urn:oasis:names:specification:ubl:schema:xsd:CreditNote-2", "CreditNote", "2.1"))
.creationTimestamp(new Date())
.identifier(InstanceIdentifier.generateUUID());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ public class SbdhWriterTest {
"urn:oasis:names:specification:ubl:schema:xsd:Invoice-2::Invoice" +
"##urn:www.cenbii.eu:transaction:biicoretrdm010:ver1.0" +
":#urn:www.peppol.eu:bis:peppol4a:ver1.0::2.0"))
.c1CountryIdentifier(C1CountryIdentifier.of("NO"))
.instanceType(InstanceType.of("urn:oasis:names:specification:ubl:schema:xsd:Invoice-2", "Invoice", "2.0"))
.creationTimestamp(new Date())
.identifier(InstanceIdentifier.generateUUID());
Expand Down
4 changes: 4 additions & 0 deletions peppol-sbdh/src/test/resources/iso20022/sbdh.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,9 @@
<Type>PROCESSID</Type>
<InstanceIdentifier>urn:fdc:bits.no:2017:profile:01:1.0</InstanceIdentifier>
</Scope>
<Scope>
<Type>COUNTRY_C1</Type>
<InstanceIdentifier>NO</InstanceIdentifier>
</Scope>
</BusinessScope>
</StandardBusinessDocumentHeader>

0 comments on commit a333265

Please sign in to comment.