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

tune z cookie dla przypadku pracy z oxygena oraz natywne przyjecie opcji z API

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

+ 41 - 22
SE/schema/ant-url_action/default_db.crm_proces/CRM_PROCES_tree/build.xml

@@ -38,6 +38,7 @@
     
     <property name="uuid" value="${uuid}"/> <!--TODO-->
     <property name="passwordBase64Basic" value="${passwordBase64Basic}"/>
+    <property name="php_session_id" value="${php_session_id}"/> <!-- optional cookie if sent work with it if not - get it -->
     <property name="url" value="${url}"/>
     <property name="webRootUrl" value="${$webRootUrl}"/>
 
@@ -211,7 +212,6 @@
         <echo message="OUTPUT__END"/>
     </target>
     
-    
     <target name="dita_ok" if="${test_if_dita}">
         <!-- polaczenie pdfa -->
         <antcall target="build_recurse_ant_merge_dita_from_temp.xsl"/>
@@ -219,11 +219,6 @@
     
     
     <!-- ####  tr_map #### -->
-    
-    
-                    
-    
-    
                     
                     <target name="set_tr_map" depends="check_set_default_db_xml_cache.public_local,check_default_db_xml_cache.public_default" >
                         <!--<property name="main_build_recurse_ant.dita" value="main_build_recurse_ant.dita"/>-->
@@ -251,29 +246,51 @@
                         <echo>&lt;br&gt;Brakuje druku dla powiązanego obiektu ${main_build_recurse_ant.dita} &lt;/br&gt;</echo>         
                         <echo message="OUTPUT__END"/>
                     </target>
-                    
-                    
+                                        
                     <target name="tr_map_ok" if="${test_if_tr_map}">
                         <!-- polaczenie pdfa -->
                         <echo>#251 wyzwalam build_recurse_ant_merge_dita_from_temp.xsl</echo>
                         <antcall target="build_recurse_ant_merge_dita_from_temp.xsl"/>
                     </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"/>
-                <move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>
-                
-                <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" 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"/>
+                        <move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>
+                        
+                        <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>
    
-    
     <!-- #### eof tr_map #### -->
     
+    
+    <!-- ### php_session_id ### -->
+    
+        <target name="php_session_id_cond">
+            <condition property="php_session_id_fail" taskname="php_session_id_check">
+                <or>
+                    <equals arg1="${php_session_id}" arg2=""/>
+                    <equals arg1="${php_session_id}" arg2="$${php_session_id}"/>
+                </or>
+            </condition>
+        </target>
+        <target name="php_session_id_check" depends="php_session_id_cond,php_session_id_ok,php_session_id_fail"/>
+        <target name="php_session_id_ok" unless="${php_session_id_fail}" description="use php_session_id from parameter ">
+            <property name="php_session_id_tested" value="--cookie 'PHPSESSID=${php_session_id}'"/>
+        </target>
+        <target name="php_session_id_fail" if="${php_session_id_fail}" description="retrieve php_session_id from API to use it after for fasten api requests ">
+            <property name="cookie_file" value="${temp}/${uuid_tested}.cookie"/>
+            <exec executable="curl"> <!--  errorproperty="wfs_error" resultproperty="wfs_result" -->
+                <arg line=" -c ${cookie_file} -H 'Authorization: Basic ${passwordBase64Basic_tested}' &#34;${api_url}&#34;"/> <!-- /default_db/?SERVICE=WFS&amp;VERSION=1.0.0&amp;REQUEST=GetCapabilities&#34; -->
+            </exec>
+            <property name="php_session_id_tested" value=" -b ${cookie_file}"/>
+            <echo> #289 we set php_session_id_tested=(${php_session_id_tested}) </echo>
+        </target>
+    
+    <!-- ### eof php_session_id ### -->
+    
     <target name="set_default_db_xml_cache.public_local">
         <condition property="set_default_db_xml_cache.public_local">
             <available file="default_db_xml_cache.public/build_recurse_ant_merge_dita_from_temp.xsl"/> 
@@ -314,6 +331,7 @@
                 <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
             </factory>
             <param name="namespace_prefix" expression="${namespace_prefix}"/>
+            <param name="detect_resource_type_dir" expression="${detect_resource_type_dir}"/>
             <classpath location="/opt/local/share/java/saxon9he.jar"/>
         </xslt>
     </target>
@@ -340,7 +358,7 @@
     </target>
 
     <!-- wygenerowanie ant builda do sciagniecia niezbednego elementu na podstawie template main.dita i tam zagniezdzonego RelatedFeature-->
-    <target name="build_recurse_ant.xml" depends="main_build_recurse_ant.dita_with_id,main_build_recurse_ant.tr_map_with_id">
+    <target name="build_recurse_ant.xml" depends="php_session_id_check,main_build_recurse_ant.dita_with_id,main_build_recurse_ant.tr_map_with_id">
         <!-- build do wytworzenia pierwszego przetworzenia zagniezdzen -->
         <record name="${temp}/ant.log" loglevel="verbose" append="true"/>
         <property name="loop_xpath"  value="root"/>
@@ -375,6 +393,7 @@
             <param name="build_recurse_ant.xsl" expression="${build_recurse_ant.xsl}"/>
             <param name="temp" expression="${temp}"/>
             <param name="builds_to_ant.xsl" expression="${builds_to_ant.xsl}"/>
+            <param name="cookie_curl_option" expression="${php_session_id_tested}"/>
         </xslt>
         <!--<import file="${build_recurse_ant.xml}"/>-->
         <ant  antfile="${build_recurse_ant.xml}" dir="."/>
@@ -402,7 +421,7 @@
 
 
 
-    <target name="buildpdf_recursed" depends="uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,check_dita" if="${test_if_dita}">
+    <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"/>
         <exec executable="${dita.dir}" dir=".">
             <arg value="-i"/>

+ 44 - 18
SE/schema/ant-url_action/default_db.in7_dziennik_koresp/test-druk/build.xml

@@ -34,15 +34,17 @@
     <property name="temp" value="temp"/> <!-- temp files-->
     <property name="out" value="out"/> <!-- output ready files like pdf -->
     <property name="p5_tr_map_dir" location="../../../default_db.instance.xml/p5_tr_map" />
+    <property name="detect_resource_type_dir" location="../../../default_db.instance.xml/detect_resource_type" />
     
     <property name="uuid" value="${uuid}"/> <!--TODO-->
     <property name="passwordBase64Basic" value="${passwordBase64Basic}"/>
+    <property name="php_session_id" value="${php_session_id}"/> <!-- optional cookie if sent work with it if not - get it -->
     <property name="url" value="${url}"/>
     <property name="webRootUrl" value="${$webRootUrl}"/>
 
     <property name="api_url" value="https://biuro.biall-net.pl/SE/version-git/wfs-data.php"/>
     <property name="namespace_prefix" value="p5_default_db"/> <!-- ex: p5_default_db to complete after p5_default_db:IN7_DZIENNIK_KORESP -->
-    <property name="namespace_prefix_p5_tr_map" value="default_db"/> <!-- do przetowrzenia w nazwie pliku docelowej element-default_db__x3A__CRM_PROCES__x3A__CRM_PROCES -->
+    <property name="namespace_prefix_p5_tr_map" value="default_db"/> <!-- do przetowrzenia w nazwie pliku docelowej element-default_db__x3A__CRM_PROCES__x3A__CRM_PROCES oraz dla detect_resource_type_dir -->
     <property name="typeName" value="${typeName}"/> <!-- to be set initially ex: p5_default_db:IN7_DZIENNIK_KORESP - be careful not to give it in apostrophs like 'p5_default_db:IN7_DZIENNIK_KORESP' - it wont work! -->
     <property name="xpath" value="${xpath}"/> <!-- to be set initially like as key to search ID  -->
     <property name="xpath_value" value="${xpath_value}"/> <!-- to be set initially like 1000 (to search ID=1000, if ID we get by featureID  -->
@@ -210,7 +212,6 @@
         <echo message="OUTPUT__END"/>
     </target>
     
-    
     <target name="dita_ok" if="${test_if_dita}">
         <!-- polaczenie pdfa -->
         <antcall target="build_recurse_ant_merge_dita_from_temp.xsl"/>
@@ -218,8 +219,6 @@
     
     
     <!-- ####  tr_map #### -->
-    
-    
                     
                     <target name="set_tr_map" depends="check_set_default_db_xml_cache.public_local,check_default_db_xml_cache.public_default" >
                         <!--<property name="main_build_recurse_ant.dita" value="main_build_recurse_ant.dita"/>-->
@@ -247,27 +246,51 @@
                         <echo>&lt;br&gt;Brakuje druku dla powiązanego obiektu ${main_build_recurse_ant.dita} &lt;/br&gt;</echo>         
                         <echo message="OUTPUT__END"/>
                     </target>
-                    
-                    
+                                        
                     <target name="tr_map_ok" if="${test_if_tr_map}">
                         <!-- polaczenie pdfa -->
                         <echo>#251 wyzwalam build_recurse_ant_merge_dita_from_temp.xsl</echo>
                         <antcall target="build_recurse_ant_merge_dita_from_temp.xsl"/>
                     </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>
-                    &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final}&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final}&lt;/a&gt;&lt;/br&gt; 
-                </echo>
-                <echo message="OUTPUT__END"/>
-            </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"/>
+                        <move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>
+                        
+                        <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>
    
-    
     <!-- #### eof tr_map #### -->
     
+    
+    <!-- ### php_session_id ### -->
+    
+        <target name="php_session_id_cond">
+            <condition property="php_session_id_fail" taskname="php_session_id_check">
+                <or>
+                    <equals arg1="${php_session_id}" arg2=""/>
+                    <equals arg1="${php_session_id}" arg2="$${php_session_id}"/>
+                </or>
+            </condition>
+        </target>
+        <target name="php_session_id_check" depends="php_session_id_cond,php_session_id_ok,php_session_id_fail"/>
+        <target name="php_session_id_ok" unless="${php_session_id_fail}" description="use php_session_id from parameter ">
+            <property name="php_session_id_tested" value="--cookie 'PHPSESSID=${php_session_id}'"/>
+        </target>
+        <target name="php_session_id_fail" if="${php_session_id_fail}" description="retrieve php_session_id from API to use it after for fasten api requests ">
+            <property name="cookie_file" value="${temp}/${uuid_tested}.cookie"/>
+            <exec executable="curl"> <!--  errorproperty="wfs_error" resultproperty="wfs_result" -->
+                <arg line=" -c ${cookie_file} -H 'Authorization: Basic ${passwordBase64Basic_tested}' &#34;${api_url}&#34;"/> <!-- /default_db/?SERVICE=WFS&amp;VERSION=1.0.0&amp;REQUEST=GetCapabilities&#34; -->
+            </exec>
+            <property name="php_session_id_tested" value=" -b ${cookie_file}"/>
+            <echo> #289 we set php_session_id_tested=(${php_session_id_tested}) </echo>
+        </target>
+    
+    <!-- ### eof php_session_id ### -->
+    
     <target name="set_default_db_xml_cache.public_local">
         <condition property="set_default_db_xml_cache.public_local">
             <available file="default_db_xml_cache.public/build_recurse_ant_merge_dita_from_temp.xsl"/> 
@@ -308,6 +331,7 @@
                 <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
             </factory>
             <param name="namespace_prefix" expression="${namespace_prefix}"/>
+            <param name="detect_resource_type_dir" expression="${detect_resource_type_dir}"/>
             <classpath location="/opt/local/share/java/saxon9he.jar"/>
         </xslt>
     </target>
@@ -318,6 +342,7 @@
                 <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
             </factory>
             <param name="namespace_prefix" expression="${namespace_prefix}"/>
+            <param name="detect_resource_type_dir" expression="${detect_resource_type_dir}"/>
             <classpath location="/opt/local/share/java/saxon9he.jar"/>
         </xslt>
     </target>
@@ -333,7 +358,7 @@
     </target>
 
     <!-- wygenerowanie ant builda do sciagniecia niezbednego elementu na podstawie template main.dita i tam zagniezdzonego RelatedFeature-->
-    <target name="build_recurse_ant.xml" depends="main_build_recurse_ant.dita_with_id,main_build_recurse_ant.tr_map_with_id">
+    <target name="build_recurse_ant.xml" depends="php_session_id_check,main_build_recurse_ant.dita_with_id,main_build_recurse_ant.tr_map_with_id">
         <!-- build do wytworzenia pierwszego przetworzenia zagniezdzen -->
         <record name="${temp}/ant.log" loglevel="verbose" append="true"/>
         <property name="loop_xpath"  value="root"/>
@@ -368,6 +393,7 @@
             <param name="build_recurse_ant.xsl" expression="${build_recurse_ant.xsl}"/>
             <param name="temp" expression="${temp}"/>
             <param name="builds_to_ant.xsl" expression="${builds_to_ant.xsl}"/>
+            <param name="cookie_curl_option" expression="${php_session_id_tested}"/>
         </xslt>
         <!--<import file="${build_recurse_ant.xml}"/>-->
         <ant  antfile="${build_recurse_ant.xml}" dir="."/>
@@ -395,7 +421,7 @@
 
 
 
-    <target name="buildpdf_recursed" depends="uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,check_dita" if="${test_if_dita}">
+    <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"/>
         <exec executable="${dita.dir}" dir=".">
             <arg value="-i"/>

+ 44 - 18
SE/schema/ant-url_action/default_db.in7_dziennik_koresp/umowa/build.xml

@@ -34,15 +34,17 @@
     <property name="temp" value="temp"/> <!-- temp files-->
     <property name="out" value="out"/> <!-- output ready files like pdf -->
     <property name="p5_tr_map_dir" location="../../../default_db.instance.xml/p5_tr_map" />
+    <property name="detect_resource_type_dir" location="../../../default_db.instance.xml/detect_resource_type" />
     
     <property name="uuid" value="${uuid}"/> <!--TODO-->
     <property name="passwordBase64Basic" value="${passwordBase64Basic}"/>
+    <property name="php_session_id" value="${php_session_id}"/> <!-- optional cookie if sent work with it if not - get it -->
     <property name="url" value="${url}"/>
     <property name="webRootUrl" value="${$webRootUrl}"/>
 
     <property name="api_url" value="https://biuro.biall-net.pl/SE/version-git/wfs-data.php"/>
     <property name="namespace_prefix" value="p5_default_db"/> <!-- ex: p5_default_db to complete after p5_default_db:IN7_DZIENNIK_KORESP -->
-    <property name="namespace_prefix_p5_tr_map" value="default_db"/> <!-- do przetowrzenia w nazwie pliku docelowej element-default_db__x3A__CRM_PROCES__x3A__CRM_PROCES -->
+    <property name="namespace_prefix_p5_tr_map" value="default_db"/> <!-- do przetowrzenia w nazwie pliku docelowej element-default_db__x3A__CRM_PROCES__x3A__CRM_PROCES oraz dla detect_resource_type_dir -->
     <property name="typeName" value="${typeName}"/> <!-- to be set initially ex: p5_default_db:IN7_DZIENNIK_KORESP - be careful not to give it in apostrophs like 'p5_default_db:IN7_DZIENNIK_KORESP' - it wont work! -->
     <property name="xpath" value="${xpath}"/> <!-- to be set initially like as key to search ID  -->
     <property name="xpath_value" value="${xpath_value}"/> <!-- to be set initially like 1000 (to search ID=1000, if ID we get by featureID  -->
@@ -210,7 +212,6 @@
         <echo message="OUTPUT__END"/>
     </target>
     
-    
     <target name="dita_ok" if="${test_if_dita}">
         <!-- polaczenie pdfa -->
         <antcall target="build_recurse_ant_merge_dita_from_temp.xsl"/>
@@ -218,8 +219,6 @@
     
     
     <!-- ####  tr_map #### -->
-    
-    
                     
                     <target name="set_tr_map" depends="check_set_default_db_xml_cache.public_local,check_default_db_xml_cache.public_default" >
                         <!--<property name="main_build_recurse_ant.dita" value="main_build_recurse_ant.dita"/>-->
@@ -247,27 +246,51 @@
                         <echo>&lt;br&gt;Brakuje druku dla powiązanego obiektu ${main_build_recurse_ant.dita} &lt;/br&gt;</echo>         
                         <echo message="OUTPUT__END"/>
                     </target>
-                    
-                    
+                                        
                     <target name="tr_map_ok" if="${test_if_tr_map}">
                         <!-- polaczenie pdfa -->
                         <echo>#251 wyzwalam build_recurse_ant_merge_dita_from_temp.xsl</echo>
                         <antcall target="build_recurse_ant_merge_dita_from_temp.xsl"/>
                     </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>
-                    &lt;br&gt;Wygenerowano wyjsciowy plik XML - sciagnij go &lt;a href=&quot;${webRootUrl}/${out_task.dita.final}&quot; target=&quot;_blank&quot;&gt; &quot;${webRootUrl}/${out_task.dita.final}&lt;/a&gt;&lt;/br&gt; 
-                </echo>
-                <echo message="OUTPUT__END"/>
-            </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"/>
+                        <move file="${out_task.dita.final}" tofile="${out_task.dita.final}.xml"/>
+                        
+                        <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>
    
-    
     <!-- #### eof tr_map #### -->
     
+    
+    <!-- ### php_session_id ### -->
+    
+        <target name="php_session_id_cond">
+            <condition property="php_session_id_fail" taskname="php_session_id_check">
+                <or>
+                    <equals arg1="${php_session_id}" arg2=""/>
+                    <equals arg1="${php_session_id}" arg2="$${php_session_id}"/>
+                </or>
+            </condition>
+        </target>
+        <target name="php_session_id_check" depends="php_session_id_cond,php_session_id_ok,php_session_id_fail"/>
+        <target name="php_session_id_ok" unless="${php_session_id_fail}" description="use php_session_id from parameter ">
+            <property name="php_session_id_tested" value="--cookie 'PHPSESSID=${php_session_id}'"/>
+        </target>
+        <target name="php_session_id_fail" if="${php_session_id_fail}" description="retrieve php_session_id from API to use it after for fasten api requests ">
+            <property name="cookie_file" value="${temp}/${uuid_tested}.cookie"/>
+            <exec executable="curl"> <!--  errorproperty="wfs_error" resultproperty="wfs_result" -->
+                <arg line=" -c ${cookie_file} -H 'Authorization: Basic ${passwordBase64Basic_tested}' &#34;${api_url}&#34;"/> <!-- /default_db/?SERVICE=WFS&amp;VERSION=1.0.0&amp;REQUEST=GetCapabilities&#34; -->
+            </exec>
+            <property name="php_session_id_tested" value=" -b ${cookie_file}"/>
+            <echo> #289 we set php_session_id_tested=(${php_session_id_tested}) </echo>
+        </target>
+    
+    <!-- ### eof php_session_id ### -->
+    
     <target name="set_default_db_xml_cache.public_local">
         <condition property="set_default_db_xml_cache.public_local">
             <available file="default_db_xml_cache.public/build_recurse_ant_merge_dita_from_temp.xsl"/> 
@@ -308,6 +331,7 @@
                 <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
             </factory>
             <param name="namespace_prefix" expression="${namespace_prefix}"/>
+            <param name="detect_resource_type_dir" expression="${detect_resource_type_dir}"/>
             <classpath location="/opt/local/share/java/saxon9he.jar"/>
         </xslt>
     </target>
@@ -318,6 +342,7 @@
                 <attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
             </factory>
             <param name="namespace_prefix" expression="${namespace_prefix}"/>
+            <param name="detect_resource_type_dir" expression="${detect_resource_type_dir}"/>
             <classpath location="/opt/local/share/java/saxon9he.jar"/>
         </xslt>
     </target>
@@ -333,7 +358,7 @@
     </target>
 
     <!-- wygenerowanie ant builda do sciagniecia niezbednego elementu na podstawie template main.dita i tam zagniezdzonego RelatedFeature-->
-    <target name="build_recurse_ant.xml" depends="main_build_recurse_ant.dita_with_id,main_build_recurse_ant.tr_map_with_id">
+    <target name="build_recurse_ant.xml" depends="php_session_id_check,main_build_recurse_ant.dita_with_id,main_build_recurse_ant.tr_map_with_id">
         <!-- build do wytworzenia pierwszego przetworzenia zagniezdzen -->
         <record name="${temp}/ant.log" loglevel="verbose" append="true"/>
         <property name="loop_xpath"  value="root"/>
@@ -368,6 +393,7 @@
             <param name="build_recurse_ant.xsl" expression="${build_recurse_ant.xsl}"/>
             <param name="temp" expression="${temp}"/>
             <param name="builds_to_ant.xsl" expression="${builds_to_ant.xsl}"/>
+            <param name="cookie_curl_option" expression="${php_session_id_tested}"/>
         </xslt>
         <!--<import file="${build_recurse_ant.xml}"/>-->
         <ant  antfile="${build_recurse_ant.xml}" dir="."/>
@@ -395,7 +421,7 @@
 
 
 
-    <target name="buildpdf_recursed" depends="uuid_check,typeName_check,xpath_check,xpath_value_check,passwordBase64Basic_check,check_dita" if="${test_if_dita}">
+    <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"/>
         <exec executable="${dita.dir}" dir=".">
             <arg value="-i"/>

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

@@ -53,6 +53,7 @@
     <xsl:param name="build_recurse_ant.xsl" required="yes"/>
     <xsl:param name="temp" select="'temp'"/>
     <xsl:param name="builds_to_ant.xsl" required="yes"/>
+    <xsl:param name="cookie_curl_option" required="yes"/>
     <!-- second step fist loop - with data -->
     <!--<xsl:param name="wfs_output.xml"/>--> <!-- to be set in second step by ant build generated by this style to fill by its data childs -->
     
@@ -433,7 +434,8 @@
                                         <xsl:attribute name="resultproperty" select="'wfs_result'"/>
                                         <xsl:element name="arg">
                                             <!--<xsl:attribute name="line" select='concat("-H ","&amp;Authorization: Basic ",$passwordBase64Basic," ",$url)'/>-->
-                                            <xsl:attribute name="line">-H 'Authorization: Basic <xsl:value-of select="$passwordBase64Basic"/>' "<xsl:value-of select="$url"/>"</xsl:attribute> 
+                                            <!--<xsl:attribute name="line">-H 'Authorization: Basic <xsl:value-of select="$passwordBase64Basic"/>' "<xsl:value-of select="$url"/>"</xsl:attribute>-->
+                                            <xsl:attribute name="line"> <xsl:value-of select="$cookie_curl_option"/> "<xsl:value-of select="$url"/>"</xsl:attribute>
                                         </xsl:element>
                                     </xsl:element>
                                     <echo message="ERROR__START"/>
@@ -472,6 +474,7 @@
                                             <param name="build_recurse_ant.xsl" expression="{$build_recurse_ant.xsl}"/>
                                             <param name="temp" expression="{$temp}"/>
                                             <param name="builds_to_ant.xsl" expression="{$builds_to_ant.xsl}"/>
+                                            <param name="cookie_curl_option" expression="{$cookie_curl_option}"/>
                                     </xslt>
                             </xsl:element>
                         <!-- zapisujemy wynik naszego biezacego przetwarzania dita element nizej do kolejnego przejechania z ant wyniku dla podstawienia danych  -->

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

@@ -134,7 +134,9 @@
         <xsl:element name="{$element-name}">
             <xsl:apply-templates select="@*">
                 <xsl:with-param name="element" select="name()"/>
+                <xsl:with-param name="node" select="."/>
             </xsl:apply-templates>
+            <xsl:copy-of select="@*"/>
             <xsl:choose>
                 <!-- <xsl:when test="@system_cache__appinfo:id">
                     <xsl:attribute name="xml_id" select="@system_cache__appinfo:id"/>
@@ -155,10 +157,14 @@
     
     <xsl:template match="@*">
         <xsl:param name="element"/>
+        <xsl:param name="node"/>
         <xsl:choose>
             <xsl:when test="$element='p5_tr_map:go_recurse_from_root_by_build_element_loop'">
                 <xsl:copy-of select="."/>
             </xsl:when>
+            <xsl:when test="  namespace-uri($node)!='http://biuro.biall-net.pl/xmlschema_procesy5/default_db_xml_cache/procesy5_translate_map.xsd'">
+                <xsl:copy-of select="."/>
+            </xsl:when>
         </xsl:choose>
     </xsl:template>