diff --git a/cii/schematron/CII/EN16931-CII-model.sch b/cii/schematron/CII/EN16931-CII-model.sch index 42860839..18cec719 100644 --- a/cii/schematron/CII/EN16931-CII-model.sch +++ b/cii/schematron/CII/EN16931-CII-model.sch @@ -63,7 +63,7 @@ - + @@ -267,6 +267,7 @@ + diff --git a/cii/schematron/CII/EN16931-CII-syntax.sch b/cii/schematron/CII/EN16931-CII-syntax.sch index ef43185d..fcb497a4 100644 --- a/cii/schematron/CII/EN16931-CII-syntax.sch +++ b/cii/schematron/CII/EN16931-CII-syntax.sch @@ -252,6 +252,8 @@ + + @@ -264,6 +266,9 @@ + + + @@ -351,6 +356,10 @@ + + + + @@ -486,9 +495,11 @@ - + + + - + diff --git a/cii/schematron/abstract/EN16931-CII-model.sch b/cii/schematron/abstract/EN16931-CII-model.sch index 7e790790..6d65cca3 100644 --- a/cii/schematron/abstract/EN16931-CII-model.sch +++ b/cii/schematron/abstract/EN16931-CII-model.sch @@ -9,6 +9,10 @@ [BR-66]-Each Specified Trade Allowance Charge (BG-20)(BG-21) shall contain a Charge Indicator. + + [BR-65]-The Item classification identifier (BT-158) shall have a Scheme identifier. + + [BR-52]-Each Additional supporting document (BG-24) shall contain a Supporting document reference (BT-122). @@ -101,7 +105,6 @@ [BR-27]-The Item net price (BT-146) shall NOT be negative. [BR-28]-The Item gross price (BT-148) shall NOT be negative. [BR-64]-The Item standard identifier (BT-157) shall have a Scheme identifier. - [BR-65]-The Item classification identifier (BT-158) shall have a Scheme identifier. [BR-CO-04]-Each Invoice line (BG-25) shall be categorized with an Invoiced item VAT category code (BT-151). [BR-CO-18]-An Invoice shall at least have one VAT breakdown group (BG-23). [BR-DEC-23]-The allowed maximum number of decimals for the Invoice line net amount (BT-131) is 2. diff --git a/cii/schematron/abstract/EN16931-CII-syntax.sch b/cii/schematron/abstract/EN16931-CII-syntax.sch index 28bbc8ed..aeab7692 100644 --- a/cii/schematron/abstract/EN16931-CII-syntax.sch +++ b/cii/schematron/abstract/EN16931-CII-syntax.sch @@ -265,6 +265,7 @@ [CII-SR-218] - PurchaseSpecifiedTradeAccountingAccount should not be present [CII-SR-219] - SalesSpecifiedTradeAccountingAccount should not be present [CII-SR-220] - SpecifiedTradeSettlementFinancialCard should not be present + [CII-SR-454] - Only one ApplicableTradeTax should be present @@ -369,6 +370,11 @@ [CII-SR-307] - Description should not be present [CII-SR-448] - UltimateCustomerOrderReferencedDocument should not be present [CII-SR-450] - Only one buyer identifier should be present (either the ID or the Global ID) + [CII-SR-455] - DefinedTradeContact of SellerTradeParty shall exist maximum once + [CII-SR-456] - DefinedTradeContact of BuyerTradeParty shall exist maximum once + [CII-SR-457] - IssuerAssignedID with TypeCode 50 should exist maximum once + [CII-SR-458] - IssuerAssignedID with TypeCode 130 should exist maximum once + [CII-SR-308] - RelatedSupplyChainConsignment should not be present @@ -506,6 +512,8 @@ [CII-SR-435] - SpecifiedTradeSettlementFinancialCard should not be present [CII-SR-436] - SpecifiedAdvancePayment should not be present [CII-SR-437] - UltimatePayeeTradeParty should not be present + [CII-SR-452] - Only one SpecifiedTradePaymentTerms should be present + [CII-SR-453] - Only one SpecifiedTradePaymentTerms Description should be present diff --git a/cii/schematron/codelist/EN16931-CII-codes.sch b/cii/schematron/codelist/EN16931-CII-codes.sch index 1ff7094f..0add8338 100644 --- a/cii/schematron/codelist/EN16931-CII-codes.sch +++ b/cii/schematron/codelist/EN16931-CII-codes.sch @@ -14,21 +14,21 @@ [BR-CL-03]-currencyID MUST be coded using ISO code list 4217 alpha-3 [BR-CL-04]-Invoice currency code MUST be coded using ISO code list 4217 alpha-3 [BR-CL-05]-Tax currency code MUST be coded using ISO code list 4217 alpha-3 diff --git a/cii/schematron/preprocessed/EN16931-CII-validation-preprocessed.sch b/cii/schematron/preprocessed/EN16931-CII-validation-preprocessed.sch index 0a1d5725..1e2df5af 100644 --- a/cii/schematron/preprocessed/EN16931-CII-validation-preprocessed.sch +++ b/cii/schematron/preprocessed/EN16931-CII-validation-preprocessed.sch @@ -24,6 +24,9 @@ [BR-66]-Each Specified Trade Allowance Charge (BG-20)(BG-21) shall contain a Charge Indicator. + + [BR-65]-The Item classification identifier (BT-158) shall have a Scheme identifier. + [BR-52]-Each Additional supporting document (BG-24) shall contain a Supporting document reference (BT-122). @@ -116,7 +119,6 @@ [BR-27]-The Item net price (BT-146) shall NOT be negative. [BR-28]-The Item gross price (BT-148) shall NOT be negative. [BR-64]-The Item standard identifier (BT-157) shall have a Scheme identifier. - [BR-65]-The Item classification identifier (BT-158) shall have a Scheme identifier. [BR-CO-04]-Each Invoice line (BG-25) shall be categorized with an Invoiced item VAT category code (BT-151). [BR-CO-18]-An Invoice shall at least have one VAT breakdown group (BG-23). [BR-DEC-23]-The allowed maximum number of decimals for the Invoice line net amount (BT-131) is 2. @@ -583,6 +585,7 @@ [CII-SR-218] - PurchaseSpecifiedTradeAccountingAccount should not be present [CII-SR-219] - SalesSpecifiedTradeAccountingAccount should not be present [CII-SR-220] - SpecifiedTradeSettlementFinancialCard should not be present + [CII-SR-454] - Only one ApplicableTradeTax should be present [CII-SR-442] - Reference should not be present @@ -673,6 +676,10 @@ [CII-SR-307] - Description should not be present [CII-SR-448] - UltimateCustomerOrderReferencedDocument should not be present [CII-SR-450] - Only one buyer identifier should be present (either the ID or the Global ID) + [CII-SR-455] - DefinedTradeContact of SellerTradeParty shall exist maximum once + [CII-SR-456] - DefinedTradeContact of BuyerTradeParty shall exist maximum once + [CII-SR-457] - IssuerAssignedID with TypeCode 50 should exist maximum once + [CII-SR-458] - IssuerAssignedID with TypeCode 130 should exist maximum once [CII-SR-308] - RelatedSupplyChainConsignment should not be present @@ -795,6 +802,8 @@ [CII-SR-435] - SpecifiedTradeSettlementFinancialCard should not be present [CII-SR-436] - SpecifiedAdvancePayment should not be present [CII-SR-437] - UltimatePayeeTradeParty should not be present + [CII-SR-452] - Only one SpecifiedTradePaymentTerms should be present + [CII-SR-453] - Only one SpecifiedTradePaymentTerms Description should be present [CII-SR-411] - InformationAmount should not be present @@ -942,13 +951,13 @@ [BR-CL-01]-The document type code MUST be coded by the invoice and credit note related code lists of UNTDID 1001. - [BR-CL-03]-currencyID MUST be coded using ISO code list 4217 alpha-3 + [BR-CL-03]-currencyID MUST be coded using ISO code list 4217 alpha-3 - [BR-CL-04]-Invoice currency code MUST be coded using ISO code list 4217 alpha-3 + [BR-CL-04]-Invoice currency code MUST be coded using ISO code list 4217 alpha-3 - [BR-CL-05]-Tax currency code MUST be coded using ISO code list 4217 alpha-3 + [BR-CL-05]-Tax currency code MUST be coded using ISO code list 4217 alpha-3 [BR-CL-06]-Value added tax point date code MUST be coded using a restriction of UNTDID 2475. diff --git a/cii/xslt/EN16931-CII-validation.xslt b/cii/xslt/EN16931-CII-validation.xslt index eab956a4..806c7b6a 100644 --- a/cii/xslt/EN16931-CII-validation.xslt +++ b/cii/xslt/EN16931-CII-validation.xslt @@ -208,7 +208,7 @@ - + @@ -228,6 +228,27 @@ + + + + + + + + + + BR-65 + fatal + + + + [BR-65]-The Item classification identifier (BT-158) shall have a Scheme identifier. + + + + + + @@ -1407,21 +1428,6 @@ - - - - BR-65 - fatal - - - - [BR-65]-The Item classification identifier (BT-158) shall have a Scheme identifier. - - - - - - @@ -6970,6 +6976,21 @@ + + + + + + + CII-SR-454 + warning + + + + [CII-SR-454] - Only one ApplicableTradeTax should be present + + + @@ -8296,6 +8317,66 @@ + + + + + + + CII-SR-455 + fatal + + + + [CII-SR-455] - DefinedTradeContact of SellerTradeParty shall exist maximum once + + + + + + + + + + CII-SR-456 + fatal + + + + [CII-SR-456] - DefinedTradeContact of BuyerTradeParty shall exist maximum once + + + + + + + + + + CII-SR-457 + warning + + + + [CII-SR-457] - IssuerAssignedID with TypeCode 50 should exist maximum once + + + + + + + + + + CII-SR-458 + warning + + + + [CII-SR-458] - IssuerAssignedID with TypeCode 130 should exist maximum once + + + @@ -10078,6 +10159,36 @@ + + + + + + + CII-SR-452 + warning + + + + [CII-SR-452] - Only one SpecifiedTradePaymentTerms should be present + + + + + + + + + + CII-SR-453 + warning + + + + [CII-SR-453] - Only one SpecifiedTradePaymentTerms Description should be present + + + @@ -11855,9 +11966,9 @@ - + - + BR-CL-03 fatal @@ -11876,9 +11987,9 @@ - + - + BR-CL-04 fatal @@ -11897,9 +12008,9 @@ - + - + BR-CL-05 fatal diff --git a/ubl/schematron/UBL/EN16931-UBL-syntax.sch b/ubl/schematron/UBL/EN16931-UBL-syntax.sch index faa5afcc..0084fb33 100644 --- a/ubl/schematron/UBL/EN16931-UBL-syntax.sch +++ b/ubl/schematron/UBL/EN16931-UBL-syntax.sch @@ -45,7 +45,7 @@ - + @@ -779,5 +779,5 @@ - + diff --git a/ubl/schematron/abstract/EN16931-syntax.sch b/ubl/schematron/abstract/EN16931-syntax.sch index bcab54b4..8c94aae9 100644 --- a/ubl/schematron/abstract/EN16931-syntax.sch +++ b/ubl/schematron/abstract/EN16931-syntax.sch @@ -13,7 +13,7 @@ [UBL-SR-33]-Supporting document description shall occur maximum once - [UBL-SR-43]-Scheme identifier shall only be used for invoiced object (document type code with value 130) + [UBL-SR-43]-Scheme identifier shall only be used for invoiced object (document type code with value 130 or 50) [UBL-DT-01]-Amounts shall be decimal up to two fraction digits diff --git a/ubl/schematron/codelist/EN16931-UBL-codes.sch b/ubl/schematron/codelist/EN16931-UBL-codes.sch index e4f381c4..8e129660 100644 --- a/ubl/schematron/codelist/EN16931-UBL-codes.sch +++ b/ubl/schematron/codelist/EN16931-UBL-codes.sch @@ -15,20 +15,20 @@ [BR-CL-03]-currencyID MUST be coded using ISO code list 4217 alpha-3 [BR-CL-04]-Invoice currency code MUST be coded using ISO code list 4217 alpha-3 [BR-CL-05]-Tax currency code MUST be coded using ISO code list 4217 alpha-3 diff --git a/ubl/schematron/preprocessed/EN16931-UBL-validation-preprocessed.sch b/ubl/schematron/preprocessed/EN16931-UBL-validation-preprocessed.sch index 66597ff6..1e949404 100644 --- a/ubl/schematron/preprocessed/EN16931-UBL-validation-preprocessed.sch +++ b/ubl/schematron/preprocessed/EN16931-UBL-validation-preprocessed.sch @@ -360,7 +360,7 @@ - + [UBL-SR-51]-An address can only have one third line. @@ -368,7 +368,7 @@ [UBL-SR-33]-Supporting document description shall occur maximum once - [UBL-SR-43]-Scheme identifier shall only be used for invoiced object (document type code with value 130) + [UBL-SR-43]-Scheme identifier shall only be used for invoiced object (document type code with value 130 or 50) [UBL-DT-01]-Amounts shall be decimal up to two fraction digits @@ -1149,13 +1149,13 @@ [BR-CL-01]-The document type code MUST be coded by the invoice and credit note related code lists of UNTDID 1001. - [BR-CL-03]-currencyID MUST be coded using ISO code list 4217 alpha-3 + [BR-CL-03]-currencyID MUST be coded using ISO code list 4217 alpha-3 - [BR-CL-04]-Invoice currency code MUST be coded using ISO code list 4217 alpha-3 + [BR-CL-04]-Invoice currency code MUST be coded using ISO code list 4217 alpha-3 - [BR-CL-05]-Tax currency code MUST be coded using ISO code list 4217 alpha-3 + [BR-CL-05]-Tax currency code MUST be coded using ISO code list 4217 alpha-3 [BR-CL-06]-Value added tax point date code MUST be coded using a restriction of UNTDID 2005. diff --git a/ubl/xslt/EN16931-UBL-validation.xslt b/ubl/xslt/EN16931-UBL-validation.xslt index a850bea3..0c7f30a6 100644 --- a/ubl/xslt/EN16931-UBL-validation.xslt +++ b/ubl/xslt/EN16931-UBL-validation.xslt @@ -3679,8 +3679,8 @@ - - + + @@ -3741,15 +3741,15 @@ - + - + UBL-SR-43 fatal - [UBL-SR-43]-Scheme identifier shall only be used for invoiced object (document type code with value 130) + [UBL-SR-43]-Scheme identifier shall only be used for invoiced object (document type code with value 130 or 50) @@ -15097,9 +15097,9 @@ - + - + BR-CL-03 fatal @@ -15118,9 +15118,9 @@ - + - + BR-CL-04 fatal @@ -15139,9 +15139,9 @@ - + - + BR-CL-05 fatal