Skip to content

Commit

Permalink
Implements #8
Browse files Browse the repository at this point in the history
  • Loading branch information
chrismostert committed Jan 27, 2025
1 parent 54d9d39 commit bc893ce
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion xsd/210-nomination-kiesraad-strict.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
<xs:element name="CandidateIdentifier" type="CandidateIdentifierStructure210"/>
<xs:element name="CandidateFullName" type="PersonNameStructure"/>
<xs:element name="DateOfBirth" type="xs:date" minOccurs="0"/>
<xs:element ref="Gender"/>
<xs:element name="Gender" type="GenderTypeKR"/>
<xs:element name="QualifyingAddress" type="QualifyingAddressStructureKR"/>
<xs:element name="Contact" type="ContactDetailsStructureKR" minOccurs="0"/>
<xs:element name="Agent" type="AgentStructureKR" minOccurs="0"/>
Expand Down
2 changes: 1 addition & 1 deletion xsd/520-result-kiesraad-strict.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
<xs:sequence>
<xs:element name="CandidateIdentifier" type="CandidateIdentifierStructure520"/>
<xs:element name="CandidateFullName" type="PersonNameStructure"/>
<xs:element ref="Gender" minOccurs="0"/>
<xs:element name="Gender" type="GenderTypeKR" minOccurs="0"/>
<xs:element name="QualifyingAddress" type="MinimalQualifyingAddressStructureKR"/>
</xs:sequence>
</xs:restriction>
Expand Down
12 changes: 11 additions & 1 deletion xsd/kiesraad-eml-restrictions.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,16 @@
</xs:restriction>
</xs:complexContent>
</xs:complexType>
<xs:simpleType name="GenderTypeKR">
<xs:annotation>
<xs:documentation>Restricts the base EML gender type to not allow 'unknown', replacing it with 'other'.</xs:documentation>
</xs:annotation>
<xs:restriction base="xs:token">
<xs:enumeration value="male"/>
<xs:enumeration value="female"/>
<xs:enumeration value="other"/>
</xs:restriction>
</xs:simpleType>
<xs:complexType name="CandidateStructureKR">
<xs:annotation>
<xs:documentation>only CandidateIdentifier, CandidateFullName, Gender, QualifyingAddress, Contact, Agent, kr:DateOfBirthAnnex and kr:NationalIdentificationNumber allowed; re-defined without inheritance because of inflexible rules of restriction</xs:documentation>
Expand All @@ -112,7 +122,7 @@
<xs:element name="CandidateIdentifier" type="CandidateIdentifierStructureKR"/>
<xs:element name="CandidateFullName" type="PersonNameStructure" minOccurs="0"/>
<xs:element name="DateOfBirth" type="xs:date" minOccurs="0"/>
<xs:element ref="Gender" minOccurs="0"/>
<xs:element name="Gender" type="GenderTypeKR" minOccurs="0"/>
<xs:element name="QualifyingAddress" type="GenericQualifyingAddressStructureKR" minOccurs="0"/>
<xs:element name="Contact" type="ContactDetailsStructureKR" minOccurs="0"/>
<xs:element name="Agent" type="AgentStructureKR" minOccurs="0"/>
Expand Down

0 comments on commit bc893ce

Please sign in to comment.