diff options
author | Miika Turkia <miika.turkia@gmail.com> | 2018-02-15 06:44:37 +0200 |
---|---|---|
committer | mturkia <miika.turkia@gmail.com> | 2018-02-15 17:54:05 +0200 |
commit | b0eca5cb3212f76e664b4a9745aeb07fe7b52d6f (patch) | |
tree | 0686f2f47a57edac800a2d4b1af46aeccb6ac582 /xslt/udcf.xslt | |
parent | 006e00ebc44c7698104795c22b963d00f664ef84 (diff) | |
download | subsurface-b0eca5cb3212f76e664b4a9745aeb07fe7b52d6f.tar.gz |
Convert cylinder volume to metric
This is a rough conversion from cuft to liters. Should be close enough
when we don't have working pressure to do the real calculation. (As far
as I know, this is the case with UDCF.)
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Diffstat (limited to 'xslt/udcf.xslt')
-rw-r--r-- | xslt/udcf.xslt | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/xslt/udcf.xslt b/xslt/udcf.xslt index b39d0267a..4f111347c 100644 --- a/xslt/udcf.xslt +++ b/xslt/udcf.xslt @@ -85,7 +85,14 @@ <xsl:value-of select="MIXNAME|mixname"/> </xsl:attribute> <xsl:attribute name="size"> - <xsl:value-of select="concat(TANK/TANKVOLUME|tank/tankvolume, ' l')"/> + <xsl:choose> + <xsl:when test="$units = 'Imperial'"> + <xsl:value-of select="concat(TANK/TANKVOLUME|tank/tankvolume div 7, ' l')"/> + </xsl:when> + <xsl:otherwise> + <xsl:value-of select="concat(TANK/TANKVOLUME|tank/tankvolume, ' l')"/> + </xsl:otherwise> + </xsl:choose> </xsl:attribute> <xsl:attribute name="start"> <xsl:call-template name="pressureConvert"> |