a.binder пре 9 година
родитељ
комит
406e879b19

+ 11 - 3
SE/schema/ant-url_action/default_db.in7_dziennik_koresp/test-druk/build.xml

@@ -22,10 +22,16 @@
         <property name="DwebRootUrl" value="${$webRootUrl}"/> - this is the place where script is localized to easyli to target user GUI by href to generated output      
     />
     -->
+    
+    
+    <!---DpasswordBase64Basic="xxxxx=="
+        -DtypeName="p5_default_db:IN7_DZIENNIK_KORESP" 
+        -Dxpath=ID -Dxpath_value=1000 
+        -Duuid=1 -DwebRootUrl=somePathDir-->
     <property name="temp" value="temp"/> <!-- temp files-->
     <property name="out" value="out"/> <!-- output ready files like pdf -->
     
-    <!--<property name="uuid" value="${uuid}"/> TODO-->
+    <property name="uuid" value="${uuid}"/> <!--TODO-->
     <property name="passwordBase64Basic" value="${passwordBase64Basic}"/>
     <property name="url" value="${url}"/>
     <property name="webRootUrl" value="${$webRootUrl}"/>
@@ -34,7 +40,7 @@
     <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="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="ID"/> <!-- 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  -->
     
     <!-- variables to first transform of doc for then get related features -->
@@ -42,7 +48,7 @@
     <property name="build_recurse_ant_merge_dita_from_temp.xsl" value="build_recurse_ant_merge_dita_from_temp.xsl"/>
     <property name="main_build_recurse_ant.dita" value="main_build_recurse_ant.dita"/>
  
-    <tempfile property="uuid" deleteonexit="yes"/>
+    <!--<tempfile property="uuid" deleteonexit="yes"/>-->
     <tempfile property="out_task.dita" deleteonexit="no"  destdir="temp"/>
     <tempfile property="wfs_output" deleteonexit="no"  destdir="temp"  suffix=".xml" />
     
@@ -54,6 +60,8 @@
     </target>
 
    
+   
+   
 
     <!-- wygenerowanie ant builda do sciagniecia niezbednego elementu na podstawie template main.dita i tam zagniezdzonego RelatedFeature-->
     <target name="build_recurse_ant.xml">

+ 3 - 1
SE/se-lib/Route/UrlAction/Ant.php

@@ -52,6 +52,8 @@ class Route_UrlAction_Ant extends Route_Ant {// @doc @see Route_Ant
       $path = V::get('path', '', $_GET);
       if (!$path) throw new Exception("Missing Ant path!");
       $primaryKey = V::get('primaryKey', '', $_GET);
+      $xpath = V::get('xpath', '', $_GET);
+
       $typeName = V::get('typeName', '', $_GET);
       list($nsPrefix, $objectName) = explode(':', $typeName);// TODO: get wfs prefix from typeName
 
@@ -71,7 +73,7 @@ class Route_UrlAction_Ant extends Route_Ant {// @doc @see Route_Ant
       DBG::log([ 'msg'=>'$outputFunctionUrl', '$outputFunctionUrl'=>$outputFunctionUrl]);
       $testUrl = Request::getPathUri() . "wfs-data.php/default_db/?SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=".$typeName."&SRSNAME=EPSG:3003&featureID={$objectName}.{$primaryKey}";
       $cryptedPass = base64_encode(User::getLogin() . ":" . Crypt::decrypt($_SESSION['ADM_PASS_HASH']));
-      $cmd = "cd {$this->pathUrlActions}{$path} && {$this->antBin} -S  -DoutputFunctionUrl='{$outputFunctionUrl}' -DwebRootUrl='{$webRootUrl}' -Durl='{$testUrl}' -DpasswordBase64Basic='{$cryptedPass}' -Duuid='".session_id()."'  2>&1";
+      $cmd = "cd {$this->pathUrlActions}{$path} && {$this->antBin} -S  -DoutputFunctionUrl='{$outputFunctionUrl}' -DwebRootUrl='{$webRootUrl}' -Durl='{$testUrl}' -DpasswordBase64Basic='{$cryptedPass}' -Duuid='".session_id()."' -Dxpath=".$xpath." -Dxpath_value=".$primaryKey."  2>&1";
       DBG::log([ 'msg'=>"cmd", 'cmd'=>str_replace(APP_PATH_ROOT, 'SE', $cmd) ]);
       V::exec($cmd, $out, $ret);
       DBG::log([ 'msg'=>"cmd and returns({$ret})", 'output'=>$out ]);