|
|
@@ -5,6 +5,18 @@
|
|
|
na output mamy pdf'a
|
|
|
-->
|
|
|
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ <!--https://biuro.biall-net.pl/SE/version-git/index.php?_route=UrlAction_Ant&_task=ant&
|
|
|
+ path=${default_db.in7_dziennik_koresp/test-get-wfs-xml} - this is the place to keep ant build (directory name with build.xml)
|
|
|
+ &namespace=p5_default_db:Rozdzielcza_test_bzyk_PE&featureID=123 - this is setting the <property name="url" value="${url}"/> - to point what is record/table to download
|
|
|
+ <property name="uuid" value="${uuid}"/> it is automatically also set to enable uinque transaction and to allow to save data with user
|
|
|
+ <property name="passwordBase64Basic" value="${passwordBase64Basic}"/> - this is also set - to enable communicate with API -
|
|
|
+ />
|
|
|
+ -->
|
|
|
+
|
|
|
+
|
|
|
<property name="INPUT" value="Test_z_getfeature_do_parse.xml"/>
|
|
|
<tempfile property="tmp.xml" destdir="temp" deleteonexit="yes"/>
|
|
|
<tempfile property="Test_z_getfeature_do_parse__noxml.xml" destdir="temp" deleteonexit="yes"/>
|
|
|
@@ -23,29 +35,36 @@
|
|
|
</if>-->
|
|
|
|
|
|
|
|
|
-
|
|
|
- <target name="check" >
|
|
|
- <echo message="testuje check"/>
|
|
|
- <condition property="test_if_INPUTxml" taskname="buildpdf" value="AVIABLE">
|
|
|
- <available file="Test_z_getfeature_do_parse.xml" filepath="." />
|
|
|
- </condition>
|
|
|
+ <target name="get_related_feature">
|
|
|
+
|
|
|
+ <exec executable="curl" outputproperty="wfs_output" errorproperty="wfs_error" resultproperty="wfs_result">
|
|
|
+ <arg line="-H 'Authorization: Basic ${passwordBase64Basic}' ${url}"/>
|
|
|
+ </exec>
|
|
|
+ <echo message="curl -H 'Authorization: Basic ${passwordBase64Basic}' '${url}'"/>
|
|
|
+ <echo message="OUTPUT__START"/>
|
|
|
+ <echo message="${wfs_output}"/>
|
|
|
+ <echo message="OUTPUT__END"/>
|
|
|
+
|
|
|
+ <echo message="RESULT__START"/>
|
|
|
+ <echo message="${wfs_result}"/>
|
|
|
+ <echo message="RESULT__END"/>
|
|
|
+
|
|
|
+ <echo message="ERROR__START"/>
|
|
|
+ <echo message="${wfs_error}"/>
|
|
|
+ <echo message="ERROR__END"/>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
</target>
|
|
|
|
|
|
- <target name="make_inputXML_from_stdin" unless="test_if_INPUTxml">
|
|
|
- <echo message="make_inputXML_from_stdin is not aviable appending"/>
|
|
|
- <input addproperty="INPUT_from_stdin"/>
|
|
|
- <echo message="${INPUT_from_stdin}" file="${INPUT}"/>
|
|
|
- <!--<echo file="${test_if_INPUTxml}" message=""/>-->
|
|
|
- </target>
|
|
|
- <target name="check-info" if="test_if_INPUTxml">
|
|
|
- <echo message="Using default XML object on input from file ${INPUT} . "/>
|
|
|
- </target>
|
|
|
|
|
|
- <target name="buildpdf" depends="check,check-info,make_inputXML_from_stdin">
|
|
|
|
|
|
- <echo message="buildpdf to ${test_if_INPUTxml}"/>
|
|
|
+ <target name="buildpdf" depends="get_related_feature">
|
|
|
+
|
|
|
+
|
|
|
<!-- przyklad z uzywaniem saxona ktorego wczesniej trzeba pobrac z port install saxon -->
|
|
|
- <xslt style="copy-no-xml.xsl" in="${INPUT}" out="${Test_z_getfeature_do_parse__noxml.xml}"> <!-- {Test_z_getfeature_do_parse__noxml.xml"-->
|
|
|
+ <xslt style="copy-no-xml.xsl" in="${wfs_result}" out="${Test_z_getfeature_do_parse__noxml.xml}"> <!-- {Test_z_getfeature_do_parse__noxml.xml"-->
|
|
|
<factory name="net.sf.saxon.TransformerFactoryImpl">
|
|
|
<attribute name="http://saxon.sf.net/feature/xinclude-aware" value="true"/>
|
|
|
</factory>
|
|
|
@@ -81,16 +100,12 @@
|
|
|
</exec>
|
|
|
|
|
|
<!--<propertyregex property="out_file" input="${out_task.dita}" regexp="$.*/(.*)" select="\1."/>-->
|
|
|
- <loadfile property="result" srcFile="out/${out_task_file}.pdf"/>
|
|
|
+ <!--<loadfile property="result" srcFile="out/${out_task_file}.pdf"/>-->
|
|
|
<!--<echo message="input was : ${input}"/>-->
|
|
|
- <echo message="OUTPUT_PDF_FILE: out/${out_task_file}.pdf"/>
|
|
|
- <!-- <echo message="${result}"/> -->
|
|
|
- <!--<propertyregex
|
|
|
- name="test"
|
|
|
- property="current.target.dir"
|
|
|
- input="com.element.subelement"
|
|
|
- regexp="\."
|
|
|
- replace="/"
|
|
|
- global="true" />-->
|
|
|
+ <!--<echo message="OUTPUT_PDF_FILE: out/${out_task_file}.pdf"/>-->
|
|
|
+ <echo>
|
|
|
+ <br>Wygenerowano druk pdf - sciagnij go <a href="${out_task_file}"> ${out_task_file}</a></br>
|
|
|
+ </echo>
|
|
|
+
|
|
|
</target>
|
|
|
</project>
|