123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379 |
- <xts:morphlet xmlns:xts="http://developer.cognos.com/schemas/xts/" requiredCapability="canUseQueryStudio">
- <!--
- Licensed Materials - Property of IBM
- BI and PM: qs
- (C) Copyright IBM Corp. 2001, 2019
- US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- -->
- <!--
- Copyright (C) 2008 Cognos ULC, an IBM Company. All rights reserved.
- Cognos (R) is a trademark of Cognos ULC, (formerly Cognos Incorporated).
- -->
- <xts:block id="convertParameters" condition=".[/root/env/param[@name='xxExecutionParameters']!='']" mode="interpret" processor="XSLT" type="exec" mandatory="false">
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt">
- <xsl:template match="/">
- <xts:sequence>
- <xts:append select="/root">
- <executionParameters>
- <xsl:choose>
- <xsl:when test="starts-with(/root/env/param[@name='xxExecutionParameters'], 'CAF')">
- <xsl:value-of select="xtsext:web64decode(xtsext:cafaction('sign_unwrap_settemplatename_filterpicklist_settemplateid_01', string(/root/env/param[@name='xxExecutionParameters'])), true())" disable-output-escaping="yes"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="xtsext:web64decode(string(/root/env/param[@name='xxExecutionParameters']), true())" disable-output-escaping="yes"/>
- </xsl:otherwise>
- </xsl:choose>
- </executionParameters>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <xts:block id="wait" condition=".[/root/env/param[@name='ui.action']='wait']" mode="interpret" processor="XSLT" type="exec" mandatory="false">
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
- xmlns:xos="http://developer.cognos.com/schemas/xts/output/"
- xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:bus="http://developer.cognos.com/schemas/bibus/3/"
- xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- exclude-result-prefixes="xsl xtsext xos cm bus SOAP-ENV xsi">
- <xsl:output method="xml"/>
- <xsl:template match="/root">
- <xts:sequence>
- <xts:append select="/root">
- <doWait/>
- </xts:append>
- <xts:append select="/root">
- <xts:request href="bus://dispatcher" protocol="BUS" responseEnvelope="true" outputHeader="true" soapAction="http://www.ibm.com/xmlns/prod/cognos/reportService/201404/.absolute">
- <SOAP-ENV:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <SOAP-ENV:Header>
- <bus:biBusHeader xsi:type="bus:biBusHeader" xmlns:bus="http://developer.cognos.com/schemas/bibus/3/">
- <xsl:if test="/root/env/param[@name='m_tracking']!='' or /root/header/bus:biBusHeader/bus:tracking">
- <bus:tracking>
- <xsl:choose>
- <xsl:when test="/root/env/param[@name='m_tracking']!=''">
- <xsl:value-of select="xtsext:web64decode(xtsext:cafaction('sign_unwrap', string(/root/env/param[@name='m_tracking'])), true())" disable-output-escaping="yes"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-templates select="/root/header/bus:biBusHeader/bus:tracking"/>
- </xsl:otherwise>
- </xsl:choose>
- </bus:tracking>
- </xsl:if>
- <xsl:choose>
- <xsl:when test="/root/env/param[@name='ui.routingServerGroup']!=''">
- <bus:routing>
- <routingServerGroup>
- <xsl:value-of select="/root/env/param[@name='ui.routingServerGroup']"/>
- </routingServerGroup>
- </bus:routing>
- <xsl:apply-templates select="/root/header/bus:biBusHeader/*[local-name()!='routing' and local-name()!='tracking']"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-templates select="/root/header/bus:biBusHeader/*[local-name()!='tracking']"/>
- </xsl:otherwise>
- </xsl:choose>
- </bus:biBusHeader>
- </SOAP-ENV:Header>
- <SOAP-ENV:Body>
- <xsl:element name="wait" namespace="http://developer.cognos.com/schemas/reportService/1">
- <bus:conversation xsi:type="bus:asynchRequest" xsi:nil="true"/>
- <parameterValues xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:parameterValue[]"/>
- <options xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:option[]"/>
- </xsl:element>
- </SOAP-ENV:Body>
- </SOAP-ENV:Envelope>
- </xts:request>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- <xsl:template match="*">
- <xsl:copy>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </xsl:copy>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <xts:block id="getOutput" condition=".[(/root/*[local-name()='doWait']) and (/root/*[local-name()='Envelope']/*[local-name()='Body']/*/*[local-name()='result']/*[local-name()='details']/*[local-name()='item']/*[local-name()='status']='responseReady')]" mode="interpret" processor="XSLT" type="exec" dependency="wait" mandatory="false">
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
- xmlns:xos="http://developer.cognos.com/schemas/xts/output/"
- xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:bus="http://developer.cognos.com/schemas/bibus/3/"
- xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- exclude-result-prefixes="xsl xtsext xos cm bus SOAP-ENV xsi">
- <xsl:output method="xml"/>
- <xsl:template match="/root">
- <xts:sequence>
- <xts:replace select="/root/*[local-name()='Envelope']">
- <xts:request href="bus://dispatcher" protocol="BUS" responseEnvelope="true" outputHeader="true" soapAction="http://www.ibm.com/xmlns/prod/cognos/reportService/201404/.absolute">
- <SOAP-ENV:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <SOAP-ENV:Header>
- <bus:biBusHeader xsi:type="bus:biBusHeader" xmlns:bus="http://developer.cognos.com/schemas/bibus/3/">
- <xsl:if test="/root/env/param[@name='m_tracking']!='' or /root/header/bus:biBusHeader/bus:tracking">
- <bus:tracking>
- <xsl:choose>
- <xsl:when test="/root/env/param[@name='m_tracking']!=''">
- <xsl:value-of select="xtsext:web64decode(xtsext:cafaction('sign_unwrap', string(/root/env/param[@name='m_tracking'])), true())" disable-output-escaping="yes"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-templates select="/root/header/bus:biBusHeader/bus:tracking"/>
- </xsl:otherwise>
- </xsl:choose>
- </bus:tracking>
- </xsl:if>
- <xsl:choose>
- <xsl:when test="/root/env/param[@name='ui.routingServerGroup']!=''">
- <bus:routing>
- <routingServerGroup>
- <xsl:value-of select="/root/env/param[@name='ui.routingServerGroup']"/>
- </routingServerGroup>
- </bus:routing>
- <xsl:apply-templates select="/root/header/bus:biBusHeader/*[local-name()!='routing' and local-name()!='tracking']"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-templates select="/root/header/bus:biBusHeader/*[local-name()!='tracking']"/>
- </xsl:otherwise>
- </xsl:choose>
- </bus:biBusHeader>
- </SOAP-ENV:Header>
- <SOAP-ENV:Body>
- <xsl:element name="getOutput" namespace="http://developer.cognos.com/schemas/reportService/1">
- <bus:conversation xsi:type="bus:asynchRequest" xsi:nil="true"/>
- <parameterValues xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:parameterValue[]"/>
- <options xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:option[]"/>
- </xsl:element>
- </SOAP-ENV:Body>
- </SOAP-ENV:Envelope>
- </xts:request>
- </xts:replace>
- </xts:sequence>
- </xsl:template>
- <xsl:template match="*">
- <xsl:copy>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </xsl:copy>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <xts:block id="getContent" condition=".[not(/root/*[local-name()='doWait'])]" mode="interpret" processor="XSLT" type="exec" dependency="getOutput convertParameters" mandatory="false">
- <xts:logicsheet path="logicsheets/buslogic.xslt"/>
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:SOAP-ENV="http://www.w3.org/2001/09/soap-envelope" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt" xmlns:bus="http://developer.cognos.com/schemas/bibus/3/">
- <xsl:output method="xml" version="1.0" encoding="UTF-8"/>
- <xsl:key name="env-param" match="/root/env/param" use="@name"/>
- <xsl:template match="/">
- <xts:sequence>
- <xts:append>
- <xts:request responseEnvelope="true" outputHeader="true" asText="true" href="bus://dispatcher" protocol="BUS" soapAction="http://www.ibm.com/xmlns/prod/cognos/reportService/201404/" faultBlock="faultHandler">
- <SOAP-ENV:Envelope xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xs="http://www.w3.org/2001/XMLSchema">
- <SOAP-ENV:Header>
- <bus:biBusHeader xsi:type="bus:biBusHeader">
- <!--<xsl:choose>
- <xsl:when test="/root/env/param[@name='ui.routingServerGroup']!=''">
- <bus:routing>
- <routingServerGroup>
- <xsl:value-of select="/root/env/param[@name='ui.routingServerGroup']"/>
- </routingServerGroup>
- </bus:routing>
- <xsl:apply-templates select="/root/header/bus:biBusHeader/*[local-name()!='routing' and local-name() != 'dispatcherTransportVars']"/>
- </xsl:when>
- <xsl:otherwise>
- --><!-- For bug 611371. Don't copy the dispatcherTransportVars since these are copied directly from
- the browser. This can cause permission problems due to a 'front' = 'true' variable signifying
- this as an external request, even though it's internal. --><!--
- <xsl:apply-templates select="/root/header/bus:biBusHeader/*[local-name() != 'dispatcherTransportVars']"/>
- </xsl:otherwise>
- </xsl:choose>-->
- <xsl:if test="/root/env/param[@name='markup_track']!=''">
- <xsl:value-of select="xtsext:web64decode(xtsext:cafaction('sign_unwrap', string(key('env-param','markup_track'))), true())" disable-output-escaping="yes"/>
- </xsl:if>
- <xsl:apply-templates select="/root/header/*[local-name() = 'biBusHeader']/*[local-name() != 'tracking' and local-name() != 'dispatcherTransportVars']"/>
- <xsl:if test="string(/root/env/param[@name='ui.routingServerGroup'])!=''">
- <bus:routing xsi:type="bus:routingInfo">
- <routingServerGroup>
- <xsl:value-of select="/root/env/param[@name='ui.routingServerGroup']"/>
- </routingServerGroup>
- </bus:routing>
- </xsl:if>
- </bus:biBusHeader>
- </SOAP-ENV:Header>
- <SOAP-ENV:Body>
- <runSpecification xmlns="http://developer.cognos.com/schemas/reportService/1">
- <specification xsi:type="bus:reportServiceReportSpecification">
- <bus:value xsi:type="bus:specification">
- <report expressionLocale="<xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name='xxExprLocale']))"/>" xmlns="http://developer.cognos.com/schemas/report/5.0/">
- <layouts>
- <layout>
- <reportPages>
- <page name="PromptPage">
- <pageBody>
- <contents>
- <selectValue parameter="Parameter1" refQuery="Query1">
- <useItem refDataItem="<xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name='xxColumnName']))"/>">
- <displayItem refDataItem="<xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name='xxColumnName']))"/>"/>
- </useItem>
- <sortList>
- <sortItem refDataItem="<xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name='xxColumnName']))"/>" sortOrder="ascending"/>
- </sortList>
- </selectValue>
- </contents>
- </pageBody>
- </page>
- </reportPages>
- </layout>
- </layouts>
- <modelPath><xsl:value-of select="xtsext:xmlencode(xtsext:urldecode(string(/root/env/param[@name='xxModelName'])))"/></modelPath>
- <queries>
- <query name="Query1">
- <source>
- <model/>
- </source>
- <selection>
- <dataItem name="<xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name='xxColumnName']))"/>" <xsl:if test="/root/env/param[@name='xxDetailAggregateType'] != ''">aggregate="<xsl:value-of select="/root/env/param[@name='xxDetailAggregateType']"/>"</xsl:if>>
- <expression>
- <xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name='xxColumnExpression']))"/>
- </expression>
- </dataItem>
- <xsl:for-each select="/root/env/param[@name='xxOtherCols']">
- <xsl:variable name="var"><xsl:value-of select="."/></xsl:variable>
- <xsl:variable name="colLabel"><xsl:value-of select="substring-before($var,',')"/></xsl:variable>
- <xsl:variable name="colExpr"><xsl:value-of select="substring-after($var,',')"/></xsl:variable>
- <dataItem name="<xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name=$colLabel]))"/>">
- <expression>
- <xsl:value-of select="xtsext:xmlencode(string(/root/env/param[@name=$colExpr]))"/>
- </expression>
- </dataItem>
- </xsl:for-each>
- </selection>
- </query>
- </queries>
- </report>
- </bus:value>
- </specification>
- <parameterValues xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:parameterValue[]">
- <xsl:for-each select="/root/env/param[@name='xxPromptValues']">
- <xsl:value-of select="." disable-output-escaping="yes"/>
- </xsl:for-each>
- <xsl:if test="/root/executionParameters">
- <xsl:copy-of select="/root/executionParameters/*[local-name()='parameters']/*"/>
- </xsl:if>
- </parameterValues>
- <options xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:option[]">
- <item xsi:type="bus:runOptionStringArray">
- <bus:name xsi:type="bus:runOptionEnum">outputFormat</bus:name>
- <bus:value xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="xsd:string[1]">
- <item>XHTML</item>
- </bus:value>
- </item>
- <item xsi:type="bus:runOptionAnyURI">
- <bus:name xsi:type="bus:runOptionEnum">xslURL</bus:name>
- <bus:value xsi:type="xsd:string">null.xsl</bus:value>
- </item>
- <item xsi:type="bus:asynchOptionInt">
- <bus:name xsi:type="bus:asynchOptionEnum">primaryWaitThreshold</bus:name>
- <bus:value xsi:type="xsd:int">3</bus:value>
- </item>
- <item xsi:type="bus:runOptionBoolean">
- <bus:name xsi:type="bus:runOptionEnum">prompt</bus:name>
- <bus:value xsi:type="xsd:boolean">false</bus:value>
- </item>
- <item xsi:type="bus:runOptionBoolean">
- <bus:name xsi:type="bus:runOptionEnum">selectionBasedFeatures</bus:name>
- <bus:value xsi:type="xsd:boolean">false</bus:value>
- </item>
- <xsl:if test="/root/env/param[@name='xxDesignMode'] = 'true'">
- <item xsi:type="bus:runOptionData">
- <bus:name xsi:type="bus:runOptionEnum">data</bus:name>
- <bus:value xsi:type="bus:dataEnum">previewWithLimitedData</bus:value>
- </item>
- </xsl:if>
- </options>
- </runSpecification>
- </SOAP-ENV:Body>
- </SOAP-ENV:Envelope>
- </xts:request>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- <xsl:template match="*">
- <xsl:copy>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </xsl:copy>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <xts:block id="appendDocument" mode="interpret" processor="XSLT" type="exec" dependency="getContent">
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:cm="http://developer.cognos.com/schemas/cm/1/" xmlns:bus="http://developer.cognos.com/schemas/bibus/3/" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt" exclude-result-prefixes="xsl xts cm bus xtsext">
- <xsl:output method="xml" version="1.0" encoding="UTF-8"/>
- <xsl:template match="/root">
- <xts:sequence>
- <xts:append select="/root">
- <xsl:value-of select="/root/*[local-name()='Envelope']/*[local-name()='Body']/*/*[local-name()='result']/*[local-name()='details']/*[local-name()='item']/*[local-name()='outputPages']/*[local-name()='item']" disable-output-escaping="yes"/>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <xts:block id="parseContent" mode="output" processor="XSLT" type="exec" mimeType="application/x-javascript" dependency="appendDocument">
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:pf="http://developer.cognos.com/schemas/xts/pf" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt" version="1.0">
- <xsl:output method="text" version="1.0" encoding="UTF-8" indent="no"/>
- <pf:variables/>
- <xsl:template match="/root">
- <xsl:choose>
- <xsl:when test="/root/*[local-name()='Envelope']/*[local-name()='Body']/*/*[local-name()='result']/*[local-name()='status']='working' or /root/*[local-name()='Envelope']/*[local-name()='Body']/*/*[local-name()='result']/*[local-name()='status']='stillWorking'">
- <xsl:text>var status='working';</xsl:text>
- <xsl:variable name="markup-track">
- <xsl:apply-templates select="/root/*[local-name()='Envelope']/*[local-name()='Header']/*[local-name()='biBusHeader']/*[local-name()='tracking']/*[local-name() = 'conversationContext']" mode="markup"/>
- </xsl:variable>
- <xsl:text>var tracking = '</xsl:text>
- <xsl:value-of select="xtsext:javascriptencode(string(xtsext:cafaction(concat('sign_wrap_setpassportid_', $passport), xtsext:web64encode(string($markup-track), true()))))"/>
- <xsl:text>';</xsl:text>
- </xsl:when>
- <xsl:when test="/root/logonFault">
- <xsl:text/>FAULT;timeout<xsl:text/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:if test="/root/Document/DATA/PAGE/OTR/OTD/selectValue/@dataType!=''">
- <xsl:text/>setupDataType("<xsl:value-of select="xtsext:javascriptencode(/root/Document/DATA/PAGE/OTR/OTD/selectValue/@dataType)"/>");<xsl:text/>
- </xsl:if>
- <xsl:for-each select="/root/Document/DATA/PAGE/OTR/OTD/selectValue/selectOptions/selectOption">
- <xsl:text/>addToAvailableValues("<xsl:value-of select="xtsext:javascriptencode(./@useValue)"/>","<xsl:value-of select="xtsext:javascriptencode(./@displayValue)"/>");<xsl:text/>
- </xsl:for-each>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:template>
- <pf:serialize-xml/>
- </xsl:stylesheet>
- </xts:block>
- <xts:block id="faultHandler" path="qs/logicsheets/faultHandler.xsl" type="fault" processor="XSLT"/>
- </xts:morphlet>
|