mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Fix import when locale set to decimal comma
This should take care of locale caused problems when the input uses decimal point but locale uses decimal comma. Also the sample I have of Suunto DM3 format weight is represented with comma instead of dot so converting that as well. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
2120bc3a9e
commit
a9cc7f9b10
4 changed files with 9 additions and 9 deletions
|
@ -65,7 +65,7 @@
|
|||
<xsl:if test="WEIGTH != ''">
|
||||
<weightsystem>
|
||||
<xsl:attribute name="weight">
|
||||
<xsl:value-of select="concat(WEIGTH, ' kg')"/>
|
||||
<xsl:value-of select="concat(translate(WEIGTH, ',', '.'), ' kg')"/>
|
||||
</xsl:attribute>
|
||||
</weightsystem>
|
||||
</xsl:if>
|
||||
|
@ -240,7 +240,7 @@
|
|||
|
||||
<xsl:choose>
|
||||
<xsl:when test="$number != ''">
|
||||
<xsl:value-of select="concat(($number div 1000), ' bar')"/>
|
||||
<xsl:value-of select="concat(format-number(($number div 1000), '#.##'), ' bar')"/>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>0</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue