123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176 |
- <xts:morphlet xmlns:xts="http://developer.cognos.com/schemas/xts/" messageBase="messages/AGS.xml,messages/portal.xml,messages/portalRL.xml" requiredCapability="canUseEventStudio">
- <!--
- Licensed Materials - Property of IBM
-
- IBM Cognos Products: AGS
-
- (C) Copyright IBM Corp. 2005, 2014
-
- US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- -->
- <!--
- ===============================================================================================
- formlogic_init - standard form logic initialization dependency="storePreviousTab"
- ===============================================================================================
- -->
- <xts:block id="formlogic_init" type="exec" mode="interpret" processor="XSLT" path="/logicsheets/formlogic_init.xslt"/>
-
- <xts:block id="decode_agent_definition" processor="XSLT" type="exec">
- <xts:logicsheet path="logicsheets/presentation/dialog/templates.xsl"/>
- <xts:logicsheet path="logicsheets/buslogic.xslt"/>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt">
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
- <xsl:template match="/">
- <xts:sequence>
- <xsl:choose>
- <xsl:when test="/root/env/param[@name = 'agent_definition_blob']">
- <!-- decode the agent items -->
- <xts:append select="/root">
- <xsl:value-of select="xtsext:web64decode( xtsext:cafaction('sign_unwrap_settemplatename_decodeagentdefinition_settemplateid_presave001', string( /root/env/param[@name = 'agent_definition_blob'])), true() )" disable-output-escaping="yes"/>
- </xts:append>
- </xsl:when>
- </xsl:choose>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
-
- <!--
- ===========================================================================
- checkForEventOutput
- ===========================================================================
- -->
- <xts:block id="checkForEventOutput" dependency="decode_agent_definition" processor="XSLT" condition="/root/agent_definition/agentDefinition" mandatory="false" type="exec">
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <xts:logicsheet path="logicsheets/buslogic.xslt"/>
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:form="http://developer.cognos.com/schemas/xts/ags/iFrmCmd/1/"
- xmlns:send="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/brl/1/"
- xmlns:xtscm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:pf="http://developer.cognos.com/schemas/xts/pf"
- xmlns:bus="http://developer.cognos.com/schemas/bibus/3/"
- xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:x="x" 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:xts="http://developer.cognos.com/schemas/xts/"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
- exclude-result-prefixes="form send xtscm pf bus cm x SOAP-ENC SOAP-ENV xsi xts xtsext">
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
- <xsl:template match="/">
- <xts:sequence>
- <xts:append>
- <outputResponse>
- <send:request provider="cm" outputHeader="true" responseEnvelope="true" requester="AGS:reset_event_list">
- <xts:transform src="transforms/CM/pre-process.xslt" processor="XSLT">
- <cm:query>
- <cm:search>/transientStateFolder/agentState[containsReferences(@definition, <xsl:value-of select="/root/agent_definition/agentDefinition"/>)]/reportView/reportVersion/*</cm:search>
- <cm:properties>
- <cm:property name="searchPath"/>
- </cm:properties>
- </cm:query>
- </xts:transform>
- </send:request>
- </outputResponse>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
-
- <!--
- ===========================================================================
- doResetEventList
- ===========================================================================
- -->
- <xts:block id="doResetEventList" dependency="checkForEventOutput" processor="XSLT" condition=".[/root/agent_definition/agentDefinition and count(/root/outputResponse//*[local-name()='queryResponse']//*[local-name()='item']) > 0 and (not(/root/outputResponse/soapFault) or not(/root/outputResponse/authenticationFault)) ]" mandatory="false" type="exec">
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <xts:logicsheet path="logicsheets/buslogic.xslt"/>
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:form="http://developer.cognos.com/schemas/xts/ags/iFrmCmd/1/"
- xmlns:send="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/brl/1/"
- xmlns:xtscm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:pf="http://developer.cognos.com/schemas/xts/pf"
- xmlns:bus="http://developer.cognos.com/schemas/bibus/3/"
- xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:x="x" 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:xts="http://developer.cognos.com/schemas/xts/"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
- exclude-result-prefixes="form send xtscm pf bus cm x SOAP-ENC SOAP-ENV xsi xts xtsext">
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
- <xsl:template match="/">
- <xts:sequence>
- <xts:append>
- <resetEventListResponse>
- <xts:request href="bus://dispatcher" protocol="BUS" responseEnvelope="true" option="xml-multipart" outputHeader="true">
- <xsl:attribute name="soapAction"><xsl:text>http://www.ibm.com/xmlns/prod/cognos/agentService/201505/</xsl:text></xsl:attribute>
- <SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
- <SOAP-ENV:Header>
- <bus:biBusHeader xsi:type="bus:biBusHeader">
- <xsl:copy-of select="/root/header/bus:biBusHeader/*"/>
- </bus:biBusHeader>
- </SOAP-ENV:Header>
- <SOAP-ENV:Body>
- <bus:deleteHotList xmlns:bus="http://developer.cognos.com/schemas/bibus/3/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
- <objectPath xsi:type="bus:searchPathSingleObject">
- <xsl:value-of select="/root/agent_definition/agentDefinition"/>
- </objectPath>
- </bus:deleteHotList>
- </SOAP-ENV:Body>
- </SOAP-ENV:Envelope>
- </xts:request>
- </resetEventListResponse>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <!--
- ===============================================================================================
- processResult - add the results of the request into the right place
- ===============================================================================================
- -->
- <xts:block id="processResult" mode="output" mimeType="application/xml; charset=utf-8" processor="XSLT" type="exec" dependency="doResetEventList" mandatory="false">
- <xts:logicsheet path="logicsheets/buslogic.xslt"/>
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
- xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:pf="http://developer.cognos.com/schemas/xts/pf"
- xmlns:bus="http://developer.cognos.com/schemas/bibus/3/"
- xmlns:send="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/brl/1/"
- xmlns:cml="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/cml/1/"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:xos="http://developer.cognos.com/schemas/xts/output/"
- exclude-result-prefixes="xtsext SOAP-ENV pf bus send cml xsi xos">
- <xsl:output method="xml" version="1.0" encoding="UTF-8"/>
- <xsl:template match="/root">
- <xsl:choose>
- <xsl:when test="not(./agent_definition/agentDefinition) or ./agent_definition/agentDefinition = ''">
- <xsl:variable name="msg1">
- <xts:string id="SAVE_AGENT_FIRST"/>
- </xsl:variable>
- <message><xsl:value-of select="normalize-space(xtsext:javascriptencode($msg1))"/></message>
- </xsl:when>
- <xsl:when test="./agent_definition/agentDefinition and ./agent_definition/agentDefinition != '' and count(./outputResponse//*[local-name()='queryResponse']//*[local-name()='item']) > 0 ">
- <xsl:variable name="msg2">
- <xts:string id="RESET_AGENT_SUCCESSFUL"/>
- </xsl:variable>
- <message><xsl:value-of select="normalize-space(xtsext:javascriptencode($msg2))"/></message>
- </xsl:when>
- <xsl:when test="./agent_definition/agentDefinition and ./agent_definition/agentDefinition != '' and count(./outputResponse//*[local-name()='queryResponse']//*[local-name()='item']) = 0 ">
- <xsl:variable name="msg3">
- <xts:string id="RUN_AGENT_FIRST"/>
- </xsl:variable>
- <message><xsl:value-of select="normalize-space(xtsext:javascriptencode($msg3))"/></message>
- </xsl:when>
- </xsl:choose>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- </xts:morphlet>
|