Skip to content

Allow adding own UBL Extensions within eforms customized UBL-XSD to enable German tailoring required by German law #1247

@rkottmann

Description

@rkottmann

Currently, we have a severe showstopper in order to implement German legal requirements in eForms-DE. For our national change requests we require some new BTs (BT-DEX-01, BT-DEX-02, BT-DEX-03). Here are the issues currently blocked:

Because we need to work with your customized UBL-XSD, we need to be able to introduce our own UBL extension, so that we can define the syntax bindings for those German BTs.

However, the way you extended UBL stopps us from adding own national extensions.

Currently, the XML documents CN, PIN or CAN can be extended using the UBLExtensions element which consists of UBLExtension elements which can have ExtensionContent elements. The type of ExtensionContent element is defined in UBL-ExtensionContentDataType-2.3.xsd where the only allowed element is EformsExtension (which is then defined in EFORMS-ExtensionApex-2.3.xsd). This way you introduced strict definition for the ExtensionContent which then removes the possibility to introduce customized extensions for different purposes, depending on the needs of user.

Hence, we kindly ask you, if it would be possible to allow other extension already in upcoming 1.14 release (otherwise, we won't be able to fullfil German legal reqirements in time). Technically, the required change to your XSD as simple as follows:

Possible Extension outside eForms-Extension (mocked)

Change UBL-ExtensionContentDataType-2.3.xsd to

 <!-- ===== Type Declaration ===== -->
  <xsd:complexType name="ExtensionContentType">
     <!-- sequence as of original UBL -->
    <xsd:sequence minOccurs="0" maxOccurs="1">
      <xsd:element ref="efext:EformsExtension" />
      <xsd:any namespace="##other" processContents="lax" minOccurs="0"
        maxOccurs="unbounded">
        <xsd:annotation>
          <xsd:documentation>
Any element in any namespace other than the UBL extension namespace is allowed to be the apex element of an extension. Only those elements found in the UBL schemas and in the trees of schemas imported in this module are validated. Any element for which there is no schema declaration in any of the trees of schemas passes validation and is not treated as a schema constraint violation.
</xsd:documentation>
        </xsd:annotation>
      </xsd:any>

    </xsd:sequence>
  </xsd:complexType>

Result:

<ext:ExtensionContent>
   <efext:EformsExtension>
     <efac:AwardCriterionParameter>
       <efbc:ParameterCode listName="number-weight">per-exa</efbc:ParameterCode>
       <efbc:ParameterNumeric>40.00</efbc:ParameterNumeric>
     </efac:AwardCriterionParameter>
     
   </efext:EformsExtension>
   
   <!-- National extension outside  eForms extension -->
   <german:extended-element xmlns:german="german-extension-namespace" />

</ext:ExtensionContent>

Possible Extension inside eForms-Extension (mocked)

Change EFORMS-ExtensionApex-2.3.xsd:

<?xml version="1.0" encoding="UTF-8"?>

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns="http://data.europa.eu/p27/eforms-ubl-extensions/1"
  xmlns:efext="http://data.europa.eu/p27/eforms-ubl-extensions/1"
  xmlns:efac="http://data.europa.eu/p27/eforms-ubl-extension-aggregate-components/1"
  xmlns:efbc="http://data.europa.eu/p27/eforms-ubl-extension-basic-components/1"
  xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
  xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
  targetNamespace="http://data.europa.eu/p27/eforms-ubl-extensions/1"
  elementFormDefault="qualified" attributeFormDefault="unqualified">
 <!-- left out for brevity -->
  <xsd:element name="EformsExtension">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element ref="efbc:AccessToolName" minOccurs="0"
          maxOccurs="unbounded" />
<!-- left out for brevity -->

        <xsd:element ref="efac:TenderSubcontractingRequirements" minOccurs="0"
          maxOccurs="unbounded" />

  <xsd:element name="national-extensions" minOccurs="0" maxOccurs="1">
          <xsd:complexType>
            <xsd:sequence>
              <xsd:any namespace="##other" processContents="skip" minOccurs="1"
                maxOccurs="unbounded">
                <xsd:annotation>
                  <xsd:documentation>
Any element in any namespace other than the UBL extension namespace is allowed to be the apex element of an extension. Only those elements found in the UBL schemas and in the trees of schemas imported in this module are validated. Any element for which there is no schema declaration in any of the trees of schemas passes validation and is not treated as a schema constraint violation.
</xsd:documentation>
                </xsd:annotation>
              </xsd:any>
            </xsd:sequence>
          </xsd:complexType>
        </xsd:element>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>

Result:

<ext:UBLExtensions>
              <ext:UBLExtension>
                <ext:ExtensionContent>
                  <efext:EformsExtension>
                    <efac:AwardCriterionParameter>
                      <efbc:ParameterCode listName="number-weight"
                        >per-exa</efbc:ParameterCode>
                      <efbc:ParameterNumeric>40.00</efbc:ParameterNumeric>
                    </efac:AwardCriterionParameter>
                    <!-- National extension inside  eForms extension -->
                    <efext:national-extensions>

                      <german:extended-element
                        xmlns:german="german-extension-namespace" />

                    </efext:national-extensions>


                  </efext:EformsExtension>

                </ext:ExtensionContent>
              </ext:UBLExtension>
            </ext:UBLExtensions>

Any of those or even both would help us tremendously in implementing German requirements using eForms.

thx for your consideration

Metadata

Metadata

Assignees

Labels

schemasRelated to eForms Schemas (/schemas SDK folder).

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions