123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: AGS
- (C) Copyright IBM Corp. 2005, 2015
- US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- -->
- <xts:morphlet xmlns:xts="http://developer.cognos.com/schemas/xts/" messageBase="messages/portal.xml" requiredCapability="canUseEventStudio">
- <!--
- =======================================================================================
- execute_report_viewer
-
- Make a page who's sole purpose is to get the report spec - and fire itself off to report viewer. Just make a form and post it
- =======================================================================================
- -->
- <xts:block id="execute_report_viewer" dependency="" mode="output" processor="XSLT" type="exec" mimeType="text/html">
- <!-- portal specific information -->
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <!-- Get the new theme framework. -->
- <xts:logicsheet path="logicsheets/presentation/dialog/presentation.xsl"/>
- <!-- apply the form logic -->
- <xts:logicsheet path="logicsheets/formlogic.xslt"/>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:pf="http://developer.cognos.com/schemas/xts/pf" xmlns:dp="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/presentation/" xmlns:utml="http://developer.cognos.com/schemas/xts/logicsheet/xslt/formlogic/" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt" xmlns:xts="http://developer.cognos.com/schemas/xts/" xmlns:x="x" exclude-result-prefixes="xsl dp pf utml xtsext x">
- <xsl:output method="html" version="1.0" encoding="UTF-8" indent="no"/>
- <!-- add any theme variables -->
- <pf:variables/>
- <!-- start the output -->
- <xsl:template match="root">
- <xsl:text disable-output-escaping='yes'><!DOCTYPE html></xsl:text><dp:page>
- <form name="pform" method="post" action="{$gateway}">
- <input type="hidden" name="b_action" id="b_action" value="cognosViewer"/>
- <input type="hidden" name="ui.action" id="ui.action" value="run"/>
- <input type="hidden" name="errURL" id="errURL" value="javascript:window.close();"/>
- <input type="hidden" name="ui.spec" id="ui.spec" value=""/>
- <input type="hidden" name="ui.format" id="ui.format" value="HTML"/>
- <input type="hidden" name="outputLocale" id="outputLocale" value=""/>
- <input type="hidden" name="outputPageDefinition" id="outputPageDefinition" value=""/>
- <input type="hidden" name="outputPageOrientation" id="outputPageOrientation" value=""/>
- <input type="hidden" name="verticalElements" id="verticalElements" value=""/>
- <input type="hidden" name="horizontalElements" id="horizontalElements" value=""/>
- <input type="hidden" name="prompt" id="prompt" value="true"/>
- <input type="hidden" name="ui.folder" id="ui.folder" value=""/>
- <input type="hidden" name="cafcontextid" id="cafcontextid" value="{/root/env/param[@name='cafcontextid']}"/>
- <input type="hidden" name="cv.toolbar" id="cv.toolbar" value="{/root/env/param[@name='cv.toolbar']}"/>
- <input type="hidden" name="cv.id" id="cv.id" value="{/root/env/param[@name='cv.id']}"/>
- <input type="hidden" name="ui.routingServerGroup" id="ui.routingServerGroup" value="{/root/env/param[@name='ui.routingServerGroup']}"/>
- </form>
- <dp:script>
- <script type="text/javascript">
-
- function init()
- {
- // have to ask the opening window to build us a report spec
- var noDataItems = window.opener.noDataItems();
- if(noDataItems)
- {
- var inline = window.opener.createHiddenInput(document, "m", "ags/noData.xts")
- document.pform.appendChild(inline);
- document.pform.b_action.value="xts.run";
- // submit it
- document.pform.submit();
- }
- else {
- runReport();
- }
- }
-
- function runReport() {
- //get the spec
- var inlineSpec = window.opener.cfgGet("inlineSpec");
- if (inlineSpec != undefined && inlineSpec != '') {
- // set the model path for server routing requirements
- document.pform['ui.folder'].value = window.opener.cfgGet("cmLastModel");
-
- // change some values - set the spec
- document.pform['ui.spec'].value=inlineSpec;
-
- // submit it
- document.pform.submit();
- }
-
- }
- </script>
- </dp:script>
- </dp:page>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <!--
- ================================================================================
- debug
-
- ================================================================================
- -->
- <xts:block id="debug" type="exec" mode="output" processor="XSLT" condition=".[/root/session/param[@name = 'debug'] = '1']" mandatory="false" mimeType="text/html" dependency="execute_report_viewer">
- <!-- Get the debug logic sheet -->
- <xts:logicsheet path="logicsheets/debuglogic.xslt"/>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:dbg="http://developer.cognos.com/schemas/xts/logicsheets/xslt/debug/" exclude-result-prefixes="dbg">
- <xsl:output method="html" version="1.0" encoding="UTF-8" indent="no"/>
- <xsl:template match="/">
- <dbg:dumpxml select="/root"/>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- </xts:morphlet>
|