mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-19 06:15:26 +00:00
CSV import might have time in sec.fraction format
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
c78bbf6883
commit
b88d403fb6
1 changed files with 2 additions and 2 deletions
|
@ -226,14 +226,14 @@
|
|||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
<xsl:when test="number(translate($value, ',', '.')) = translate($value, ',', '.')">
|
||||
<!-- We assume time in seconds -->
|
||||
|
||||
<!-- We assume time in seconds with possibly fractions -->
|
||||
<xsl:call-template name="sec2time">
|
||||
<xsl:with-param name="timeSec">
|
||||
<xsl:choose>
|
||||
<xsl:when test="substring-after($value, '.') != ''">
|
||||
<!-- Well, I suppose it was min.sec -->
|
||||
<xsl:value-of select="substring-before($value, '.') * 60 + substring-after($value, '.')" />
|
||||
<xsl:value-of select="substring-before($value, '.') * 60 + substring(substring-after($value, '.') * 60, 1, 2)" />
|
||||
</xsl:when>
|
||||
<xsl:when test="substring-after($value, ',') != ''">
|
||||
<!-- Well, I suppose it was min.sec -->
|
||||
|
|
Loading…
Add table
Reference in a new issue