Show
Ignore:
Timestamp:
04/13/11 12:42:05 (13 years ago)
Author:
yaolu
Message:

fixed duration calculation that was missing from previous commits

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • projects/DailyDrillingReport_1.2/XML/PDFreport/ddr_PDFReport_transformation_2011_03_09.xsl

    r190 r192  
    11<?xml version="1.0" encoding="UTF-8" standalone="yes"?> 
    22<xslt:stylesheet xmlns:date="http://exslt.org/dates-and-times" xmlns:str="http://exslt.org/strings" xmlns:xslt="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:xf="http://www.ecrion.com/xf/1.0" xmlns:xc="http://www.ecrion.com/2008/xc" xmlns:xfd="http://www.ecrion.com/xfd/1.0" xmlns:svg="http://www.w3.org/2000/svg" xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:witsml="http://www.witsml.org/schemas/1series" xmlns:sawsdl="http://www.w3.org/ns/sawsdl" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" extension-element-prefixes="date str"> 
     3        <xsl:import href="./difference/date.difference.xsl"/> 
    34        <xslt:output indent="yes" encoding="utf-8"/> 
    45        <xslt:param name="XFCrtLocalDate">2011-04-06</xslt:param> 
     
    42284229                                                                                                        <xsl:for-each select="/witsml:drillReports/witsml:drillReport/witsml:perfInfo"> 
    42294230                                                                                                                <fo:table-row> 
     4231                                                                                                                        <xsl:variable name="duration"> 
     4232                                                                                                                                <xsl:call-template name="date:difference"> 
     4233                                                                                                                                        <xsl:with-param name="start" select="substring(witsml:dTimOpen, 0, 20)"/> 
     4234                                                                                                                                        <xsl:with-param name="end" select="substring(witsml:dTimClose, 0, 20)"/> 
     4235                                                                                                                                </xsl:call-template> 
     4236                                                                                                                        </xsl:variable> 
    42304237                                                                                                                        <fo:table-cell> 
    42314238                                                                                                                                <fo:block> 
     
    42484255                                                                                                                        <fo:table-cell> 
    42494256                                                                                                                                <fo:block> 
    4250                                                                                                                                         <xslt:comment>&lt;xfd:field xpath="substring-after(xsl:dateTime(witsml:dTimClose) - xsl:dateTime(witsml:dTimOpen), 'PT')"/&gt;</xslt:comment> 
    4251                                                                                                                 duration 
     4257                                                                                                                                        <xsl:value-of select="substring-after($duration, 'PT')"/> 
    42524258                                                                                                                                </fo:block> 
    42534259                                                                                                                        </fo:table-cell>