Browse Source

fix Related rood extra add

a.binder 9 years ago
parent
commit
90633d4143

+ 7 - 4
SE/schema/default_db_xml_cache.public/build_recurse_ant.xsl

@@ -126,10 +126,7 @@
                 
                 
                 <xsl:variable name="xpath_value_dita">
                 <xsl:variable name="xpath_value_dita">
                     <xsl:choose>
                     <xsl:choose>
-                        <xsl:when test="string-length($xpath_value) &gt;0">
-                            <xsl:message>#67.0 $xpath_value=(<xsl:value-of select="$xpath_value"/>); narzucone pewnie z wyzwolenia build.xml</xsl:message>
-                            <xsl:value-of select="$xpath_value"/>
-                        </xsl:when>
+                        
                         <xsl:when test="@xpath_value">
                         <xsl:when test="@xpath_value">
                             <!--<xsl:variable name="xpath_value_tokens" select="tokenize(@xpath_value,'/')"/>-->
                             <!--<xsl:variable name="xpath_value_tokens" select="tokenize(@xpath_value,'/')"/>-->
                             <!--<xsl:value-of select="'todo zapytanie xpath do przetworzenia'"/>-->
                             <!--<xsl:value-of select="'todo zapytanie xpath do przetworzenia'"/>-->
@@ -147,6 +144,10 @@
                             <!--<xsl:value-of select="$xpath_value_token/node()[1]/text()"/>-->
                             <!--<xsl:value-of select="$xpath_value_token/node()[1]/text()"/>-->
                             <!--<xsl:value-of select="$xpath_value_token"/>-->
                             <!--<xsl:value-of select="$xpath_value_token"/>-->
                         </xsl:when>
                         </xsl:when>
+                        <xsl:when test="string-length($xpath_value) &gt;0">
+                            <xsl:message>#67.0 $xpath_value=(<xsl:value-of select="$xpath_value"/>); narzucone pewnie z wyzwolenia build.xml</xsl:message>
+                            <xsl:value-of select="$xpath_value"/>
+                        </xsl:when>
                         <xsl:otherwise>
                         <xsl:otherwise>
                             <xsl:value-of select="$xpath_value"/><!-- parametr z template narzuca wartosc -->
                             <xsl:value-of select="$xpath_value"/><!-- parametr z template narzuca wartosc -->
                         </xsl:otherwise>
                         </xsl:otherwise>
@@ -413,6 +414,8 @@
                         <xsl:element name="tempfile">
                         <xsl:element name="tempfile">
                             <xsl:attribute name="property" select="concat('get_related_feature_run_child_ant',$loop_xpath_real,'_',$loop_path_recurs,'_temp')" />
                             <xsl:attribute name="property" select="concat('get_related_feature_run_child_ant',$loop_xpath_real,'_',$loop_path_recurs,'_temp')" />
                             <xsl:attribute name="destdir" select="$temp"/>
                             <xsl:attribute name="destdir" select="$temp"/>
+                            <xsl:attribute name="prefix" select="'test_if_exec_child_ant-'"/>
+                            <xsl:attribute name="suffix" select="'.xml'"/>
                         </xsl:element>
                         </xsl:element>
                         <xsl:variable name="OGC_Filter">
                         <xsl:variable name="OGC_Filter">
                             <xsl:call-template name="simpleTypeMakeOgcFilter_merge">
                             <xsl:call-template name="simpleTypeMakeOgcFilter_merge">

+ 10 - 3
SE/schema/default_db_xml_cache.public/build_recurse_ant_merge_dita_from_temp.xsl

@@ -56,6 +56,13 @@
         <xsl:copy-of select="collection($path)"/>
         <xsl:copy-of select="collection($path)"/>
     </xsl:template>-->
     </xsl:template>-->
     
     
+    <!--<xsl:template match="RelatedFeatureRoot" mode="root">
+        <xsl:param name="loop_xpath"/>
+            <xsl:apply-templates>
+                <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
+            </xsl:apply-templates>
+    </xsl:template>-->
+    
     <xsl:template match="*" mode="root">
     <xsl:template match="*" mode="root">
         <xsl:param name="loop_xpath"/>
         <xsl:param name="loop_xpath"/>
         <xsl:element name="{name()}">
         <xsl:element name="{name()}">
@@ -132,14 +139,14 @@
         <!--<debug_RelatedFeature>
         <!--<debug_RelatedFeature>
             <xsl:copy-of select="$dita_fragment"/>
             <xsl:copy-of select="$dita_fragment"/>
         </debug_RelatedFeature>-->
         </debug_RelatedFeature>-->
-        <RelatedFeatureRoot>
+        <!--<RelatedFeatureRoot>-->
                 <xsl:for-each select="$dita_fragment">
                 <xsl:for-each select="$dita_fragment">
                     <xsl:apply-templates mode="RelatedFeature" select="$dita_fragment/RelatedFeatureRoot/*">
                     <xsl:apply-templates mode="RelatedFeature" select="$dita_fragment/RelatedFeatureRoot/*">
                         <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
                         <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
                         <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
                         <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
                     </xsl:apply-templates>
                     </xsl:apply-templates>
                 </xsl:for-each>
                 </xsl:for-each>
-        </RelatedFeatureRoot>
+        <!--</RelatedFeatureRoot>-->
 
 
     </xsl:template>
     </xsl:template>
     
     
@@ -235,7 +242,7 @@
                         <xsl:for-each select="$current/*">
                         <xsl:for-each select="$current/*">
                             <xsl:choose>
                             <xsl:choose>
                                 <xsl:when test="name()='RelatedFeatureRoot'"/>                                
                                 <xsl:when test="name()='RelatedFeatureRoot'"/>                                
-                                <xsl:otherwise><xsl:copy-of select="."/></xsl:otherwise>
+                                <xsl:otherwise><xsl:copy-of select="." copy-namespaces="no"/></xsl:otherwise>
                             </xsl:choose>
                             </xsl:choose>
                         </xsl:for-each>
                         </xsl:for-each>
                             
                             

+ 9 - 3
SE/schema/default_db_xml_cache.public/main_build_recurse_ant.dita_with_id.xsl

@@ -312,10 +312,16 @@
     <xsl:template name="p5_tr_map:simpleTypeMakeOgcFilter">
     <xsl:template name="p5_tr_map:simpleTypeMakeOgcFilter">
         <xsl:param name="build_complexType" required="yes"/>
         <xsl:param name="build_complexType" required="yes"/>
         <!--<xsl:param name="system_cache__appinfo:id" required="yes"/>-->
         <!--<xsl:param name="system_cache__appinfo:id" required="yes"/>-->
-        <simpleTypeMakeOgcFilter>
-            <xsl:attribute name="name" select="$build_complexType/element/@name" xpath-default-namespace="http://www.w3.org/2001/XMLSchema"/>
+        <xsl:variable name="simpleTypeMakeOgcFilter">
             <xsl:apply-templates mode="p5_tr_map:simpleTypeMakeOgcFilter" select="$build_complexType/element" xpath-default-namespace="http://www.w3.org/2001/XMLSchema"/>
             <xsl:apply-templates mode="p5_tr_map:simpleTypeMakeOgcFilter" select="$build_complexType/element" xpath-default-namespace="http://www.w3.org/2001/XMLSchema"/>
-        </simpleTypeMakeOgcFilter>
+        </xsl:variable>
+        <xsl:if test="$simpleTypeMakeOgcFilter/*"><!-- display element only if exists filter -->
+            <simpleTypeMakeOgcFilter>
+                <xsl:attribute name="name" select="$build_complexType/element/@name" xpath-default-namespace="http://www.w3.org/2001/XMLSchema"/>
+                <xsl:copy-of select="$simpleTypeMakeOgcFilter"/>
+            </simpleTypeMakeOgcFilter>
+        </xsl:if>
+        
     </xsl:template>
     </xsl:template>
     
     
     <xsl:template mode="p5_tr_map:simpleTypeMakeOgcFilter" match="sequence|complexType" xpath-default-namespace="http://www.w3.org/2001/XMLSchema">
     <xsl:template mode="p5_tr_map:simpleTypeMakeOgcFilter" match="sequence|complexType" xpath-default-namespace="http://www.w3.org/2001/XMLSchema">