123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: ps
- (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/" messageBase="messages/portal.xml, messages/portalRL.xml">
-
- <!--
- ===============================================================================================
- 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"/>
-
- <!-- Load object-specific property tabs map ============================================================== -->
- <xts:block id="getTabs" type="exec" mode="interpret" processor="XML" >
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <xsl:template match="/">
- <xts:sequence>
- <xts:append>
- <tabs>
- <object class="metricsExportTask">
- <tab name="metrics_export" page="properties_metrics_export.xts"><xts:string id="IDS_PROP_TAB_METRICS_EXPORT"/></tab>
- </object>
- </tabs>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
-
- </xts:block>
- <!--
- ===============================================================================================
- getContent - get our data from Content Manager
- ===============================================================================================
- -->
- <xts:block id="getContent" processor="XSLT" type="exec" dependency="formlogic_init">
- <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:dt="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/templates/"
- xmlns:send="http://developer.cognos.com/schemas/xts/logic-sheet/xslt/brl/1/">
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
-
- <xsl:template match="/">
- <xts:sequence>
- <xts:append>
- <xts:transform src="transforms/CM/post-process.xslt" processor="XSLT">
- <send:request provider="cm">
- <xts:transform src="transforms/CM/pre-process.xslt" processor="XSLT">
- <cm:query xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/">
- <cm:search>
- <xsl:value-of select="/root/env/param[@name='m_obj']"/>
- </cm:search>
- <cm:properties>
- <cm:property name="defaultName"/>
- <cm:property name="owner"/>
- <cm:property name="permissions"/>
- <cm:property name="runAsOwner"/>
- <cm:property name="storeID"/>
- <cm:property name="metadataModelPackage"/>
- </cm:properties>
- <cm:options schemaInfo="true">
- <cm:refProps>
- <cm:refProp refPropName="owner">
- <cm:properties>
- <cm:property name="searchPath"/>
- <cm:property name="defaultName"/>
- <cm:property name="email"/>
- </cm:properties>
- </cm:refProp>
- </cm:refProps>
- </cm:options>
- </cm:query>
- </xts:transform>
- </send:request>
- </xts:transform>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
-
- <!--
- ===============================================================================================
- Produce default options under /root/env, but only on first visit to the page
- ===============================================================================================
- -->
- <xts:block id="generateDefaultOptions" processor="XSLT" type="exec" dependency="getContent" condition=".[not(/root/env/param[@name = 'visited_metrics_import_property'])]" mandatory="false">
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/">
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
-
- <xsl:variable name="the-object" select="/root/cm:queryResponse/*[1]"/>
- <xsl:template match="/">
- <xts:sequence>
- <xts:append select="/root/env">
- <xsl:if test="$the-object/cm:runAsOwner!=''">
- <param name="m_re_runAsOwner">
- <xsl:value-of select="$the-object/cm:runAsOwner"/>
- </param>
- </xsl:if>
- </xts:append>
- </xts:sequence>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
-
- <!--
- ===============================================================================================
- renderPage - render the page
- ===============================================================================================
- -->
- <xts:block id="renderPage" mode="output" processor="XSLT" type="exec" mimeType="text/html" dependency="generateDefaultOptions getTabs">
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/dialog/framework.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/dialog/presentation.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/layout.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/controls/framework.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/controls/presentation.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/dialog/confirm.xslt"/>
- <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: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:dc="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/confirm/1/"
- xmlns:lyt="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/layout/"
- 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:utml="http://developer.cognos.com/schemas/xts/logicsheet/xslt/formlogic/"
- xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt">
- <xsl:output method="html" version="1.0" encoding="UTF-8" indent="no" omit-xml-declaration="yes"/>
-
- <!-- current file name -->
- <xsl:variable name="mname" select="'properties_metrics_export.xts'"/>
- <xsl:variable name="the-object" select="/root/cm:queryResponse/*[1]"/>
- <xsl:variable name="the-class" select="/root/cm:queryResponse/*[1]/cm:objectClass"/>
- <xsl:variable name="has_write_permission" select="contains(concat(' ', /root/cm:queryResponse/*[1]/cm:permissions, ' '), ' write ')"/>
- <xsl:variable name="has_policy_permission" select="contains(concat(' ', /root/cm:queryResponse/*[1]/cm:permissions, ' '), ' setPolicy ')"/>
- <xsl:variable name="showOKCancel" select="$has_write_permission or $has_policy_permission"/>
- <pf:variables/>
-
- <xsl:template match="/">
- <xsl:variable name="browserTitle"><xts:string id="IDS_PROPERTIES_TITLE"><xts:param name="objectName"><span lang="{$contentLocale}"><xsl:value-of select="key('env-param', 'm_name')"/></span></xts:param></xts:string></xsl:variable>
-
- <xsl:text disable-output-escaping='yes'><!DOCTYPE html></xsl:text><dp:page longTitle="$browserTitle">
- <dp:meta>
- <pf:meta/> <!-- Standard meta tags -->
- </dp:meta>
- <!-- get passed in parameters -->
- <dp:script>
- <pf:help context="HID_PROPERTIES"/> <!-- Help system -->
- <xsl:if test="$has_write_permission = true()">
- <dc:confirm-cancel/>
- </xsl:if>
- <script language="JavaScript">
- function goToWizard()
- {
- var form=document.pform;
- form.b_action.value='mms.run';
- form.pid.value='export_summary';
- form.exportid.value='<xsl:value-of select="$the-object/cm:storeID"/>';
- form.backID.value='<xsl:value-of select="/root/env/param[@name='m']"/>';
- form.submit();
- }
-
- </script>
- </dp:script>
-
- <utml:form name="pform" method="post" action="{$gateway}">
- <input type="hidden" name="ui.backURL" value="{/root/env/param[@name='backURL']}"/>
- <utml:read-only>
- <xsl:choose>
- <xsl:when test="$has_write_permission = true()">
- <xsl:text>false</xsl:text>
- </xsl:when>
- <xsl:otherwise>
- <xsl:text>true</xsl:text>
- </xsl:otherwise>
- </xsl:choose>
- </utml:read-only>
- <utml:input type="hidden" name="ps_nav_op" value="" utml:update="false"/>
- <utml:input type="hidden" name="pid" utml:update="false"/>
- <utml:input type="hidden" name="exportid" utml:update="false"/>
- <utml:input type="hidden" name="backID" utml:update="false"/>
- <utml:input type="hidden" name="ifrmcmd" value="save" utml:update="false"/>
- <utml:input type="hidden" value="true" name="m_validate" utml:update="false"/>
- <utml:input type="hidden" value="true" name="visited_metrics_export_property" utml:update="false"/>
- <utml:input type="hidden" name="m_p_metadataModelPackage" utml:update="false">
- <utml:value><xsl:value-of select="$the-object/cm:metadataModelPackage/*/*[local-name()='searchPath']"/></utml:value>
- </utml:input>
- <!-- dialog header -->
- <dp:header useBackURL="not($showOKCancel)">
- <!-- header titles-->
- <dp:title><xsl:copy-of select="$browserTitle"/></dp:title>
- </dp:header>
- <!-- property tabs -->
- <df:propertiesTabsTitanPagelet select="metrics_export">
- <df:hasSetPolicy><xsl:value-of select="$has_policy_permission"/></df:hasSetPolicy>
- </df:propertiesTabsTitanPagelet>
- <!-- description tabs -->
- <dp:description>
- <xts:string id="IDS_PROP_METRICS_EXPORT_INTRO"/>
- </dp:description>
- <lyt:layout style="2">
- <lyt:section>
- <table cellspacing="0" border="0" cellpadding="1">
- <tr>
- <td nowrap="nowrap" class="formLabel">
- <xts:string id="IDS_PROP_METRICS_EXPORT_OPTIONS"/>
- </td>
- </tr>
- </table>
-
- <table cellspacing="0" border="0" cellpadding="1">
- <tr>
- <td nowrap="nowrap" align="center">
- <img border="0" src="{concat($image_root, 'checkmark.gif')}"/>
- </td>
- <td nowrap="nowrap" class="formText">
- <xts:string id="IDS_PROP_METRICS_EXPORT"/>
- </td>
- </tr>
- </table>
- </lyt:section>
- <lyt:section>
- <dp:choice>
- <dp:section1>
- <img height="30" width="30">
- <xsl:attribute name="alt"><xts:string id="IDS_ICON_TIP"/></xsl:attribute>
- <xsl:attribute name="src"><xsl:value-of select="$skin_images"/>tip_template.gif</xsl:attribute>
- </img>
- </dp:section1>
- <dp:section2>
- <xsl:variable name="link">
- <a href="#" onclick="JavaScript:goToWizard()"><xsl:text><xts:string id="IDS_ACT_UPDATE_METRICS_EXPORT"/></xsl:text></a>
- </xsl:variable>
- <xts:string id="IDS_PROP_METRICS_EXPORT_UPDATE">
- <xts:param name="link"><xsl:copy-of select="$link"/></xts:param>
- </xts:string>
- </dp:section2>
- </dp:choice>
- </lyt:section>
- </lyt:layout>
- <lyt:layout style="1">
- <lyt:section>
- <!-- run as owner -->
- <dp:choice title="IDS_OTHERRUN_RUN_AS_OWNER">
- <dp:section1>
- <utml:input type="checkbox" name="m_re_runAsOwner" value="true" utml:track="true"/>
- </dp:section1>
- <dp:section2>
- <dp:text>
- <xsl:choose>
- <xsl:when test="(key('env-param', 'm_defaultName')) and not(key('env-param', 'm_defaultName') = '')">
- <xsl:value-of select="key('env-param', 'm_defaultName')"/>
- </xsl:when>
- <xsl:when test="$the-object/cm:owner/*/cm:defaultName">
- <xsl:value-of select="$the-object/cm:owner/*/cm:defaultName"/>
- </xsl:when>
- <xsl:when test="$the-object/cm:owner/*/cm:email">
- <xsl:value-of select="$the-object/cm:owner/*/cm:email"/>
- </xsl:when>
- <xsl:when test="$the-object/cm:owner/cm:nil">
- <xts:string id="IDS_PROP_UNKNOWN_OWNER"/>
- </xsl:when>
- <xsl:otherwise>
- <xts:string id="IDS_NONE"/>
- </xsl:otherwise>
- </xsl:choose>
- </dp:text>
- </dp:section2>
- </dp:choice>
- </lyt:section>
- </lyt:layout>
- <dp:footer>
- <xsl:choose>
- <xsl:when test="$showOKCancel">
- <df:button df:id="IDS_OK" utml:validate="true" df:style="submit" df:nav_op="stack-down"/>
- <xsl:choose>
- <xsl:when test="key('env-param', 'ps_nav_stack') and not(key('env-param', 'ps_nav_stack') = '') ">
- <df:button df:id="IDS_CANCEL" df:style="stack-down" onclick="{$dc-confirm-cancel}"/>
- </xsl:when>
- <xsl:otherwise>
- <df:button df:id="IDS_CANCEL" df:style="back-url" onclick="{$dc-confirm-cancel}"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:when>
- <xsl:otherwise>
- <df:button df:id="IDS_CLOSE" df:style="back-url"/>
- </xsl:otherwise>
- </xsl:choose>
- </dp:footer>
- </utml:form>
- </dp:page>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <!--
- ===============================================================================================
- debug - display debug information
- ===============================================================================================
- -->
- <xts:block id="debug" dependency="renderPage" 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>
|