Просмотр исходного кода

skladanie xmla z mapy TODO testy z innymi refami z innych klas oraz TODO wydajnosc i walidacja

a.binder 9 лет назад
Родитель
Сommit
9c740b552f

+ 56 - 2
SE/schema/ant-url_action/default_db.crm_proces/CRM_PROCES_tree/build.xml

@@ -58,6 +58,7 @@
     <!--<tempfile property="uuid" deleteonexit="yes"/>-->
     <property name="out_task.dita"  value="${temp}/${uuid}.out_task_dita"/>
     <property name="out_task.dita.final"   value="${temp}/${uuid}.out_task.dita.final"/>
+    <property name="out_task.dita.final_with_RelatedFeatureLoop"   value="${temp}/${uuid}.out_task.dita.final_with_RelatedFeatureLoop"/>
     <!--<tempfile property="wfs_output" deleteonexit="no"  destdir="temp"  suffix=".xml" />-->
     
 
@@ -265,16 +266,51 @@
                     </target>
                     
                     <target name="xml_recursed_from_tr_map" depends="install_folders,uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,check_tr_map" description="Buduje wyjsciowego XMLa na podstawie mapy transportowej dla zastosowan w API DEVEL">
-                        <echo message="OUTPUT__START"/>
+                        <!--<echo message="OUTPUT__START"/>-->
                         
                         <!-- TODO proba wlaczenia rekursywnosci zapisanie wezla do sciezki w folderze-->
                         <!--<copy file="${out_task.dita.final}" tofile="${temp}/${loop_path_recurs}/${uuid_tested}.loop_path.xml" />-->
                         
+                        <!--<loadfile property="out_task.dita.final_no_RelatedFeatureRoot" srcfile="${out_task.dita.final}"/>-->
                         <move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>
+                        <!--<echoxml file="${out_task.dita.final}.xml">
+                            <RelatedFeatureRoot>${out_task.dita.final_no_RelatedFeatureRoot}</RelatedFeatureRoot>
+                        </echoxml>-->
                         
                         <echo>
                             &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final}.xml&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final}.xml&lt;/a&gt;&lt;/br&gt; 
                         </echo>
+                        <!--<echo message="OUTPUT__END"/>-->
+                    </target>
+    
+                    <target name="xml_recursed_from_tr_map_with_RelatedFeatureLoop" depends="xml_recursed_from_tr_map" description="Buduje wyjsciowego XMLa na podstawie mapy transportowej dla zastosowan w API DEVEL - finalne zlozenie z Rekurencja Loop">
+                        <echo message="OUTPUT__START"/>
+                        
+                        <!-- TODO proba wlaczenia rekursywnosci zapisanie wezla do sciezki w folderze-->
+                        <!--<copy file="${out_task.dita.final}" tofile="${temp}/${loop_path_recurs}/${uuid_tested}.loop_path.xml" />-->
+                        
+                        <!--<loadfile property="out_task.dita.final_no_RelatedFeatureRoot" srcfile="${out_task.dita.final}"/>-->
+                        <!--<move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>-->
+                        <!--<echoxml file="${out_task.dita.final}.xml">
+                            <RelatedFeatureRoot>${out_task.dita.final_no_RelatedFeatureRoot}</RelatedFeatureRoot>
+                        </echoxml>-->
+                        
+                        <xslt basedir="./" style="${build_recurse_ant_merge_dita_from_temp.xsl}" in="${main_build_recurse_ant.dita_with_id}"  destdir="./" out="${out_task.dita.final_with_RelatedFeatureLoop}.xml" >
+                            <factory name="net.sf.saxon.TransformerFactoryImpl">    
+                                <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
+                            </factory>
+                            <classpath location="/opt/local/share/java/saxon9he.jar"/>
+                            <!--<param name="webRootUrl" expression="${webRootUrl}" />--> 
+                            <!--<param name="main_build_recurse_ant.dita" expression="${main_build_recurse_ant.dita}"/>-->
+                            <param name="uuid" expression="${uuid_tested}"/>
+                            <!--<param name="basedir" expression="${basedir}"/>-->
+                            <param name="temp" expression="${temp}"/>
+                            <param name="with_RelatedFeatureLoop" expression="true"/>
+                        </xslt>
+                        <echo message="OUTPUT__START"/>
+                        <echo>
+                            &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final_with_RelatedFeatureLoop}.xml&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final_with_RelatedFeatureLoop}.xml&lt;/a&gt;&lt;/br&gt; 
+                        </echo>
                         <echo message="OUTPUT__END"/>
                     </target>
    
@@ -433,10 +469,28 @@
             <param name="uuid" expression="${uuid_tested}"/>
             <!--<param name="basedir" expression="${basedir}"/>-->
             <param name="temp" expression="${temp}"/>
+            <param name="temp" expression="${temp}"/>
         </xslt>
-        <echo> zapisalem plik gotowy do utworzenia dita do ${out_task.dita}. </echo>
+        <echo> zapisalem plik gotowy do utworzenia dita do ${out_task.dita.final}. </echo>
     </target>
 
+    <!--<target name="build_recurse_ant_merge_dita_from_temp.xsl_with_RelatedFeatureLoop" depends="build_recurse_ant_merge_dita_from_temp.xsl" description="z plikow temp/$uuid.* buduje $out_task.dita.final ">
+        <xslt basedir="./" style="${build_recurse_ant_merge_dita_from_temp.xsl}" in="${main_build_recurse_ant.dita_with_id}"  destdir="./" out="${out_task.dita.final_with_RelatedFeatureLoop}" >
+            <factory name="net.sf.saxon.TransformerFactoryImpl">    
+                <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
+            </factory>
+            <classpath location="/opt/local/share/java/saxon9he.jar"/>
+            <!-\-<param name="webRootUrl" expression="${webRootUrl}" />-\-> 
+            <!-\-<param name="main_build_recurse_ant.dita" expression="${main_build_recurse_ant.dita}"/>-\->
+            <param name="uuid" expression="${uuid_tested}"/>
+            <!-\-<param name="basedir" expression="${basedir}"/>-\->
+            <param name="temp" expression="${temp}"/>
+            <param name="with_RelatedFeatureLoop" expression="true"/>
+        </xslt>
+        <echo> zapisalem plik z zagniezdzeniami out_task.dita.final_with_RelatedFeatureLoop gotowy do utworzenia dita do ${out_task.dita.final_with_RelatedFeatureLoop}. </echo>
+    </target>-->
+
+
 
     <target name="buildpdf_recursed" depends="uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,php_session_id_check,check_dita" if="${test_if_dita}">
         <property name="dita.dir" location="/Library/Server/Web/Data/Sites/Default/SE/stuff/dita-ot-2.3.3/bin/dita"/>

+ 56 - 2
SE/schema/ant-url_action/default_db.in7_dziennik_koresp/test-druk/build.xml

@@ -58,6 +58,7 @@
     <!--<tempfile property="uuid" deleteonexit="yes"/>-->
     <property name="out_task.dita"  value="${temp}/${uuid}.out_task_dita"/>
     <property name="out_task.dita.final"   value="${temp}/${uuid}.out_task.dita.final"/>
+    <property name="out_task.dita.final_with_RelatedFeatureLoop"   value="${temp}/${uuid}.out_task.dita.final_with_RelatedFeatureLoop"/>
     <!--<tempfile property="wfs_output" deleteonexit="no"  destdir="temp"  suffix=".xml" />-->
     
 
@@ -265,16 +266,51 @@
                     </target>
                     
                     <target name="xml_recursed_from_tr_map" depends="install_folders,uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,check_tr_map" description="Buduje wyjsciowego XMLa na podstawie mapy transportowej dla zastosowan w API DEVEL">
-                        <echo message="OUTPUT__START"/>
+                        <!--<echo message="OUTPUT__START"/>-->
                         
                         <!-- TODO proba wlaczenia rekursywnosci zapisanie wezla do sciezki w folderze-->
                         <!--<copy file="${out_task.dita.final}" tofile="${temp}/${loop_path_recurs}/${uuid_tested}.loop_path.xml" />-->
                         
+                        <!--<loadfile property="out_task.dita.final_no_RelatedFeatureRoot" srcfile="${out_task.dita.final}"/>-->
                         <move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>
+                        <!--<echoxml file="${out_task.dita.final}.xml">
+                            <RelatedFeatureRoot>${out_task.dita.final_no_RelatedFeatureRoot}</RelatedFeatureRoot>
+                        </echoxml>-->
                         
                         <echo>
                             &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final}.xml&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final}.xml&lt;/a&gt;&lt;/br&gt; 
                         </echo>
+                        <!--<echo message="OUTPUT__END"/>-->
+                    </target>
+    
+                    <target name="xml_recursed_from_tr_map_with_RelatedFeatureLoop" depends="xml_recursed_from_tr_map" description="Buduje wyjsciowego XMLa na podstawie mapy transportowej dla zastosowan w API DEVEL - finalne zlozenie z Rekurencja Loop">
+                        <echo message="OUTPUT__START"/>
+                        
+                        <!-- TODO proba wlaczenia rekursywnosci zapisanie wezla do sciezki w folderze-->
+                        <!--<copy file="${out_task.dita.final}" tofile="${temp}/${loop_path_recurs}/${uuid_tested}.loop_path.xml" />-->
+                        
+                        <!--<loadfile property="out_task.dita.final_no_RelatedFeatureRoot" srcfile="${out_task.dita.final}"/>-->
+                        <!--<move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>-->
+                        <!--<echoxml file="${out_task.dita.final}.xml">
+                            <RelatedFeatureRoot>${out_task.dita.final_no_RelatedFeatureRoot}</RelatedFeatureRoot>
+                        </echoxml>-->
+                        
+                        <xslt basedir="./" style="${build_recurse_ant_merge_dita_from_temp.xsl}" in="${main_build_recurse_ant.dita_with_id}"  destdir="./" out="${out_task.dita.final_with_RelatedFeatureLoop}.xml" >
+                            <factory name="net.sf.saxon.TransformerFactoryImpl">    
+                                <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
+                            </factory>
+                            <classpath location="/opt/local/share/java/saxon9he.jar"/>
+                            <!--<param name="webRootUrl" expression="${webRootUrl}" />--> 
+                            <!--<param name="main_build_recurse_ant.dita" expression="${main_build_recurse_ant.dita}"/>-->
+                            <param name="uuid" expression="${uuid_tested}"/>
+                            <!--<param name="basedir" expression="${basedir}"/>-->
+                            <param name="temp" expression="${temp}"/>
+                            <param name="with_RelatedFeatureLoop" expression="true"/>
+                        </xslt>
+                        <echo message="OUTPUT__START"/>
+                        <echo>
+                            &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final_with_RelatedFeatureLoop}.xml&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final_with_RelatedFeatureLoop}.xml&lt;/a&gt;&lt;/br&gt; 
+                        </echo>
                         <echo message="OUTPUT__END"/>
                     </target>
    
@@ -433,10 +469,28 @@
             <param name="uuid" expression="${uuid_tested}"/>
             <!--<param name="basedir" expression="${basedir}"/>-->
             <param name="temp" expression="${temp}"/>
+            <param name="temp" expression="${temp}"/>
         </xslt>
-        <echo> zapisalem plik gotowy do utworzenia dita do ${out_task.dita}. </echo>
+        <echo> zapisalem plik gotowy do utworzenia dita do ${out_task.dita.final}. </echo>
     </target>
 
+    <!--<target name="build_recurse_ant_merge_dita_from_temp.xsl_with_RelatedFeatureLoop" depends="build_recurse_ant_merge_dita_from_temp.xsl" description="z plikow temp/$uuid.* buduje $out_task.dita.final ">
+        <xslt basedir="./" style="${build_recurse_ant_merge_dita_from_temp.xsl}" in="${main_build_recurse_ant.dita_with_id}"  destdir="./" out="${out_task.dita.final_with_RelatedFeatureLoop}" >
+            <factory name="net.sf.saxon.TransformerFactoryImpl">    
+                <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
+            </factory>
+            <classpath location="/opt/local/share/java/saxon9he.jar"/>
+            <!-\-<param name="webRootUrl" expression="${webRootUrl}" />-\-> 
+            <!-\-<param name="main_build_recurse_ant.dita" expression="${main_build_recurse_ant.dita}"/>-\->
+            <param name="uuid" expression="${uuid_tested}"/>
+            <!-\-<param name="basedir" expression="${basedir}"/>-\->
+            <param name="temp" expression="${temp}"/>
+            <param name="with_RelatedFeatureLoop" expression="true"/>
+        </xslt>
+        <echo> zapisalem plik z zagniezdzeniami out_task.dita.final_with_RelatedFeatureLoop gotowy do utworzenia dita do ${out_task.dita.final_with_RelatedFeatureLoop}. </echo>
+    </target>-->
+
+
 
     <target name="buildpdf_recursed" depends="uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,php_session_id_check,check_dita" if="${test_if_dita}">
         <property name="dita.dir" location="/Library/Server/Web/Data/Sites/Default/SE/stuff/dita-ot-2.3.3/bin/dita"/>

+ 56 - 2
SE/schema/ant-url_action/default_db.in7_dziennik_koresp/umowa/build.xml

@@ -58,6 +58,7 @@
     <!--<tempfile property="uuid" deleteonexit="yes"/>-->
     <property name="out_task.dita"  value="${temp}/${uuid}.out_task_dita"/>
     <property name="out_task.dita.final"   value="${temp}/${uuid}.out_task.dita.final"/>
+    <property name="out_task.dita.final_with_RelatedFeatureLoop"   value="${temp}/${uuid}.out_task.dita.final_with_RelatedFeatureLoop"/>
     <!--<tempfile property="wfs_output" deleteonexit="no"  destdir="temp"  suffix=".xml" />-->
     
 
@@ -265,16 +266,51 @@
                     </target>
                     
                     <target name="xml_recursed_from_tr_map" depends="install_folders,uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,check_tr_map" description="Buduje wyjsciowego XMLa na podstawie mapy transportowej dla zastosowan w API DEVEL">
-                        <echo message="OUTPUT__START"/>
+                        <!--<echo message="OUTPUT__START"/>-->
                         
                         <!-- TODO proba wlaczenia rekursywnosci zapisanie wezla do sciezki w folderze-->
                         <!--<copy file="${out_task.dita.final}" tofile="${temp}/${loop_path_recurs}/${uuid_tested}.loop_path.xml" />-->
                         
+                        <!--<loadfile property="out_task.dita.final_no_RelatedFeatureRoot" srcfile="${out_task.dita.final}"/>-->
                         <move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>
+                        <!--<echoxml file="${out_task.dita.final}.xml">
+                            <RelatedFeatureRoot>${out_task.dita.final_no_RelatedFeatureRoot}</RelatedFeatureRoot>
+                        </echoxml>-->
                         
                         <echo>
                             &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final}.xml&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final}.xml&lt;/a&gt;&lt;/br&gt; 
                         </echo>
+                        <!--<echo message="OUTPUT__END"/>-->
+                    </target>
+    
+                    <target name="xml_recursed_from_tr_map_with_RelatedFeatureLoop" depends="xml_recursed_from_tr_map" description="Buduje wyjsciowego XMLa na podstawie mapy transportowej dla zastosowan w API DEVEL - finalne zlozenie z Rekurencja Loop">
+                        <echo message="OUTPUT__START"/>
+                        
+                        <!-- TODO proba wlaczenia rekursywnosci zapisanie wezla do sciezki w folderze-->
+                        <!--<copy file="${out_task.dita.final}" tofile="${temp}/${loop_path_recurs}/${uuid_tested}.loop_path.xml" />-->
+                        
+                        <!--<loadfile property="out_task.dita.final_no_RelatedFeatureRoot" srcfile="${out_task.dita.final}"/>-->
+                        <!--<move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>-->
+                        <!--<echoxml file="${out_task.dita.final}.xml">
+                            <RelatedFeatureRoot>${out_task.dita.final_no_RelatedFeatureRoot}</RelatedFeatureRoot>
+                        </echoxml>-->
+                        
+                        <xslt basedir="./" style="${build_recurse_ant_merge_dita_from_temp.xsl}" in="${main_build_recurse_ant.dita_with_id}"  destdir="./" out="${out_task.dita.final_with_RelatedFeatureLoop}.xml" >
+                            <factory name="net.sf.saxon.TransformerFactoryImpl">    
+                                <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
+                            </factory>
+                            <classpath location="/opt/local/share/java/saxon9he.jar"/>
+                            <!--<param name="webRootUrl" expression="${webRootUrl}" />--> 
+                            <!--<param name="main_build_recurse_ant.dita" expression="${main_build_recurse_ant.dita}"/>-->
+                            <param name="uuid" expression="${uuid_tested}"/>
+                            <!--<param name="basedir" expression="${basedir}"/>-->
+                            <param name="temp" expression="${temp}"/>
+                            <param name="with_RelatedFeatureLoop" expression="true"/>
+                        </xslt>
+                        <echo message="OUTPUT__START"/>
+                        <echo>
+                            &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final_with_RelatedFeatureLoop}.xml&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final_with_RelatedFeatureLoop}.xml&lt;/a&gt;&lt;/br&gt; 
+                        </echo>
                         <echo message="OUTPUT__END"/>
                     </target>
    
@@ -433,10 +469,28 @@
             <param name="uuid" expression="${uuid_tested}"/>
             <!--<param name="basedir" expression="${basedir}"/>-->
             <param name="temp" expression="${temp}"/>
+            <param name="temp" expression="${temp}"/>
         </xslt>
-        <echo> zapisalem plik gotowy do utworzenia dita do ${out_task.dita}. </echo>
+        <echo> zapisalem plik gotowy do utworzenia dita do ${out_task.dita.final}. </echo>
     </target>
 
+    <!--<target name="build_recurse_ant_merge_dita_from_temp.xsl_with_RelatedFeatureLoop" depends="build_recurse_ant_merge_dita_from_temp.xsl" description="z plikow temp/$uuid.* buduje $out_task.dita.final ">
+        <xslt basedir="./" style="${build_recurse_ant_merge_dita_from_temp.xsl}" in="${main_build_recurse_ant.dita_with_id}"  destdir="./" out="${out_task.dita.final_with_RelatedFeatureLoop}" >
+            <factory name="net.sf.saxon.TransformerFactoryImpl">    
+                <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
+            </factory>
+            <classpath location="/opt/local/share/java/saxon9he.jar"/>
+            <!-\-<param name="webRootUrl" expression="${webRootUrl}" />-\-> 
+            <!-\-<param name="main_build_recurse_ant.dita" expression="${main_build_recurse_ant.dita}"/>-\->
+            <param name="uuid" expression="${uuid_tested}"/>
+            <!-\-<param name="basedir" expression="${basedir}"/>-\->
+            <param name="temp" expression="${temp}"/>
+            <param name="with_RelatedFeatureLoop" expression="true"/>
+        </xslt>
+        <echo> zapisalem plik z zagniezdzeniami out_task.dita.final_with_RelatedFeatureLoop gotowy do utworzenia dita do ${out_task.dita.final_with_RelatedFeatureLoop}. </echo>
+    </target>-->
+
+
 
     <target name="buildpdf_recursed" depends="uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,php_session_id_check,check_dita" if="${test_if_dita}">
         <property name="dita.dir" location="/Library/Server/Web/Data/Sites/Default/SE/stuff/dita-ot-2.3.3/bin/dita"/>

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

@@ -586,15 +586,73 @@
         <xsl:param name="xpath_value_dita" required="yes"/>
         <!--<xsl:param name="loop_path_recurs" required="yes"/>-->
         <!-- wygenerujemy liste ant -->
+        
+        <xsl:comment>
+            #590 LOOP BEGIN</xsl:comment>
         <echo> #523 RelatedFeatureLoop ant bede odpalac w podkatalogu:@xml_id=(<xsl:value-of select="@xml_id"/>) 
             <xsl:value-of select="concat($temp,'/',@xml_id,'/',$uuid,'.build_',$loop_xpath,'_x2f_.',@xml_id,'.',substring-after(@typeName,':'),'.1.xml')"/> </echo>
         <xsl:message>#591 todo executing by exec instead of ant without inheritAll because it's looping!!! </xsl:message>
-        <exec command="/opt/local/bin/ant" dir="{$temp}" failifexecutionfails="true">
-            <!--<arg line="-f ${builds_to_ant_file.xml}"/>-->
+        
+        <!-- Lista do wyzwolenia dzieci w podkalagach na bazie params-->
+        
+        
+        <echo> #596 ant szukam fileset id=builds_to_ant w <xsl:value-of select="concat($uuid,'.build_',$loop_xpath,'_x2f_.',@xml_id,'.',substring-after(@typeName,':'),'.*.xml')"/> </echo>
+        <dirset id="builds_to_ant{$loop_xpath_real}{@xml_id}" dir="{$temp}" includes="{@xml_id}.{$uuid}.*" />
+        <property name="builds_to_ant{$loop_xpath_real}{@xml_id}" refid="builds_to_ant{$loop_xpath_real}{@xml_id}"/>
+        <!--<tempfile property="builds_to_ant.xml" deleteonexit="no" destdir="temp" suffix=".xml" prefix="${uuid}.builds_to_ant-"/>-->
+        <xsl:element name="tempfile">
+            <xsl:attribute name="property" select="concat('builds_to_ant.xml',$loop_xpath_real,@xml_id)"/>
+            <xsl:attribute name="deleteonexit" select="'no'"/>
+            <xsl:attribute name="destdir" select="$temp"/>
+            <xsl:attribute name="suffix" select="'.xml'"/>
+            <xsl:attribute name="prefix" select="concat('${uuid}.builds_to_ant-loop-',@xml_id,'-')"/>
+        </xsl:element>
+        <!--<tempfile property="builds_to_ant_file.xml" deleteonexit="no" destdir="temp" suffix=".xml" prefix="${uuid}.build_to_ant_file-"/>-->
+        <xsl:element name="tempfile">
+            <xsl:attribute name="property" select="concat('builds_to_ant_file.xml',$loop_xpath_real,@xml_id)"/>
+            <xsl:attribute name="deleteonexit" select="'no'"/>
+            <xsl:attribute name="destdir" select="$temp"/>
+            <xsl:attribute name="suffix" select="'.xml'"/>
+            <xsl:attribute name="prefix" select="concat('${uuid}.build_to_ant_file-loop-',@xml_id,'-')"/>
+        </xsl:element>
+        <echo>#615 ant do: builds_to_ant.xml=${builds_to_ant_file.xml} mode="place_subant" match="RelatedFeature" </echo>
+        <!--<echoxml file="'${builds_to_ant.xml}'"><builds_to_ant>${builds_to_ant}</builds_to_ant></echoxml>-->
+        <xsl:element name="echoxml">
+            <xsl:attribute name="file" select="concat('${builds_to_ant.xml',$loop_xpath_real,@xml_id,'}')"/>
+            <builds_to_ant>${builds_to_ant<xsl:value-of select="concat($loop_xpath_real,@xml_id)"/>}</builds_to_ant>
+        </xsl:element>
+        <xsl:element name="xslt">
+            <xsl:attribute name="basedir" select="'./'"/>
+            <xsl:attribute name="style" select="$builds_to_ant.xsl"/>
+            <xsl:attribute name="in" select="concat('${builds_to_ant.xml',$loop_xpath_real,@xml_id,'}')"/>
+            <xsl:attribute name="destdir" select="'./'"/>
+            <xsl:attribute name="out" select="concat('${builds_to_ant_file.xml',$loop_xpath_real,@xml_id,'}')"/>
+            <factory name="net.sf.saxon.TransformerFactoryImpl">
+                <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
+                <attribute name="http://saxon.sf.net/feature/initialMode" value="exec"/>
+            </factory>
+            <param name="temp" expression="{$temp}"/>
+            <param name="loop_xpath_real" expression="{$loop_xpath_real}{@xml_id}"/>
+            <!--<xsl:element name="param">
+                <xsl:attribute name="name" select="'default_antfile'"/>
+                <xsl:attribute name="expression" select="concat($temp,'/',$builds_to_ant_file.xml"/>
+            </xsl:element>-->
+            <param name="default_antfile" expression="{$temp}/{$uuid}.build_{$loop_xpath}_x2f_.{@xml_id}.{ substring-after(@typeName,':') }.1.xml"/>
+            <classpath location="/opt/local/share/java/saxon9he.jar"/>
+        </xsl:element>
+        
+        <xsl:element name="ant">
+            <xsl:attribute name="antfile" select="concat('${builds_to_ant_file.xml',$loop_xpath_real,@xml_id,'}')"/>
+        </xsl:element>
+        
+        <!-- EOF Lista do wyzwolenia dzieci -->
+
+        <!--<exec command="/opt/local/bin/ant" dir="{$temp}" failifexecutionfails="true">
+            <!-\-<arg line="-f ${builds_to_ant_file.xml}"/>-\->
             <xsl:element name="arg">
                 <xsl:attribute name="line" select="concat('-f ',@xml_id,'/',$uuid,'.build_',$loop_xpath,'_x2f_.',@xml_id,'.',substring-after(@typeName,':'),'.1.xml')"/>
             </xsl:element>
-        </exec>
+        </exec>-->
         <!--<xsl:element name="ant">
             <xsl:attribute name="antfile" select="concat($temp,'/',@xml_id,'/',$uuid,'.build_',$loop_xpath,'_x2f_.',@xml_id,'.',substring-after(@typeName,':'),'.1.xml')"/>
             <xsl:attribute name="inheritAll" select="'false'"/>
@@ -603,6 +661,8 @@
             <property name="xpath_value_dita" value="{$xpath_value_dita}"/>
         </xsl:element>-->
         <!--<ant antfile="{$temp}/${builds_to_ant_file.xml}" dir="."/>-->
+        <xsl:comment>#590 LOOP END
+        </xsl:comment>
     </xsl:template>
    
     <xsl:template mode="place_subant" match="*">
@@ -1067,12 +1127,12 @@
         <xsl:variable name="loop_path_recurs">
             <xsl:choose>
                 <xsl:when test=" string-length($loop_path_recurs) &lt;1">
-                    <xsl:value-of select="concat('/',@xml_id)"/>
+                    <xsl:value-of select="concat('/',@xml_id,'.',$uuid,'.',$feature_pos)"/>
                 </xsl:when>
-                <xsl:otherwise><xsl:value-of select="concat($loop_path_recurs,'/',@xml_id)"/></xsl:otherwise>
+                <xsl:otherwise><xsl:value-of select="concat($loop_path_recurs,'/',@xml_id,'.',$uuid,'.',$feature_pos)"/></xsl:otherwise>
             </xsl:choose>
         </xsl:variable>
-        <xsl:result-document href="{$temp}/{@xml_id}/{$uuid}.build_{$loop_xpath}.{$feature_pos}.xml" >
+        <xsl:result-document href="{$temp}/{@xml_id}.{$uuid}.{$feature_pos}/build_root.xml" >
             <xsl:apply-templates select=".">
                 <xsl:with-param name="typeName" select="@typeName"/>
                 <xsl:with-param name="xpath" select="@xpath"/>
@@ -1087,7 +1147,7 @@
                 <!--<xsl:with-param name="wfs_output.xml" />-->
             </xsl:apply-templates>
         </xsl:result-document>
-        <xsl:element name="RelatedFeature">
+        <xsl:element name="RelatedFeatureLoop">
             <xsl:copy-of select="@*"/>
             <xsl:attribute name="featureID_name" select="$featureID_name"/>
             <xsl:attribute name="loop_xpath" select="$loop_xpath"/>

+ 195 - 15
SE/schema/default_db_xml_cache.public/build_recurse_ant_merge_dita_from_temp.xsl

@@ -17,26 +17,44 @@
     <xsl:param name="uuid" required="yes"/>
     <!--<xsl:param name="basedir" required="yes"/>-->
     <xsl:param name="temp" required="yes"/>
-    
+    <xsl:param name="with_RelatedFeatureLoop" select="false()"/>
     <!-- template do zlaczenia wszystkich xmli z danymi z dita 
     description="z plikow temp/$uuid.* buduje $out_task.dita " -->
     
-    <xsl:template name="get_childs_rows">
-        <xsl:param name="element-filename"  required="yes"/> <!-- prezes1.root_x2f_.d1e1.CRM_PROCES_x2f_.d1e46.CRM_WSKAZNIK_x2f_.d1e51.CRM_LISTA_ZASOBOW.1. -->
-        <xsl:param name="path2collection" select="concat($temp,'/')"/> <!-- $basedir,'/' -->
+    <!--<xsl:template name="get_childs_rows">
+        <xsl:param name="element-filename"  required="yes"/> <!-\- prezes1.root_x2f_.d1e1.CRM_PROCES_x2f_.d1e46.CRM_WSKAZNIK_x2f_.d1e51.CRM_LISTA_ZASOBOW.1. -\->
+        <xsl:param name="path2collection" select="concat($temp,'/')"/> <!-\- $basedir,'/' -\->
         <xsl:variable name="path">
-            <xsl:value-of select="concat($path2collection,'?select=',$element-filename,'*.dita.xml.vals.dita')"/> <!-- $element-filename,'-->
+            <xsl:value-of select="concat($path2collection,'?select=',$element-filename,'*.dita.xml.vals.dita')"/> <!-\- $element-filename,'-\->
         </xsl:variable>
         <xsl:message>#30 otwieram kolekcje $path=<xsl:value-of select="$path"/>; </xsl:message>
         
-        <!--<xsl:variable name="docs" select="collection($path)"/>-->
-        <!--<xsl:variable name="docs" select="collection($path)"/>-->
-        <!--<xsl:for-each select="$docs">
+        <!-\-<xsl:variable name="docs" select="collection($path)"/>-\->
+        <!-\-<xsl:variable name="docs" select="collection($path)"/>-\->
+        <!-\-<xsl:for-each select="$docs">
             <xsl:message>#35 test - cos jest <xsl:value-of select="name()"/></xsl:message>
             <xsl:copy-of select="."/>
-        </xsl:for-each>-->
+        </xsl:for-each>-\->
         <xsl:copy-of select="collection($path)"/>
-    </xsl:template>
+    </xsl:template>-->
+    
+    
+    <!--<xsl:template name="RelatedFeatureLoop">
+        <xsl:param name="element-filename"  required="yes"/> <!-\- prezes1.root_x2f_.d1e1.CRM_PROCES_x2f_.d1e46.CRM_WSKAZNIK_x2f_.d1e51.CRM_LISTA_ZASOBOW.1. -\->
+        <xsl:param name="path2collection" select="concat($temp,'/')"/> <!-\- $basedir,'/' -\->
+        <xsl:variable name="path">
+            <xsl:value-of select="concat($path2collection,'?select=',$element-filename,'*.dita.xml.vals.dita')"/> <!-\- $element-filename,'-\->
+        </xsl:variable>
+        <xsl:message>#30 otwieram kolekcje $path=<xsl:value-of select="$path"/>; </xsl:message>
+        
+        <!-\-<xsl:variable name="docs" select="collection($path)"/>-\->
+        <!-\-<xsl:variable name="docs" select="collection($path)"/>-\->
+        <!-\-<xsl:for-each select="$docs">
+            <xsl:message>#35 test - cos jest <xsl:value-of select="name()"/></xsl:message>
+            <xsl:copy-of select="."/>
+        </xsl:for-each>-\->
+        <xsl:copy-of select="collection($path)"/>
+    </xsl:template>-->
     
     <xsl:template match="*" mode="root">
         <xsl:param name="loop_xpath"/>
@@ -79,6 +97,7 @@
         <!-- podstawamy dane z xml na podstawie path -->
         <xsl:param name="loop_xpath" select="'root'"/>
         <xsl:param name="feature_pos_child"  select="1"/> <!-- pierwsze wyzwolenie narzuca 1 - kolejne sa z related -->
+        <xsl:param name="dita_with_id" select="."/>
         <xsl:variable name="xml_id" select="@xml_id"/>
         <xsl:variable name="RelatedFeaturePos" select="position()"/>
         <xsl:variable name="featureID_name" select="substring-after(@typeName,':')"/>
@@ -113,16 +132,170 @@
         <!--<debug_RelatedFeature>
             <xsl:copy-of select="$dita_fragment"/>
         </debug_RelatedFeature>-->
+        <RelatedFeatureRoot>
+                <xsl:for-each select="$dita_fragment">
+                    <xsl:apply-templates mode="RelatedFeature" select="$dita_fragment/RelatedFeatureRoot/*">
+                        <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
+                        <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
+                    </xsl:apply-templates>
+                </xsl:for-each>
+        </RelatedFeatureRoot>
+
+    </xsl:template>
+    
+    
+    <xsl:template match="RelatedFeatureLoop" mode="RelatedFeatureChild">
+        <!-- podstawamy dane z xml na podstawie path -->
+        <xsl:param name="path" select="$temp"/> <!-- budowa sciezki do wchodzenia do struktur - domyslnie zaczyna sie od $temp-->
+        <xsl:param name="feature_pos_child"  select="1"/>
+        <xsl:param name="dita_with_id" required="yes"/>
         
-        <xsl:for-each select="$dita_fragment">
-            <xsl:apply-templates mode="RelatedFeature" select="$dita_fragment/RelatedFeatureRoot/*">
-                <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
-            </xsl:apply-templates>
-        </xsl:for-each>
+        <xsl:if test="$with_RelatedFeatureLoop">
+                    <xsl:variable name="xml_id" select="@xml_id"/>
+                    <xsl:variable name="RelatedFeaturePos" select="position()"/>
+                    <xsl:variable name="featureID_name" select="substring-after(@typeName,':')"/>
+                    <xsl:variable name="system_cache__appinfo:loop_id" select="@system_cache__appinfo:loop_id"/>
+                    <xsl:variable name="path">
+                        <xsl:value-of select="concat($path,'/',$xml_id,'.',$uuid,'.',$feature_pos_child)"/> 
+                    </xsl:variable>
+                    
+                    <xsl:message>#157 RelatedFeatureLoop $path=<xsl:value-of select="$path"/>; $xml_id=<xsl:value-of select="$xml_id"/>; $RelatedFeaturePos=<xsl:value-of select="$RelatedFeaturePos"/>; $feature_pos_child=<xsl:value-of select="$feature_pos_child"/>;</xsl:message>
+                    <!--<debug26>
+                        Will try to put file=<xsl:value-of select="concat($uuid,'.',$loop_xpath,$featureID_name,'.',$RelatedFeaturePos,'.dita.xml.vals.dita')"/>;
+                    </debug26>-->
+                    <!--<xsl:variable name="dita_fragment" select="doc(concat($basedir,'/temp/',$uuid,'.',$loop_xpath,'.',$RelatedFeaturePos,'.dita.xml.vals.dita'))"/>-->
+                    
+                    <xsl:variable name="dita_fragment">
+                        <xsl:choose>
+                            <xsl:when test=" doc-available(concat($temp,'/',$xml_id,'.',$uuid,'.',$feature_pos_child,'/',$uuid,'.out_task.dita.final.xml'))">
+                                <xsl:message>#156 INFO Related leaf xml file <xsl:value-of select="concat($temp,'/',$xml_id,'.',$uuid,'.',$feature_pos_child,'/',$uuid,'.out_task.dita.final.xml')"/></xsl:message>
+                                <xsl:copy-of select="doc(concat($temp,'/',$xml_id,'.',$uuid,'.',$feature_pos_child,'/',$uuid,'.out_task.dita.final.xml'))"/>
+                            </xsl:when>
+                            <xsl:otherwise>
+                                <xsl:comment>#156 INFO no Related leaf xml file <xsl:value-of select="concat($temp,'/',$xml_id,'.',$uuid,'.',$feature_pos_child,'/',$uuid,'.out_task.dita.final.xml')"/>;</xsl:comment>
+                                <xsl:message>#156 INFO no Related leaf xml file <xsl:value-of select="concat($temp,'/',$xml_id,'.',$uuid,'.',$feature_pos_child,'/',$uuid,'.out_task.dita.final.xml')"/></xsl:message>
+                            </xsl:otherwise>
+                        </xsl:choose>
+                    </xsl:variable>
+                        <!--<Loop_dita_fragment>
+                            <xsl:copy-of select="$dita_fragment"/>
+                        </Loop_dita_fragment>-->
+                    <xsl:comment>#180 loop $xml_id=<xsl:value-of select="$xml_id"/>; $RelatedFeaturePos=<xsl:value-of select="$RelatedFeaturePos"/>;  </xsl:comment>
+                    
+                    <xsl:for-each select="$dita_fragment">
+                        <xsl:for-each select="$dita_fragment">
+                            <xsl:apply-templates mode="RelatedFeatureLoop" select="$dita_fragment/RelatedFeatureRoot">
+                                <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
+                                <xsl:with-param name="xml_id" select="$xml_id"/>
+                                <xsl:with-param name="path" select="$path"/>
+                                <!--<xsl:with-param name="system_cache__appinfo:loop_id" select="$system_cache__appinfo:loop_id"/>-->
+                            </xsl:apply-templates>
+                        </xsl:for-each>
+                    </xsl:for-each>
+                    <!--<xsl:variable name="dita_fragment" select="doc(concat($basedir,'/temp/',$uuid,'.',$loop_xpath,'.',$RelatedFeaturePos,'.',$feature_pos_child,'.dita.xml.vals.dita'))"/>-->
+                    <!--<xsl:variable name="dita_fragment">
+                        <xsl:call-template name="get_childs_rows">
+                            <xsl:with-param name="element-filename" select="concat($uuid,'.',$loop_xpath,'.',$RelatedFeaturePos,'.')"/>
+                        </xsl:call-template>
+                    </xsl:variable>-->
+                    
+                    <!--<debug_RelatedFeature>
+                        <xsl:copy-of select="$dita_fragment"/>
+                    </debug_RelatedFeature>-->
+        </xsl:if>
+    </xsl:template>
+    
+    <xsl:template match="RelatedFeatureRoot" mode="RelatedFeatureLoop"><!-- zejscie po $dita_with_id z powrotem w czasie przetwarzania loop  -->
+        <xsl:param name="path" required="yes"/>
+        <xsl:param name="dita_with_id" required="yes"/>
+        <xsl:param name="xml_id" required="yes"/>
+        <!--<xsl:param name="system_cache__appinfo:loop_id" required="yes"/>-->
+        <!--<dita_with_id>
+            <xsl:copy-of select="$dita_with_id"/>
+        </dita_with_id>-->
+        <!--<RelatedFeatureLoop>-->
+            <xsl:comment>#211  $path=<xsl:value-of select="$path"/>; </xsl:comment>
+            <!--<xsl:copy-of select="."/>-->
+
+            <xsl:for-each select="*">
+                <xsl:variable name="loop_pos" select="position()"/>
+                <xsl:variable name="current" select="."/>
+                <xsl:variable name="find_Child_RelatedFeatureLoop"><!-- tutaj dowiemy sie jakie moga byc odgalezienia do wstawienia -->
+                    <find_Child_RelatedFeatureLoop>
+                        <xsl:apply-templates mode="find_Child_RelatedFeatureLoop" select="$dita_with_id"/>
+                    </find_Child_RelatedFeatureLoop>
+                </xsl:variable>
+                
+                <!--<find_Child_RelatedFeatureLoop>
+                    <xsl:copy-of select="$find_Child_RelatedFeatureLoop"/>
+                </find_Child_RelatedFeatureLoop>-->
+                <!--<test>-->
+                    <xsl:element name="{$current/name()}">
+                        <!--<current>-->
+                        <xsl:for-each select="$current/*">
+                            <xsl:choose>
+                                <xsl:when test="name()='RelatedFeatureRoot'"/>                                
+                                <xsl:otherwise><xsl:copy-of select="."/></xsl:otherwise>
+                            </xsl:choose>
+                        </xsl:for-each>
+                            
+                        <!--</current>-->
+                        <xsl:for-each select="$find_Child_RelatedFeatureLoop/find_Child_RelatedFeatureLoop/RelatedFeatureLoop">
+                            
+                            <xsl:variable name="path">
+                                <xsl:value-of select="concat($path,'/',@xml_id,'.',$uuid,'.',$loop_pos)"/> 
+                            </xsl:variable>
+                            <xsl:comment>#220 $path=<xsl:value-of select="$path"/>;  </xsl:comment>
+                            <xsl:variable name="dita_fragment">
+                                <xsl:choose>
+                                    <xsl:when test=" doc-available(concat($path,'/',$uuid,'.out_task.dita.final.xml'))">
+                                        <xsl:message>#221 INFO Related leaf xml file <xsl:value-of select="concat($path,'/',$uuid,'.out_task.dita.final.xml')"/></xsl:message>
+                                        <xsl:copy-of select="doc(concat($path,'/',$uuid,'.out_task.dita.final.xml'))"/>
+                                    </xsl:when>
+                                    <xsl:otherwise>
+                                        <xsl:comment>#221 INFO no Related leaf xml file <xsl:value-of select="concat($path,'/',$uuid,'.out_task.dita.final.xml')"/>;</xsl:comment>
+                                        <xsl:message>#221 INFO no Related leaf xml file <xsl:value-of select="concat($path,'/',$uuid,'.out_task.dita.final.xml')"/></xsl:message>
+                                    </xsl:otherwise>
+                                </xsl:choose>
+                            </xsl:variable>
+                            
+                              
+                                <!--<dita>-->
+                                <!--<xsl:copy-of select="$dita_fragment/RelatedFeatureRoot/*"/>-->
+                                <!--</dita>-->
+                                <!--<child_recurs>-->
+                                    <xsl:apply-templates select="$dita_fragment" mode="RelatedFeatureLoop">
+                                                    <xsl:with-param name="path" select="$path"/>
+                                                    <xsl:with-param name="feature_pos_child"  select="$loop_pos"/>
+                                                    <xsl:with-param name="dita_with_id"  select="$dita_with_id"/>
+                                                    <xsl:with-param name="xml_id" select="@xml_id"/>
+                                     </xsl:apply-templates>
+                                <!--</child_recurs>-->
+                            <!-- cofniecie sie do wlasciwego dita_with_id -->
+                        </xsl:for-each>
+                    </xsl:element>
+                <!--</test>-->
+                                   
+            </xsl:for-each>
+        <!--</RelatedFeatureLoop>-->
+    </xsl:template>
+    
+    
+    <xsl:template mode="find_Child_RelatedFeatureLoop" match="*|text()|comment()">
+        <xsl:apply-templates mode="find_Child_RelatedFeatureLoop"/>
     </xsl:template>
     
+    <xsl:template mode="find_Child_RelatedFeatureLoop" match="RelatedFeatureLoop">
+        <xsl:element name="{name()}">
+            <xsl:copy-of select="@*"/>
+        </xsl:element>
+    </xsl:template>
+    
+    
+    
     <xsl:template mode="RelatedFeature" match="*">
         <xsl:param name="loop_xpath" required="yes"/>
+        <xsl:param name="dita_with_id" required="yes"/>
         <!--<xsl:element name="{name()}">-->
             <!--<xsl:copy-of select="@*"/>-->
             <!--<xsl:apply-templates select="@*"/>-->
@@ -130,6 +303,7 @@
             <xsl:apply-templates mode="RelatedFeatureChild" select=".">
                 <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
                 <xsl:with-param name="feature_pos_child" select="position()"/>
+                <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
             </xsl:apply-templates>
         <!--</xsl:element>-->
     </xsl:template>
@@ -137,12 +311,14 @@
     <xsl:template mode="RelatedFeatureChild" match="*">
         <xsl:param name="loop_xpath" required="yes"/>
         <xsl:param name="feature_pos_child" required="yes"/>
+        <xsl:param name="dita_with_id" required="yes"/>
         <xsl:element name="{name()}">
             <!--<xsl:copy-of select="@*"/>-->
             <xsl:apply-templates select="@*"/>
             <xsl:apply-templates mode="RelatedFeatureChild">
                 <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
                 <xsl:with-param name="feature_pos_child" select="$feature_pos_child"/>
+                <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
             </xsl:apply-templates>
         </xsl:element>
     </xsl:template>
@@ -150,20 +326,24 @@
     <xsl:template mode="RelatedFeatureChild" match="RelatedFeature">
         <xsl:param name="loop_xpath" required="yes"/>
         <xsl:param name="feature_pos_child" required="yes"/>
+        <xsl:param name="dita_with_id"  required="yes"/>
         <xsl:apply-templates select=".">
             <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
             <xsl:with-param name="feature_pos_child" select="$feature_pos_child"/>
+            <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
         </xsl:apply-templates>
     </xsl:template>
     
     <xsl:template match="*" >
         <xsl:param name="loop_xpath"/>
         <xsl:param name="feature_pos_child" required="yes"/>
+        <xsl:param name="dita_with_id" required="yes"/>
         <xsl:element name="{name()}">
             <xsl:copy-of select="@*"/>
             <xsl:apply-templates>
                 <xsl:with-param name="loop_xpath" select="$loop_xpath"/>
                 <xsl:with-param name="feature_pos_child" select="$feature_pos_child"/>
+                <xsl:with-param name="dita_with_id" select="$dita_with_id"/>
             </xsl:apply-templates>
         </xsl:element>
     </xsl:template>

+ 36 - 0
SE/schema/default_db_xml_cache.public/builds_to_ant.xsl

@@ -13,6 +13,7 @@
     <xsl:param name="default_antfile"/>
     <!--<xsl:param name="loop_xpath" required="yes"/>-->
     <xsl:param name="loop_xpath_real" required="yes"/>
+    
     <xsl:template match="builds_to_ant">
         <project xmlns:gml="http://www.opengis.net/gml"
             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
@@ -43,4 +44,39 @@
         </project>
     </xsl:template>
     
+    
+    <xsl:template match="builds_to_ant" mode="exec">
+        <project xmlns:gml="http://www.opengis.net/gml"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xmlns:xlink="http://www.w3.org/1999/xlink"
+            xmlns:p5_default_db="https://biuro.biall-net.pl/wfs/default_db"
+            xmlns:wfs="http://www.opengis.net/wfs"
+            xmlns:ogc="http://www.opengis.net/ogc"
+            xmlns:system_cache__appinfo="http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/appinfo.xsd"
+            basedir="../."
+            name="builds_to_ant_proj{$loop_xpath_real}"
+            default="builds_to_ant{$loop_xpath_real}">
+            <target name="builds_to_ant{$loop_xpath_real}">
+                <xsl:comment> default_antfile: <xsl:value-of select="$default_antfile"/> ; </xsl:comment>
+                
+                <xsl:for-each select="tokenize(.,';')">
+                    <echo>
+                        #
+                        #    
+                        #
+                        #
+                        builds_to_ant - za chwile uruchomie antfile  exec temp/<xsl:value-of select="."/>;
+                        #
+                        #
+                    </echo>
+                    <exec command="/opt/local/bin/ant" dir="{$temp}" failifexecutionfails="true">
+                        <xsl:element name="arg">
+                            <xsl:attribute name="line" select="concat('-f ',.,'/build_root.xml')"/>
+                        </xsl:element>
+                    </exec>
+                </xsl:for-each>
+            </target>
+        </project>
+    </xsl:template>
+    
 </xsl:stylesheet>

+ 2 - 0
SE/schema/default_db_xml_cache.public/main_build_recurse_ant.dita_with_id.xsl

@@ -173,6 +173,7 @@
             <xsl:attribute name="flat_relation_cache_xpath" select="@flat_relation_cache_xpath"/>
             <xsl:attribute name="flat_relation_cache_name" select="@flat_relation_cache_name"/>            
             <xsl:attribute name="system_cache__appinfo:get_default_db_obj_url_table_name" select="$detect_resource_type//system_cache__resources_tree_generate_xsl_required_occurs_raport:detect_resource_type/@system_cache__appinfo:get_default_db_obj_url_table_name"/>
+            <xsl:copy-of select="@system_cache__appinfo:loop_id"/>
             <xsl:choose>
                 <xsl:when test="@system_cache__appinfo:maxOccurs='0' and @system_cache__appinfo:minOccurs='0'">
                     <xsl:message>#90 node=<xsl:value-of select="@system_cache__appinfo:ref"/>; to BYPASS! TODO @system_cache__appinfo:maxOccurs=0 and @system_cache__appinfo:minOccurs  </xsl:message>
@@ -290,6 +291,7 @@
                     <xsl:attribute name="xml_id" select="generate-id()"/>
                 </xsl:otherwise>
             </xsl:choose>
+            <xsl:copy-of select="@system_cache__appinfo:id"/>
             <!--<xsl:attribute name="xml_id" select="generate-id()"/>-->
             <xsl:apply-templates>
                 <xsl:with-param name="build_complexType" select="$build_complexType"/>