123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: ps
- (C) Copyright IBM Corp. 2005, 2014
- 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:morphlet xmlns:xts="http://developer.cognos.com/schemas/xts/" xmlns:cml="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/cml/1/" xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/" messageBase="messages/portal.xml, messages/portalRL.xml" requiredCapability="canUseAdministrationPortal">
- <!--
- ===============================================================================================
- formlogic_init - standard form logic initialization
- ===============================================================================================
- -->
- <xts:block id="formlogic_init" type="exec" mode="interpret" processor="XSLT" path="/logicsheets/formlogic_init.xslt" nodelist="env,credential,system,http"/>
-
- <!--
- ===============================================================================================
- renderPage - render the page
- ===============================================================================================
- -->
- <xts:block id="render_page" mode="output" processor="XSLT" type="exec" mimeType="text/html" dependency="formlogic_init">
- <!-- get the presentation theme -->
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/dialog/framework.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/layout.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/dialog/presentation.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/controls/framework.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/controls/presentation.xsl"/>
- <!-- apply the form logic -->
- <xts:logicsheet path="logicsheets/formlogic.xslt"/>
- <xts:logicsheet path="logicsheets/validation.xslt"/> <xts:logicsheet path="logicsheets/presentation/touch_up.xslt"/>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:lyt="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/layout/"
- xmlns:pf="http://developer.cognos.com/schemas/xts/pf"
- xmlns:dp="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/presentation/"
- xmlns:df="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/framework/"
- xmlns:cf="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/controls/framework/"
- xmlns:cp="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/controls/presentation/"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
- xmlns:utml="http://developer.cognos.com/schemas/xts/logicsheet/xslt/formlogic/"
- exclude-result-prefixes="xsl cf cp pf df dp lyt utml">
-
- <xsl:output method="html" version="1.0" encoding="UTF-8" indent="no" omit-xml-declaration="yes"/>
- <!-- current file name -->
- <xsl:variable name="mname" select="'set_commands.xts'"/>
- <!-- add any theme variables -->
- <pf:variables/>
- <!-- start the output -->
- <xsl:template match="/root">
- <xsl:variable name="backURL" select="key('env-param','backURL')"/>
-
- <!--
- IMPORTANT: This logic to set the commandToEdit variable fixes a sev 2 XSS scripting issue #COGCQ00587230
- Do not change it or implement correctly the way the command to edit should be treated
- in this page:
- - names of the input fields should not be generated from submitted values
- - the current command to edit is stored in a hidden input and sends backs to the
- calling page with the new value and/or a flag indicating if the value was changed
- -->
- <xsl:variable name="commandToEdit">
- <xsl:variable name="submittedCommand" select="key('env-param','commandToEdit')"/>
- <xsl:choose>
- <xsl:when test="contains(' openConnectionCommands openSessionCommands closeSessionCommands closeConnectionCommands ',concat(' ',$submittedCommand,' '))">
- <xsl:value-of select="$submittedCommand"/>
- </xsl:when>
- <xsl:otherwise></xsl:otherwise>
- </xsl:choose>
- </xsl:variable>
- <!-- select="key('env-param','commandToEdit')"/>-->
- <xsl:variable name="browserTitle">
- <xsl:choose>
- <xsl:when test="$commandToEdit != ''">
- <xts:string id="IDS_SET_COMMANDS_TITLE">
- <xts:param name="commandDisplayString"><xsl:value-of select="/root/env/param[@name=concat('m_display_cbp_',$commandToEdit)]"/></xts:param>
- </xts:string>
- </xsl:when>
- <xsl:otherwise>
- <xts:string id="IDS_SET_COMMANDS_GENERIC_TITLE"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:variable>
-
- <xsl:text disable-output-escaping='yes'><!DOCTYPE html></xsl:text><dp:page longTitle="$browserTitle">
- <dp:meta>
- <!-- Standard meta tags -->
- <pf:meta/>
- </dp:meta>
- <dp:script>
- <!-- Help system -->
- <pf:help context="HID_DATABASE_COMMANDS"/>
- <script language="javascript">
- <xsl:if test="key('env-param','from_bmt')!=''">
- <!-- Called only when canceling back to BMT environment. -->
- function doCancel()
- {
- window.external.OnClose(1);
- }
- </xsl:if>
- </script>
- </dp:script>
- <utml:form name="pform" method="post" action="{$gateway}">
- <dp:header>
- <!-- header titles-->
- <dp:title><xsl:value-of select="normalize-space($browserTitle)"/></dp:title>
- <dp:description>
- <xts:string id="IDS_SET_COMMANDS_DESCRIPTION"/>
- </dp:description>
- <dp:close>
- <xsl:choose>
- <xsl:when test="key('env-param','from_bmt')">
- <a href="javascript:doCancel()">
- <dp:closeMarker/>
- </a>
- </xsl:when>
- <xsl:otherwise>
- <a href="{$backURL}">
- <dp:closeMarker/>
- </a>
- </xsl:otherwise>
- </xsl:choose>
- </dp:close>
- </dp:header>
- <lyt:layout style="1">
- <lyt:section>
- <dp:input>
- <dp:section1 for="ctrl_m_cbp_edit_{$commandToEdit}">
- <xts:string id="IDS_PROP_XML_DATABASE_COMMANDS"/>
- </dp:section1>
- <dp:section2>
- <utml:textarea cols="50" rows="13" style="width: 600px; height: 200px;" utml:track="true" id="ctrl_m_cbp_edit_{$commandToEdit}">
- <utml:name><xsl:value-of select="concat('m_cbp_edit_',$commandToEdit)"/></utml:name>
- <utml:value><xsl:value-of select="/root/env/param[@name=concat('m_cbp_',$commandToEdit)]"/></utml:value>
- </utml:textarea >
- </dp:section2>
- </dp:input>
- </lyt:section>
- </lyt:layout>
-
- <dp:footer>
- <!-- Cancel button -->
- <df:button df:id="IDS_OK" df:style="stack-down-save"/>
- <df:button df:id="IDS_CANCEL" df:style="stack-down"/>
- </dp:footer>
- </utml:form>
- </dp:page>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <!--
- ===============================================================================================
- debug - display debug information
- ===============================================================================================
- -->
- <xts:block id="debug" dependency="render_page" condition=".[/root/session/param[@name='debug']='1']" type="exec" mode="output" processor="XSLT" mandatory="false" mimeType="text/html">
- <!-- 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" omit-xml-declaration="yes"/>
- <xsl:template match="/">
- <dbg:dumpxml select="/root"/>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- </xts:morphlet>
|