123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: cogadmin
- (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).
- -->
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ui="http://developer.cognos.com/schemas/ui/presentation/markup/" xmlns:uic="http://developer.cognos.com/schemas/uic/presentation/markup/" xmlns:xts="http://developer.cognos.com/schemas/xts/" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt" xmlns:admui="http://developer.cognos.com/schemas/xts/admui" xmlns:pgr="http://developer.cognos.com/schemas/uic/presentation/cogadminpager/" xmlns:cm="http://developer.cognos.com/schemas/bibus/3/" xmlns:nav="http://developer.cognos.com/schemas/cps/navigation/1/" exclude-result-prefixes="ui uic xts xtsext admui nav cm">
- <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>
- <!-- Display variables -->
- <admui:variables/>
- <!-- Pager variables -->
- <admui:pagerVariables pagerName="printers"/>
- <!-- Pager templates -->
- <pgr:cogadminPagerTemplates/>
- <!-- Action templates-->
- <ui:commonActions/>
- <xsl:variable name="containerId" select="/root/nav:getContainerResponse/nav:container/nav:internalId"/>
- <xsl:template match="/root">
- <xsl:variable name="tooltip"><xts:string id="IDS_SORT_TOOLTIP"/></xsl:variable>
- <uic:fragment>
- <!-- add the reload event listener -->
- <ui:standardReloadListener/>
- <xsl:if test="not(key('env-param','searchMode')) or key('env-param','searchMode') = ''">
- <uic:fragmentHeader>
- <uic:pathControl>
- <uic:breadcrumb>
- <xts:string id="IDS_ADM_PRINTERS"/>
- </uic:breadcrumb>
- </uic:pathControl>
- <uic:headerActions>
- <xsl:variable name="permissions" select="nav:getContainerResponse/nav:container/nav:permissions"/>
- <xsl:variable name="canWrite" select="contains($permissions, 'write')"/>
- <xsl:variable name="hideNewPrinter" select="contains($ui_black_list, ' CC_TOOLBAR_BUTTONS_newprinter ')"/>
- <ui:groupActionMsgs/>
- <xsl:choose>
- <xsl:when test="not($canWrite)">
- <xsl:if test="not($hideNewPrinter)">
- <uic:icon uic:noSpace="true">
- <uic:src>
- <admui:imageURL image="action_new_printer_dis.gif" type="common"/>
- </uic:src>
- <uic:tooltip><xts:string id="IDS_ADM_PRINTERS_NEW" /></uic:tooltip>
- </uic:icon>
- <uic:headerSeperator/>
- </xsl:if>
- <ui:groupAction action="delete" disable="true"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:if test="not($hideNewPrinter)">
- <uic:icon uic:noSpace="true" rollOver="true">
- <uic:src>
- <admui:imageURL image="action_new_printer.gif" type="common"/>
- </uic:src>
- <uic:tooltip>
- <xts:string id="IDS_ADM_PRINTERS_NEW"/>
- </uic:tooltip>
- <xsl:variable name="url">?b_action=xts.run&m=<xsl:value-of select="$common_app"/>/new_general.xts&m_new_class=printer&backURL=javascript:parent._THIS_callBack();</xsl:variable>
- <uic:onclick>ui_modal_dialog.open('<xsl:value-of select="xtsext:javascriptencode($url)"/>', false, true, true)</uic:onclick>
- </uic:icon>
- <uic:headerSeperator/>
- </xsl:if>
- <ui:groupAction action="delete" tablename="printers"/>
- </xsl:otherwise>
- </xsl:choose>
- <uic:headerSeperator/>
- <ui:groupAction action="setContainerProperties" navContainerXPath="nav:getContainerResponse/nav:container"/>
- <uic:icon uic:noSpace="true" rollOver="true">
- <uic:src>
- <admui:imageURL image="action_search_basic.gif" type="common"/>
- </uic:src>
- <uic:tooltip>
- <xts:string id="IDS_ADM_SEARCH"/>
- </uic:tooltip>
- <uic:onclick>_THIS_.retrieve('searchMode=printer')</uic:onclick>
- </uic:icon>
- </uic:headerActions>
- </uic:fragmentHeader>
- </xsl:if>
- <xsl:choose>
- <xsl:when test="key('env-param','searchMode') = 'printer'">
- <div id="_THIS_PRINTERS_SEARCH_FRAGMENTcontent">_THIS?frag-subfragment=PRINTERS_SEARCH_FRAGMENT/THIS_</div>
- </xsl:when>
- <xsl:otherwise>
- <uic:table width="100%">
- <uic:features>
- <uic:name>printers</uic:name>
- <uic:summary><xts:string id="IDS_ADM_PRINTERS_SUMMARY"/></uic:summary>
- <uic:scrollable/>
- <uic:type>checkbox</uic:type>
- <ui:tableFeatures/>
- </uic:features>
- <xsl:call-template name="pgr:cogadminPager">
- <xsl:with-param name="pagerName" select="$pagerName"/>
- <xsl:with-param name="pageStart" select="nav:getContainerResponse/nav:container/nav:content/@start"/>
- <xsl:with-param name="pageEnd" select="nav:getContainerResponse/nav:container/nav:content/@end"/>
- <xsl:with-param name="pageMax" select="nav:getContainerResponse/nav:container/nav:content/@max"/>
- <xsl:with-param name="pageMore" select="nav:getContainerResponse/nav:container/nav:content/@more"/>
- <xsl:with-param name="linesPerPage" select="$linesPerPage"/>
- </xsl:call-template>
- <uic:header>
- <uic:row>
- <uic:column nowrap="nowrap"/>
- <uic:column width="100%" nowrap="nowrap" sort="name" iconTooltip="{$tooltip}">
- <uic:text>
- <xts:string id="IDS_HEADING_NAME"/>
- </uic:text>
- </uic:column>
- <uic:column nowrap="nowrap" sort="lastModifiedDate" iconTooltip="{$tooltip}">
- <uic:text>
- <xts:string id="IDS_HEADING_MODIFIED"/>
- </uic:text>
- </uic:column>
- </uic:row>
- </uic:header>
- <uic:body>
- <xsl:for-each select="nav:getContainerResponse/nav:container/nav:content/nav:item">
- <uic:row value="{concat('storeID("', string(nav:internalId), '")')}" label="{xtsext:htmlencode(string(nav:name))}">
- <xsl:if test="$productLocale != $contentLocale">
- <xsl:attribute name="lang"><xsl:value-of select="$contentLocale"/></xsl:attribute>
- </xsl:if>
- <uic:column nowrap="nowrap">
- <uic:icon>
- <uic:src>
- <admui:imageURL type="nav">
- <admui:image><xsl:value-of select="nav:imgURL"/></admui:image>
- </admui:imageURL>
- </uic:src>
- <uic:tooltip>
- <xsl:value-of select="nav:screenTip"/>
- </uic:tooltip>
- <xsl:if test="nav:hidden='true'">
- <uic:class>hiddenEntryIcon</uic:class>
- </xsl:if>
- </uic:icon>
- </uic:column>
- <uic:column nowrap="nowrap" scope="row" abbr="{xtsext:htmlencode(nav:name)}">
- <uic:text>
- <xsl:value-of select="nav:name"/>
- </uic:text>
- <!-- Render the disabled icon if this entry is disabled -->
- <xsl:if test="nav:icon/nav:name = 'disabled'">
- <uic:icon height="16" width="16" valign="middle">
- <uic:src>
- <admui:imageURL type="nav">
- <admui:image><xsl:value-of select="nav:icon/nav:imgURL"/></admui:image>
- </admui:imageURL>
- </uic:src>
- <uic:tooltip>
- <xsl:value-of select="nav:icon/nav:alt"/>
- </uic:tooltip>
- </uic:icon>
- </xsl:if>
- <xsl:variable name="permissions" select="nav:permissions"/>
- <xsl:call-template name="ui:menuActions">
- <xsl:with-param name="obj-class" select="nav:type"/>
- <xsl:with-param name="obj-id" select="nav:internalId"/>
- <xsl:with-param name="obj-name" select="nav:name"/>
- <xsl:with-param name="obj-path" select="nav:internalId"/>
- <xsl:with-param name="obj-parent" select="$containerId"/>
- <xsl:with-param name="supportSetProperties" select="true()"/>
- <xsl:with-param name="supportViewPermissions" select="true()"/>
- <xsl:with-param name="supportCopy" select="true()"/>
- <xsl:with-param name="supportDelete" select="true()"/>
- <xsl:with-param name="canRead" select="contains($permissions, 'read')"/>
- <xsl:with-param name="canWrite" select="contains($permissions, 'write')"/>
- <xsl:with-param name="canExecute" select="contains($permissions, 'execute')"/>
- <xsl:with-param name="canTraverse" select="contains($permissions, 'traverse')"/>
- <xsl:with-param name="canSetPolicy" select="contains($permissions, 'setPolicy')"/>
- </xsl:call-template>
- </uic:column>
- <uic:column nowrap="nowrap">
- <uic:text>
- <xsl:value-of select="nav:lastModifiedDate"/>
- </uic:text>
- </uic:column>
- </uic:row>
- </xsl:for-each>
- </uic:body>
- <uic:footer displayLastUpdate="true" />
- </uic:table>
- </xsl:otherwise>
- </xsl:choose>
- </uic:fragment>
- </xsl:template>
- </xsl:stylesheet>
|