123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: cogadmin
- (C) Copyright IBM Corp. 2005, 2013
- 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/" resolverBase="cogadmin" messageBase="messages/config.xml, messages/cogadminuimsgs.xml" requiredCapability="canUseServerAdministrationTool">
-
- <!--
- ===============================================================================================
- getConfig - retrieve the configuration UI settings
- ===============================================================================================
- -->
- <xts:block id="getConfig" type="exec" mode="interpret" processor="XSLT" condition=".[string(/root/env/param[@name='frag-directive'])!='meta-only']" mandatory="false">
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- exclude-result-prefixes="xsl">
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
-
- <xsl:template match="/">
- <xts:sequence>
- <xts:append>
- <xts:transform src="/portal/config_rt_ui.xslt" processor="XSLT">
- <xts:param name="messageBase">/messages/config.xml</xts:param>
- <root/>
- </xts:transform>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <xts:block id="getContent" nodelist="env, header, session, system, config" type="exec" mode="interpret" processor="XSLT" dependency="getConfig">
- <xts:logicsheet path="/cogadmin/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"
- xmlns:xts="http://developer.cognos.com/schemas/xts/"
- xmlns:send="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/brl/1/"
- xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:bus="http://developer.cognos.com/schemas/bibus/3/"
- xmlns:xos="http://developer.cognos.com/schemas/xts/output/"
- xmlns:resourceId="xalan://com.cognos.admin.xts.ResourceId"
- exclude-result-prefixes="xts xsl xtsext send">
-
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
- <xsl:key name="env-param" match="/root/env/param" use="@name"/>
- <xsl:variable name="resourceIdentifier">
- <xsl:choose>
- <xsl:when test="not(key('env-param','resourceID'))">
- <xsl:value-of select="resourceId:getDefaultResourceId(string(key('env-param','application')))"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="resourceId:getMetricsAndSettingsResourceId(xtsext:urldecode(string(key('env-param','resourceID'))))"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:variable>
- <xsl:variable name="storeID" select="resourceId:getId($resourceIdentifier)"/>
- <xsl:template match="/">
- <xts:sequence>
- <xts:append select="/root">
-
-
- <!-- need to get the metadata -->
- <metadata>
- <xts:request protocol="GetMultipleResourceProperties">
- <SOAP-ENV:Envelope
- xmlns:nemo="http://developer.cognos.com/nemo"
- xmlns:wsrf-rp="http://docs.oasis-open.org/wsrf/rp-2"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:xsd="http://www.w3.org/2001/XMLSchema">
- <SOAP-ENV:Header>
- <xsl:copy-of select="/root/header/bus:biBusHeader"/>
- <nemo:cogadminHeader>
- <nemo:ResourceIdentifier><xsl:value-of select="$resourceIdentifier"/></nemo:ResourceIdentifier>
- </nemo:cogadminHeader>
- </SOAP-ENV:Header>
- <SOAP-ENV:Body>
- <wsrf-rp:GetMultipleResourceProperties>
- <wsrf-rp:ResourceProperty>MetadataDescriptor</wsrf-rp:ResourceProperty>
- <wsrf-rp:ResourceProperty>Caption</wsrf-rp:ResourceProperty>
- </wsrf-rp:GetMultipleResourceProperties>
- </SOAP-ENV:Body>
- </SOAP-ENV:Envelope>
- </xts:request>
- </metadata>
- <response>
- <send:request provider="cm">
- <cm:query xmlns:cm="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">
- <requests xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="cm:queryRequest[]">
- <item xsi:type="cm:queryRequest">
- <xsl:choose>
- <xsl:when test="($storeID != '') and ($storeID != '/configuration')">
- <search xsi:type="xsd:string">storeID("<xsl:value-of select="$storeID"/>")</search>
- </xsl:when>
- <xsl:otherwise>
- <search xsi:type="xsd:string">/configuration</search>
- </xsl:otherwise>
- </xsl:choose>
- <properties>
- <xsl:for-each select="/root/config/section/parameter">
- <item xsi:type="cm:propEnum"><xsl:value-of select="@name"/></item>
- </xsl:for-each>
- <item xsi:type="cm:propEnum">objectClass</item>
- <item xsi:type="cm:propEnum">defaultName</item>
- <item xsi:type="cm:guidProp">storeID</item>
- <item xsi:type="cm:guidProp">permissions</item>
- </properties>
- <options xsi:type="cm:queryOptions">
- <schemaInfo xsi:type="xsd:boolean">true</schemaInfo>
- </options>
- </item>
- <!-- Query for the installed components. -->
- <item xsi:type="cm:queryRequest">
- <cm:search xsi:type="xsd:string">/configuration//dispatcher/installedComponent</cm:search>
- <properties>
- <item xsi:type="cm:propEnum">componentID</item>
- </properties>
- </item>
- </requests>
- </cm:query>
- </send:request>
- </response>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
-
- <!--This block gets the localized names for the queryService cube configurations-->
- <xts:block id="getRolapDataSourceContent" nodelist="env, header, metadata, session, system, config, response" type="exec" mode="interpret" processor="XSLT" dependency="getContent" condition=".[/root/response/*[local-name()='queryResponse']/*/item[1]/queryResult/item/objectClass/value='queryService' and count(/root/response/*[local-name()='queryResponse']/*/item[1]/queryResult/item/qsROLAPCubeConfigurations/value/item/dataSourceName) > 0]" mandatory="false">
- <xts:logicsheet path="/cogadmin/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"
- xmlns:xts="http://developer.cognos.com/schemas/xts/"
- xmlns:send="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/brl/1/"
- xmlns:cm="http://developer.cognos.com/schemas/bibus/3/">
-
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
- <xsl:template match="/">
- <xsl:variable name="searchPath">
- CAMID(":")/*[@objectClass='rolapDataSource' or @objectClass='rolapVirtualDataSource' and <xsl:for-each select="/root/response/cm:queryResponse/*/item[1]/queryResult/item/qsROLAPCubeConfigurations/value/item/dataSourceName">
- <xsl:if test="position() > 1"><xsl:text> or </xsl:text></xsl:if>@name='<xsl:value-of select="."/>'</xsl:for-each><xsl:text>]</xsl:text>
- </xsl:variable>
-
- <xts:sequence>
- <xts:append select="/root">
- <response>
- <rolapDatasources>
- <send:request provider="cm">
- <cm:query xmlns:cm="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">
- <requests xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="cm:queryRequest[]">
- <item xsi:type="cm:queryRequest">
- <search xsi:type="xsd:string">
- <xsl:value-of select="$searchPath"/>
- </search>
- <properties>
- <item xsi:type="cm:propEnum">defaultName</item>
- </properties>
- </item>
- </requests>
- </cm:query>
- </send:request>
- </rolapDatasources>
- </response>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <!--no need to break the meta out of render in this particular case, since the meta depend on cm response-->
- <xts:block id="render" type="exec" processor="XSLT" dependency="getContent">
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:xts="http://developer.cognos.com/schemas/xts/"
- xmlns:cm="http://developer.cognos.com/schemas/bibus/3/"
- xmlns:xos="http://developer.cognos.com/schemas/xts/output/"
- xmlns:send="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/brl/1/"
- exclude-result-prefixes="xsl xts xos cm">
-
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
-
- <xsl:variable name="storeID" select="/root/env/param[@name = 'storeID']"/>
- <!--xsl:key name="env-param" match="/root/env/param" use="@name"/-->
-
- <xsl:template match="/">
- <xts:sequence>
- <xts:append select="/root/output">
- <xos:part>
- <xos:entityHeader>
- <xos:param name="Content-Type">text/xml; charset=utf-8</xos:param>
- </xos:entityHeader>
- <xos:entityBody>
- <fragment>
- <xsl:variable name="default">
- <xts:string id="IDS_ADM_SET_SYSTEM"/>
- </xsl:variable>
- <xsl:variable name="objectClass">
- <xsl:value-of select="/root/response/cm:queryResponse/*/item[1]/queryResult/item/objectClass/value"/>
- </xsl:variable>
- <xsl:variable name="title">
- <xts:transform name="XMLEncode">
- <xts:string id="IDS_ADM_SET_HEADER">
- <xts:param name="objName"><xsl:value-of select="/root/metadata/*[local-name()='GetMultipleResourcePropertiesResponse']/*[local-name()='Caption']"/></xts:param>
- </xts:string>
- </xts:transform>
- </xsl:variable>
- <info>
- <title>
- <xts:string id="IDS_ADM_SET_TITLE"/>
- </title>
- </info>
- <preferredTitle>
- <xsl:value-of select="$title"/>
- </preferredTitle>
- <!-- update the sibling fragments with the resourceLabel -->
- <!-- transientUpdate name="resourceLabel" scope="page">
- <xsl:value-of select="$resourceLabel"/>
- </transientUpdate-->
-
- <meta>
- <transientProperties name="resourceID"/>
- <transientProperties name="storeID">
- <default>
- <value>/configuration</value>
- </default>
- <validate>
- <name>storeID</name>
- <ruleRef id="fragment-cogadmin:storeID"/>
- </validate>
- </transientProperties>
- <transientProperties name="resourceLabel">
- <validate>
- <name>resourceLabel</name>
- <ruleRef id="fragment-cogadmin:resourceLabel"/>
- </validate>
- </transientProperties>
- <requiredCapabilities>canUseServerAdministrationTool</requiredCapabilities>
- </meta>
- <xsl:if test="not(/root/env/param[@name = 'frag-directive']='meta-only')">
- <markup>
- <mimeType>text/html</mimeType>
- <markupXml>
- <xts:transform src="/cogadmin/transforms/presentation/renderFragment.xslt" processor="XSLT">
- <xts:param name="messageBase">/messages/cogadminuimsgs.xml</xts:param>
- <xts:param name="logicsheet">/cogadmin/logicsheets/admin.xslt</xts:param>
- <root>
- <xts:transform src="/cogadmin/transforms/gen-ui-markup/settings.xslt" processor="XSLT">
- <xts:param name="messageBase">/messages/cogadminuimsgs.xml</xts:param>
- <xts:param name="messageBase">/messages/portal.xml</xts:param>
- <xts:param name="logicsheet">/cogadmin/logicsheets/presentation/common.xslt</xts:param>
- <xts:param name="logicsheet">/cogadmin/logicsheets/admin.xslt</xts:param>
- <root>
- <xsl:if test="not(/root/env/param[@name = 'application'] = 'ds' and $objectClass='configuration')">
- <xsl:if test="not(/root/env/param[@name = 'storeID']) or ($storeID != '' and not(starts-with($storeID, 'cm:')))">
- <xts:transform src="/cogadmin/transforms/addAdvancedSettings.xslt" processor="XSLT">
- <root>
- <xsl:copy-of select="/root/response/*"/>
- <xts:queryNode select="/root/config"/>
- </root>
- </xts:transform>
- </xsl:if>
- </xsl:if>
- <contentLocale>
- <xsl:value-of select="/root/user/param[@name='contentLocale']"/>
- </contentLocale>
- <xts:queryNode select="/root/http | /root/system | /root/env | /root/user"/>
- </root>
- </xts:transform>
- <xts:queryNode select="/root/system | /root/user"/>
- </root>
- </xts:transform>
- </markupXml>
- </markup>
- </xsl:if>
- </fragment>
- </xos:entityBody>
- </xos:part>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <!--
- ===============================================================================================
- debug - display debug information
- ===============================================================================================
- -->
- <xts:block id="debug" dependency="render" 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="cogadmin/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>
|