CSV import: support for decimal comma on temperature

Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Miika Turkia 2016-11-09 21:39:25 +02:00 committed by Dirk Hohndel
parent 50ea5ec296
commit c78bbf6883

View file

@ -290,10 +290,10 @@
<xsl:attribute name="temp">
<xsl:choose>
<xsl:when test="$units = 0">
<xsl:value-of select="$temp"/>
<xsl:value-of select="translate($temp, ',', '.')"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="concat(format-number(($temp - 32) * 5 div 9, '0.0'), ' C')"/>
<xsl:value-of select="concat(format-number((translate($temp, ',', '.') - 32) * 5 div 9, '0.0'), ' C')"/>
</xsl:otherwise>
</xsl:choose>
</xsl:attribute>