summaryrefslogtreecommitdiffstats
path: root/xslt/xml2csv.xslt
diff options
context:
space:
mode:
authorGravatar Stefan Fuchs <sfuchs@gmx.de>2018-03-12 07:22:59 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-03-19 11:59:58 -0700
commit46f1fea1b6d1d85adc1b4d56ff75b07a292915d4 (patch)
treea1d278572e2ace53d20a9224193ea81f04ee371c /xslt/xml2csv.xslt
parentfc01045680230e3d8a85b74520b268eea42a67b1 (diff)
downloadsubsurface-46f1fea1b6d1d85adc1b4d56ff75b07a292915d4.tar.gz
CSV export: Correct numeric format for depth
Add two missing format-number functions for mean depth in dive list export and depth in dive profile export. Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
Diffstat (limited to 'xslt/xml2csv.xslt')
-rw-r--r--xslt/xml2csv.xslt4
1 files changed, 2 insertions, 2 deletions
diff --git a/xslt/xml2csv.xslt b/xslt/xml2csv.xslt
index e4a40cc74..a0492cbba 100644
--- a/xslt/xml2csv.xslt
+++ b/xslt/xml2csv.xslt
@@ -41,10 +41,10 @@
<xsl:value-of select="$fs"/>
<xsl:choose>
<xsl:when test="$units = 1">
- <xsl:value-of select="concat('&quot;', round((substring-before(@depth, ' ') div 0.3048) * 1000) div 1000, '&quot;')"/>
+ <xsl:value-of select="concat('&quot;', format-number(substring-before(@depth, ' ') div 0.3048, '#.###'), '&quot;')"/>
</xsl:when>
<xsl:otherwise>
- <xsl:value-of select="concat('&quot;', round(substring-before(@depth, ' ') * 1000) div 1000, '&quot;')"/>
+ <xsl:value-of select="concat('&quot;', format-number(substring-before(@depth, ' '), '#.###'), '&quot;')"/>
</xsl:otherwise>
</xsl:choose>