mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-19 14:25:27 +00:00
CSV import: add min:sec format support
On CSV import the time can be represented with seconds, min:sec or hour:min:sec. This patch adds support for the min:sec format that was missing. See #662 Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
0b5fe99353
commit
28bd1fdcb5
1 changed files with 5 additions and 0 deletions
|
@ -105,6 +105,11 @@
|
|||
</xsl:with-param>
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
<xsl:when test="substring-after(substring-after($value, ':'), ':') = ''">
|
||||
<!-- We assume time format m:s -->
|
||||
|
||||
<xsl:value-of select="substring-before($value, ':') * 60 + substring-after($value, ':')" />
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<!-- We assume time format h:m:s -->
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue