mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Add the missed csv-field stopdepth
I managed to mess up and grab parts of my unfinished otu field code and squash it into the wrong patch. Here is the code for stopdepth, and now the code sets the in_deco flag to. Signed-off-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
eec732548b
commit
5e04aaa756
1 changed files with 20 additions and 0 deletions
|
@ -8,6 +8,7 @@
|
|||
<xsl:param name="po2Field" select="po2Field"/>
|
||||
<xsl:param name="cnsField" select="cnsField"/>
|
||||
<xsl:param name="otuField" select="otuField"/>
|
||||
<xsl:param name="stopdepthField" select="stopdepthField"/>
|
||||
<xsl:param name="date" select="date"/>
|
||||
<xsl:param name="time" select="time"/>
|
||||
<xsl:output method="xml" indent="yes"/>
|
||||
|
@ -141,6 +142,25 @@
|
|||
</xsl:when>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
|
||||
<xsl:if test="$stopdepthField >= 0">
|
||||
<xsl:variable name="stopdepth">
|
||||
<xsl:call-template name="getFieldByIndex">
|
||||
<xsl:with-param name="index" select="$stopdepthField"/>
|
||||
<xsl:with-param name="line" select="$line"/>
|
||||
</xsl:call-template>
|
||||
</xsl:variable>
|
||||
<xsl:attribute name="stopdepth">
|
||||
<xsl:copy-of select="$stopdepth"/>
|
||||
</xsl:attribute>
|
||||
|
||||
<xsl:attribute name="in_deco">
|
||||
<xsl:choose>
|
||||
<xsl:when test="$stopdepth > 0">1</xsl:when>
|
||||
<xsl:otherwise>0</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
</sample>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
|
Loading…
Add table
Reference in a new issue