[PATCH] Fix locale originating decimal point on import
Lubomir I. Ivanov
neolit123 at gmail.com
Thu Mar 7 10:44:13 PST 2013
On 7 March 2013 20:43, Lubomir I. Ivanov <neolit123 at gmail.com> wrote:
> From: Miika Turkia <miika.turkia at gmail.com>
>
> This should take care of the decimal point problem for tank size when
> importing from divelogs.de. We have to keep formatting the numbers to
> our liking before and after math operation.
>
> Signed-off-by: Miika Turkia <miika.turkia at gmail.com>
> ---
> This is just a single issue fixed, I bet there are more lurking in
> there. If this really fixes the issue then I'll just go through all the
> XSLTs and do the same in all required math operations.
> ---
> xslt/divelogs.xslt | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/xslt/divelogs.xslt b/xslt/divelogs.xslt
> index 879fd3d..88b2420 100644
> --- a/xslt/divelogs.xslt
> +++ b/xslt/divelogs.xslt
> @@ -94,7 +94,7 @@
> </xsl:attribute>
> <xsl:if test="CYLINDERSIZE != ''">
> <xsl:attribute name="size">
> - <xsl:value-of select="CYLINDERSIZE + CYLINDERSIZE * DBLTANK"/>
> + <xsl:value-of select="format-number((format-number(CYLINDERSIZE, '#.##') + format-number(CYLINDERSIZE, '#.##') * DBLTANK), '#.##')"/>
> </xsl:attribute>
> </xsl:if>
> <xsl:if test="WORKINGPRESSURE > 0">
> --
> 1.7.9.5
>
oops wrong patch...
lubomir
--
More information about the subsurface
mailing list