- Timestamp:
- 11/23/15 06:37:21 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
metadata/trunk/toolkit/src/main/resources/toolkit/xslt/comp2schema.xsl
r6751 r6833 135 135 <xsl:template match="Element/ValueScheme[exists(Vocabulary/enumeration)]" mode="types"> 136 136 137 <xsl:message>DBG: create complex types</xsl:message> 138 137 139 <!-- only handle the ValueScheme if this is the first occurence of the Component --> 138 140 <xsl:variable name="Component" select="ancestor::Component[exists(@ComponentId)]"/> 139 141 <xsl:if test="empty($Component/preceding::Component[@ComponentId=$Component/@ComponentId])"> 140 142 <xsl:message>DBG: first occurence</xsl:message> 143 141 144 <!-- create a unique suffix (the path to the element) to ensure the unicity of the types to be created --> 142 145 <xsl:variable name="uniquePath" select="cmd:getComponentId(..)"/> … … 146 149 <xs:restriction base="xs:string"> 147 150 <xsl:apply-templates select="pattern"/> 148 <xsl:apply-templates select=" enumeration"/>151 <xsl:apply-templates select="Vocabulary/enumeration"/> 149 152 </xs:restriction> 150 153 </xs:simpleType> … … 300 303 <xsl:template match="AttributeList/Attribute"> 301 304 <xs:attribute name="{@name}"> 305 306 <!-- a mandatory attribute? --> 307 <xsl:if test="@Required='true'"> 308 <xsl:attribute name="use" select="'required'"/> 309 </xsl:if> 302 310 303 311 <!-- Add a cmd:ConceptLink if a ConceptLink element is found --> … … 312 320 313 321 <!-- complex situation: CV or regex --> 314 <xsl:when test="exists(./ValueScheme/( Vocabulary/enumeration|pattern))">322 <xsl:when test="exists(./ValueScheme/((Vocabulary/enumeration)|pattern))"> 315 323 316 324 <xs:annotation>
Note: See TracChangeset
for help on using the changeset viewer.