diff options
author | Anton Lundin <glance@acc.umu.se> | 2015-06-27 23:38:10 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-06-27 14:42:05 -0700 |
commit | f04b3bc166fe714f810a90dcd606db60dc7bc900 (patch) | |
tree | 34a65321ac91bb0bc98f2659931f45368813477e /xslt/csv2xml.xslt | |
parent | 1f0c9eec9640450f20449140244966e2b3a2ea13 (diff) | |
download | subsurface-f04b3bc166fe714f810a90dcd606db60dc7bc900.tar.gz |
Add support for importing O2 sensors from CSV file
This adds support for importing individual O2 sensors from a CSV file,
e.g. an APD log viewer file.
Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'xslt/csv2xml.xslt')
-rw-r--r-- | xslt/csv2xml.xslt | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/xslt/csv2xml.xslt b/xslt/csv2xml.xslt index 05f9e23c6..29ebbce24 100644 --- a/xslt/csv2xml.xslt +++ b/xslt/csv2xml.xslt @@ -6,6 +6,9 @@ <xsl:param name="depthField" select="depthField"/> <xsl:param name="tempField" select="tempField"/> <xsl:param name="po2Field" select="po2Field"/> + <xsl:param name="o2sensor1Field" select="o2sensor1Field"/> + <xsl:param name="o2sensor2Field" select="o2sensor2Field"/> + <xsl:param name="o2sensor3Field" select="o2sensor3Field"/> <xsl:param name="cnsField" select="cnsField"/> <xsl:param name="otuField" select="otuField"/> <xsl:param name="ndlField" select="ndlField"/> @@ -199,6 +202,33 @@ </xsl:attribute> </xsl:if> + <xsl:if test="$o2sensor1Field >= 0"> + <xsl:attribute name="sensor1"> + <xsl:call-template name="getFieldByIndex"> + <xsl:with-param name="index" select="$o2sensor1Field"/> + <xsl:with-param name="line" select="$line"/> + </xsl:call-template> + </xsl:attribute> + </xsl:if> + + <xsl:if test="$o2sensor2Field >= 0"> + <xsl:attribute name="sensor2"> + <xsl:call-template name="getFieldByIndex"> + <xsl:with-param name="index" select="$o2sensor2Field"/> + <xsl:with-param name="line" select="$line"/> + </xsl:call-template> + </xsl:attribute> + </xsl:if> + + <xsl:if test="$o2sensor3Field >= 0"> + <xsl:attribute name="sensor3"> + <xsl:call-template name="getFieldByIndex"> + <xsl:with-param name="index" select="$o2sensor3Field"/> + <xsl:with-param name="line" select="$line"/> + </xsl:call-template> + </xsl:attribute> + </xsl:if> + <xsl:if test="$cnsField >= 0"> <xsl:attribute name="cns"> <xsl:call-template name="getFieldByIndex"> |