[Libreoffice-commits] core.git: filter/source

Mike Kaganski mike.kaganski at collabora.com
Fri May 5 19:07:53 UTC 2017


 filter/source/xslt/import/spreadsheetml/adorowset2ods.xsl |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 8d10be803ce0598489aa102953473fb9ea95db6e
Author: Mike Kaganski <mike.kaganski at collabora.com>
Date:   Fri May 5 21:08:32 2017 +0300

    tdf#106525: fix date import
    
    Change-Id: I81c1cc58b0201412f650854fa9ebf920b4df68bd
    Reviewed-on: https://gerrit.libreoffice.org/37302
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Mike Kaganski <mike.kaganski at collabora.com>

diff --git a/filter/source/xslt/import/spreadsheetml/adorowset2ods.xsl b/filter/source/xslt/import/spreadsheetml/adorowset2ods.xsl
index d8e77f39a047..727dd1df150a 100644
--- a/filter/source/xslt/import/spreadsheetml/adorowset2ods.xsl
+++ b/filter/source/xslt/import/spreadsheetml/adorowset2ods.xsl
@@ -88,7 +88,8 @@
                 <xsl:attribute name="office:value"><xsl:value-of select="$thisCellValue"/></xsl:attribute>
               </xsl:when>
               <xsl:when test="$thisColType='date'">
-                <xsl:attribute name="office:date-value"><xsl:value-of select="$thisCellValue"/></xsl:attribute>
+                <!-- We need to convert '2017-04-06 00:40:40' to '2017-04-06T00:40:40', so replace space with 'T' -->
+                <xsl:attribute name="office:date-value"><xsl:value-of select="translate($thisCellValue,' ','T')"/></xsl:attribute>
               </xsl:when>
               <xsl:when test="$thisColType='time'">
                 <xsl:attribute name="office:time-value"><xsl:value-of select="$thisCellValue"/></xsl:attribute>


More information about the Libreoffice-commits mailing list