UDDF Export: Moved equipmentused to informationbeforedive section as per updated spec

Signed-off-by: Martin Long <martin@longhome.co.uk>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Martin Long 2015-02-11 21:20:55 +00:00 committed by Dirk Hohndel
parent 9b6c546244
commit dca78fe6fc

View file

@ -279,6 +279,20 @@
<xsl:value-of select="format-number(substring-before(., ' ') + 273.15, '0.00')"/> <xsl:value-of select="format-number(substring-before(., ' ') + 273.15, '0.00')"/>
</airtemperature> </airtemperature>
</xsl:for-each> </xsl:for-each>
<xsl:variable name="trimmedweightlist">
<xsl:for-each select="weightsystem">
<weight>
<xsl:value-of select="substring-before(@weight, ' ')"/>
</weight>
</xsl:for-each>
</xsl:variable>
<xsl:if test="sum(xt:node-set($trimmedweightlist)/node()) >= 0">
<equipmentused>
<leadquantity>
<xsl:value-of select="sum(xt:node-set($trimmedweightlist)/node())"/>
</leadquantity>
</equipmentused>
</xsl:if>
<xsl:if test="parent::trip"> <xsl:if test="parent::trip">
<tripmembership ref="trip{generate-id(..)}"/> <tripmembership ref="trip{generate-id(..)}"/>
</xsl:if> </xsl:if>
@ -534,14 +548,6 @@
</samples> </samples>
<informationafterdive> <informationafterdive>
<xsl:variable name="trimmedweightlist">
<xsl:for-each select="weightsystem">
<weight>
<xsl:value-of select="substring-before(@weight, ' ')"/>
</weight>
</xsl:for-each>
</xsl:variable>
<xsl:if test="node()/depth/@max != ''"> <xsl:if test="node()/depth/@max != ''">
<greatestdepth> <greatestdepth>
<xsl:value-of select="substring-before(node()/depth/@max, ' ')"/> <xsl:value-of select="substring-before(node()/depth/@max, ' ')"/>
@ -605,14 +611,6 @@
</xsl:when> </xsl:when>
</xsl:choose> </xsl:choose>
</visibility> </visibility>
<equipmentused>
<leadquantity>
<xsl:if test="sum(xt:node-set($trimmedweightlist)/node()) >= 0">
<xsl:value-of select="sum(xt:node-set($trimmedweightlist)/node())"/>
</xsl:if>
</leadquantity>
</equipmentused>
</informationafterdive> </informationafterdive>
</dive> </dive>