generateRecipientsSummary.xslt 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. Licensed Materials - Property of IBM
  4. IBM Cognos Products: ASV
  5. (C) Copyright IBM Corp. 2005, 2010
  6. US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  7. -->
  8. <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  9. xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/"
  10. xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
  11. xmlns:xts="http://developer.cognos.com/schemas/xts/"
  12. exclude-result-prefixes="xtsext cm xts">
  13. <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
  14. <xsl:template match="*">
  15. <xsl:choose>
  16. <xsl:when test="./asParam='true'">
  17. <param name="taskDescription">
  18. <xsl:call-template name="genDescription"/>
  19. </param>
  20. </xsl:when>
  21. <xsl:otherwise>
  22. <xsl:call-template name="genDescription"/>
  23. </xsl:otherwise>
  24. </xsl:choose>
  25. </xsl:template>
  26. <xsl:template name="genDescription">
  27. <xsl:choose>
  28. <xsl:when test="/root/*[local-name()='queryResponse']/*[local-name()='queryReply']/*/*[local-name()='userName'] != ''">
  29. <xts:string id ="IDS_EMAIL_DISPLAY_USER">
  30. <xts:param name="defaultName"><xsl:value-of select="/root/*[local-name()='queryResponse']/*[local-name()='queryReply']/*/*[local-name()='defaultName']"/></xts:param>
  31. <xts:param name="userName"><xsl:value-of select="/root/*[local-name()='queryResponse']/*[local-name()='queryReply']/*/*[local-name()='userName']"/></xts:param>
  32. </xts:string>
  33. </xsl:when>
  34. <xsl:when test="/root/*[local-name()='queryResponse']/*[local-name()='queryReply']/*/*[local-name()='defaultName'] != ''">
  35. <xsl:value-of select="/root/*[local-name()='queryResponse']/*[local-name()='queryReply']/*/*[local-name()='defaultName']"/>
  36. </xsl:when>
  37. <xsl:otherwise><xts:string id="IDS_OTHERRUN_EMAIL_UNKNOWN_RECIPIENT"/></xsl:otherwise>
  38. </xsl:choose>
  39. </xsl:template>
  40. </xsl:stylesheet>