summaryrefslogtreecommitdiffstats
path: root/xslt/udcf.xslt
diff options
context:
space:
mode:
Diffstat (limited to 'xslt/udcf.xslt')
-rw-r--r--xslt/udcf.xslt24
1 files changed, 24 insertions, 0 deletions
diff --git a/xslt/udcf.xslt b/xslt/udcf.xslt
index 982516fee..4f3362638 100644
--- a/xslt/udcf.xslt
+++ b/xslt/udcf.xslt
@@ -5,12 +5,30 @@
<xsl:template match="/">
<divelog program="subsurface" version="2">
+ <settings>
+ <divecomputerid deviceid="ffffffff">
+ <xsl:apply-templates select="/PROFILE/DEVICE|/profile/device"/>
+ </divecomputerid>
+ </settings>
<dives>
<xsl:apply-templates select="/PROFILE/REPGROUP/DIVE|/profile/repgroup/dive"/>
</dives>
</divelog>
</xsl:template>
+ <xsl:template match="DEVICE|device">
+ <xsl:if test="MODEL|model != ''">
+ <xsl:attribute name="model">
+ <xsl:value-of select="MODEL|model"/>
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:if test="version|VERSION != ''">
+ <xsl:attribute name="serial">
+ <xsl:value-of select="VERSION|version"/>
+ </xsl:attribute>
+ </xsl:if>
+ </xsl:template>
+
<xsl:template match="DIVE|dive">
<dive>
<xsl:attribute name="date">
@@ -39,6 +57,12 @@
</temperature>
</xsl:if>
+ <divecomputer deviceid="ffffffff">
+ <xsl:attribute name="model">
+ <xsl:value-of select="/PROFILE/DEVICE/MODEL|/profile/device/model"/>
+ </xsl:attribute>
+ </divecomputer>
+
<xsl:for-each select="GASES/MIX|gases/mix">
<cylinder>
<xsl:attribute name="description">