1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: ps
- (C) Copyright IBM Corp. 2005, 2019
- US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- -->
- <!-- This stylesheet defines global portal variables and templates. -->
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:out="dummy-uri"
- xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt"
- xmlns:xts="http://developer.cognos.com/schemas/xts/"
- xmlns:pf="http://developer.cognos.com/schemas/xts/pf"
- xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/"
- xmlns:mt="http://developer.cognos.com/schemas/xts/logicsheets/presentation/main/mt"
- exclude-result-prefixes="xsl xtsext xts pf cm">
- <xsl:output method="xml" encoding="UTF-8" indent="no"/>
- <xsl:namespace-alias stylesheet-prefix="out" result-prefix="xsl"/>
- <!--
- This stylesheet (portal.xsl) consists of the following templates:
- html[mt:page] - converts html doc to standards mode
- pf:modalVariables - defines various global variables required by the modal dialog framework
- pf:variables - defines various global variables (system, user, root,...) that are used in CC pages.
- pf:meta - defines meta data for the CC web pages.
- pf:help - defines CC web page help javascript.
- pf:launch - Adds functions and includes necessary to run Studios.
- pf:gen-url - generates the gen-url template that in turn generates CC web page hyperlinks.
- pf:gen-icon - generates the gen-icon template that in turn generates CC web page icons.
- pf:gen-class-name - generates the gen-class-name template that is used to determine class names.
- pf:serialize-xml - generates the serialize-xml template that is used to convert a chunk of xml into a xml-encoded string.
- pf:utilities - misc. helper templates
- pf:common-bidi-templates" - enforce BTD on the given value if bidiEnabled is set to true
- -->
- <!--
- Template - html[mt:page]:
- This template adds the HTML standards mode doctype in an applicable way
- -->
- <xsl:template match="html[descendant::mt:page]">
- <xsl:choose>
- <xsl:when test="@encodeDocType='false'">
- <out:text disable-output-escaping='yes'><!DOCTYPE html></out:text>
- </xsl:when>
- <xsl:otherwise>
- <out:text disable-output-escaping="yes"><![CDATA[<!DOCTYPE html>]]> </out:text>
- </xsl:otherwise>
- </xsl:choose>
- <html>
- <xsl:copy-of select="@*[name() != 'encodeDocType']"/>
- <xsl:apply-templates select="./*"/>
- </html>
- </xsl:template>
- <!--
- Template - pf:modalVariables:
- This template defines global variables used to enable dialogs to be used in the modal dialog framework
- Operation:
- Generate global variables.
- -->
- <xsl:template match="pf:modalVariables">
- <out:variable name="isModal" select="/root/env/param[@name='md.callBack'] or /root/command/*[local-name()='handleFault']/*[local-name()='originalRequest']//item[name='md.callBack']"/>
- <out:variable name="callBackDataFormat">
- <out:choose>
- <out:when test="string(/root/env/param[@name='md.callBack']) = 'xml' or string(/root/command/*[local-name()='handleFault']/*[local-name()='originalRequest']//item[name='md.callBack']/value) = 'xml'">xml</out:when>
- <out:when test="string(/root/env/param[@name='md.callBack']) = 'singleValue' or string(/root/command/*[local-name()='handleFault']/*[local-name()='originalRequest']//item[name='md.callBack']/value) = 'singleValue'">singleValue</out:when><!-- TODO: get rid of this -->
- <out:when test="string(/root/env/param[@name='md.callBack']) != '' or string(/root/command/*[local-name()='handleFault']/*[local-name()='originalRequest']//item[name='md.callBack']/value) != ''">data</out:when>
- </out:choose>
- </out:variable>
- <out:variable name="callBackMode">
- <out:choose>
- <out:when test="string(/root/env/param[@name='md.callBackMode']) = 'external' or string(/root/command/*[local-name()='handleFault']/*[local-name()='originalRequest']//item[name='md.callBackMode']/value) = 'external'">external</out:when>
- <out:otherwise>parent</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="callBackFunctionName" select="'ccModalCallBack'"/>
- <out:variable name="callBackTargetJSVar">
- <out:choose>
- <out:when test="$callBackMode = 'external'">
- <out:text/>window.external && typeof window.external.Has<out:value-of select="$callBackFunctionName"/> != "undefined" ? window.external : null<out:text/>
- </out:when>
- <out:otherwise>
- <out:text/>window.opener && typeof window.opener.<out:value-of select="$callBackFunctionName"/> != "undefined" ? window.opener : <out:value-of select="$callBackMode"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- </xsl:template>
- <!-- Global JavaScript - Requires <pf:variables> -->
- <xsl:template match="pf:script">
- <script language="JavaScript">
- function g_PS_getWebRoot()
- {
- return "<out:value-of select="xtsext:javascriptencode($webRoot)"/>";
- }
- </script>
- </xsl:template>
- <xsl:template match="pf:mvc-variables" name="mvc-variables">
- <!-- MVC -->
- <out:variable name="mvc-remote-gateway" select="string(/root/mvcSettings/configuration/property[@name='MVC_remoteGateway'])"/>
- <out:variable name="mvc-remote-webcontent" select="string(/root/mvcSettings/configuration/property[@name='MVC_remoteWebContent'])"/>
- <out:variable name="mvc-domain" select="string(/root/mvcSettings/configuration/property[@name='MVC_domain'])"/>
- <out:variable name="mvc-disable-autologon" select="string(/root/mvcSettings/configuration/property[@name='MVC_disableAutoLogOn']) = 'true'"/>
- <out:variable name="mvc-N-enabled" select="/root/session/param[@name='mvcsys'] = 'n'"/>
- </xsl:template>
- <xsl:template match="pf:campassportcookie" name="campassportcookie">
- <out:variable name="CAMPassportCookie">
- <out:choose>
- <out:when test="/root/setCookies/cookie[@name='cam_passport' and string(@maxAge) != '-1']">
- <out:value-of select="string(/root/setCookies/cookie[@name='cam_passport'])"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="string(/root/cookies/cookie[@name='cam_passport'])"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- </xsl:template>
- <xsl:template match="pf:sessionpassport" name="sessionpassport">
- <xsl:call-template name="campassportcookie"/>
- <out:variable name="passport">
- <out:choose>
- <!-- pull the passport out of the bus header -->
- <out:when test="/root/credential/param[@name='CAM']/*[local-name() ='CAM']/*[local-name() = 'CAMPassport']/*[local-name() = 'id']">
- <out:value-of select="/root/credential/param[@name='CAM']/*[local-name() ='CAM']/*[local-name() = 'CAMPassport']/*[local-name() = 'id']"/>
- </out:when>
- <!-- For those blocks that specify node list and execlude <credential> node -->
- <out:when test="/root/header/*[local-name() = 'biBusHeader']/*[local-name()= 'CAM']/CAMPassport/id">
- <out:value-of select="/root/header/*[local-name() = 'biBusHeader']/*[local-name()= 'CAM']/CAMPassport/id"/>
- </out:when>
- <!-- For those super rare cases where both <credential> and <header> elements are not available - or - the passport is being cleared -->
- <out:otherwise>
- <out:value-of select="xtsext:camcookie_action('getPassportID', $CAMPassportCookie)"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- </xsl:template>
- <!--
- Template - pf:variable:
- This template defines global variables used to guide the construction of the CC Web pages. These
- variables are based on information from various system, user and root information.
- Operation:
- Generate global variables.
- -->
- <xsl:template match="pf:variables">
- <out:key name="system-param" match="/root/system/param" use="@name"/>
- <out:key name="env-param" match="/root/env/param" use="@name"/>
- <out:key name="session-param" match="/root/session/param" use="@name"/>
- <out:key name="user-param" match="/root/user/param" use="@name"/>
- <out:key name="ui-object" match="/root/system/param[@name='ui_objects']/object" use="@class"/>
- <out:key name="ui-object-actions" match="/root/system/param[@name='base-object-actions']/actions/object | /root/actions/object" use="@class"/>
- <out:key name="ui-object-properties" match="/root/tabs/object" use="@class"/>
- <xsl:call-template name="mvc-variables"/>
- <!-- Application variables -->
- <out:variable name="user_skin">
- <out:choose>
- <out:when test="key('env-param', 'skin') != ''">
- <out:value-of select="key('env-param', 'skin')"/>
- </out:when>
- <out:when test="key('user-param', 'skin') != ''">
- <out:value-of select="key('user-param', 'skin')"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key('system-param', 'defaultPortalPreferences')/pref[@name='skin']"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <!-- bidi -->
- <out:variable name="isBidiEnabled">
- <out:choose>
- <out:when test="key('user-param', 'http://developer.cognos.com/ceba/constants/biDirectionalOptionEnum#biDirectionalFeaturesEnabled') != ''">
- <out:value-of select="key('user-param', 'http://developer.cognos.com/ceba/constants/biDirectionalOptionEnum#biDirectionalFeaturesEnabled')"/>
- </out:when>
- <out:otherwise>false</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="baseTextDirection">
- <out:variable name="ns_name">
- <out:value-of select="key('user-param', 'http://developer.cognos.com/ceba/constants/biDirectionalOptionEnum#baseTextDirection')"/>
- </out:variable>
- <out:choose>
- <out:when test="$ns_name != ''">
- <out:value-of select="translate(substring-after($ns_name,'#'),'LTRA','ltra')"/>
- </out:when>
- <out:otherwise>auto</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="defTextAlign">
- <out:choose>
- <out:when test="xtsext:isRTLLocale($productLocale) = 'true'">right</out:when>
- <out:otherwise>left</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="webRoot">
- <out:choose>
- <out:when test="/root/http/param[@name='WEB_CONTENT_ROOT']">
- <out:value-of select="string(/root/http/param[@name='WEB_CONTENT_ROOT'])"/>
- </out:when>
- <!-- No official config param is present. Make this relative. -->
- <out:otherwise>..</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="webcontent" select="concat($webRoot, '/ps')"/>
- <out:variable name="skincontent" select="concat($webRoot, '/skins')"/>
- <out:variable name="gateway" select="string(/root/http/param[@name='SCRIPT_NAME'])"/>
- <out:variable name="cookie_path">
- <out:value-of select="/root/configProps/param[@name='cc']/property[@name='cookiePath']"/>
- </out:variable>
- <out:variable name="cookie_domain">
- <out:value-of select="/root/configProps/param[@name='cc']/property[@name='cookieDomain']"/>
- </out:variable>
- <out:variable name="cookie_secure">
- <out:value-of select="/root/configProps/param[@name='cc']/property[@name='cookieSecure']"/>
- </out:variable>
- <out:variable name="app" select="key('system-param', 'app')"/>
- <out:variable name="image_root" select="concat($webcontent, '/', $app, '/images/')"/>
- <out:variable name="skin_root" select="concat($webRoot, '/skins', '/', $user_skin)"/>
- <out:variable name="skin_images" select="concat($skin_root, '/', $app, '/images/')"/>
- <out:variable name="skin_shared_images" select="concat($skin_root, '/shared/images/')"/>
- <out:variable name="skin_style" select="concat($skin_root, '/', $app, '/default.css')"/>
- <out:variable name="skin_banner" select="concat($skin_root, '/shared/banner.css')"/>
- <out:variable name="skin_fonts" select="concat($skin_root, '/fonts.css')"/>
- <out:variable name="skin_portlet" select="concat($skin_root, '/fragments/portlet.css')"/>
- <out:variable name="brand_images" select="concat($skin_root, '/branding/')"/>
- <out:variable name="product_name"><xts:string id="IDS_COGNOS_REPORTS"/></out:variable>
- <out:variable name="download_specialCharacters"><xts:string id="IDS_DOWNLOAD_SPECIALCHARACTERS"/></out:variable>
- <!-- Session variables -->
- <xsl:call-template name="sessionpassport"/>
- <!-- TODO: read these flags directly from the CAM header -->
- <out:variable name="is-secure" select="substring($passport,1,1)"/>
- <out:variable name="allow-anon" select="substring($passport,2,1)"/>
- <out:variable name="is-named" select="substring($passport,3,1)"/>
- <!-- Set this variable up, so that CAF will not error when doing logoff and attempting to set up the cafContextID<studio> variables below -->
- <out:variable name="passportForCafContext">
- <out:choose>
- <out:when test="/root/setCookies/cookie[@name='cam_passport' and string(@maxAge)='-1']"/>
- <out:otherwise><out:value-of select="$passport"/></out:otherwise>
- </out:choose>
- </out:variable>
- <!-- CAF Context IDs -->
- <!-- Report Studio -->
- <out:variable name="cafContextIDRS">
- <out:if test="$passportForCafContext != ''"><out:value-of select="xtsext:cafaction(concat('get_contextid_settemplatename_portalxsl_setcomponent_rs_setpassportid_', $passportForCafContext), '')"/></out:if>
- </out:variable>
- <!-- Query Studio -->
- <out:variable name="cafContextIDQS">
- <out:if test="$passportForCafContext != ''"><out:value-of select="xtsext:cafaction(concat('get_contextid_settemplatename_portalxsl_setcomponent_qs_setpassportid_', $passportForCafContext), '')"/></out:if>
- </out:variable>
- <!-- Analysis Studio -->
- <out:variable name="cafContextIDANS">
- <out:if test="$passportForCafContext != ''"><out:value-of select="xtsext:cafaction(concat('get_contextid_settemplatename_portalxsl_setcomponent_ans_setpassportid_', $passportForCafContext), '')"/></out:if>
- </out:variable>
- <!-- Event Studio -->
- <out:variable name="cafContextIDAGS">
- <out:if test="$passportForCafContext != ''"><out:value-of select="xtsext:cafaction(concat('get_contextid_settemplatename_portalxsl_setcomponent_es_setpassportid_', $passportForCafContext), '')"/></out:if>
- </out:variable>
- <!-- CMM -->
- <out:variable name="cafContextIDCMM">
- <out:if test="$passportForCafContext != ''"><out:value-of select="xtsext:cafaction(concat('get_contextid_settemplatename_portalxsl_setcomponent_cmm_setpassportid_', $passportForCafContext), '')"/></out:if>
- </out:variable>
- <!-- Request variables -->
- <out:variable name="user-agent" select="string(/root/http/param[@name='HTTP_USER_AGENT'])"/>
- <out:variable name="browser">
- <out:choose>
- <out:when test="contains($user-agent , 'MSIE')">ie</out:when> <!-- IE 4.xx and above -->
- <out:when test="contains($user-agent , 'Trident')">ie</out:when> <!-- ie 11 -->
- <out:when test="contains($user-agent , 'Safari/5') and not(contains($user-agent , 'Chrome'))">safari</out:when> <!-- Safari user-agent does not contain Chrome -->
- <out:when test="contains($user-agent , 'Chrome')">chrome</out:when> <!-- Chrome user-agent contains Safari also -->
- <out:when test="contains($user-agent , 'Mozilla/5.0')">moz</out:when> <!-- NS 6.xx and 7.xx -->
- <out:when test="contains($user-agent , 'Mozilla/4.')">ns4</out:when> <!-- NS 4.xx -->
- <out:when test="string-length($user-agent) = 0">undefined</out:when>
- <out:otherwise>other</out:otherwise>
- </out:choose>
- </out:variable>
- <!-- Browsers that work with QS -->
- <out:variable name="isQSFriendlyBrowser" select="contains(key('system-param', 'capabilities')/capability[@name='canUseQueryStudio']/@browser, $browser)"/>
- <!-- User Preferences -->
- <out:variable name="userPreferences" select="/root/user"/>
- <out:variable name="productLocale">
- <out:value-of select="$userPreferences/param[@name='productLocale']"/>
- </out:variable>
- <out:variable name="defaultOutputFormat">
- <out:value-of select="$userPreferences/param[@name='format']"/>
- </out:variable>
- <out:variable name="contentLocale">
- <out:value-of select="$userPreferences/param[@name='contentLocale']"/>
- </out:variable>
- <out:variable name="timeZone">
- <out:value-of select="$userPreferences/param[@name='timeZoneID']"/>
- </out:variable>
- <out:variable name="mappedProductLocale" select="xtsext:mapProductLocale(string(/root/user/param[@name='productLocale']))"/>
- <!-- Disabled for Titan -->
- <out:variable name="rsBIAProfile" select="false()"/>
- <out:variable name="rsPROProfile" select="false()"/>
- <!-- edition is set in cogstartup.xml -->
- <out:variable name="edition" select="string(/root/configProps/param[@name='cc']/property[@name='edition'])"/>
- <xsl:call-template name="gen-sessionCapabilitiesVars"/>
- <out:variable name="defaultContentRoot">
- <out:choose>
- <out:when test="key('session-param', 'e_root') and key('session-param', 'e_root') != ''">
- <out:value-of select="key('session-param', 'e_root')"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="'/content'"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="rsUIProfile">
- <out:choose>
- <out:when test="$rsPROProfile">
- <out:text>Professional</out:text>
- </out:when>
- <out:when test="$rsBIAProfile">
- <out:text>BUA_standalone</out:text>
- </out:when>
- </out:choose>
- </out:variable>
- <out:variable name="formatNameLookUp">
- <formats>
- <format id="CSV"><xts:string id="IDS_PROP_FORMAT_CSV"/></format>
- <format id="PDF"><xts:string id="IDS_PROP_FORMAT_PDF"/></format>
- <format id="HTML"><xts:string id="IDS_PROP_FORMAT_HTML"/></format>
- <format id="XML"><xts:string id="IDS_PROP_FORMAT_XML"/></format>
- <format id="XLWA"><xts:string id="IDS_PROP_FORMAT_XLS_2002"/></format>
- <format id="spreadsheetML"><xts:string id="IDS_PROP_FORMAT_XLS_2007"/></format>
- <format id="singleXLS"><xts:string id="IDS_PROP_FORMAT_SINGLE_XLS"/></format>
- <format id="XLS"><xts:string id="IDS_PROP_FORMAT_XLS"/></format>
- <format id="XHTML"><xts:string id="IDS_PROP_FORMAT_XHTML"/></format>
- <format id="HTMLFragment"><xts:string id="IDS_OTHERRUN_FORMAT_HTMLFRAGMENT"/></format>
- <format id="spreadsheetMLOfficeConnectionEnabled"><xts:string id="IDS_PROP_FORMAT_XLS_COC"/></format>
- <format id="xlsxData"><xts:string id="IDS_PROP_FORMAT_XLS_2007_DATA"/></format>
- <!--Restricting output formats -->
- <format id="CSV_RO"><xts:string id="IDS_PROP_FORMAT_CSV_RO"/></format>
- <format id="PDF_RO"><xts:string id="IDS_PROP_FORMAT_PDF_RO"/></format>
- <format id="XML_RO"><xts:string id="IDS_PROP_FORMAT_XML_RO"/></format>
- <format id="XLWA_RO"><xts:string id="IDS_PROP_FORMAT_XLS_2002_RO"/></format>
- <format id="spreadsheetML_RO"><xts:string id="IDS_PROP_FORMAT_XLS_2007_RO"/></format>
- <format id="singleXLS_RO"><xts:string id="IDS_PROP_FORMAT_SINGLE_XLS_RO"/></format>
- <format id="XLS_RO"><xts:string id="IDS_PROP_FORMAT_XLS_RO"/></format>
- <format id="spreadsheetMLOfficeConnectionEnabled_RO"><xts:string id="IDS_PROP_FORMAT_XLS_COC_RO"/></format>
- <format id="xlsxData_RO"><xts:string id="IDS_PROP_FORMAT_XLS_2007_DATA_RO"/></format>
- </formats>
- </out:variable>
- <out:variable name="supportedFormats">
- <out:for-each select="key('system-param','reportFormats')/format">
- <out:value-of select="concat(' ',@id, ' ')"/>
- </out:for-each>
- </out:variable>
- <out:variable name="documentFormats">
- <!-- 2003 -->
- <format name="application/vnd.coc-xl">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_XLS"/></readableFormat>
- </format>
- <format name="application/vnd.coc-wd">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_WORD"/></readableFormat>
- </format>
- <format name="application/vnd.coc-pp">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_POWERPOINT"/></readableFormat>
- </format>
- <!-- 2007 -->
- <format name="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_XLSX"/></readableFormat>
- </format>
- <format name="application/vnd.openxmlformats-officedocument.wordprocessingml.document">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_WORDX"/></readableFormat>
- </format>
- <format name="application/vnd.openxmlformats-officedocument.presentationml.presentation">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_POWERPOINTX"/></readableFormat>
- </format>
- <!-- 2007 - macro-enabled -->
- <format name="application/vnd.coc-xl.2007.macroEnabled">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_XLSX"/></readableFormat>
- </format>
- <format name="application/vnd.coc-wd.2007.macroEnabled">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_WORDX"/></readableFormat>
- </format>
- <format name="application/vnd.coc-pp.2007.macroEnabled">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_POWERPOINTX"/></readableFormat>
- </format>
- <!-- 2010 - macro-enabled both use excel 2007 icon, binary extenstion is xlsb the other is xlsm-->
- <format name="application/vnd.ms-excel.sheet.binary.macroEnabled.12">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_XLSB"/></readableFormat>
- </format>
- <format name="application/vnd.ms-excel.sheet.macroEnabled.12">
- <type><xts:string id="IDS_OBJ_COGNOS_OFFICE_DOCUMENT"/></type>
- <readableFormat><xts:string id="IDS_PROP_FORMAT_DOCUMENT_XLSB"/></readableFormat>
- </format>
- </out:variable>
- <!-- ====================
- = RTC Task 4127 Avoid running a report when a view is possible but not in user's default format.
- = New variables used to generate a view url and a report icon when the default output format from content manager is non-consumable.
- ====================
- -->
- <out:variable name="consumableOutputFormatIcon" select="'report'"/>
- <out:variable name="is-ui-rtl" select="xtsext:isRTLLocale($productLocale)"/>
- <!-- Calculates effective user capability taking into account the browser information -->
- <!-- Note: consult ../ps/system.xml for the studio-browser restriction map -->
- <out:template name="calUserCapability">
- <out:param name="capability"/>
- <out:param name="value"/>
- <out:variable name="browserRestrictionEntry" select="key('system-param', 'capabilities')/capability[@name=$capability]"/>
- <out:value-of select="$value = 'true' and (not($browserRestrictionEntry) or contains($browserRestrictionEntry/@browser, $browser))"/>
- </out:template>
- <!-- Calculates effective user capabilities of an object (e.g.: package) taking into account the browser information -->
- <!-- Output is a flat list of user capabilities (e.g.: " userCanUseANS userCanUsePPS ... ") -->
- <out:template name="calEffectiveObjectCapabilities">
- <out:param name="capabilities"/>
- <out:param name="canRecurse" select="true()"/>
- <out:choose>
- <!-- If no capability node is available (case of missing package object) then default to global capabilities. -->
- <out:when test="not(boolean($capabilities)) and $canRecurse">
- <!-- Call this template again using global capabilities instead -->
- <out:call-template name="calEffectiveObjectCapabilities">
- <out:with-param name="capabilities" select="/root/session/param[@name='capabilities']"/>
- <out:with-param name="canRecurse" select="false()"/> <!-- prevent recursive calls -->
- </out:call-template>
- </out:when>
- <out:otherwise>
- <out:for-each select="$capabilities/*">
- <out:variable name="capability" select="name(.)"/>
- <out:choose>
- <out:when test="$capability = 'canUseAdaptiveAnalyticsAdministration'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUseAdaptiveAnalyticsAdministration'"/></out:if>
- </out:when>
- <out:when test="$capability = 'canUseAdaptiveAnalytics'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUseAdaptiveAnalytics '"/></out:if>
- </out:when>
- <out:when test="$capability = 'canUseAnalysisStudio'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUseANS '"/></out:if>
- </out:when>
- <!--
- <out:when test="$capability = 'canUseReportStudio'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUseRS '"/></out:if>
- </out:when>
- -->
- <out:when test="$capability = 'canUseQueryStudio'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUseQS '"/></out:if>
- </out:when>
- <out:when test="$capability = 'canUsePowerPlay'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUsePPS '"/></out:if>
- </out:when>
- <out:when test="$capability = 'canOpenPowerPlayInAnalysisStudio'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanOpenPPInAnalysisStudio '"/></out:if>
- </out:when>
- <out:when test="$capability = 'canOpenPowerPlayInReportStudio'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanOpenPPInReportStudio '"/></out:if>
- </out:when>
- <out:when test="$capability = 'canUsePlanningContributor'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUsePlanningContributor '"/></out:if>
- </out:when>
- <out:when test="$capability = 'canUseEV'">
- <out:variable name="test-capability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:if test="$test-capability = 'true'"><out:value-of select="' userCanUseEV '"/></out:if>
- </out:when>
- <out:when test="$capability = 'canUseMetricStudio'">
- <out:variable name="canUseMetricStudio"><out:call-template name="calUserCapability"><out:with-param name="capability" select="$capability"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:variable name="canUseMetricsManagerAdministration"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMetricsManagerAdministration'"/><out:with-param name="value" select="boolean($capabilities/canUseMetricsManagerAdministration)"/></out:call-template></out:variable>
- <out:if test="$canUseMetricStudio = 'true' or $canUseMetricsManagerAdministration = 'true'"><out:value-of select="' userCanUseMetricsManager '"/></out:if>
- </out:when>
- </out:choose>
- </out:for-each>
- </out:otherwise>
- </out:choose>
- </out:template>
- </xsl:template>
- <!-- Generic meta tags -->
- <xsl:template match="pf:meta">
- <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
- <meta name="copyright">
- <out:attribute name="content"><xts:string id="IDS_COPYRIGHT"/></out:attribute>
- </meta>
- <meta name="trademark">
- <out:attribute name="content"><xts:string id="IDS_TRADEMARK"/></out:attribute>
- </meta>
- <meta name="template">
- <out:attribute name="content"><out:value-of select="key('env-param', 'm')"/></out:attribute>
- </meta>
- </xsl:template>
- <!--
- Template - pf:idToSearchPathForURL:
- This tempalte concerts a guid to a form that is usable in a searchPath. The result is caf protected and urlencoded
- because such a seach path is not web safe
- -->
- <xsl:template match="pf:idToSearchPathForURL">
- <xsl:variable name="source"><xsl:value-of select="@source"/></xsl:variable>
- <out:value-of select="xtsext:protect(xtsext:urlencode(concat(concat('storeID("',string({$source})),'")')),'url','storeID','getdata')"/>
- </xsl:template>
- <!--
- creates a url based on the url passed with with various replacement prameters resolved
- custom url's can contain the replacement variables %LOCALE% and or %STYLE%
- this replaces those variables with appriopiate values
- -->
- <xsl:template match="pf:CustomWelcomeURL">
- <out:variable name="welcomeURLOverride" select="/root/system/param[@name='welcomeURLOverride']"/>
- <out:variable name="replacedLangCustomURL" select="xtsext:replace(string($welcomeURLOverride), string('%LOCALE%'), string($productLocale)) "/>
- <out:variable name="customWelcomeURL" select="xtsext:replace(string($replacedLangCustomURL), string('%STYLE%'), string(/root/user/param[@name='skin']))" />
- <out:variable name="hasCustomWelcomeURL" select="string-length(normalize-space($customWelcomeURL)) > 0"/>
- </xsl:template>
- <!--
- Template - pf:help:
- This template defines the javascript to execute CC help when web page help hyperlink pressed.
- Operation:
- Generate the function help() javascript.
- -->
- <xsl:template match="pf:help">
- <out:variable name="es">
- <xsl:choose>
- <xsl:when test="@eventStudio='true'">true</xsl:when>
- <xsl:otherwise>false</xsl:otherwise>
- </xsl:choose>
- </out:variable>
- <out:variable name="context">
- <xsl:choose>
- <xsl:when test="@context">
- <xsl:value-of select="@context"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="''"/> <!-- Add default help context here -->
- </xsl:otherwise>
- </xsl:choose>
- </out:variable>
- <script language="javascript" src="{'{$webRoot}'}/ccl/helpDocs.js"></script>
- <script language="javascript">
- function help(sContext)
- {
- if (!sContext) {
- sContext = "<out:value-of select="$context"/>";
- }
- <out:variable name="helpBook">
- <out:text/>ug_<out:text/>
- <out:choose>
- <out:when test="$es='true'">cr_es</out:when>
- <out:when test="key('session-param','capabilities')/canUseAdministrationPortal">cra</out:when>
- <out:otherwise>cc</out:otherwise>
- </out:choose>
- <out:if test="$context!=''">_a</out:if>
- </out:variable>
- gotoHelp("<out:value-of select="xtsext:javascriptencode(string($mappedProductLocale))"/>", "<out:value-of select="$helpBook"/>", sContext,"<out:value-of select="xtsext:javascriptencode(string($webRoot))"/>");
- }
- </script>
- </xsl:template>
- <!-- Javascript Includes and Variables for the cognosLaunch function -->
- <xsl:template match="pf:launch">
- <script language="javascript">
- <out:attribute name="src"><out:value-of select="$webcontent"/><xsl:value-of select=" '/../cognoslaunch.js' "/></out:attribute>
- </script>
- <script language="javascript">
- var sGateway = "<out:value-of select="xtsext:javascriptencode(string($gateway))"/>";
- var sBackURL = "<out:value-of select="xtsext:javascriptencode(string($back-url))"/>";
- var sEncodedBackURL = "<out:value-of select="xtsext:protect(xtsext:urlencode(string($back-url)),'url','url','getdata')"/>";
- </script>
- </xsl:template>
- <xsl:template match="pf:getDefaultMorphletForObject">
- <xsl:variable name="class"><xsl:value-of select="@objectClass"/></xsl:variable>
- <out:choose>
- <out:when test="$class='portletProducer' or $class='portletFolder'">tools_portaladmin.xts</out:when>
- <out:when test="$class='portalSkinFolder'">tools_skinadmin.xts</out:when>
- <out:when test="$class='adminFolder'">tools_cs_administration.xts</out:when>
- <out:when test="$class='configurationFolder'">tools_service_config.xts</out:when>
- <out:when test="$class='namespaceFolder'">tools_directory.xts</out:when>
- <out:when test="$class='dispatcher'">tools_service_config.xts</out:when>
- <out:when test="$class='package' and string(key('env-param','from_tool'))='true'">cc_drillthrough.xts</out:when>
- <out:when test="$class='namespace' or $class='account' or $class='dataSource' or $class='dataSourceConnection' or $class='role'">tools_directory.xts</out:when>
- <out:when test="$class='securedFunction'">tools_capabilities.xts</out:when>
- <out:when test="$class='subscriptionFolder'">subscriptions/subscriptions.xts</out:when>
- <out:otherwise>cc.xts</out:otherwise>
- </out:choose>
- </xsl:template>
- <xsl:template match="pf:gen-action-string">
- <out:template name="gen-action-string">
- <out:param name="action" select="''"/>
- <out:param name="class"/>
- <out:param name="userInterfaces" select="''"/>
- <out:param name="targetUserInterfaces" select="''"/>
- <out:param name="documentType" select="''"/>
- <out:param name="launchableType" select="''"/>
- <out:param name="effectiveUserCapabilities" select="''"/>
- <out:variable name="sessionRSUIProfile" select="key('session-param','rsuiprofile')"/>
- <out:variable name="studioName">
- <out:choose>
- <out:when test="$class = 'analysis'">
- <out:text/><xts:string id="IDS_TOOLS_ANALYSIS"/><out:text/>
- </out:when>
- <out:when test="$class = 'query'">
- <out:text/><xts:string id="IDS_TOOLS_QUERY"/><out:text/>
- </out:when>
- <out:when test="$class = 'report' or $class = 'interactiveReport'">
- <out:choose>
- <out:when test="$sessionRSUIProfile='pro' or $sessionRSUIProfile='all'">
- <xts:string id="IDS_TOOLS_REPORT" />
- </out:when>
- <out:when test="$class = 'report' and $sessionRSUIProfile='bua'"> <!-- only Reports can be opened in Business Insight Advanced -->
- <xts:string id="IDS_TOOLS_ICE" />
- </out:when>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:text/><xts:string id="IDS_TOOLS_REPORT"/><out:text/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:choose>
- <out:when test="contains(' analysis report query interactiveReport reportView ', concat(' ', $class, ' ' ))">
- <out:choose>
- <out:when test="string($action) = 'run'">
- <out:text/><xts:string id="IDS_PROP_RUN_DEFAULT_ACTION_RUN_REPORT"/><out:text/>
- </out:when>
- <out:when test="string($action) = 'view'">
- <out:text/><xts:string id="IDS_PROP_RUN_DEFAULT_ACTION_VIEW_RECENT_REPORT"/><out:text/>
- </out:when>
- <out:when test="$action = 'edit' and $studioName != ''">
- <out:text/><xts:string id="IDS_PROP_RUN_DEFAULT_ACTION_OPEN_WITH_STUDIO"><xts:param name="studio"><out:value-of select="$studioName"/></xts:param></xts:string><out:text/>
- </out:when>
- </out:choose>
- </out:when>
- <out:when test="$class = 'package'">
- <out:choose>
- <out:when test="string(key('env-param','from_tool'))='true'">
- <out:text/><xts:string id="IDS_ACT_VIEW_PACKAGE_DRILL_THRU"/><out:text/>
- </out:when>
- <out:when test="($userInterfaces='metricStudio' or $targetUserInterfaces='metricStudio') and $action='view'">
- <out:text/><xts:string id="IDS_ACT_VIEW_METRICSPACKAGE_CONTENT"/><out:text/>
- </out:when>
- <out:when test="($userInterfaces='metricStudio' or $targetUserInterfaces='metricStudio') and $action='run'">
- <out:text/><xts:string id="IDS_ACT_OPEN_METRICS_MANAGER"/><out:text/>
- </out:when>
- <out:when test="($userInterfaces='planningContributor' or $targetUserInterfaces='planningContributor') and $action='view'">
- <out:text/><xts:string id="IDS_ACT_VIEW_PLANNINGPACKAGE_CONTENT"/><out:text/>
- </out:when>
- <out:when test="($userInterfaces='planningContributor' or $targetUserInterfaces='planningContributor') and $action='run'">
- <out:text/><xts:string id="IDS_ACT_OPEN_CONTRIBUTOR"/><out:text/>
- </out:when>
- <out:when test="($userInterfaces='adaptiveAnalytics' or $targetUserInterfaces='adaptiveAnalytics') and $action='view'">
- <out:text/><xts:string id="IDS_ACT_VIEW_ANALYTICS"/><out:text/>
- </out:when>
- <out:when test="($userInterfaces='adaptiveAnalytics' or $targetUserInterfaces='adaptiveAnalytics') and $action='run'">
- <out:text/><xts:string id="IDS_ACT_OPEN_ANALYTICS"/><out:text/>
- </out:when>
- <out:otherwise>
- <out:text/><xts:string id="IDS_ACT_VIEW_PACKAGE_CONTENT"/><out:text/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$class = 'folder' or $class = 'adminFolder' or $class='configurationFolder' or $class='namespaceFolder' or $class = 'content' or $class = 'portletFolder' or $class = 'portalSkinFolder'">
- <out:text/><xts:string id="IDS_ACT_VIEW_FOLDER_CONTENT"/><out:text/>
- </out:when>
- <out:when test="$class = 'URL'">
- <out:text/><xts:string id="IDS_ACT_OPEN_URL"/><out:text/>
- </out:when>
- <out:when test="starts-with(string($class),'powerPlay8')">
- <out:choose>
- <out:when test="$action='edit'">
- <out:text/><xts:string id="IDS_ACT_EDIT_WPPWX8"/><out:text/>
- </out:when>
- <out:otherwise>
- <out:text/><xts:string id="IDS_ACT_RUN_PDF_EX"/><out:text/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="starts-with(string($class),'powerPlay')">
- <out:choose>
- <out:when test="$action='edit'">
- <out:text/><xts:string id="IDS_ACT_EDIT_WPPWX_DESIGN"/><out:text/>
- </out:when>
- <out:otherwise>
- <out:text/><xts:string id="IDS_ACT_EDIT_WPPWX"/><out:text/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$class='portletProducer'">
- <out:text/><xts:string id="IDS_ACT_VIEW_PORTLETS"/><out:text/>
- </out:when>
- <out:when test="$class='portlet'">
- <out:text/><xts:string id="IDS_ACT_PREVIEW_PORTLET"/><out:text/>
- </out:when>
- <out:when test="$class='dispatcher'">
- <out:text/><xts:string id="IDS_VIEW_SERVICES"/><out:text/>
- </out:when>
- <out:when test="$class='namespace'">
- <out:text/><xts:string id="IDS_ACT_VIEW_NAMESPACE_CONTENT"/><out:text/>
- </out:when>
- <out:when test="$class='account'">
- <out:text/><xts:string id="IDS_ACT_VIEW_ACCOUNT"/><out:text/>
- </out:when>
- <out:when test="$class='dashboard'">
- <out:text/><xts:string id="IDS_ACT_OPEN_DASHBOARD"/><out:text/>
- </out:when>
- <out:when test="$class='dataSource'">
- <out:text/><xts:string id="IDS_ACT_VIEW_CONNECTIONS"/><out:text/>
- </out:when>
- <out:when test="$class='dataSourceConnection'">
- <out:text/><xts:string id="IDS_ACT_VIEW_SIGNONS"/><out:text/>
- </out:when>
- <out:when test="$class='agentDefinition'">
- <out:choose>
- <out:when test="$action='edit'">
- <out:text/><xts:string id="IDS_ACT_EDIT_WAG"/><out:text/>
- </out:when>
- <out:when test="$action='view'">
- <out:text/><xts:string id="IDS_ACT_HOTLIST_AGS"/><out:text/>
- </out:when>
- <out:when test="$action='run'">
- <out:text/><xts:string id="IDS_ACT_RUN_AGENT"/><out:text/>
- </out:when>
- </out:choose>
- </out:when>
- <out:when test="contains(' metricsFileImportTask metricsDataSourceETLTask metricsMaintenanceTask metricsExportTask ', concat(' ', $class, ' ' ))">
- <out:text/><xts:string id="IDS_ACT_RUN_METRICS_TASK"/><out:text/>
- </out:when>
- <out:when test="$class='reportTemplate'">
- <out:choose>
- <out:when test="$sessionRSUIProfile='pro' or $sessionRSUIProfile='all'">
- <xts:string id="IDS_ACT_EDIT_WRS" />
- </out:when>
- <out:when test="key('session-param','rsuiprofile')='bua'">
- <xts:string id="IDS_ACT_EDIT_WBUA" />
- </out:when>
- </out:choose>
- </out:when>
- <out:when test="$class = 'output' ">
- <out:text/><xts:string id="IDS_PROP_RUN_DEFAULT_ACTION_VIEW_RECENT_REPORT"/><out:text/>
- </out:when>
- <out:when test="$class='pagelet' ">
- <out:text/><xts:string id="IDS_ACT_PREVIEW_PAGE"/><out:text/>
- </out:when>
- <out:when test="$class='role' ">
- <out:text/><xts:string id="IDS_ACT_VIEW_ROLE"/><out:text/>
- </out:when>
- <out:when test="$class='group' ">
- <out:text/><xts:string id="IDS_ACT_VIEW_GROUP"/><out:text/>
- </out:when>
- <out:when test="$class='launchable'">
- <out:choose>
- <out:when test="$launchableType = 'application/vnd.ibm.cognos.ev' or $launchableType = 'application/vnd.ibm.cognos.ev.canvas'">
- <out:text/><xts:string id="IDS_ACT_EDIT_ADVISOR"/><out:text/>
- </out:when>
- <out:when test="$launchableType = 'application/vnd.ibm.cognos.cd'">
- <out:text />
- <xts:string id="IDS_ACT_OPEN_CD" />
- <out:text />
- </out:when>
- </out:choose>
- </out:when>
- <out:when test="$class='document' ">
- <out:variable name="readableFormat">
- <out:value-of select="$documentFormats/format[@name = $documentType]/readableFormat"/>
- </out:variable>
- <out:choose>
- <out:when test="$readableFormat != ''">
- <xts:string id="IDS_ACT_DOCUMENT_VIEW"><xts:param name="format"><out:value-of select="$readableFormat"/></xts:param></xts:string>
- </out:when>
- <out:otherwise><xts:string id="IDS_ACT_DEFAULT_DOCUMENT_VIEW"/></out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$class='securedFunction'">
- <out:text/><xts:string id="IDS_ACT_VIEW_CAPABILITY"/><out:text/>
- </out:when>
- </out:choose>
- </out:template>
- </xsl:template>
- <!--
- Template - pf:gen-action:
- This template generates another template gen-action which generates the action used by gen-url and gen-icon,
- -->
- <xsl:template match="pf:gen-action">
- <out:template name="gen-action">
- <out:param name="class"/>
- <out:param name="object"/>
- <out:param name="canExecute" select="false()"/>
- <out:param name="canRead" select="false()"/>
- <out:param name="canTraverse" select="false()"/>
- <out:param name="output_format" select="''"/>
- <out:param name="userInterfaces" select="''"/>
- <out:param name="targetUserInterfaces" select="''"/>
- <out:param name="effectiveUserCapabilities" select="''"/>
- <out:param name="launchableType" select="''"/>
- <!-- Perhaps in the future the preferredAction variable should be moved out of this template. That would remove the need for gen-action to interact directly with the cm object. -->
- <!--WO767 default action as selected by the use -->
- <out:variable name="preferredAction">
- <out:choose>
- <out:when test="( $object/cm:target/*/cm:defaultPortalAction and not($object/cm:target/*/cm:defaultPortalAction/@nil ) )">
- <out:value-of select="$object/cm:target/*/cm:defaultPortalAction"/>
- </out:when>
- <out:when test="($object/cm:defaultPortalAction and not( $object/cm:defaultPortalAction/@nil ) )">
- <out:value-of select="$object/cm:defaultPortalAction"/>
- </out:when>
- </out:choose>
- </out:variable>
- <out:variable name="sessionRSUIProfile" select="key('session-param','rsuiprofile')"/>
- <!-- WO767 if object has a preferredAction (defaultPortalAction property), then calculate final action -->
- <!-- based on class, defaultPortalAction property, permissions, output format, and capabilities/browser support -->
- <out:choose>
- <out:when test="$class = 'launchable' and ($launchableType='application/vnd.ibm.cognos.ev' or $launchableType='application/vnd.ibm.cognos.ev.canvas' or $launchableType='application/vnd.ibm.cognos.cd')">
- <out:text>edit</out:text>
- </out:when>
- <out:when test="contains(' analysis report interactiveReport query reportView ', concat(' ', $class, ' ' ))">
- <out:choose>
- <out:when test="$preferredAction='viewOutput'">
- <out:choose>
- <out:when test="$output_format != '' and $canRead and $canTraverse">view</out:when>
- <out:when test="$class='query' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseQS ')">edit</out:when>
- <out:when test="$class='analysis' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseANS ')">edit</out:when>
- <out:when test="$canExecute">run</out:when>
- <out:when test="(($class='report' and key('session-param','rsuiprofile')!='') or ($class='interactiveReport' and ($sessionRSUIProfile='pro' or $sessionRSUIProfile='all'))) and $canRead and contains($effectiveUserCapabilities, ' userCanUseRS ')">edit</out:when>
- </out:choose>
- </out:when>
- <out:when test="$preferredAction='run'">
- <out:choose>
- <out:when test="$canExecute">run</out:when>
- <out:when test="$output_format !='' and $canRead and $canTraverse">view</out:when>
- <out:when test="$class='query' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseQS ')">edit</out:when>
- <out:when test="$class='analysis' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseANS ')">edit</out:when>
- <out:when test="(($class='report' and key('session-param','rsuiprofile')!='') or ($class='interactiveReport' and ($sessionRSUIProfile='pro' or $sessionRSUIProfile='all'))) and $canRead and contains($effectiveUserCapabilities, ' userCanUseRS ')">edit</out:when>
- </out:choose>
- </out:when>
- <out:when test="$preferredAction='edit'">
- <out:choose>
- <out:when test="$class='query' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseQS ')">edit</out:when>
- <out:when test="(($class='report' and key('session-param','rsuiprofile')!='') or ($class='interactiveReport' and ($sessionRSUIProfile='pro' or $sessionRSUIProfile='all'))) and $canRead and contains($effectiveUserCapabilities, ' userCanUseRS ')">edit</out:when>
- <out:when test="$class='analysis' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseANS ')">edit</out:when>
- <out:when test="$output_format != '' and $canRead and $canTraverse">view</out:when>
- <out:when test="$canExecute">run</out:when>
- </out:choose>
- </out:when>
- <!-- this is the fall back if action was not set. For report, interactiveReport and report view it's: view, run, edit -->
- <!-- but for query and analysis it's: view, edit and run -->
- <out:when test="$output_format != '' and $canRead and $canTraverse">view</out:when>
- <out:when test="$class='query' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseQS ')">edit</out:when>
- <out:when test="$class='analysis' and $canRead and $canExecute and contains($effectiveUserCapabilities, ' userCanUseANS ')">edit</out:when>
- <out:when test="$canExecute">run</out:when>
- <out:when test="(($class='report' and key('session-param','rsuiprofile')!='') or ($class='interactiveReport' and ($sessionRSUIProfile='pro' or $sessionRSUIProfile='all'))) and $canRead and contains($effectiveUserCapabilities, ' userCanUseRS ')">edit</out:when>
- </out:choose>
- </out:when>
- <out:when test="contains(' package ', concat(' ', $class, ' ' ))">
- <out:if test="$userInterfaces='metricStudio' or $targetUserInterfaces='metricStudio'">
- <out:choose>
- <out:when test="($preferredAction='view') and $canTraverse">view</out:when>
- <out:when test="($preferredAction='run' or $preferredAction='') and ($canRead and $canExecute) and contains($effectiveUserCapabilities, ' userCanUseMetricsManager ')">run</out:when>
- <!-- default to View when user has Traverse access -->
- <out:when test="$canTraverse">view</out:when>
- </out:choose>
- </out:if>
- <out:if test="$userInterfaces='planningContributor' or $targetUserInterfaces='planningContributor'">
- <out:choose>
- <out:when test="($preferredAction='view') and $canTraverse">view</out:when>
- <out:when test="($preferredAction='run' or $preferredAction='') and ($canRead and $canExecute) and contains($effectiveUserCapabilities, ' userCanUsePlanningContributor ')">run</out:when>
- <!-- default to View when user has Traverse access -->
- <out:when test="$canTraverse">view</out:when>
- </out:choose>
- </out:if>
- <out:if test="$userInterfaces='adaptiveAnalytics' or $targetUserInterfaces='adaptiveAnalytics'">
- <out:choose>
- <out:when test="($preferredAction='view') and $canTraverse">view</out:when>
- <out:when test="($preferredAction='run' or $preferredAction='') and ($canRead and $canExecute) and contains($effectiveUserCapabilities, ' userCanUseAdaptiveAnalytics ')">run</out:when>
- <!-- default to View when user has Traverse access -->
- <out:when test="$canTraverse">view</out:when>
- </out:choose>
- </out:if>
- </out:when>
- <out:when test="$class='powerPlayReport'">
- <out:variable name="ppOutputFormat">
- <out:choose>
- <out:when test="cm:objectClass = 'shortcut'">
- <out:value-of select="cm:target/cm:powerPlayReport/cm:options/cm:powerPlayOptionOutputFormat[cm:name='outputFormat']/cm:value"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="cm:options/cm:powerPlayOptionOutputFormat[cm:name='outputFormat']/cm:value"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:choose>
- <out:when test="$ppOutputFormat = 'HTML' and ($canRead and $canExecute)"><xsl:text/>edit<xsl:text/></out:when>
- <out:when test="$preferredAction='run' and ($canRead and $canExecute)">run</out:when>
- <out:when test="$preferredAction='edit' and ($canRead and $canExecute)">edit</out:when>
- </out:choose>
- </out:when>
- <out:when test="$class='powerPlay8Report' or $class='powerPlay8ReportView'">
- <out:choose>
- <out:when test="$preferredAction = 'viewOutput'">
- <out:choose>
- <out:when test="$output_format != '' and $canRead">view</out:when>
- <out:when test="$canRead and $canExecute and $class != 'powerPlay8ReportView' and contains($effectiveUserCapabilities, ' userCanUsePPS ')">edit</out:when>
- <out:when test="$canRead and $canExecute">run</out:when>
- </out:choose>
- </out:when>
- <out:when test="$preferredAction = 'edit'">
- <out:choose>
- <out:when test="$canRead and $canExecute and (contains($effectiveUserCapabilities, ' userCanUsePPS ') or (contains($effectiveUserCapabilities, ' userCanUseRS ') and contains($effectiveUserCapabilities, 'userCanOpenPPInReportStudio')))">edit</out:when>
- <out:when test="$output_format != '' and $canRead">view</out:when>
- <out:when test="$canRead and $canExecute">run</out:when>
- </out:choose>
- </out:when>
- <out:when test="$preferredAction = 'run'">
- <out:choose>
- <out:when test="$canRead and $canExecute">run</out:when>
- <out:when test="$output_format != '' and $canRead">view</out:when>
- <out:when test="$canRead and $canExecute and $class !='powerPlay8ReportView' and contains($effectiveUserCapabilities, ' userCanUsePPS ')">edit</out:when>
- </out:choose>
- </out:when>
- </out:choose>
- </out:when>
- <out:when test="$class='agentDefinition' or $class='agentDefinitionView'">
- <out:variable name="hasEventList">
- <out:choose>
- <out:when test="( $object/cm:target/*/cm:mostRecentEventList and not($object/cm:target/*/cm:mostRecentEventList/@nil ) )">true</out:when>
- <out:when test="($object/cm:mostRecentEventList and not( $object/cm:mostRecentEventList/@nil ) )">true</out:when>
- <out:otherwise>false</out:otherwise>
- </out:choose>
- </out:variable>
- <out:choose>
- <out:when test="$preferredAction='viewEventList'">
- <out:choose>
- <out:when test="$hasEventList='true' and $canRead and $canTraverse">view</out:when>
- <out:when test="$canExecute and $canRead and $canTraverse">run</out:when>
- <out:when test="$class != 'agentDefinitionView' and $canRead and $canTraverse and $userCanUseAGS">edit</out:when>
- </out:choose>
- </out:when>
- <out:when test="$preferredAction='run'">
- <out:choose>
- <out:when test="$canExecute and $canRead and $canTraverse">run</out:when>
- <out:when test="$hasEventList='true' and $canRead and $canTraverse">view</out:when>
- <out:when test="$class != 'agentDefinitionView' and $canRead and $canTraverse and $userCanUseAGS">edit</out:when>
- </out:choose>
- </out:when>
- <out:when test="$preferredAction='edit'">
- <out:choose>
- <out:when test="$canRead and $canTraverse and $userCanUseAGS">edit</out:when>
- <out:when test="$hasEventList='true' and $canRead and $canTraverse">view</out:when>
- <out:when test="$canExecute and $canRead and $canTraverse">run</out:when>
- </out:choose>
- </out:when>
- </out:choose>
- </out:when>
- </out:choose>
- </out:template>
- </xsl:template>
- <!--
- Template - pf:gen-url:
- This template generates another template gen-url that builds a url. The url is dropped in the href attribute of a hyperlink to an entry.
- Operation:
- Outputs a gen-url template.
- -->
- <xsl:template match="pf:gen-url">
- <out:template name="gen-url">
- <out:param name="canExecute" select="true()"/>
- <out:param name="canRead" select="true()"/>
- <out:param name="canTraverse" select="true()"/>
- <out:param name="output_format" select="''"/>
- <out:param name="target" select="'false'"/>
- <out:param name="class"/>
- <out:param name="userInterfaces" select="''"/>
- <out:param name="targetUserInterfaces" select="''"/>
- <out:param name="morphlet"/>
- <out:param name="action" select="''"/>
- <out:param name="isDangling" select="false()"/>
- <out:param name="isContainer" select="false()"/>
- <out:param name="isIgnoreBackURL" select="false()"/>
- <out:param name="isDrillthruMode" select="false()"/>
- <out:param name="canWrite" select="true()"/>
- <out:param name="url-encoded-id"/>
- <out:param name="specifyRunOutputFormat" select="false()"/> <!-- if true: pass the output format for run actions -->
- <out:param name="canReadParent" select="true()"/>
- <out:param name="hasChildren" select="true()"/>
- <out:param name="bookmark"/>
- <out:param name="genURLForBookmark" select="false()"/>
- <out:param name="bShortcut" select="false()"/>
- <out:param name="id" select="''"/>
- <out:param name="executionPrompt" select="''"/>
- <out:param name="navigateUsingID" select="'false'"/>
- <out:param name="effectiveUserCapabilities" select="''"/>
- <out:param name="isSearch" select="false()"/>
- <!-- Restricting output formats variables-->
- <out:variable name="adjustedExecutionFormat">
- <out:choose>
- <out:when test="(string(cm:executionFormat) = 'PDF' and not($userCanGeneratePDFOutput))
- or (string(cm:executionFormat) = 'CSV' and not($userCanGenerateCSVOutput))
- or (string(cm:executionFormat) = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and (string(cm:executionFormat) = 'XLS' or
- string(cm:executionFormat) = 'XLWA' or
- string(cm:executionFormat) = 'singleXLS' or
- string(cm:executionFormat) = 'spreadsheetML' or
- string(cm:executionFormat) = 'xlsxData' or
- string(cm:executionFormat) = 'spreadsheetMLOfficeConnectionEnabled'))">
- <out:choose>
- <out:when test="($defaultOutputFormat = 'PDF' and not($userCanGeneratePDFOutput))
- or ($defaultOutputFormat = 'CSV' and not($userCanGenerateCSVOutput))
- or ($defaultOutputFormat = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and ($defaultOutputFormat = 'XLS' or
- $defaultOutputFormat = 'XLWA' or
- $defaultOutputFormat = 'singleXLS' or
- $defaultOutputFormat = 'spreadsheetML' or
- $defaultOutputFormat = 'xlsxData' or
- $defaultOutputFormat = 'spreadsheetMLOfficeConnectionEnabled'))">
- <out:text>HTML</out:text>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="$defaultOutputFormat"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="cm:executionFormat"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="adjustedShortcutExecutionFormat">
- <out:choose>
- <out:when test="(string(cm:target/*/cm:executionFormat) = 'PDF' and not($userCanGeneratePDFOutput))
- or (string(cm:target/*/cm:executionFormat) = 'CSV' and not($userCanGenerateCSVOutput))
- or (string(cm:target/*/cm:executionFormat) = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and (string(cm:target/*/cm:executionFormat) = 'XLS' or
- string(cm:target/*/cm:executionFormat) = 'XLWA' or
- string(cm:target/*/cm:executionFormat) = 'singleXLS' or
- string(cm:target/*/cm:executionFormat) = 'spreadsheetML' or
- string(cm:target/*/cm:executionFormat) = 'xlsxData' or
- string(cm:target/*/cm:executionFormat) = 'spreadsheetMLOfficeConnectionEnabled'))">
- <out:choose>
- <out:when test="($defaultOutputFormat = 'PDF' and not($userCanGeneratePDFOutput))
- or ($defaultOutputFormat = 'CSV' and not($userCanGenerateCSVOutput))
- or ($defaultOutputFormat = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and ($defaultOutputFormat = 'XLS' or
- $defaultOutputFormat = 'XLWA' or
- $defaultOutputFormat = 'singleXLS' or
- $defaultOutputFormat = 'spreadsheetML' or
- $defaultOutputFormat = 'xlsxData' or
- $defaultOutputFormat = 'spreadsheetMLOfficeConnectionEnabled'))">
- <out:text>HTML</out:text>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="$defaultOutputFormat"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="cm:target/*/cm:executionFormat"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="adjustedOutputFormat">
- <out:choose>
- <out:when test="($output_format = 'PDF' and not($userCanGeneratePDFOutput))
- or ($output_format = 'CSV' and not($userCanGenerateCSVOutput))
- or ($output_format = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and ($output_format = 'XLS' or
- $output_format = 'XLWA' or
- $output_format = 'singleXLS' or
- $output_format = 'spreadsheetML' or
- $output_format = 'xlsxData' or
- $output_format = 'spreadsheetMLOfficeConnectionEnabled'))">
- <out:choose>
- <out:when test="($defaultOutputFormat = 'PDF' and not($userCanGeneratePDFOutput))
- or ($defaultOutputFormat = 'CSV' and not($userCanGenerateCSVOutput))
- or ($defaultOutputFormat = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and ($defaultOutputFormat = 'XLS' or
- $defaultOutputFormat = 'XLWA' or
- $defaultOutputFormat = 'singleXLS' or
- $defaultOutputFormat = 'spreadsheetML' or
- $defaultOutputFormat = 'xlsxData' or
- $defaultOutputFormat = 'spreadsheetMLOfficeConnectionEnabled'))">
- <out:text>HTML</out:text>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="$defaultOutputFormat"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="$output_format"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="isShortcut" select="$bShortcut or cm:target"/>
- <!-- ===============================
- = Added for RTC Task 4127.
- = This variable constructs the consumable format list to add to the cognosViewer defaultOutput call.
- ===============================
- -->
- <out:variable name="viewer-output-formats-list">
- <out:if test="$output_format != '' and not(contains($supportedFormats,concat(' ',$output_format,' ')))">
- <out:text>,'','','</out:text>
- <out:value-of select="normalize-space($supportedFormats)"/>
- <out:text>'</out:text>
- </out:if>
- </out:variable>
- <!-- ===============================
- = Added for RTC Task 4127.
- = This variable is required so that the generated url does not show the non-consumable format in the ui.format parameter.
- ===============================
- -->
- <out:variable name="ui-output-format">
- <out:if test="$viewer-output-formats-list=''">
- <out:value-of select="$output_format"/>
- </out:if>
- </out:variable>
- <!-- path -->
- <out:variable name="target-path">
- <out:choose>
- <!-- Shortcut -->
- <out:when test=" cm:target/*/cm:searchPath ">
- <out:value-of select="cm:target/*/cm:searchPath"/>
- </out:when>
- <!-- Base object -->
- <out:otherwise>
- <out:value-of select="cm:searchPath"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <!-- id -->
- <out:variable name="target-id">
- <out:choose>
- <!-- id explicitly passed in -->
- <out:when test="$id != ''">
- <out:value-of select="$id"/>
- </out:when>
- <!-- Shortcut -->
- <out:when test=" cm:target/*/cm:storeID ">
- <out:value-of select="cm:target/*/cm:storeID"/>
- </out:when>
- <!-- Base object -->
- <out:otherwise>
- <out:value-of select="cm:storeID"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <!-- RV execution prompt -->
- <out:variable name="rv-executionprompt-launch">
- <out:choose>
- <out:when test="$executionPrompt = 'none'"></out:when> <!-- By design: do not pass any run.prompt value when executionPrompt is set to none - WO 2426 -->
- <out:when test="$executionPrompt != ''">, 'run.prompt', '<out:value-of select="$executionPrompt"/>'</out:when>
- <out:when test="cm:target/*/cm:executionPrompt">, 'run.prompt', '<out:value-of select="cm:target/*/cm:executionPrompt"/>'</out:when>
- <out:when test="cm:executionPrompt">, 'run.prompt', '<out:value-of select="cm:executionPrompt"/>'</out:when>
- </out:choose>
- </out:variable>
- <!-- RV language context option (asks RV to render in one locale)-->
- <out:variable name="rv-run-language">
- <out:choose>
- <out:when test=" cm:target/*/cm:executionLocale ">
- <out:value-of select="cm:target/*/cm:executionLocale"/>
- </out:when>
- <out:when test="cm:executionLocale">
- <out:value-of select="cm:executionLocale"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$contentLocale"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="rv-lang-execution">
- <out:if test="key('system-param', 'useReportLocaleInRVUI') = 'true'">
- <out:text/>&lang=<out:value-of select="$rv-run-language"/>
- </out:if>
- </out:variable>
- <out:variable name="rv-lang-cl">
- <out:if test="key('system-param', 'useReportLocaleInRVUI') = 'true'">
- <out:text/>&lang=<out:value-of select="$contentLocale"/>
- </out:if>
- </out:variable>
- <out:variable name="launch-rv-lang-execution">
- <out:if test="key('system-param', 'useReportLocaleInRVUI') = 'true'">
- <out:text/>, 'ui.language', '<out:value-of select="xtsext:javascriptencode($rv-run-language)"/>'
- </out:if>
- </out:variable>
- <out:variable name="launch-rv-lang-cl">
- <out:if test="key('system-param', 'useReportLocaleInRVUI') = 'true'">
- <out:text/>, 'ui.language', '<out:value-of select="xtsext:javascriptencode($contentLocale)"/>'
- </out:if>
- </out:variable>
- <out:variable name="ui-bookmark">
- <out:if test="string($bookmark) != ''">
- <out:text/>&ui.bookmark=<out:value-of select="xtsext:urlencode(string($bookmark))"/>
- </out:if>
- </out:variable>
- <out:variable name="ui-bookmark-launch">
- <out:if test="string($bookmark) != ''">
- <out:text/>, 'ui.bookmark', '<out:value-of select="xtsext:javascriptencode($bookmark)"/>'
- </out:if>
- </out:variable>
- <out:variable name="rv-execution-params">
- <out:choose>
- <!-- Shortcut -->
- <out:when test="cm:target/*/cm:searchPath and string(cm:target/*/cm:executionPrompt) != ''">
- <out:text/>&run.outputFormat=<out:value-of select="$adjustedShortcutExecutionFormat"/>&run.prompt=<out:value-of select="cm:target/*/cm:executionPrompt"/>
- </out:when>
- <out:when test="cm:target/*/cm:searchPath and string(cm:target/*/cm:executionPrompt) = ''">
- <out:text/>&run.outputFormat=<out:value-of select="$adjustedShortcutExecutionFormat"/>
- </out:when>
- <!-- Base object -->
- <out:when test="string(cm:executionPrompt) = ''">
- <out:text/>&run.outputFormat=<out:value-of select="$adjustedExecutionFormat"/>
- </out:when>
- <out:otherwise>
- <out:text/>&run.outputFormat=<out:value-of select="$adjustedExecutionFormat"/>&run.prompt=<out:value-of select="cm:executionPrompt"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="rv-execution-params-launch">
- <out:choose>
- <!-- Shortcut -->
- <out:when test=" cm:target/*/cm:searchPath">
- <!-- Restricting output formats -->
- <out:text/>, 'run.outputFormat', '<out:value-of select="$adjustedShortcutExecutionFormat"/>'<out:value-of select="$rv-executionprompt-launch"/><out:text/>
- </out:when>
- <!-- Base object -->
- <out:otherwise>
- <out:text/>, 'run.outputFormat', '<out:value-of select="$adjustedExecutionFormat"/>'<out:value-of select="$rv-executionprompt-launch"/><out:text/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="drillThroughTargetParameterValues">
- <out:if test="drillThroughTargetParameterValues and drillThroughTargetParameterValues != ''">
- <out:value-of select="drillThroughTargetParameterValues"/>
- </out:if>
- </out:variable>
- <out:variable name="launchableType">
- <out:choose>
- <!-- Shortcut -->
- <out:when test="cm:target/*/cm:searchPath"><out:value-of select="cm:target/*/cm:launchableType"/></out:when>
- <!-- Base object -->
- <out:otherwise><out:value-of select="cm:launchableType"/></out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="general-url-prefix">
- <out:choose>
- <out:when test="$genURLForBookmark"> <!-- When generating a bookmark, use the gateway configuration setting. -->
- <out:value-of select="string(/root/configProps/param[@name='cps']/property[@name='gateway'])"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="string($gateway)"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <!-- For bookmarks that are not redirected to a new window need to use abosolute url from general-url-prefix variable and the inner url (ui.gateway) should be relative-->
- <out:variable name="launch-url-prefix">
- <out:value-of select="$general-url-prefix"/>?b_action=xts.run&m=<out:text/>
- <out:value-of select="concat($app, '/', 'launch.xts')"/>
- <out:text/>&ui.gateway=<out:value-of select="xtsext:protect(xtsext:urlencode(string($gateway)),'url','userData','getdata')"/>
- </out:variable>
- <!-- For Bookmarks that open in a new window it is better to use relative urls within the outer absolute URL (redirect-bookmarkURL) -->
- <out:variable name="launch-rel-url-prefix">
- <out:value-of select="$gateway"/>?b_action=xts.run&m=<out:text/>
- <out:value-of select="concat($app, '/', 'launch.xts')"/>
- <out:text/>&ui.gateway=<out:value-of select="xtsext:protect(xtsext:urlencode(string($gateway)),'url','userData','getdata')"/>
- </out:variable>
- <out:variable name="redirect-bookmarkURL">
- <out:value-of select="concat($general-url-prefix,'?b_action=xts.run&m=portal/main.xts&m_redirect_windowmode=2&m_redirect=')"/>
- </out:variable>
- <out:variable name="encoding" select="/root/env/param[@name='encoding']"/>
- <out:choose>
- <!-- isDangling if true no hyperlink -->
- <out:when test="$isDangling"></out:when>
- <!-- isContainer but no traverse permission -->
- <out:when test="$isContainer and $canTraverse=false()"></out:when>
- <!-- folder -->
- <out:when test="$class='folder'">
- <xsl:call-template name="gen-url-other" />
- </out:when>
- <!-- content -->
- <out:when test="$class='content'">
- <xsl:call-template name="gen-url-other"/>
- </out:when>
- <!-- Handle "launchable" objects -->
- <out:when test="$class='launchable'">
- <out:choose>
- <!-- MVC - Content Reference -->
- <out:when test="$launchableType = 'application/vnd.ibm.cognos.instance'">
- <out:if test="$mvc-N-enabled">
- <out:if test="$canTraverse and $canRead">
- <xsl:call-template name="gen-url-other"/>
- </out:if>
- </out:if>
- </out:when>
- <!-- Cognos Insight objects -->
- <out:when test="$launchableType = 'application/vnd.ibm.cognos.cd'">
- <out:if test="$canRead and $canExecute and $userCanUseCI">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway,'ui.action','edit' ,'ui.tool', 'cd', 'ui.backURL', sBackURL, 'ui.id', '<out:value-of select="$target-id"/>' );<out:text/>
- </out:if>
- </out:when>
- <!-- EVStudio objects -->
- <out:when test="$launchableType = 'application/vnd.ibm.cognos.ev'">
- <out:if test="$canRead and $userCanUseEV ">
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway,'ui.action','edit' ,'ui.tool', 'EVStudio', 'ui.backURL', sBackURL, 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>' );<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$launch-url-prefix"/>
- <out:text/>&ui.tool=EVStudio&ui.action=edit&launch.openJSStudioInFrame=true<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <out:when test="$launchableType = 'application/vnd.ibm.cognos.ev.canvas'">
- <out:if test="$canRead and $userCanUseEV ">
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway,'ui.action','edit','ui.mode','canvas', 'ui.tool', 'EVStudio', 'ui.backURL', sBackURL, 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>' );<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$launch-url-prefix"/>
- <out:text/>&ui.tool=EVStudio&ui.action=edit&launch.openJSStudioInFrame=true<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <!-- other launchables -->
- </out:choose>
- </out:when>
- <!-- report or interactiveReport -->
- <out:when test="$class='report' or $class='interactiveReport'">
- <out:variable name="rsType">
- <out:if test="$rsUIProfile != ''">
- <out:text>, 'ui.profile', '</out:text><out:value-of select="$rsUIProfile"/><out:text>'</out:text>
- </out:if>
- </out:variable>
- <!--Note: capabilites included in 'action' variable calc. done in pf:gen-action -->
- <out:if test="$action != '' "> <!-- if empty user didn't have proper permissions -->
- <out:choose>
- <out:when test="$action='edit' and ($class='report' or ($class='interactiveReport' and $rsUIProfile = 'Professional'))">
- <out:variable name="sq">'</out:variable>
- <out:variable name="apos">'</out:variable>
- <out:variable name="mod-path">
- <out:value-of select="xtsext:replace(string($target-path),$sq,$apos)"/>
- </out:variable>
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway, 'ui.tool', 'ReportStudio', 'ui.backURL', sBackURL, 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $mod-path ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>', 'ui.action', 'edit'<out:value-of select="$rv-executionprompt-launch"/><out:value-of select="$rsType"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:variable name="inFrame">
- <out:choose>
- <out:when test="$class='interactiveReport'">false</out:when>
- <out:otherwise>true</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="redirectURL">
- <out:value-of select="$launch-rel-url-prefix"/>
- <out:text/>&ui.tool=ReportStudio&ui.action=edit&launch.openJSStudioInFrame=<out:text/><out:value-of select="$inFrame"/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.drillThroughTargetParameterValues=<out:value-of select="xtsext:protect(xtsext:urlencode( string($drillThroughTargetParameterValues)),'url','searchPath','getdata')"/>
- <out:if test="$rsUIProfile != ''">&ui.profile=<out:value-of select="$rsUIProfile"/></out:if>
- </out:variable>
- <out:value-of select="$redirect-bookmarkURL"/><out:value-of select="xtsext:protect(xtsext:urlencode($redirectURL),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="/root/system/param[@name = 'allowExpandedMHT'] = 'true' and $action='view' and $class='interactiveReport'">
- <!-- COGCQ00867718 -->
- <out:value-of select="$general-url-prefix"/>/repository/sid/cm/rid/<out:value-of select="$target-id"/>/oid/default/content/mht/content<out:text/>
- </out:when>
- <out:when test="$action='view' ">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'CognosViewer', 'ui.backURL', '<out:if test="not($isIgnoreBackURL)"><out:value-of select="xtsext:javascriptencode(string($back-url))"/></out:if>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( concat('defaultOutput(', $target-path, $viewer-output-formats-list, ')' ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>' <out:value-of select="$launch-rv-lang-cl"/>,'ui.action', 'view','ui.name','<out:value-of select="xtsext:javascriptencode(string(cm:defaultName))"/>','ui.format','<out:value-of select="$ui-output-format"/>' <out:value-of select="$ui-bookmark-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( concat('defaultOutput(', $target-path, $viewer-output-formats-list, ')' ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&ui.format=<out:value-of select="$ui-output-format"/>
- <out:value-of select="$rv-lang-cl"/>
- <out:value-of select="$ui-bookmark"/><out:text/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$action='run'">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'CognosViewer', 'ui.backURL', '<out:if test="not($isIgnoreBackURL)"><out:value-of select="xtsext:javascriptencode(string($back-url))"/></out:if>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>' <out:value-of select="$launch-rv-lang-execution"/>,'ui.action', 'run'<out:if test="$specifyRunOutputFormat">, 'run.outputFormat', '<out:value-of select="$adjustedOutputFormat"/>'</out:if>,'ui.name','<out:value-of select="xtsext:javascriptencode(cm:defaultName)"/>' <out:value-of select="$ui-bookmark-launch"/><out:value-of select="$rv-execution-params-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=run<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string( $target-path ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:value-of select="$rv-lang-execution"/>
- <out:value-of select="$ui-bookmark"/>
- <out:value-of select="$rv-execution-params"/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- </out:choose>
- </out:if>
- </out:when>
- <!-- query -->
- <out:when test="$class='query' ">
- <out:choose>
- <out:when test="not(cm:nid) and $action!=''"> <!-- if empty user didn't have proper permissions -->
- <!--Note: capabilites included in 'action' variable calc. done in pf:gen-action -->
- <out:choose>
- <out:when test="$action='view' ">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'CognosViewer', 'ui.backURL', '<out:if test="not($isIgnoreBackURL)"><out:value-of select="xtsext:javascriptencode(string($back-url))"/></out:if>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( concat('defaultOutput(', $viewer-output-formats-list, $target-path, ')' ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>' <out:value-of select="$launch-rv-lang-cl"/>,'ui.action', 'view','ui.name','<out:value-of select="xtsext:javascriptencode(string(cm:defaultName))"/>','ui.format','<out:value-of select="$ui-output-format"/>' <out:value-of select="$ui-bookmark-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view<xsl:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( concat('defaultOutput(', $target-path, $viewer-output-formats-list, ')' ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&ui.format=<out:value-of select="$ui-output-format"/>
- <out:value-of select="$rv-lang-cl"/>
- <out:value-of select="$ui-bookmark"/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$action='edit'">
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'QueryStudio', 'ui.backURL', '<out:if test="not($isIgnoreBackURL)"><out:value-of select="xtsext:javascriptencode(string($back-url))"/></out:if>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>', 'ui.action', 'edit'<out:value-of select="$rv-executionprompt-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$launch-url-prefix"/>
- <out:text/>&ui.tool=QueryStudio&ui.action=edit<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.drillThroughTargetParameterValues=<out:value-of select="xtsext:protect(xtsext:urlencode( string($drillThroughTargetParameterValues)),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$action='run'">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'CognosViewer', 'ui.backURL', '<out:if test="not($isIgnoreBackURL)"><out:value-of select="xtsext:javascriptencode(string($back-url))"/></out:if>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>' <out:value-of select="$launch-rv-lang-execution"/>,'ui.action', 'run'<out:if test="$specifyRunOutputFormat">, 'run.outputFormat', '<out:value-of select="$adjustedOutputFormat"/>'</out:if>,'ui.name','<out:value-of select="xtsext:javascriptencode(cm:defaultName)"/>' <out:value-of select="$ui-bookmark-launch"/><out:value-of select="$rv-execution-params-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=run<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string( $target-path ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:value-of select="$rv-lang-execution"/>
- <out:value-of select="$ui-bookmark"/>
- <out:value-of select="$rv-execution-params"/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- </out:choose>
- </out:when>
- <out:when test="cm:nid and $canRead">
- <out:variable name="daurl">
- <out:value-of select="cm:uri"/>
- <!-- Add the back URL, LA and LO -->
- <out:text/>&LA=<out:value-of select="$productLocale"/>
- <out:text/>&LO=<out:value-of select="$contentLocale"/>
- <out:if test="not($genURLForBookmark)">
- <out:text/>&back=<out:value-of select="$encoded-s7-back-url"/>
- </out:if>
- </out:variable>
- <out:value-of select="xtsext:protect(string($daurl),'none','s7url','s7url')"/>
- </out:when>
- </out:choose>
- </out:when>
- <!-- reportView -->
- <out:when test="$class='reportView' ">
- <out:variable name="rsType">
- <out:if test="$rsUIProfile != ''">
- <out:text>, 'ui.profile','</out:text><out:value-of select="$rsUIProfile"/><out:text>'</out:text>
- </out:if>
- </out:variable>
- <out:variable name="baseClass">
- <out:choose>
- <out:when test="*[local-name()='base'] and not(*[local-name()='base']/@nil )">
- <out:value-of select="*[local-name()='base']/*/*[local-name()='objectClass']"/>
- </out:when>
- <out:when test="cm:objectClass = 'shortcut'">
- <out:value-of select="*[local-name()='target']/*/*[local-name()='base']/*/*[local-name()='objectClass']"/>
- </out:when>
- </out:choose>
- </out:variable>
- <!--Note: capabilites included in 'action' variable calc. done in pf:gen-action -->
- <out:if test="$action != '' "> <!-- if empty user didn't have proper permissions -->
- <out:choose>
- <out:when test="/root/system/param[@name = 'allowExpandedMHT'] = 'true' and $action='view' and $baseClass='interactiveReport'">
- <out:value-of select="$general-url-prefix"/>/repository/sid/cm/rid/<out:value-of select="$target-id"/>/oid/default/content/mht/content<out:text/>
- </out:when>
- <out:when test="$action='view' ">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'CognosViewer', 'ui.backURL', '<out:if test="not($isIgnoreBackURL)"><out:value-of select="xtsext:javascriptencode(string($back-url))"/></out:if>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( concat('defaultOutput(', $viewer-output-formats-list, $target-path, ')' ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>' <out:value-of select="$launch-rv-lang-cl"/>,'ui.action', 'view','ui.name','<out:value-of select="xtsext:javascriptencode(string(cm:defaultName))"/>','ui.format','<out:value-of select="$ui-output-format"/>' <out:value-of select="$ui-bookmark-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( concat('defaultOutput(', $target-path, $viewer-output-formats-list, ')' ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&ui.format=<out:value-of select="$ui-output-format"/>
- <out:value-of select="$rv-lang-cl"/>
- <out:value-of select="$ui-bookmark"/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$action='run'">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'CognosViewer', 'ui.backURL', '<out:if test="not($isIgnoreBackURL)"><out:value-of select="xtsext:javascriptencode(string($back-url))"/></out:if>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>' <out:value-of select="$launch-rv-lang-execution"/>,'ui.action', 'run' <out:if test="$specifyRunOutputFormat">, 'run.outputFormat', '<out:value-of select="$adjustedOutputFormat"/>'</out:if>, 'ui.name','<out:value-of select="xtsext:javascriptencode(cm:defaultName)"/>' <out:value-of select="$ui-bookmark-launch"/><out:value-of select="$rv-execution-params-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=run<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string( $target-path ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:value-of select="$rv-lang-execution"/>
- <out:value-of select="$ui-bookmark"/>
- <out:value-of select="$rv-execution-params"/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- </out:choose>
- </out:if>
- </out:when>
- <!-- Analysis -->
- <out:when test="$class='analysis'">
- <!--Note: capabilites included in 'action' variable calc. done in pf:gen-action -->
- <out:if test="$action != '' "> <!-- if empty user didn't have proper permissions -->
- <out:choose>
- <out:when test="$action='view' ">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.format','<out:value-of select="xtsext:javascriptencode($ui-output-format)"/>' <out:value-of select="$launch-rv-lang-cl"/>,'ui.name','<out:value-of select="xtsext:javascriptencode(cm:defaultName)"/>', 'ui.gateway', sGateway, 'ui.tool', 'CognosViewer', <out:if test="not($isIgnoreBackURL)">'ui.backURL', '<out:value-of select="xtsext:javascriptencode(string($back-url))"/>', </out:if>'ui.object', '<out:value-of select="xtsext:javascriptencode( concat('defaultOutput(', $viewer-output-formats-list, $target-path, ')' ) )"/>', 'ui.action', 'view'<out:if test="$drillThroughTargetParameterValues != ''">, 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>'</out:if> <out:value-of select="$ui-bookmark-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( concat('defaultOutput(', $target-path, $viewer-output-formats-list, ')' ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&ui.format=<out:value-of select="$ui-output-format"/>
- <out:value-of select="$rv-lang-cl"/><out:text/>
- <out:value-of select="$ui-bookmark"/><out:text/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$action='edit' ">
- <out:variable name="sq">'</out:variable>
- <out:variable name="apos">'</out:variable>
- <out:variable name="mod-path">
- <out:value-of select="xtsext:replace(string($target-path),$sq,$apos)"/>
- </out:variable>
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway, 'ui.tool', 'AnalysisStudio', 'ui.backURL', sBackURL, 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $mod-path ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>', 'ui.action', 'edit'<out:value-of select="$rv-executionprompt-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:variable name="redirectURL">
- <out:value-of select="$launch-rel-url-prefix"/>
- <out:text/>&ui.tool=AnalysisStudio&ui.action=edit&launch.openJSStudioInFrame=true<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.drillThroughTargetParameterValues=<out:value-of select="xtsext:protect(xtsext:urlencode( string($drillThroughTargetParameterValues)),'url','searchPath','getdata')"/>
- </out:variable>
- <out:value-of select="$redirect-bookmarkURL"/><out:value-of select="xtsext:protect(xtsext:urlencode( string($redirectURL)),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$action='run'">
- <out:choose>
- <out:when test="$isDrillthruMode">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'CognosViewer' <out:value-of select="$launch-rv-lang-execution"/>, <out:if test="not($isIgnoreBackURL)">'ui.backURL', '<out:value-of select="xtsext:javascriptencode(string($back-url))"/>', </out:if>'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.action', 'run'<out:if test="$drillThroughTargetParameterValues != ''">, 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>'</out:if><out:if test="$specifyRunOutputFormat">, 'run.outputFormat', '<out:value-of select="$adjustedOutputFormat"/>'</out:if>,'ui.name','<out:value-of select="xtsext:javascriptencode(cm:defaultName)"/>' <out:value-of select="$ui-bookmark-launch"/><out:value-of select="$rv-execution-params-launch"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=run<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode(string($target-path)),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:value-of select="$rv-lang-execution"/>
- <out:value-of select="$ui-bookmark"/>
- <out:value-of select="$rv-execution-params"/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:when>
- </out:choose>
- </out:if>
- </out:when>
- <!-- Dashboard -->
- <out:when test="$class='dashboard' ">
- <!-- Page's requiredCapabilities check -->
- <out:if test="$userCanUseDashboardViewer and $canRead and $canTraverse">
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:choose>
- <out:when test="string(/root/generalConfigSettings/configuration/property[@name='portal.launchBusinessInsightChromeless']) = 'true'">
- <out:variable name="winProp"><out:text/>menubar=no,toolbar=no,status=no,location=no,resizable=yes,scrollbars=yes<out:text/></out:variable>
- <out:text/>javascript:cognosLaunchInWindow('_blank', '<out:value-of select="$winProp"/>', 'ui.gateway', sGateway, 'ui.tool', 'DashboardConsole', 'ui.action', 'edit', 'ui.id', '<out:value-of select="$target-id"/>');<out:text/>
- </out:when>
- <out:otherwise>
- <out:text/>javascript:directLaunch('ui.gateway', sGateway, 'ui.tool', 'DashboardConsole', 'ui.action', 'edit', 'ui.id', '<out:value-of select="xtsext:javascriptencode($target-id)"/>','ui.backURL', '<out:value-of select="xtsext:javascriptencode(string($back-url))"/>','ui.errURL','<out:value-of select="xtsext:javascriptencode(string($back-url))"/>', 'ui.encoding', '<out:value-of select="xtsext:javascriptencode($encoding)"/>');<out:text/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <!-- Build up the atom path - URL encoding each entry -->
- <out:variable name="atom-path">
- <out:call-template name="constructDashboardAtomPath">
- <out:with-param name="atomPath" select="cm:ancestors"/>
- </out:call-template>
- <out:value-of select="xtsext:urlencode(cm:defaultName)"/>
- </out:variable>
- <out:variable name="redirectURL">
- <out:value-of select="$launch-rel-url-prefix"/>
- <out:text/>&ui.tool=DashboardConsole&ui.action=edit<out:text/>
- <out:text/>&ui.atompath=<out:value-of select="xtsext:protect(xtsext:urlencode(string($atom-path)),'url','searchPath','getdata')"/>
- </out:variable>
- <out:value-of select="$redirect-bookmarkURL"/><out:value-of select="xtsext:protect(xtsext:urlencode($redirectURL),'url','searchPath','getdata')"/>
- <out:text/>&m_redirect_uitool=DashboardConsole<out:text/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <!-- pagelet -->
- <out:when test="$class='pagelet' ">
- <!-- Page's requiredCapabilities check -->
- <out:if test="$canExecute">
- <out:value-of select="$general-url-prefix"/>?b_action=dashboard&pathinfo=/pagelet&path=storeID(%22<out:value-of select="$target-id"/>%22)<out:text/>
- <out:if test="not(/root/system/param[@name='ui_hide']/CRN_HEADER_TITLE)">
- <out:text>&frag-header=true</out:text>
- </out:if>
- <out:if test="not($genURLForBookmark)">
- <out:text/>&backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:if>
- </out:when>
- <!-- Wire off generating a URL for archiveLocation objects here (before looking at cm:uri below) since these objects happen to have a uri that we don't care to handle here. -->
- <out:when test="$class='archiveLocation'"/>
- <!-- URL or short-cut to URL-->
- <out:when test="cm:uri or cm:target/*/cm:uri">
- <out:if test="$canRead"> <!-- Do not display the URL hyperlink if no read permissions -->
- <out:choose>
- <out:when test="cm:uri and xtsext:cafaction('issafeurl_null', normalize-space(cm:uri)) = 'true'">
- <out:value-of select="cm:uri"/>
- </out:when>
- <out:when test="cm:target/*/cm:uri and xtsext:cafaction('issafeurl_null', normalize-space(cm:target/*/cm:uri)) = 'true'">
- <out:value-of select="cm:target/*/cm:uri"/>
- </out:when>
- </out:choose>
- </out:if>
- </out:when>
- <!-- metrics tasks -->
- <out:when test="contains(' metricsFileImportTask metricsDataSourceETLTask metricsMaintenanceTask metricsExportTask ', concat(' ', $class, ' ' ))">
- <out:if test="$canExecute">
- <!-- Bug 610731 need to redirect to get routing server group if there is one the cost to do it for all objects is too high -->
- <out:value-of select="$general-url-prefix"/>?b_action=xts.run&m=portal/getRoutingSG.xts<out:text/>
- <out:text/>&m_obj=<out:value-of select="xtsext:protect(xtsext:urlencode( string( $target-path ) ),'url','searchPath','getdata')"/>
- <out:text/>&bAction=dis.run<out:text/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:if>
- </out:when>
- <!-- reportTemplate -->
- <out:when test="$class='reportTemplate'">
- <out:variable name="rsType">
- <out:if test="$rsUIProfile != ''">
- <out:text>, 'ui.profile', '</out:text><out:value-of select="$rsUIProfile"/><out:text>'</out:text>
- </out:if>
- </out:variable>
- <out:if test="$canRead and contains($effectiveUserCapabilities, ' userCanUseRS ')">
- <out:variable name="sq">'</out:variable>
- <out:variable name="apos">'</out:variable>
- <out:variable name="mod-path">
- <out:value-of select="xtsext:replace(string($target-path),$sq,$apos)"/>
- </out:variable>
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway, 'ui.tool', 'ReportStudio', 'ui.backURL', sBackURL, 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $mod-path ) )"/>', 'ui.action', 'edit'<out:value-of select="$rsType"/>);<out:text/>
- </out:when>
- <out:otherwise>
- <out:variable name="redirectURL">
- <out:value-of select="$launch-rel-url-prefix"/>
- <out:text/>&ui.tool=ReportStudio&ui.action=edit&launch.openJSStudioInFrame=true<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- </out:variable>
- <out:value-of select="$redirect-bookmarkURL"/><out:value-of select="xtsext:protect(xtsext:urlencode($redirectURL),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <!-- PPW Series 8 -->
- <out:when test="($class='powerPlay8Report' or $class='powerPlay8ReportView')">
- <out:if test="$action!=''"><!-- if empty user doesn't have proper permission -->
- <out:choose>
- <out:when test="cm:objectClass != 'shortcut'">
- <out:call-template name="buildpp8">
- <out:with-param name="thisnode" select="."/>
- <out:with-param name="encoded-back-url" select="$encoded-back-url"/>
- <out:with-param name="target-path" select="$target-path"/>
- <out:with-param name="target" select="$target"/>
- <out:with-param name="action" select="$action"/>
- <out:with-param name="genURLForBookmark" select="$genURLForBookmark"/>
- <out:with-param name="launch-url-prefix" select="$launch-url-prefix"/>
- <out:with-param name="launch-rel-url-prefix" select="$launch-rel-url-prefix"/>
- <out:with-param name="class" select="$class"/>
- <out:with-param name="general-url-prefix" select="$general-url-prefix"/>
- <out:with-param name="ui-bookmark" select="$ui-bookmark"/>
- <out:with-param name="output_format" select="$ui-output-format"/>
- <out:with-param name="effectiveUserCapabilities" select="$effectiveUserCapabilities"/>
- <out:with-param name="rv-executionprompt-launch" select="$rv-executionprompt-launch"/>
- <out:with-param name="drillThroughTargetParameterValues" select="$drillThroughTargetParameterValues"/>
- <out:with-param name="redirect-bookmarkURL" select="$redirect-bookmarkURL"/>
- <out:with-param name="canExecute" select="$canExecute"/>
- </out:call-template>
- </out:when>
- <out:otherwise>
- <out:call-template name="buildpp8">
- <out:with-param name="thisnode" select="cm:target/*[1]"/>
- <out:with-param name="encoded-back-url" select="$encoded-back-url"/>
- <out:with-param name="target-path" select="$target-path"/>
- <out:with-param name="target" select="$target"/>
- <out:with-param name="action" select="$action"/>
- <out:with-param name="genURLForBookmark" select="$genURLForBookmark"/>
- <out:with-param name="launch-url-prefix" select="$launch-url-prefix"/>
- <out:with-param name="launch-rel-url-prefix" select="$launch-rel-url-prefix"/>
- <out:with-param name="class" select="$class"/>
- <out:with-param name="general-url-prefix" select="$general-url-prefix"/>
- <out:with-param name="ui-bookmark" select="$ui-bookmark"/>
- <out:with-param name="output_format" select="$ui-output-format"/>
- <out:with-param name="effectiveUserCapabilities" select="$effectiveUserCapabilities"/>
- <out:with-param name="rv-executionprompt-launch" select="$rv-executionprompt-launch"/>
- <out:with-param name="drillThroughTargetParameterValues" select="$drillThroughTargetParameterValues"/>
- <out:with-param name="redirect-bookmarkURL" select="$redirect-bookmarkURL"/>
- <out:with-param name="canExecute" select="$canExecute"/>
- </out:call-template>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <!-- PPW Series 7 -->
- <out:when test="$class='powerPlayCube' or $class='powerPlayReport'">
- <!-- if empty user doesn't have proper permission except if cube which has no action-->
- <out:if test="($class='powerPlayReport' and $action!='') or $class='powerPlayCube'">
- <out:choose>
- <out:when test="cm:objectClass != 'shortcut'">
- <out:call-template name="buildpp">
- <out:with-param name="thisnode" select="."/>
- <out:with-param name="encoded-back-url" select="$encoded-back-url"/>
- <out:with-param name="target-path" select="$target-path"/>
- <out:with-param name="target" select="$target"/>
- <out:with-param name="action" select="$action"/>
- <out:with-param name="genURLForBookmark" select="$genURLForBookmark"/>
- </out:call-template>
- </out:when>
- <out:otherwise>
- <out:call-template name="buildpp">
- <out:with-param name="thisnode" select="cm:target/*[1]"/>
- <out:with-param name="encoded-back-url" select="$encoded-back-url"/>
- <out:with-param name="target-path" select="$target-path"/>
- <out:with-param name="target" select="$target"/>
- <out:with-param name="action" select="$action"/>
- <out:with-param name="genURLForBookmark" select="$genURLForBookmark"/>
- </out:call-template>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <!-- Output currently only a published news item (AGS) will create an output class-->
- <out:when test="$class = 'output' and $canRead">
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode(string($target-path)),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&ui.format=<out:value-of select="cm:format"/>
- <out:value-of select="$rv-lang-cl"/>
- <out:value-of select="$ui-bookmark"/><out:text/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:when>
- <!-- Document -->
- <out:when test="$class = 'document' ">
- <out:if test="$canRead and $canTraverse">
- <out:variable name="documentFormat">
- <out:choose>
- <out:when test="cm:target/*/cm:documentType">
- <out:value-of select="cm:target/*/cm:documentType"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="cm:documentType"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="defaultOutputPath">storeID("<out:value-of select="$target-id"/>")/documentVersion[last()]/documentContent[last()]</out:variable>
- <out:variable name="documentDownloadURL">
- <out:value-of select="$general-url-prefix"/>?b_action=xts.run&m=portal/download.xts<out:text/>
- <out:if test="count($documentFormats/format[@name = $documentFormat]) > 0">
- <out:text/>&format=<out:value-of select="xtsext:urlencode($documentFormat)"/>
- </out:if>
- <out:text/>&m_download_obj=<out:value-of select="xtsext:protect(xtsext:urlencode(string($defaultOutputPath)),'url','searchPath','getdata')"/>
- <out:text/>&m_name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- </out:variable>
- <out:choose>
- <out:when test="$genURLForBookmark">
- <out:value-of select="$documentDownloadURL"/>
- </out:when>
- <out:otherwise>
- <out:text/>javascript:checkDocumentDownload('<out:value-of select="xtsext:javascriptencode(string(cm:defaultName))"/>','<out:value-of select="xtsext:javascriptencode($download_specialCharacters)"/>','<out:value-of select="$documentDownloadURL"/>');<out:text/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <!-- documentContent -->
- <out:when test="$class='documentContent' and $canRead">
- <out:choose>
- <!-- Is this a published news item from AGS -->
- <out:when test="starts-with(string($target-path),'/transientStateFolder/periodical')">
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode(string($target-path)),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&ui.format=<out:value-of select="cm:format"/>
- <out:value-of select="$rv-lang-cl"/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:when>
- <!-- possibly another use of documentContent, re:download ( COC ) currently there is no use case for this and CC is not asking for dataType -->
- <out:otherwise>
- <out:variable name="defaultOutputPath">storeID("<out:value-of select="$target-id"/>")/documentVersion[last()]/documentContent[last()]</out:variable>
- <out:variable name="documentDownloadURL">
- <out:value-of select="$general-url-prefix"/>?b_action=xts.run&m=portal/download.xts<out:text/>
- <out:text/>&format=<out:value-of select="xtsext:urlencode(cm:dataType)"/>
- <out:text/>&m_download_obj=<out:value-of select="xtsext:protect(xtsext:urlencode(string($defaultOutputPath)),'url','searchPath','getdata')"/>
- <out:text/>&m_name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- </out:variable>
- <out:text/>javascript:checkDocumentDownload('<out:value-of select="xtsext:javascriptencode(string(cm:defaultName))"/>','<out:value-of select="xtsext:javascriptencode($download_specialCharacters)"/>','<out:value-of select="$documentDownloadURL"/>');<out:text/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <!-- agentDefinition & agentDefinitionView-->
- <out:when test="$class='agentDefinition' or $class='agentDefinitionView'">
- <out:if test="$action != '' "> <!-- if empty user didn't have proper permissions -->
- <out:choose>
- <out:when test="$action='edit'"> <!-- agentDefView will never be edit -->
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway, 'ui.tool', 'EventStudio', 'ui.backURL', sBackURL, 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.action', 'edit'); <out:text/>
- </out:when>
- <out:otherwise>
- <out:variable name="redirectURL">
- <out:value-of select="$launch-rel-url-prefix"/>
- <out:text/>&ui.tool=EventStudio&ui.action=edit<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- </out:variable>
- <out:value-of select="$redirect-bookmarkURL"/><out:value-of select="xtsext:protect(xtsext:urlencode($redirectURL),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$action='view'">
- <out:variable name="event_list">
- <out:choose>
- <out:when test="cm:target/*">
- <out:text/><out:value-of select="cm:target/*/cm:mostRecentEventList"/><out:text/>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="cm:mostRecentEventList"/><out:text/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view&ui.object=<out:value-of select="xtsext:javascriptencode(xtsext:protect(xtsext:urlencode($event_list), 'url','searchPath','getdata'))"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text>&cv.toolbar=false</out:text>
- <out:value-of select="$rv-lang-cl"/>
- <out:value-of select="$ui-bookmark"/><out:text/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:when>
- <out:when test="$action='run'">
- <out:value-of select="$general-url-prefix"/>?b_action=xts.run&m=portal/<out:value-of select="'runWithOptions/agentDefinition.xts'"/>&<out:text/>
- <out:text/>m_obj=<out:value-of select="xtsext:protect(xtsext:urlencode(string($target-path)),'url','searchPath','getdata')"/><out:text/>
- <out:text/>&m_name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&m_class=<out:value-of select="$class"/><out:text/>
- <out:text/>&m_path=storeID(<out:value-of select="$target-id"/>)<out:text/>
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark)">
- <out:text/>&backURL=<out:value-of select="$encoded-back-url"/>
- </out:if>
- </out:when>
- </out:choose>
- </out:if>
- </out:when>
- <!-- metrics package -->
- <out:when test="$class='package' and ($userInterfaces='metricStudio' or $targetUserInterfaces='metricStudio')">
- <out:choose>
- <out:when test="$action='view'">
- <xsl:call-template name="gen-url-other"/>
- </out:when>
- <out:when test="$action='run'">
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'MetricStudio', 'ui.backURL', '<out:value-of select="xtsext:javascriptencode(string($back-url))"/>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.action', 'run','ui.folder','<out:value-of select="xtsext:javascriptencode( string($location) )"/>');<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$launch-url-prefix"/>
- <out:text/>&ui.tool=MetricStudio&ui.action=run<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- </out:choose>
- </out:when>
- <!-- planning package -->
- <out:when test="$class='package' and ($userInterfaces='planningContributor' or $targetUserInterfaces='planningContributor')">
- <out:choose>
- <out:when test="$action='view'">
- <xsl:call-template name="gen-url-other"/>
- </out:when>
- <out:when test="$action='run'">
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', 'Contributor', 'ui.backURL', '<out:value-of select="xtsext:javascriptencode(string($back-url))"/>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.action', 'new','ui.folder','<out:value-of select="xtsext:javascriptencode( string($location) )"/>','ui.appname','');<out:text/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$launch-url-prefix"/>
- <out:text/>&ui.tool=Contributor&ui.action=new&ui.appname=<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- </out:choose>
- </out:when>
- <!-- adaptive analytics package -->
- <out:when test="$class='package' and ($userInterfaces='adaptiveAnalytics' or $targetUserInterfaces='adaptiveAnalytics')">
- <out:choose>
- <out:when test="$action='view'">
- <xsl:call-template name="gen-url-other"/>
- </out:when>
- <out:when test="$action='run'">
- <out:choose>
- <out:when test="not($genURLForBookmark)">
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway, 'ui.tool', 'AnalyticsTOC', 'ui.backURL', '<out:value-of select="xtsext:javascriptencode(string($back-url))"/>', 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.action', 'run','ui.folder','<out:value-of select="xtsext:javascriptencode( string($location) )"/>');<out:text/>
- </out:when>
- <out:otherwise>
- <out:variable name="redirectURL">
- <out:value-of select="$launch-rel-url-prefix"/>
- <out:text/>&ui.tool=AnalyticsTOC&ui.action=run<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- </out:variable>
- <out:value-of select="$redirect-bookmarkURL"/><out:value-of select="xtsext:protect(xtsext:urlencode($redirectURL),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- </out:choose>
- </out:when>
- <!-- portlet -->
- <out:when test="$class='portlet'">
- <out:if test="$canRead and $canExecute and $canReadParent">
- <out:variable name="portletPreviewURL">
- <out:value-of select="$general-url-prefix"/>?rui=hh&b_action=xts.run&m=<out:value-of select="$app"/>/cc.xts&m_portlet=/connection/portlet:path:<out:value-of select="$url-encoded-id"/>
- </out:variable>
- <out:choose>
- <out:when test="$genURLForBookmark">
- <out:value-of select="$portletPreviewURL"/>
- </out:when>
- <out:otherwise>
- <out:text/>javascript:window.open('<out:value-of select="xtsext:javascriptencode(string($portletPreviewURL))"/>');<xsl:text/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <!-- planningMacroTask -->
- <out:when test="contains(' planningMacroTask ', concat(' ', $class, ' ' ))"/>
- <!-- planningTask -->
- <out:when test="contains(' planningTask ', concat(' ', $class, ' ' ))">
- <!-- details/info on this object not yet available - TBD! -->
- </out:when>
- <!-- job -->
- <out:when test="contains(' jobDefinition ', concat(' ', $class, ' ' ))"></out:when>
- <!-- indexUpdateTask -->
- <out:when test="$class='indexUpdateTask' "/>
- <!-- migrationTask -->
- <out:when test="$class='migrationTask' "/>
- <!-- skin -->
- <out:when test="$class='portalSkin'"/>
- <!-- packageConfiguration -->
- <out:when test="$class='packageConfiguration'"/>
- <!-- user profile (RS) -->
- <out:when test="$class='uiProfile'"/>
- <!-- Misc. Admin objects that we don't hyperlink. -->
- <out:when test="contains($class, 'Deployment') or contains($class, 'Service') or $class = 'drillPath' or $class = 'printer' or $class = 'dataSourceSignon' or $class='contact' or $class='distributionList' or $class='securedFeature' or $class='contentTask' or $class='dataMovementTask' or $class='dataMovementTaskAlias' or $class='reportDataServiceAgentDefinition' or $class = 'tenant'"/>
- <!-- Roles and groups can generate URLs if they have children. If hasChildren is not sent, it is assumed to be true.(Used in Series 7 Namespaces) -->
- <out:when test="($class = 'role' or $class = 'group' or $class='securedFunction') and not($hasChildren)"/>
- <!-- Other Container / Shortcut -->
- <out:otherwise>
- <out:choose>
- <out:when test="$genURLForBookmark">
- <out:if test="$class = 'package' or $class = 'folder' or $class = 'subscriptionFolder' "><xsl:call-template name="gen-url-other"/></out:if>
- </out:when>
- <out:otherwise>
- <xsl:call-template name="gen-url-other"/>
- </out:otherwise>
- </out:choose>
- </out:otherwise>
- </out:choose>
- </out:template>
- <!-- Build the atom path required for dashboard bookmarks -->
- <out:template name="constructDashboardAtomPath">
- <out:param name="atomPath" select="''"/>
- <out:choose>
- <out:when test="$atomPath/*/*[local-name()='storeID']=/root/session/param[@name='mrootid'] ">
- <out:value-of select="xtsext:urlencode('~')"/><out:text>/</out:text>
- </out:when>
- <out:when test="$atomPath/*/*[local-name()='storeID']=/root/session/param[@name='prootid'] ">
- <out:value-of select="xtsext:urlencode($atomPath/*/*[local-name()='storeID' and string(.)=/root/session/param[@name='prootid']]/../*[local-name()='title'])"/><out:text>/</out:text>
- </out:when>
- </out:choose>
- <out:for-each select="$atomPath/*">
- <out:if test="preceding-sibling::*/*[local-name()='storeID']=/root/session/param[@name='mrootid'] or preceding-sibling::*/*[local-name()='storeID']=/root/session/param[@name='prootid']">
- <out:value-of select="concat(xtsext:urlencode(string(./*[local-name()='title'])),'/')"/>
- </out:if>
- </out:for-each>
- </out:template>
- <!-- Build PPW url -->
- <out:template name="buildpp">
- <out:param name="thisnode"/>
- <out:param name="encode-back-url"/>
- <out:param name="target-path"/>
- <out:param name="target"/>
- <out:param name="action"/>
- <out:param name="genURLForBookmark" select="false()"/>
- <!-- note:for WO767 two default actions were added run and edit but the functionality has not changed as yet so no changes required-->
- <!-- Build the link to support powerPlay object link, WO 770. -->
- <out:variable name="ppURL">
- <out:value-of select="$thisnode/cm:gateway"/>
- <out:text/>?crnobj=<out:value-of select="xtsext:urlencode( string( $target-path ) )"/>
- <out:text/>&crnccn=<out:value-of select="xtsext:urlencode(string($thisnode/cm:cubeContentName))"/>
- <out:variable name="ppprompt">
- <out:choose>
- <out:when test="$thisnode/cm:options/cm:powerPlayOptionBoolean[cm:name='prompt']/cm:value">
- <out:value-of select="$thisnode/cm:options/cm:powerPlayOptionBoolean[cm:name='prompt']/cm:value"/>
- </out:when>
- <out:when test="$thisnode/cm:hasPrompts">
- <out:value-of select="$thisnode/cm:hasPrompts"/>
- </out:when>
- <out:otherwise>false</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="ppdesignmode" select="$thisnode/cm:options/cm:powerPlayOptionData[cm:name='data']/cm:value"/>
- <out:if test="$thisnode/cm:objectClass='powerPlayReport'">
- <out:choose>
- <out:when test="$action='run'"> <!-- Note: powerplay only has two actions run and edit -->
- <out:text/>&crnfrm=PDF<out:text/>
- <out:if test="string($thisnode/cm:hasPrompts)='true'"><out:text/>&crnp=<out:value-of select="$ppprompt"/><out:text/></out:if>
- </out:when>
- <out:otherwise>
- <out:text/>&crnfrm=HTML<out:text/>
- <out:choose>
- <out:when test="string($ppdesignmode)='previewWithNoData'"> <!-- open in design mode is checked -->
- <out:text/>&crngnd=true<out:text/>
- </out:when>
- <out:otherwise><out:text/>&crngnd=false<out:text/></out:otherwise>
- </out:choose>
- </out:otherwise>
- </out:choose>
- </out:if>
- <out:text/>&LA=<out:value-of select="$productLocale"/><out:text/>
- <out:text/>&LO=<out:value-of select="$contentLocale"/><out:text/>
- <out:choose>
- <out:when test="(string($target)='_blank') or ($genURLForBookmark)"><out:text/>&BACK=&NOBACK=1<out:text/></out:when>
- <out:otherwise><out:text/>&BACK=<out:value-of select="$encodedPPBack"/><out:text/></out:otherwise>
- </out:choose>
- </out:variable>
- <out:value-of select="xtsext:protect(string($ppURL),'none','s7url','s7url')"/>
- </out:template>
- <!-- build PP8 url -->
- <out:template name="buildpp8">
- <out:param name="thisnode"/>
- <out:param name="encode-back-url"/>
- <out:param name="target-path"/>
- <out:param name="target"/>
- <out:param name="action"/>
- <out:param name="genURLForBookmark" select="false()"/>
- <out:param name="launch-url-prefix"/>
- <out:param name="launch-rel-url-prefix"/>
- <out:param name="class"/>
- <out:param name="general-url-prefix"/>
- <out:param name="ui-bookmark"/>
- <out:param name="output_format"/>
- <out:param name="effectiveUserCapabilities" select="''"/>
- <out:param name="rv-executionprompt-launch" select="''"/>
- <out:param name="drillThroughTargetParameterValues" select="''"/>
- <out:param name="redirect-bookmarkURL" select="''"/>
- <out:param name="canExecute" select="false()"/>
- <out:variable name="designmode" select="$thisnode/cm:options/cm:powerPlay8OptionData[cm:name='data']/cm:value"/>
- <out:variable name="openInDesignMode">
- <out:choose>
- <out:when test="string($designmode)='previewWithNoData'">true</out:when>
- <out:otherwise>false</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="prompt">
- <out:choose>
- <out:when test="$thisnode/cm:options/cm:powerPlay8OptionBoolean[cm:name='prompt']">
- <out:value-of select="$thisnode/cm:options/cm:powerPlay8OptionBoolean[cm:name='prompt']/cm:value"/>
- </out:when>
- <out:otherwise>false</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="openStudio">
- <out:choose>
- <out:when test="$action='edit' and $effectiveUserCapabilities!='' and contains($effectiveUserCapabilities, ' userCanUseRS ') and contains($effectiveUserCapabilities, ' userCanOpenPPInReportStudio ') and not(contains($effectiveUserCapabilities,' userCanUsePPS '))">ReportStudioPPReport</out:when>
- <out:otherwise>PowerplayStudio</out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="runPermission">
- <out:choose>
- <out:when test="$canExecute">execute</out:when>
- <out:otherwise>noexec</out:otherwise>
- </out:choose>
- </out:variable>
- <out:choose>
- <out:when test="$action='view' ">
- <out:value-of select="$general-url-prefix"/>?b_action=cognosViewer<out:text/>
- <out:text/>&ui.action=view<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( concat('defaultOutput(', $target-path, ')' ) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.name=<out:value-of select="xtsext:protect(xtsext:urlencode(string(cm:defaultName)),'url','userData','getdata')"/>
- <out:text/>&ui.format=<out:value-of select="$output_format"/><out:text/>
- <out:text/>&lang=<out:value-of select="$contentLocale"/>
- <out:text/><out:value-of select="$ui-bookmark"/>
- <out:if test="not($genURLForBookmark)">
- <out:text/>&ui.backURL=<out:value-of select="$encodedPP8Back"/>
- </out:if>
- </out:when>
- <!-- For edit and run -->
- <out:when test="not($genURLForBookmark)">
- <out:choose>
- <out:when test="$openStudio = 'PowerplayStudio'">
- <out:text/>javascript:cognosLaunch('ui.gateway', sGateway, 'ui.tool', '<out:value-of select="$openStudio"/>','ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.backURL', '<out:value-of select="$javascript-encodedPP8Back"/>', 'ui.la', '<out:value-of select="xtsext:javascriptencode($productLocale)"/>', 'ui.lo', '<out:value-of select="xtsext:javascriptencode($contentLocale)"/>'<out:text/>
- <out:choose>
- <out:when test="$action = 'edit' and $class != 'powerPlay8ReportView'">
- <out:text/>, 'ui.crnp', '<out:value-of select="$prompt"/>', 'ui.crnfrm', 'HTML', 'ui.action', 'edit', 'ui.crngnd', '<out:value-of select="$openInDesignMode"/>')<out:text/>
- </out:when>
- <out:when test="$action = 'run'">
- <out:text/>, 'ui.crnp', '<out:value-of select="$prompt"/>', 'ui.crnfrm', 'PDF', 'ui.action', 'run'<out:text/>
- <out:text/>,'ui.access','<out:value-of select="xtsext:cafaction( concat('sign_wrap_setpassportid_', $passport), xtsext:web64encode(string($runPermission), true()))"/>')<out:text/>
- </out:when>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:variable name="rsType">
- <out:if test="$rsUIProfile != ''">
- <out:text>, 'ui.profile', '</out:text><out:value-of select="$rsUIProfile"/><out:text>'</out:text>
- </out:if>
- </out:variable>
- <out:text/>javascript:cognosLaunchInWindow('_blank', 'menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=650,height=480', 'ui.gateway', sGateway, 'ui.tool', '<out:value-of select="$openStudio"/>', 'ui.backURL', sBackURL, 'ui.object', '<out:value-of select="xtsext:javascriptencode( string( $target-path ) )"/>', 'ui.drillThroughTargetParameterValues', '<out:value-of select="xtsext:javascriptencode( string($drillThroughTargetParameterValues))"/>', 'ui.action', 'edit'<out:value-of select="$rv-executionprompt-launch"/><out:value-of select="$rsType"/>,'ui.access','<out:value-of select="xtsext:cafaction( concat('sign_wrap_setpassportid_', $passport), xtsext:web64encode(string($runPermission), true()))"/>');<out:text/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:choose>
- <out:when test="$openStudio = 'PowerplayStudio'">
- <out:value-of select="$launch-url-prefix"/>
- <out:text/>&ui.tool=PowerplayStudio&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.la=<out:value-of select="$productLocale"/>&ui.lo=<out:value-of select="$contentLocale"/><out:text/>
- <out:choose>
- <out:when test="$action = 'edit' and $class != 'powerPlay8ReportView'">
- <out:text/>&ui.crnp=false&ui.crnfrm=HTML&ui.action=edit&ui.crngnd=<out:value-of select="$openInDesignMode"/><out:text/>
- </out:when>
- <out:when test="$action = 'run'">
- <out:text/>&ui.crnp=<out:value-of select="$prompt"/>&ui.crnfrm=PDF&ui.action=run<out:text/>
- </out:when>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:variable name="redirectURL">
- <out:value-of select="$launch-rel-url-prefix"/>
- <out:text/>&ui.tool=<out:value-of select="$openStudio"/>&ui.action=edit&launch.openJSStudioInFrame=true<out:text/>
- <out:text/>&ui.object=<out:value-of select="xtsext:protect(xtsext:urlencode( string($target-path) ),'url','searchPath','getdata')"/>
- <out:text/>&ui.drillThroughTargetParameterValues=<out:value-of select="xtsext:protect(xtsext:urlencode( string($drillThroughTargetParameterValues)),'url','searchPath','getdata')"/>
- <out:if test="$rsUIProfile != ''">&ui.profile=<out:value-of select="$rsUIProfile"/></out:if>
- </out:variable>
- <out:value-of select="$redirect-bookmarkURL"/><out:value-of select="xtsext:protect(xtsext:urlencode($redirectURL),'url','searchPath','getdata')"/>
- </out:otherwise>
- </out:choose>
- </out:otherwise>
- </out:choose>
- </out:template>
- </xsl:template>
- <!-- Code expanded in gen-url template to handle Container and Shorcut objects -->
- <xsl:template name="gen-url-other">
- <out:value-of select="$general-url-prefix"/>?b_action=xts.run&m=<out:value-of select="$app"/>/<out:text/>
- <!-- morphlet -->
- <out:choose>
- <out:when test="$morphlet = ''">
- <out:value-of select="$mname"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$morphlet"/>
- </out:otherwise>
- </out:choose>
- <out:choose>
- <!-- Consumer portal navigation -->
- <out:when test=" $mname = 'cc.xts'">
- <!-- Set the navigation target ids -->
- <out:choose>
- <out:when test="cm:nbid">&m_nbid=<out:value-of select="cm:nbid"/></out:when>
- <out:otherwise>&m_folder=<out:value-of select="$target-id"/></out:otherwise>
- </out:choose>
- <!-- Remember the current navigation context if we are switching navigation context (i.e. PF to MF or MF to PF) -->
- <!-- What is the current nav context? -->
- <out:variable name="isPFContext" select="(starts-with(cm:nbid, 'p-') and not(cm:upfShortCut = 'true')) or starts-with( string(key('env-param', 'm_nbid')), 'p-') or starts-with(cm:searchPath, '/content')"/>
- <out:variable name="isMFContext" select="not($isPFContext)"/>
- <!-- What is the target nav context? (Don't trust UPF shortcuts!!)-->
- <out:variable name="isPFNavTarget" select="starts-with(cm:nbid, 'p-') or starts-with($target-path, '/content')"/>
- <out:variable name="isMFNavTarget" select="not($isPFNavTarget)"/>
- <!-- Save the current nav state -->
- <out:choose>
- <!-- PF to MF navigation -->
- <out:when test="$isPFContext and $isMFNavTarget">
- <out:if test="string(key('env-param', 'm_folder')) != '' ">
- <out:text/>&m_folder2=<out:value-of select="concat('p-',string(key('env-param', 'm_folder')))"/>
- </out:if>
- <out:if test="string(key('env-param', 'm_nbid')) != '' ">
- <out:text/>&m_nbid2=<out:value-of select="string(key('env-param', 'm_nbid'))"/>
- </out:if>
- </out:when>
- <!-- MF to PF navigation -->
- <out:when test="$isMFContext and $isPFNavTarget">
- <out:if test="string(key('env-param', 'm_folder')) != '' ">
- <out:text/>&m_folder2=<out:value-of select="concat('m-',string(key('env-param', 'm_folder')))"/>
- </out:if>
- <out:if test="string(key('env-param', 'm_nbid')) != '' ">
- <out:text/>&m_nbid2=<out:value-of select="string(key('env-param', 'm_nbid'))"/>
- </out:if>
- </out:when>
- <!-- Navigation witin PF/MF -->
- <out:otherwise>
- <out:if test="key('env-param', 'm_folder2')!=''">&m_folder2=<out:value-of select="string(key('env-param', 'm_folder2'))"/></out:if>
- <out:if test="key('env-param', 'm_nbid2')!=''">&m_nbid2=<out:value-of select="key('env-param', 'm_nbid2')"/></out:if>
- </out:otherwise>
- </out:choose>
- <out:value-of select="$request-url-params"/>
- </out:when>
- <out:when test="$mname = 'subscriptions/subscriptions.xts' or $morphlet = 'subscriptions/subscriptions.xts'">
- <xsl:text/>&m_subfldr=<out:value-of select="$target-id"/>&m_isRule<xsl:text/>
- </out:when>
- <!-- all other navigation types -->
- <out:otherwise>
- <out:choose>
- <out:when test="$navigateUsingID='true'">
- <out:text/>&m_path=storeID(%22<out:value-of select="$target-id"/>%22)<out:text/>
- </out:when>
- <out:otherwise>
- <out:text/>&m_path=<out:value-of select="xtsext:protect(xtsext:urlencode(string($target-path)),'url','searchPath','getdata')"/><out:text/>
- </out:otherwise>
- </out:choose>
- </out:otherwise>
- </out:choose>
- <!-- These are required by tools -->
- <out:if test="key('env-param', 'tool_tab')">&tool_tab=<out:value-of select="key('env-param', 'tool_tab')"/></out:if>
- <!-- if we get in here then we are navigating something....that means if we are in a search context we do not want to keep the back url because once we being
- navigating in a search conext we need to go back to cc -->
- <out:if test="not($isIgnoreBackURL or $genURLForBookmark or $isSearch)">
- <out:if test="key('env-param', 'backURL')">&backURL=<out:value-of select="xtsext:protect(xtsext:urlencode( string( key('env-param', 'backURL') ) ),'url','url','getdata')"/></out:if>
- </out:if>
- <out:if test="key('env-param','skin')!=''">
- <out:text>&skin=</out:text><out:value-of select="key('env-param','skin')"/>
- </out:if>
- </xsl:template>
- <!--
- Template - pf:gen-icon:
- This template generates another template gen-icon that builds icon names including the path to the icon.
- Operation:
- Outputs the gen-icon template.
- -->
- <xsl:template match="pf:gen-icon">
- <out:template name="gen-icon">
- <out:param name="showAction" select="true()"/>
- <out:param name="class" select="''"/> <!-- this is the effective class. i.e. it is the class of the target object in case of a shortcut. Only usefull for morphlets that care about shortcuts. -->
- <out:param name="userInterfaces" select="''"/>
- <out:param name="targetUserInterfaces" select="''"/>
- <out:param name="canRead" select="true()"/>
- <out:param name="canWrite" select="true()"/>
- <out:param name="canExecute" select="true()"/>
- <out:param name="canTraverse" select="true()"/>
- <out:param name="output_format" select="''"/> <!-- Set this to blank by default -->
- <out:param name="isDangling" select="false()"/>
- <out:param name="tooltipOverride" select="''"/> <!-- instead of displaying the deaultName, display this -->
- <out:param name="iconURIOverride" select="''"/> <!-- instead of displaying the defaultIcon, display this -->
- <out:param name="action" select="''"/>
- <out:param name="executionFormat" select="''"/>
- <out:param name="baseClass" select="''"/>
- <out:param name="hiddenObject" select="'false'"/>
- <out:param name="effectiveUserCapabilities" select="''"/>
- <out:variable name="objectClass">
- <out:choose>
- <out:when test="$class != ''"><out:value-of select="$class"/></out:when>
- <out:otherwise><out:value-of select="cm:objectClass"/></out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="tooltip">
- <out:choose>
- <out:when test="$tooltipOverride!=''">
- <out:value-of select="xtsext:enforceBTD($tooltipOverride, $baseTextDirection, $productLocale, boolean($isBidiEnabled='true'))"/>
- </out:when>
- <out:when test="/root/objectClass/class[@name=$objectClass] != ''">
- <out:value-of select="xtsext:enforceBTD(/root/objectClass/class[@name=$objectClass], $baseTextDirection, $productLocale, boolean($isBidiEnabled='true'))"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="xtsext:enforceBTD(cm:defaultName, $baseTextDirection, $productLocale, boolean($isBidiEnabled='true'))"/>
- </out:otherwise>
- </out:choose>
- <out:if test="cm:defaultScreenTip != ''">
- <out:choose>
- <out:when test="$is-ui-rtl">
- <out:text/>‏ - <out:value-of select="xtsext:enforceBTD(cm:defaultScreenTip, $baseTextDirection, $productLocale, boolean($isBidiEnabled='true'))"/>
- </out:when>
- <out:otherwise>
- <out:text/>‎ - <out:value-of select="xtsext:enforceBTD(cm:defaultScreenTip, $baseTextDirection, $productLocale, boolean($isBidiEnabled='true'))"/>
- </out:otherwise>
- </out:choose>
- </out:if>
- <out:if test="cm:hidden = 'true'">
- <out:variable name="hiddenLabel"><xts:string id="IDS_HIDDEN_OBJECT"/></out:variable>
- <out:choose>
- <out:when test="$is-ui-rtl">
- <out:text/>‏ - <out:value-of select="xtsext:enforceBTD($hiddenLabel, $baseTextDirection, $productLocale, boolean($isBidiEnabled='true'))"/>
- </out:when>
- <out:otherwise>
- <out:text/>‎ - <out:value-of select="xtsext:enforceBTD($hiddenLabel, $baseTextDirection, $productLocale, boolean($isBidiEnabled='true'))"/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:variable>
- <out:variable name="sessionRSUIProfile" select="key('session-param','rsuiprofile')"/>
- <out:variable name="cmIconURI">
- <out:choose>
- <out:when test="$iconURIOverride!=''">
- <out:value-of select="$iconURIOverride"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="string(cm:iconURI)"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <img height="16" width="16">
- <out:if test="$hiddenObject='true'">
- <out:attribute name="class">hiddenEntryIcon</out:attribute>
- <!-- <out:attribute name="style">filter:alpha(opacity=40);opacity:0.4;-moz-opacity:0.4;</out:attribute> -->
- </out:if>
- <out:attribute name="alt">
- <out:value-of select="$tooltip"/>
- </out:attribute>
- <out:attribute name="title">
- <out:value-of select="$tooltip"/>
- </out:attribute>
- <out:choose>
- <out:when test="$cmIconURI != ''">
- <out:variable name="customIcon">
- <out:choose>
- <!-- Ignore external URLs -->
- <out:when test="contains($cmIconURI,':/') or contains($cmIconURI,'\\') or contains($cmIconURI,'//')">
- <!-- blank -->
- </out:when>
- <!-- Relative / Absolute URLs - Checking for \ is probably useless in this case -->
- <out:when test="contains($cmIconURI, '/') or contains($cmIconURI, '\')">
- <out:choose>
- <!-- Doesn't start with / -->
- <out:when test="not(starts-with($cmIconURI, '/'))">
- <out:value-of select="$webRoot"/>/<out:value-of select="$cmIconURI"/>
- </out:when>
- <!-- Starts with / -->
- <out:otherwise>
- <out:value-of select="$webRoot"/><out:value-of select="$cmIconURI"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <!-- image file -->
- <out:otherwise>
- <out:value-of select="$image_root"/><out:value-of select="$cmIconURI"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:attribute name="src"><out:value-of select="$customIcon"/></out:attribute>
- </out:when>
- <out:otherwise>
- <out:variable name="effectiveBaseClass">
- <out:choose>
- <out:when test="$baseClass != ''"><out:value-of select="$baseClass"/></out:when>
- <out:when test="*[local-name()='base'] and not(*[local-name()='base']/@nil )">
- <out:value-of select="*[local-name()='base']/*/*[local-name()='objectClass']"/>
- </out:when>
- <out:when test="cm:objectClass ='shortcut' and ($class='reportView' or $class='powerPlay8ReportView')">
- <out:value-of select="*[local-name()='target']/*/*[local-name()='base']/*/*[local-name()='objectClass']"/>
- </out:when>
- <out:otherwise>reportView</out:otherwise> <!--use generic icon -->
- </out:choose>
- </out:variable>
- <out:variable name="documentFormat">
- <out:choose>
- <out:when test="cm:objectClass = 'shortcut' and cm:target/*/cm:objectClass = 'document'">
- <out:value-of select="cm:target/*/cm:documentType"/>
- </out:when>
- <out:when test="cm:objectClass = 'document'">
- <out:value-of select="./cm:documentType"/>
- </out:when>
- </out:choose>
- </out:variable>
- <out:variable name="system_icon">
- <out:choose>
- <out:when test="cm:objectClass = 'shortcut'">
- <out:choose>
- <out:when test="$class = 'reportView'">
- <out:value-of select="key('ui-object',$effectiveBaseClass)/@icon"/><out:text/><out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='reportview_suffix']"/>
- </out:when>
- <out:when test="$class = 'powerPlay8ReportView'">
- <out:value-of select="key('ui-object',$effectiveBaseClass)/@icon"/><out:text/><out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='powerPlay8ReportView_suffix']"/>
- </out:when>
- <out:when test="$class = 'document' or cm:target/*/cm:objectClass = 'document'">
- <out:variable name="documentType" select="$documentFormat"/>
- <xsl:call-template name="pf:getDocumentIconName"/>
- </out:when>
- <out:when test="$class = 'output'"><!-- currently only output exists from AGS when new item is published -->
- <out:if test="starts-with(string(cm:target/*/cm:searchPath),'/transientStateFolder')">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='agentHotlist_format']/format[@name='agentOutputHotlist']/@icon"/>
- </out:if>
- </out:when>
- <out:when test="$class = 'documentContent'">
- <out:if test="starts-with(string(cm:target/*/cm:searchPath),'/transientStateFolder')">
- <out:variable name="docFormat" select="cm:target/*/cm:format"/>
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='output_format']/format[@name=$docFormat]/@icon"/>
- </out:if>
- </out:when>
- <out:otherwise>
- <out:variable name="targetClass" select="cm:target/*/cm:objectClass"/>
- <out:choose>
- <out:when test="$targetClass='package' and key('ui-object',$targetClass)/userInterface[@name=$targetUserInterfaces]">
- <out:variable name="uifs">
- <out:choose>
- <out:when test="$class != ''"><out:value-of select="$class"/></out:when>
- <out:otherwise><out:value-of select="$targetClass"/></out:otherwise>
- </out:choose>
- </out:variable>
- <out:choose>
- <out:when test="$targetUserInterfaces != ''">
- <out:value-of select="key('ui-object',$uifs)/userInterface[@name=$targetUserInterfaces]/@icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key( 'ui-object', $uifs )/@icon"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$targetClass = 'launchable'">
- <out:variable name="launchableType" select="cm:target/*/cm:launchableType"/>
- <out:value-of select="key( 'ui-object', $targetClass )/launchableType[@name = string($launchableType)]/@icon"/>
- </out:when>
- <out:when test="$targetClass = 'report' or $targetClass = 'interactiveReport' ">
- <out:choose>
- <out:when test="string($sessionRSUIProfile)='pro' or string($sessionRSUIProfile)='all'">
- <out:value-of select="key( 'ui-object', $targetClass )/uiprofile[@name='professional']/@icon"/>
- </out:when>
- <out:when test="$targetClass = 'report' and string($sessionRSUIProfile)='bua'">
- <out:value-of select="key( 'ui-object', $targetClass )/uiprofile[@name='bua']/@icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key( 'ui-object', $targetClass )/@icon"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:value-of select="key( 'ui-object', $targetClass )/@icon"/>
- </out:otherwise>
- </out:choose>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="($class='package' and key('ui-object',$class)/userInterface[@name=$userInterfaces]) or ($class='' and cm:objectClass = 'package' and key('ui-object',cm:objectClass)/userInterface[@name=$userInterfaces])">
- <out:variable name="uifs">
- <out:choose>
- <out:when test="$class != ''"><out:value-of select="$class"/></out:when>
- <out:otherwise><out:value-of select="cm:objectClass"/></out:otherwise>
- </out:choose>
- </out:variable>
- <out:choose>
- <out:when test="$userInterfaces != ''">
- <out:value-of select="key('ui-object',$uifs)/userInterface[@name=$userInterfaces]/@icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key( 'ui-object', $uifs )/@icon"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$class='reportView' or cm:objectClass='reportView'">
- <out:variable name="reportViewSuffix" select="/root/system/param[@name='ui_graphics']/param[@name='reportview_suffix']"/>
- <out:choose>
- <out:when test="$effectiveBaseClass = 'reportView'">
- <out:value-of select="key('ui-object',$effectiveBaseClass)/@icon"/>
- </out:when>
- <out:otherwise>
- <out:choose>
- <out:when test="$effectiveBaseClass = 'report' or $effectiveBaseClass = 'interactiveReport'">
- <out:choose>
- <out:when test="string($sessionRSUIProfile)='pro' or string($sessionRSUIProfile)='all'">
- <out:value-of select="key( 'ui-object', $effectiveBaseClass )/uiprofile[@name='professional']/@icon"/><out:text/><out:value-of select="$reportViewSuffix"/>
- </out:when>
- <out:when test="$effectiveBaseClass = 'report' and string($sessionRSUIProfile)='bua'">
- <out:value-of select="key( 'ui-object', $effectiveBaseClass )/uiprofile[@name='bua']/@icon"/><out:text/><out:value-of select="$reportViewSuffix"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key('ui-object',$effectiveBaseClass)/@icon"/><out:text/><out:value-of select="$reportViewSuffix"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:value-of select="key('ui-object',$effectiveBaseClass)/@icon"/><out:text/><out:value-of select="$reportViewSuffix"/>
- </out:otherwise>
- </out:choose>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$class='powerPlay8ReportView' or cm:objectClass='powerPlay8ReportView'">
- <out:choose>
- <out:when test="$effectiveBaseClass = 'powerPlay8ReportView'">
- <out:value-of select="key('ui-object',$effectiveBaseClass)/@icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key('ui-object',$effectiveBaseClass)/@icon"/><out:text/><out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='powerPlay8ReportView_suffix']"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$class='document' or cm:objectClass='document'">
- <out:variable name="documentType" select="$documentFormat"/>
- <xsl:call-template name="pf:getDocumentIconName"/>
- </out:when>
- <out:when test="cm:objectClass='launchable'">
- <out:variable name="launchableType" select="cm:launchableType"/>
- <out:value-of select="key( 'ui-object', cm:objectClass )/launchableType[@name = string($launchableType)]/@icon"/>
- </out:when>
- <out:when test="$class = 'report' or $class = 'interactiveReport' or ($class='' and (cm:objectClass = 'report' or cm:objectClass='interactiveReport'))">
- <out:variable name="currentClass">
- <out:choose>
- <out:when test="$class = ''"><out:value-of select="cm:objectClass"/></out:when>
- <out:otherwise><out:value-of select="$class"/></out:otherwise>
- </out:choose>
- </out:variable>
- <out:choose>
- <out:when test="string($sessionRSUIProfile)='pro' or string($sessionRSUIProfile)='all'">
- <out:value-of select="key( 'ui-object', $currentClass )/uiprofile[@name='professional']/@icon"/>
- </out:when>
- <out:when test="$currentClass = 'report' and string($sessionRSUIProfile)='bua'">
- <out:value-of select="key( 'ui-object', $currentClass )/uiprofile[@name='bua']/@icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key( 'ui-object', $currentClass )/@icon"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$class != ''">
- <out:value-of select="key( 'ui-object', $class )/@icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key( 'ui-object', cm:objectClass )/@icon"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:variable name="iconsrc">
- <out:choose>
- <out:when test="cm:objectClass='contentManagerService'">
- <out:value-of select="concat($webcontent, '/cogadmin/images/')"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$image_root"/>
- </out:otherwise>
- </out:choose>
- <out:choose>
- <out:when test="cm:nid and cm:icon != ''">series7/</out:when>
- <out:otherwise>icon_</out:otherwise>
- </out:choose>
- <out:choose>
- <!-- If this object has an explicit icon then use it. -->
- <out:when test="cm:icon != ''">
- <out:choose>
- <out:when test="contains(cm:icon, '.gif')">
- <out:value-of select="substring-before(cm:icon, '.gif')"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="cm:icon"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:when test="$isDangling">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='dang_ref']"/>
- <out:if test="$class = 'reportView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='reportview_suffix']"/>
- </out:if>
- <out:if test="$class = 'agentDefinitionView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='agentview_suffix']"/>
- </out:if>
- <out:if test="$class = 'dataMovementTaskAlias'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='datamovementtaskalias_suffix']"/>
- </out:if>
- </out:when>
- <!-- agentDef for edit and run & agentDefView for run are regular sys icon -->
- <out:when test="($class='agentDefinition' or ($class='agentDefinitionView' and not(*[local-name()='base']/@nil ))) and $action='view' ">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='agentHotlist_format']/format[@name='agentOutputHotlist']/@icon"/>
- <out:if test="$class = 'agentDefinitionView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='agentview_suffix']"/>
- </out:if>
- </out:when>
- <!-- PPW output format -->
- <out:when test="(starts-with(string($class),'powerPlayReport') or starts-with(string($class),'powerPlay8Report')) and $action ='run'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='output_format']/format[@name='PDF']/@icon"/>
- <out:if test="$class = 'powerPlay8ReportView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='powerPlay8ReportView_suffix']"/>
- </out:if>
- </out:when>
- <!-- Added for RTC Task 4127 - Avoid running a report when a view is possible but not in user's default format. -->
- <!-- Generate a non-format icon when the output format passed in contains the list of consumable output formats -->
- <!-- The '++ ' indicates that the output_format is a list of consumable output formats -->
- <out:when test="$output_format !='' and not(contains($supportedFormats,concat(' ',$output_format,' '))) and (contains(' report interactiveReport query analysis ', concat(' ', $class, ' ' )) or (($class='reportView') and not(*[local-name()='base']/@nil ))) and $action='view' ">
- <out:value-of select="$consumableOutputFormatIcon"/>
- <out:if test="$class = 'reportView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='reportview_suffix']"/>
- </out:if>
- </out:when>
- <!-- output-specific icon here if there is an output (if action is view) -->
- <out:when test="(contains(' report interactiveReport query analysis powerPlay8Report ', concat(' ', $class, ' ' )) or (($class='reportView' or $class = 'powerPlay8ReportView') and not(*[local-name()='base']/@nil ))) and $action='view' ">
- <out:variable name="useOutputFormat">
- <out:choose>
- <out:when test="$class='interactiveReport' or $effectiveBaseClass='interactiveReport'">HTML</out:when>
- <out:otherwise><out:value-of select="$output_format"/></out:otherwise>
- </out:choose>
- </out:variable>
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='output_format']/format[@name=$useOutputFormat]/@icon"/>
- <out:if test="$class = 'reportView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='reportview_suffix']"/>
- </out:if>
- <out:if test="$class = 'powerPlay8ReportView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='powerPlay8ReportView_suffix']"/>
- </out:if>
- </out:when>
- <!-- if no output exists, show the format that will be produced -->
- <out:when test="(contains(' report interactiveReport query analysis ', concat(' ', $class, ' ' )) or ($class='reportView' and not(*[local-name()='base']/@nil ))) and $action='run' ">
- <out:variable name="outputFormat">
- <!-- if format empty use default of HTML -->
- <out:choose>
- <out:when test="$class = 'interactiveReport' or $effectiveBaseClass = 'interactiveReport' ">HTML</out:when>
- <out:when test="($executionFormat = 'PDF' and not($userCanGeneratePDFOutput))
- or ($executionFormat = 'CSV' and not($userCanGenerateCSVOutput))
- or ($executionFormat = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and ($executionFormat = 'XLS' or
- $executionFormat = 'XLWA' or
- $executionFormat = 'singleXLS' or
- $executionFormat = 'spreadsheetML' or
- $executionFormat = 'xlsxData' or
- $executionFormat = 'spreadsheetMLOfficeConnectionEnabled'))
- or ($executionFormat = '')">
- <out:choose>
- <out:when test="((/root/user/param[@name='format'] = 'PDF' and not($userCanGeneratePDFOutput))
- or (/root/user/param[@name='format'] = 'CSV' and not($userCanGenerateCSVOutput))
- or (/root/user/param[@name='format'] = 'XML' and not($userCanGenerateXMLOutput))
- or (not($userCanGenerateXLSOutput) and (/root/user/param[@name='format'] = 'XLS' or
- /root/user/param[@name='format'] = 'XLWA' or
- /root/user/param[@name='format'] = 'singleXLS' or
- /root/user/param[@name='format'] = 'spreadsheetML' or
- /root/user/param[@name='format'] = 'xlsxData' or
- /root/user/param[@name='format'] = 'spreadsheetMLOfficeConnectionEnabled')))
- or (/root/user/param[@name='format'] = '')">
- <out:text>HTML</out:text>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="/root/user/param[@name='format']"/>
- </out:otherwise>
- </out:choose>
- </out:when>
- <out:otherwise>
- <out:text/><out:value-of select="$executionFormat"/>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='output_format']/format[@name=$outputFormat]/@icon"/>
- <out:if test="$class = 'reportView'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='reportview_suffix']"/>
- </out:if>
- </out:when>
- <!-- when action is edit will fall here -->
- <out:when test="$system_icon != ''">
- <out:value-of select="$system_icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='default_icon']"/>
- </out:otherwise>
- </out:choose>
- <!-- Add _ref if it is a shortcut.. -->
- <out:if test="cm:objectClass = 'shortcut' or cm:upfShortCut = 'true'">
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='shortcut_suffix']"/>
- </out:if>
- <!-- For CM Service, append state to derive applicable icon -->
- <out:if test="cm:objectClass='contentManagerService'">
- <out:value-of select="concat('_default-',cm:startAsActive,'_runningState-',cm:runningState)"/>
- </out:if>
- <!-- Add the extension.. -->
- <xsl:text/>.gif<xsl:text/>
- </out:variable>
- <out:attribute name="src"><out:value-of select="$iconsrc"/></out:attribute>
- </out:otherwise>
- </out:choose>
- </img>
- <!-- Show the action icon if:
- - We are asked to.
- - We are rendering the icon for a report, query, reportVersion or a shortcut to any of these.
- - The object is **not** a dangling reference.
- - The action is run.
- -->
- <out:if test="$showAction and not($isDangling) and $action = 'run' and ((contains(' analysis report query interactiveReport reportView package agentDefinition agentDefinitionView ', concat(' ', $class, ' ' )) and not(cm:icon)) or (starts-with(string($class),'powerPlayReport') or starts-with(string($class),'powerPlay8Report')))">
- <img height="16" width="12">
- <out:if test="$hiddenObject='true'">
- <out:attribute name="style">filter:alpha(opacity=40);opacity:0.4;-moz-opacity:0.4;</out:attribute>
- </out:if>
- <out:attribute name="src">
- <out:choose>
- <out:when test="$class!='package'"><out:value-of select="$image_root"/>action_run.gif</out:when>
- <out:when test="$class='package' and $userInterfaces='metricStudio' and ($canRead and $canExecute and $canTraverse) and contains($effectiveUserCapabilities, ' userCanUseMetricsManager ')"><out:value-of select="$image_root"/>action_cmm_10.gif</out:when>
- <out:when test="$class='package' and $userInterfaces='planningContributor' and ($canRead and $canExecute) and contains($effectiveUserCapabilities, ' userCanUseMetricsManager ')"><out:value-of select="$image_root"/>action_contributor.gif</out:when>
- <out:when test="$class='package' and $userInterfaces='adaptiveAnalytics' and ($canRead and $canExecute and $canTraverse) and contains($effectiveUserCapabilities, ' userCanUseAdaptiveAnalytics')"><out:value-of select="$image_root"/>action_analytic.gif</out:when>
- <!-- the user does not have the appropriate permissions to run or edit this entry -->
- <out:otherwise><out:value-of select="$webcontent"/>/images/space.gif</out:otherwise>
- </out:choose>
- </out:attribute>
- </img>
- </out:if>
- </out:template>
- </xsl:template>
- <!--
- Template - pf:gen-class-name: IS BEING DEPRECATED. USE THE UIOBJECTS_NAMES.XSLT LOGICSHEET INSTEAD
- -->
- <xsl:template match="pf:gen-class-name">
- <out:template name="gen-class-name">
- <out:param name="cm-class" select="''"/>
- *** The pf:gen-class-name template has been deprecated. ***
- </out:template>
- </xsl:template>
- <xsl:template match="pf:ccinav-gen-icon">
- <out:template name="ccinav-gen-icon">
- <out:param name="imgURL" select="''"/>
- <out:param name="screenTip" select="''"/>
- <out:param name="defaultAction" select="''"/>
- <out:param name="hiddenObject" select="''"/>
- <img height="16" width="16">
- <out:attribute name="title">
- <out:value-of select="$screenTip"/>
- </out:attribute>
- <out:attribute name="alt"/>
- <out:attribute name="src"><out:value-of select="$imgURL"/></out:attribute>
- <out:if test="$hiddenObject = 'true'"><out:attribute name="class">hiddenEntryIcon</out:attribute></out:if>
- </img>
- <out:if test="$defaultAction != ''">
- <img height="16" width="12">
- <out:attribute name="src">
- <out:value-of select="$defaultAction"/>
- </out:attribute>
- <out:if test="$hiddenObject = 'true'"><out:attribute name="class">hiddenEntryIcon</out:attribute></out:if>
- </img>
- </out:if>
- </out:template>
- </xsl:template>
- <xsl:template match="pf:ccinav-gen-url">
- <out:template name="ccinav-gen-url">
- <out:variable name="href">
- <out:call-template name="ccinav-generate-link">
- <out:with-param name="item" select="nav:defaultAction"/>
- <out:with-param name="item-type" select="nav:type"/>
- </out:call-template>
- </out:variable>
- <out:choose>
- <out:when test="$href !=''">
- <a>
- <out:choose>
- <out:when test="starts-with($href,'javascript:')">
- <out:attribute name="href"><out:value-of select="'#'"/></out:attribute>
- <out:attribute name="onclick"><out:value-of select="$href"/></out:attribute>
- </out:when>
- <out:otherwise>
- <out:attribute name="href"><out:value-of select="$href"/></out:attribute>
- </out:otherwise>
- </out:choose>
- <out:value-of select="nav:name"/>
- </a>
- </out:when>
- <out:otherwise>
- <out:value-of select="nav:name"/>
- </out:otherwise>
- </out:choose>
- <!-- Render the disabled icon if this entry is disabled -->
- <out:if test="nav:icon/nav:name = 'disabled'">
- <img height="16" width="16" hspace="4" align="absmiddle">
- <out:attribute name="src"><out:value-of select="nav:icon[nav:name='disabled']/nav:imgURL"/></out:attribute>
- <out:attribute name="alt"><out:value-of select="nav:icon[nav:name='disabled']/nav:alt"/></out:attribute>
- </img>
- </out:if>
- </out:template>
- <out:template name="ccinav-generate-link">
- <out:param name="item"/>
- <out:param name="item-type"/>
- <out:if test="$item">
- <out:variable name="isCognosLaunch" select="$item/nav:windowProperties or $item/nav:urlParts/nav:param[@name='m'] = 'portal/launch.xts'"/>
- <out:variable name="isCognosViewer" select="$item/nav:urlParts/nav:param[@name='b_action'] = 'cognosViewer'"/>
- <out:variable name="isTraversingContainer" select="$item/nav:name = 'traverse'"/>
- <out:variable name="isDefaultAction" select="local-name($item) = 'defaultAction'"/>
- <out:choose>
- <out:when test="$item/nav:url and $item/nav:url[@type='external']">
- <out:value-of select="$item/nav:url[@type='external']"/>
- </out:when>
- <out:when test="$isCognosLaunch">
- <out:choose>
- <out:when test="$item/nav:windowProperties">
- <out:text/>javascript:cognosLaunchInWindow('_blank', '<out:value-of select="$item/nav:windowProperties"/>',<out:text/>
- </out:when>
- <out:otherwise>
- <out:text/>javascript:cognosLaunch(<out:text/>
- </out:otherwise>
- </out:choose>
- <out:text/>'<out:value-of select="'ui.backURL'"/>','<out:value-of select="xtsext:javascriptencode(string($back-url))"/>'
- <out:for-each select="$item/nav:urlParts/nav:param[@name != 'm']">
- <out:text/>,'<out:value-of select="xtsext:javascriptencode(string(@name))"/>','<out:value-of select="xtsext:javascriptencode(string(.))"/>'<out:text/>
- </out:for-each>
- <out:text/>)<out:text/>
- </out:when>
- <out:when test="$isTraversingContainer or $isDefaultAction or not($item/nav:urlParts/nav:param[@name='m_class'])">
- <out:value-of select="$item/nav:urlParts/nav:gateway"/>?<out:text/>
- <out:for-each select="$item/nav:urlParts/nav:param">
- <out:text/>&<out:value-of select="@name"/>=<out:text/>
- <out:choose>
- <out:when test="@name='m_path' or @name='m_obj'">
- <out:value-of select="xtsext:protect(xtsext:urlencode(string(.)),'url','searchPath','getdata')"/>
- </out:when>
- <out:when test="@name='m_name'">
- <out:value-of select="xtsext:protect(xtsext:urlencode(string(.)),'url','userData','getdata')"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="xtsext:urlencode(string(.))"/>
- </out:otherwise>
- </out:choose>
- </out:for-each>
- <out:if test="not($isTraversingContainer)">
- <out:choose>
- <out:when test="$item-type='powerPlayCube' or $item-type='powerPlayReport' or $item-type='powerPlay8Report'">
- <out:text/>&BACK=<out:value-of select="xtsext:urlencode(string($back-url))"/>
- </out:when>
- <out:when test="$isCognosViewer">
- <out:text/>&ui.backURL=<out:value-of select="xtsext:urlencode(string($back-url))"/>
- </out:when>
- <out:otherwise>
- <out:text/>&backURL=<out:value-of select="xtsext:urlencode(string($back-url))"/>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:when>
- <out:otherwise>
- <out:choose>
- <!-- We handle portal page "add" rather differently. Detect if we are doing so on a pagelet object or a shortcut to one. -->
- <out:when test="($item-type='pagelet' or $item/../nav:item/nav:type = 'pagelet') and $item/nav:name='add'">
- <out:text/>javascript:pageCmd('addToMyPages','<out:value-of select="xtsext:javascriptencode($item/nav:urlParts/nav:param[@name='m_selectedPage'])"/>')<out:text/>
- </out:when>
- <out:otherwise>
- <out:text/>javascript:actions(<out:text/>
- <out:text/>'<out:value-of select="xtsext:javascriptencode(string($item/nav:urlParts/nav:param[@name='m_name']))"/>',<out:text/>
- <out:text/>'<out:value-of select="xtsext:javascriptencode(string($item/nav:urlParts/nav:param[@name='m_class']))"/>',<out:text/>
- <out:text/>'<out:value-of select="xtsext:javascriptencode(string($item/nav:urlParts/nav:param[@name='m_obj']))"/>',<out:text/>
- <out:choose>
- <out:when test="starts-with($item/nav:urlParts/nav:param[@name='m'], concat($app, '/'))">
- <out:text/>'<out:value-of select="xtsext:javascriptencode(substring-after($item/nav:urlParts/nav:param[@name='m'], concat($app, '/')))"/>',<out:text/>
- </out:when>
- <out:otherwise>
- <out:text/>'<out:value-of select="xtsext:javascriptencode(string($item/nav:urlParts/nav:param[@name='m']))"/>',<out:text/>
- </out:otherwise>
- </out:choose>
- <out:text/>'<out:value-of select="xtsext:javascriptencode(string($item/nav:urlParts/nav:param[@name='m_new_class']))"/>',<out:text/>
- <out:text/>'<out:value-of select="xtsext:javascriptencode(string($item/nav:urlParts/nav:param[@name='m_location']))"/>'<out:text/>
- <out:text/>)<out:text/>
- </out:otherwise>
- </out:choose>
- </out:otherwise>
- </out:choose>
- </out:if>
- </out:template>
- </xsl:template>
- <xsl:template match="pf:ccinav-gen-action-properties">
- <out:template name="ccinav-gen-action-properties">
- <table border="0" cellpadding="2" cellspacing="0">
- <tr>
- <out:for-each select="nav:action">
- <out:variable name="href">
- <out:call-template name="ccinav-generate-link">
- <out:with-param name="item" select="."/>
- <out:with-param name="item-type" select="../nav:type"/>
- </out:call-template>
- </out:variable>
- <out:choose>
- <out:when test="nav:name != 'actions_url'">
- <td>
- <a>
- <out:choose>
- <out:when test="starts-with($href,'javascript:')">
- <out:attribute name="href"><out:value-of select="'#'"/></out:attribute>
- <out:attribute name="onclick"><out:value-of select="$href"/></out:attribute>
- </out:when>
- <out:otherwise>
- <out:attribute name="href"><out:value-of select="$href"/></out:attribute>
- </out:otherwise>
- </out:choose>
- <img height="16" width="16" border="0">
- <out:attribute name="src"><out:value-of select="nav:imgURL"/></out:attribute>
- <out:attribute name="alt"><out:value-of select="nav:alt"/></out:attribute>
- </img>
- </a>
- </td>
- </out:when>
- <out:otherwise>
- <td class="objectOptions" nowrap="nowrap">
- <a>
- <out:choose>
- <out:when test="starts-with($href,'javascript:')">
- <out:attribute name="href"><out:value-of select="'#'"/></out:attribute>
- <out:attribute name="onclick"><out:value-of select="$href"/></out:attribute>
- </out:when>
- <out:otherwise>
- <out:attribute name="href"><out:value-of select="$href"/></out:attribute>
- </out:otherwise>
- </out:choose>
- <xts:string id="IDS_ACT_MORE"/>
- </a>
- </td>
- </out:otherwise>
- </out:choose>
- </out:for-each>
- </tr>
- </table>
- </out:template>
- </xsl:template>
- <xsl:template name="pf:getDocumentIconName">
- <out:choose>
- <out:when test="not($documentFormats/format[@name = $documentType])">
- <out:value-of select="key('ui-object','document')/@icon"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="key('ui-object','document')/@icon"/>
- <out:text/>
- <out:value-of select="/root/system/param[@name='ui_graphics']/param[@name='document_format']/format[@name = $documentType]/@icon"/>
- </out:otherwise>
- </out:choose>
- </xsl:template>
- <xsl:template match="pf:documentFormats">
- <out:template name="getDocumentIconName">
- <out:param name="documentType" select="''"/>
- <xsl:call-template name="pf:getDocumentIconName"/>
- </out:template>
- <out:template name="getDocumentObjectType">
- <out:param name="theObject"/>
- <out:choose>
- <out:when test="$documentFormats/format[@name=$theObject/cm:documentType]"><out:value-of select="$documentFormats/format[@name=$theObject/cm:documentType]/type"/></out:when>
- <out:otherwise><out:value-of select="$theObject/cm:documentType"/></out:otherwise>
- </out:choose>
- </out:template>
- </xsl:template>
- <!--
- Template - pf:serialize-xml:
- This template generates a template used to convert a chuck of xml into an xml-encoded string.
- Operation:
- Outputs the serialize-xml template.
- -->
- <xsl:template match="pf:serialize-xml">
- <out:template name="serialize-xml">
- <out:param name="node-set"/>
- <out:apply-templates mode="markup" select="$node-set"/>
- </out:template>
- <!-- generate text for simple element -->
- <out:template match="*" mode="markup">
- <out:text><</out:text>
- <out:value-of select="name()"/>
- <out:apply-templates select="@*" mode="markup"/>
- <out:if test="( namespace-uri() != '' ) and ( name() = local-name() ) and ( namespace-uri() != namespace-uri(..) )">
- <out:text> xmlns="</out:text>
- <out:value-of select="namespace-uri()"/>
- <out:text>"</out:text>
- </out:if>
- <out:if test="( contains( name(), ':' ) ) and ( namespace-uri() != namespace-uri(..) )">
- <out:text> xmlns:</out:text>
- <out:value-of select="substring-before( name(), ':' )"/>
- <out:text>="</out:text>
- <out:value-of select="namespace-uri()"/>
- <out:text>"</out:text>
- </out:if>
- <out:text>/></out:text>
- </out:template>
- <!-- generate text for an element with children or text -->
- <out:template match="*[* | text()]" mode="markup">
- <out:text><</out:text>
- <out:value-of select="name()"/>
- <out:apply-templates select="@*" mode="markup"/>
- <out:if test="( namespace-uri() != '' ) and ( name() = local-name() ) and ( namespace-uri() != namespace-uri(..) )">
- <out:text> xmlns="</out:text>
- <out:value-of select="namespace-uri()"/>
- <out:text>"</out:text>
- </out:if>
- <out:if test="( contains( name(), ':' ) ) and ( namespace-uri() != namespace-uri(..) )">
- <out:text> xmlns:</out:text>
- <out:value-of select="substring-before( name(), ':' )"/>
- <out:text>="</out:text>
- <out:value-of select="namespace-uri()"/>
- <out:text>"</out:text>
- </out:if>
- <out:text>></out:text>
- <out:apply-templates select="* | text()" mode="markup"/>
- <out:text></</out:text>
- <out:value-of select="name()"/>
- <out:text>></out:text>
- </out:template>
- <!-- generate text for an attribute -->
- <out:template match="@*" mode="markup">
- <out:value-of select="concat(' ', name(), '="', xtsext:xmlencode(string(.)), '"')"/>
- <out:if test="( namespace-uri() != '' ) and ( name() = local-name() ) and ( namespace-uri() != namespace-uri(..) )">
- <out:variable name="currentNamespace" select="namespace-uri()"/>
- <out:if test="generate-id(.) = generate-id(../@*[namespace-uri() = $currentNamespace][1])">
- <out:text> xmlns="</out:text>
- <out:value-of select="namespace-uri()"/>
- <out:text>"</out:text>
- </out:if>
- </out:if>
- <out:if test="( contains( name(), ':' ) ) and ( namespace-uri() != namespace-uri(..) )">
- <out:variable name="currentNamespace" select="namespace-uri()"/>
- <out:if test="generate-id(.) = generate-id(../@*[namespace-uri() = $currentNamespace][1])">
- <out:text> xmlns:</out:text>
- <out:value-of select="substring-before( name(), ':' )"/>
- <out:text>="</out:text>
- <out:value-of select="namespace-uri()"/>
- <out:text>"</out:text>
- </out:if>
- </out:if>
- </out:template>
- <!-- generate text -->
- <out:template match="text()" mode="markup">
- <out:value-of select="xtsext:xmlencode( string( . ) )"/>
- </out:template>
- </xsl:template>
- <xsl:template name="gen-sessionCapabilitiesVars">
- <!--
- CAPABILITIES calculations
- -->
- <!-- Admin capability -->
- <out:variable name="hasAdminCapability" select="boolean(key('session-param','capabilities')/canUseAdministrationPortal)"/>
- <!-- Launch Collaboration Tools capability -->
- <out:variable name="hasLCTCapability" select="boolean(key('session-param','capabilities')/canLaunchCollaborationTools)"/>
- <!-- Launch Collaboration - Lotus Connections Activities -->
- <out:variable name="hasLCActivities" select="boolean(key('session-param','lca')='t')"/>
- <!-- Launch Collaboration - Lotus Connections Homepage -->
- <out:variable name="hasLCHomepage" select="boolean(key('session-param','lch')='t')"/>
- <!-- Desk top capability -->
- <!--
- Note: "isCIInstalled" is only temporary until "canUseCognosInsight" calculation can take into
- account whether CognosInsight is installed or not. When that happens, "isCIInstalled" should
- be removed!
- -->
- <out:variable name="isCIInstalled" select="boolean(key('session-param','ci')='t')"/>
- <out:variable name="hasCICapability" select="$isCIInstalled and boolean(key('session-param','capabilities')/canUseCognosInsight)"/>
- <!-- QueryStudio capability -->
- <out:variable name="hasQSCapability" select="boolean(key('session-param','capabilities')/canUseQueryStudio)"/>
- <!-- Full QueryStudio capability, which allows the user to create/delete reports -->
- <out:variable name="hasFullQSCapability" select="boolean(key('session-param','capabilities')/canUseQueryStudio) and boolean(key('session-param','capabilities')/canUseQueryStudioFileManagement)"/>
- <!-- ReportStudio capability (disabled for Titan))-->
- <out:variable name="hasRSCapability" select="false()"/>
- <!-- Full ReportStudio capability, which allows the user to create/delete reports (disabled for Titan) -->
- <out:variable name="hasFullRSCapability" select="false()"/>
- <!-- External Data capability -->
- <out:variable name="hasExternalDataCapability" select="boolean(key('session-param','capabilities')/canUseExternalData)"/>
- <!-- This var is set for MetricsManager Full Access -->
- <out:variable name="hasMetricsManagerCapability" select="boolean(key('session-param','capabilities')/canUseMetricStudio)"/>
- <out:variable name="hasMetricsManagerAdministrationCapability" select="boolean(key('session-param','capabilities')/canUseMetricsManagerAdministration)"/>
- <!-- Capabilities Tool Access capability-->
- <out:variable name="hasCTCapability" select="boolean(key('session-param','capabilities')/canUseCapabilitiesTool)"/>
- <!-- Object Capabilities Access capability-->
- <out:variable name="hasOCCapability" select="boolean(key('session-param','capabilities')/canUseObjectCapabilities)"/>
- <!-- Users Groups and Roles Tool Access capability-->
- <out:variable name="hasUGRTCapability" select="boolean(key('session-param','capabilities')/canUseUsersGroupsAndRolesTool)"/>
- <!-- Query Service Tool Access capability-->
- <out:variable name="hasQSTCapability" select="boolean(key('session-param','capabilities')/canUseQueryServiceTool)"/>
- <!-- Data Sources Tool Access capability-->
- <out:variable name="hasDSTCapability" select="boolean(key('session-param','capabilities')/canUseDataSourcesTool)"/>
- <!-- Content Store Tool Access capability-->
- <out:variable name="hasCSTCapability" select="boolean(key('session-param','capabilities')/canUseContentStoreTool)"/>
- <!-- Server Administration Tool Access capability-->
- <out:variable name="hasSATCapability" select="boolean(key('session-param','capabilities')/canUseServerAdministrationTool)"/>
- <!-- Portal Administration Tool Access capability-->
- <out:variable name="hasPATCapability" select="boolean(key('session-param','capabilities')/canUsePortalAdministrationTool)"/>
- <!-- Adaptive Analytics Administration Access capability-->
- <out:variable name="hasAAACapability" select="boolean(key('session-param', 'capabilities')/canUseAdaptiveAnalyticsAdministration)"/>
- <!-- Adaptive Analytics (TOC) Access capability-->
- <out:variable name="hasAATOCCapability" select="boolean(key('session-param', 'capabilities')/canUseAdaptiveAnalytics)"/>
- <!-- Analysis Studio Access capability-->
- <out:variable name="hasANSCapability" select="boolean(key('session-param', 'capabilities')/canUseAnalysisStudio)"/>
- <!-- Powerplay Studio Access capability-->
- <out:variable name="hasPPSCapability" select="boolean(key('session-param', 'capabilities')/canUsePowerPlay)"/>
- <!-- Event Studio Access capability-->
- <out:variable name="hasAGSCapability" select="boolean(key('session-param', 'capabilities')/canUseEventStudio)"/>
- <!-- Scheduling Access capability-->
- <out:variable name="hasSchedCapability" select="boolean(key('session-param', 'capabilities')/canUseScheduling)"/>
- <!-- Granularity of Scheduling Access capability-->
- <out:variable name="hasSchedCapabilityByDay" select="boolean(key('session-param', 'capabilities')/canUseSchedulingByDay)"/>
- <out:variable name="hasSchedCapabilityByHour" select="boolean(key('session-param', 'capabilities')/canUseSchedulingByHour)"/>
- <out:variable name="hasSchedCapabilityByMinute" select="boolean(key('session-param', 'capabilities')/canUseSchedulingByMinute)"/>
- <out:variable name="hasSchedCapabilityByWeek" select="boolean(key('session-param', 'capabilities')/canUseSchedulingByWeek)"/>
- <out:variable name="hasSchedCapabilityByMonth" select="boolean(key('session-param', 'capabilities')/canUseSchedulingByMonth)"/>
- <out:variable name="hasSchedCapabilityByYear" select="boolean(key('session-param', 'capabilities')/canUseSchedulingByYear)"/>
- <out:variable name="hasSchedCapabilityByTrigger" select="boolean(key('session-param', 'capabilities')/canUseSchedulingByTrigger)"/>
- <!-- Scheduling Priority capability-->
- <out:variable name="hasSchedPriorityCapability" select="boolean(key('session-param', 'capabilities')/canUseSchedulingPriority)"/>
- <!-- Monitor Activity tool -->
- <out:variable name="hasMonitorActivityToolCapability" select="boolean(key('session-param', 'capabilities')/canUseMonitorActivityTool)"/>
- <!-- Run with Options capability-->
- <out:variable name="hasRWOCapability" select="boolean(key('session-param', 'capabilities')/canUseCognosViewerRunWithOptions)"/>
- <!-- Full Planning Administration capability -->
- <out:variable name="hasPlanningAdministrationCapability" select="boolean(key('session-param', 'capabilities')/canUsePlanningAdministration)"/>
- <!-- Run Planning Contributor capability -->
- <out:variable name="hasPlanningContributorCapability" select="boolean(key('session-param', 'capabilities')/canUsePlanningContributor)"/>
- <!-- Cognos Viewer capability -->
- <out:variable name="hasCVCapability" select="boolean(key('session-param', 'capabilities')/canUseCognosViewer)"/>
- <!-- Controller Studio capability -->
- <out:variable name="hasControllerCapability" select="boolean(key('session-param', 'capabilities')/canUseControllerStudio)"/>
- <!-- EV capability -->
- <out:variable name="hasEVCapability" select="boolean(key('session-param', 'capabilities')/canUseEV)"/>
- <!-- Cognos Viewer security features -->
- <out:variable name="hasCVSelectionCapability" select="boolean(key('session-param', 'capabilities')/canUseCognosViewerSelection)"/>
- <out:variable name="hasCVToolbarCapability" select="boolean(key('session-param', 'capabilities')/canUseCognosViewerToolbar)"/>
- <out:variable name="hasCVContextMenuCapability" select="boolean(key('session-param', 'capabilities')/canUseCognosViewerContextMenu)"/>
- <!-- index search (disabled for titan)-->
- <out:variable name="hasIndexSearchCapability" select="false()"/>
- <out:variable name="hasSpecificationCapability" select="boolean(key('session-param', 'capabilities')/canUseSpecifications)"/>
- <out:variable name="hasDrillMetadataCapability" select="$hasRSCapability or
- $hasQSCapability or $hasAGSCapability or $hasANSCapability or
- $hasControllerCapability or $hasPlanningContributorCapability or
- $hasMetricsManagerCapability or $hasMetricsManagerAdministrationCapability or
- $hasSpecificationCapability"/>
- <!-- can user subscribe to reports -->
- <out:variable name="hasCondSubscriptionsCapability" select="boolean(key('session-param', 'capabilities')/canUseConditionalSubscriptions)"/>
- <out:variable name="hasDrillThroughAssistantCapability" select="boolean(key('session-param', 'capabilities')/canUseDrillThroughAssistant)"/>
- <out:variable name="hasCanUseMobileServiceCapability" select="boolean(key('session-param', 'capabilities')/canUseMobileService)"/>
- <!-- can user generate output in selected formats -->
- <out:variable name="hasCanGenerateCSVOutputCapability" select="boolean(key('session-param', 'capabilities')/canGenerateCSVOutput)"/>
- <out:variable name="hasCanGeneratePDFOutputCapability" select="boolean(key('session-param', 'capabilities')/canGeneratePDFOutput)"/>
- <out:variable name="hasCanGenerateXMLOutputCapability" select="boolean(key('session-param', 'capabilities')/canGenerateXMLOutput)"/>
- <out:variable name="hasCanGenerateXLSOutputCapability" select="boolean(key('session-param', 'capabilities')/canGenerateXLSOutput)"/>
- <!-- can user open pp7 and pp8 reports in Analysis/Report studios -->
- <out:variable name="hasOpenPowerPlayInAnalysisStudioCapability" select="boolean(key('session-param', 'capabilities')/canOpenPowerPlayInAnalysisStudio)"/>
- <out:variable name="hasOpenPowerPlayInReportStudioCapability" select="boolean(key('session-param', 'capabilities')/canOpenPowerPlayInReportStudio)"/>
- <!-- can user set hide entries in preferences tab -->
- <out:variable name="hasCanUseShowHiddenObjectsPreferenceCapability" select="boolean(key('session-param', 'capabilities')/canUseShowHiddenObjectsPreference)"/>
- <!-- can user open dashboard objects -->
- <out:variable name="hasCanUseDashboardViewer" select="boolean(key('session-param', 'capabilities')/canUseDashboardViewer)"/>
- <!-- related to dashboard object, can use advanced features -->
- <out:variable name="hasCanUseAdvancedDashboardFeatures" select="boolean(key('session-param', 'capabilities')/canUseAdvancedDashboardFeatures)"/>
- <!-- can user open self-serve wizard to create package objects -->
- <out:variable name="hasCanUseSelfServicePackageWizard" select="boolean(key('session-param', 'capabilities')/canUseSelfServicePackageWizard)"/>
- <!-- can user access Repository -->
- <out:variable name="hasCanUseRepositoryCapability" select="boolean(key('session-param','capabilities')/canUseRepository)"/>
- <!-- can user view Repository content -->
- <out:variable name="hasCanViewContentInRepositoryCapability" select="boolean(key('session-param','capabilities')/canViewContentInRepository)"/>
- <!-- can user view Repository content -->
- <out:variable name="hasCanUpdateRepositoryRulesCapability" select="boolean(key('session-param','capabilities')/canUpdateRepositoryRules)"/>
- <!-- can user use My Data Sets feature -->
- <out:variable name="hasCanUseMyDataSetsCapability" select="boolean(key('session-param','capabilities')/canUseMyDataSets)"/>
- <!--This var is set for EV users-->
- <out:variable name="userCanUseEVValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseEV'"/><out:with-param name="value" select="$hasEVCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseEV" select="$userCanUseEVValue = 'true'"/>
- <!-- This var is set for administrators -->
- <out:variable name="isAdminUser" select="$hasAdminCapability"/>
- <!-- This var is set for QueryStudio Access -->
- <out:variable name="userCanUseQSValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseQueryStudio'"/><out:with-param name="value" select="$hasQSCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseQS" select="$userCanUseQSValue = 'true'"/>
- <!-- This var is set for QueryStudio Full Access, which allows the user to create/delete reports -->
- <out:variable name="userCanUseFullQS" select="$userCanUseQS and $hasFullQSCapability"/>
- <!-- This var is set for ReportStudio Access -->
- <out:variable name="userCanUseRSValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseReportStudio'"/><out:with-param name="value" select="$hasRSCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseRS" select="$userCanUseRSValue = 'true'"/>
- <!-- This var is set for ReportStudio Full Access, which allows the user to create/delete reports -->
- <out:variable name="userCanUseFullRS" select="$userCanUseRS and $hasFullRSCapability"/>
- <!-- This var is set for ExternalData Access -->
- <out:variable name="userCanUseExternalDataValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseExternalData'"/><out:with-param name="value" select="$hasExternalDataCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseExternalData" select="$userCanUseExternalDataValue = 'true'"/>
- <!-- This var is set for MetricsManager Full Access -->
- <out:variable name="userCanUseMetricsManagerAdministrationValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMetricsManagerAdministration'"/><out:with-param name="value" select="$hasMetricsManagerAdministrationCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseMetricsManagerAdministration" select="$userCanUseMetricsManagerAdministrationValue = 'true'"/>
- <out:variable name="userCanUseMetricsManagerValue">
- <out:variable name="canUseMetricStudio"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMetricStudio'"/><out:with-param name="value" select="$hasMetricsManagerCapability"/></out:call-template></out:variable>
- <out:value-of select="$canUseMetricStudio = 'true' or $userCanUseMetricsManagerAdministration"/>
- </out:variable>
- <out:variable name="userCanUseMetricsManager" select="$userCanUseMetricsManagerValue = 'true'"/>
- <!-- This var is set for Capabilities Tool Access -->
- <out:variable name="userCanUseCTValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseCapabilitiesTool'"/><out:with-param name="value" select="$hasCTCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseCT" select="$userCanUseCTValue = 'true'"/>
- <!-- This var is set for Object Capabilities Access -->
- <out:variable name="userCanUseOCValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseObjectCapabilities'"/><out:with-param name="value" select="$hasOCCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseOC" select="$userCanUseOCValue = 'true'"/>
- <!-- This var is set for Users Groups and Roles Tool Access -->
- <out:variable name="userCanUseUGRTValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseUsersGroupsAndRolesTool'"/><out:with-param name="value" select="$hasUGRTCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseUGRT" select="$userCanUseUGRTValue = 'true'"/>
- <!-- This var is set for Query Service Tool Access -->
- <out:variable name="userCanUseQSTValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseQueryServiceTool'"/><out:with-param name="value" select="$hasQSTCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseQST" select="$userCanUseQSTValue = 'true'"/>
- <!-- This var is set for Data Sources Tool Access -->
- <out:variable name="userCanUseDSTValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseDataSourcesTool'"/><out:with-param name="value" select="$hasDSTCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseDST" select="$userCanUseDSTValue = 'true'"/>
- <!-- This var is set for Content Store Tool Access -->
- <out:variable name="userCanUseCSTValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseContentStoreTool'"/><out:with-param name="value" select="$hasCSTCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseCST" select="$userCanUseCSTValue = 'true'"/>
- <!-- This var is set for Server Administration Tool Access -->
- <out:variable name="userCanUseSATValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseServerAdministrationTool'"/><out:with-param name="value" select="$hasSATCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseSAT" select="$userCanUseSATValue = 'true'"/>
- <!-- This var is set for Portal Administration Tool Access -->
- <out:variable name="userCanUsePATValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUsePortalAdministrationTool'"/><out:with-param name="value" select="$hasPATCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUsePAT" select="$userCanUsePATValue = 'true'"/>
- <!-- This var is set for Adaptive Analytics Administration Access -->
- <out:variable name="userCanUseAdaptiveAnalyticsAdministrationValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseAdaptiveAnalyticsAdministration'"/><out:with-param name="value" select="$hasAAACapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseAdaptiveAnalyticsAdministration" select="$userCanUseAdaptiveAnalyticsAdministrationValue = 'true'"/>
- <!-- This var is set for Adaptive Analytics TOC Access -->
- <out:variable name="userCanUseAdaptiveAnalyticsValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseAdaptiveAnalytics'"/><out:with-param name="value" select="$hasAATOCCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseAdaptiveAnalytics" select="$userCanUseAdaptiveAnalyticsValue = 'true'"/>
- <!-- This var is set for Analysis Studio Access -->
- <out:variable name="userCanUseANSValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseAnalysisStudio'"/><out:with-param name="value" select="$hasANSCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseANS" select="$userCanUseANSValue = 'true'"/>
- <!-- This var is set for Powerplay Studio Access -->
- <out:variable name="userCanUsePPSValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUsePowerPlay'"/><out:with-param name="value" select="$hasPPSCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUsePPS" select="$userCanUsePPSValue = 'true'"/>
- <!-- This var is set for Event Studio Access -->
- <out:variable name="userCanUseAGSValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseEventStudio'"/><out:with-param name="value" select="$hasAGSCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseAGS" select="$userCanUseAGSValue = 'true'"/>
- <!-- This var is set for Scheduling Access -->
- <out:variable name="userCanUseSchedValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseScheduling'"/><out:with-param name="value" select="$hasSchedCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseSched" select="$userCanUseSchedValue = 'true'"/>
- <out:variable name="userCanUseMonitorActivityValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMonitorActivityTool'"/><out:with-param name="value" select="$hasMonitorActivityToolCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseMonitorActivity" select="$userCanUseMonitorActivityValue = 'true'"/>
- <!-- This var is set for Run With Options Access -->
- <out:variable name="userCanUseRWOValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseCognosViewerRunWithOptions'"/><out:with-param name="value" select="$hasRWOCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseRWO" select="$userCanUseRWOValue = 'true'"/>
- <!-- This var is set for Contributor Administration Access -->
- <out:variable name="userCanUsePlanningAdministrationValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUsePlanningAdministration'"/><out:with-param name="value" select="$hasPlanningAdministrationCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUsePlanningAdministration" select="$userCanUsePlanningAdministrationValue = 'true'"/>
- <!-- This var is set for Contributor Access -->
- <out:variable name="userCanUsePlanningContributorValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUsePlanningContributor'"/><out:with-param name="value" select="$hasPlanningContributorCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUsePlanningContributor" select="$userCanUsePlanningContributorValue = 'true'"/>
- <!-- This var is set for Cognos Viewer Access -->
- <out:variable name="userCanUseCVValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseCognosViewer'"/><out:with-param name="value" select="$hasCVCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseCV" select="$userCanUseCVValue = 'true'"/>
- <!-- This var is set for Controller Administration Access - based on BOAM, but is not required at this time. -->
- <!-- <out:variable name="userCanUseControllerAdministration" select="$hasFullControllerCapability"/> -->
- <!-- This var is set for Controller Studio -->
- <out:variable name="userCanUseControllerStudioValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseControllerStudio'"/><out:with-param name="value" select="$hasControllerCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseControllerStudio" select="$userCanUseControllerStudioValue = 'true'"/>
- <!-- Cognos Viewer security features -->
- <out:variable name="userCanUseCVSelectionValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseCognosViewerSelection'"/><out:with-param name="value" select="$hasCVSelectionCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseCVSelection" select="$userCanUseCVSelectionValue = 'true'"/>
- <out:variable name="userCanUseCVToolbarValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseCognosViewerToolbar'"/><out:with-param name="value" select="$hasCVToolbarCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseCVToolbar" select="$userCanUseCVToolbarValue = 'true'"/>
- <out:variable name="userCanUseCVContextMenuValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseCognosViewerContextMenu'"/><out:with-param name="value" select="$hasCVContextMenuCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseCVContextMenu" select="$userCanUseCVContextMenuValue = 'true'"/>
- <!-- index search - use advanced settings -->
- <out:variable name="userCanUseIndexSearch" select="false()"/>
- <out:variable name="userCanSelectMetadata" select="$hasDrillMetadataCapability and $isQSFriendlyBrowser"/>
- <!-- allow pp7/pp8 rpts to open in analysis/report studios -->
- <out:variable name="userCanOpenPPInAnalysisStudioValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canOpenPowerPlayInAnalysisStudio'"/><out:with-param name="value" select="$hasOpenPowerPlayInAnalysisStudioCapability"/></out:call-template></out:variable>
- <out:variable name="userCanOpenPPInAnalysisStudio" select="$userCanOpenPPInAnalysisStudioValue = 'true'"/>
- <out:variable name="userCanOpenPPInReportStudioValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canOpenPowerPlayInReportStudio'"/><out:with-param name="value" select="$hasOpenPowerPlayInReportStudioCapability"/></out:call-template></out:variable>
- <out:variable name="userCanOpenPPInReportStudio" select="$userCanOpenPPInReportStudioValue = 'true'"/>
- <!-- The var is set for a user that can set the hide entries field on the preferences page -->
- <out:variable name="userCanUseShowHiddenObjectsPreferenceCapability"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseShowHiddenObjectsPreference'"/><out:with-param name="value" select="$hasCanUseShowHiddenObjectsPreferenceCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseDashboardViewerValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseDashboardViewer'"/><out:with-param name="value" select="$hasCanUseDashboardViewer"/></out:call-template></out:variable>
- <out:variable name="userCanUseDashboardViewer" select="$userCanUseDashboardViewerValue='true'"/>
- <out:variable name="userCanUseAdvancedDashboardFeaturesValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseAdvancedDashboardFeatures'"/><out:with-param name="value" select="$hasCanUseAdvancedDashboardFeatures"/></out:call-template></out:variable>
- <out:variable name="userCanUseAdvancedDashboardFeatures" select="$userCanUseAdvancedDashboardFeaturesValue='true'"/>
- <out:variable name="userCanUseSelfServicePackageWizardValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseSelfServicePackageWizard'"/><out:with-param name="value" select="$hasCanUseSelfServicePackageWizard"/></out:call-template></out:variable>
- <out:variable name="userCanUseSelfServicePackageWizard" select="$userCanUseSelfServicePackageWizardValue='true'"/>
- <out:variable name="userCanUseDrillThroughAssistantValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseDrillThroughAssistant'"/><out:with-param name="value" select="$hasDrillThroughAssistantCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseDrillThroughAssistant" select="$userCanUseDrillThroughAssistantValue='true'"/>
- <out:variable name="userCanUseMobileServiceValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMobileService'"/><out:with-param name="value" select="$hasCanUseMobileServiceCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseMobileService" select="$userCanUseMobileServiceValue='true'"/>
- <out:variable name="userCanLaunchCollaborationToolsValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canLaunchCollaborationTools'"/><out:with-param name="value" select="$hasLCTCapability"/></out:call-template></out:variable>
- <out:variable name="userCanLaunchCollaborationTools" select="$userCanLaunchCollaborationToolsValue='true'"/>
- <!-- User can generate report outputs -->
- <out:variable name="userCanGenerateCSVOutputValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canGenerateCSVOutput'"/><out:with-param name="value" select="$hasCanGenerateCSVOutputCapability"/></out:call-template></out:variable>
- <out:variable name="userCanGenerateCSVOutput" select="$userCanGenerateCSVOutputValue='true'"/>
- <out:variable name="userCanGeneratePDFOutputValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canGeneratePDFOutput'"/><out:with-param name="value" select="$hasCanGeneratePDFOutputCapability"/></out:call-template></out:variable>
- <out:variable name="userCanGeneratePDFOutput" select="$userCanGeneratePDFOutputValue='true'"/>
- <out:variable name="userCanGenerateXMLOutputValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canGenerateXMLOutput'"/><out:with-param name="value" select="$hasCanGenerateXMLOutputCapability"/></out:call-template></out:variable>
- <out:variable name="userCanGenerateXMLOutput" select="$userCanGenerateXMLOutputValue='true'"/>
- <out:variable name="userCanGenerateXLSOutputValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canGenerateXLSOutput'"/><out:with-param name="value" select="$hasCanGenerateXLSOutputCapability"/></out:call-template></out:variable>
- <out:variable name="userCanGenerateXLSOutput" select="$userCanGenerateXLSOutputValue='true'"/>
- <!-- User can access Repository and view content -->
- <out:variable name="userCanUseRepository"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseRepository'"/><out:with-param name="value" select="$hasCanUseRepositoryCapability"/></out:call-template></out:variable>
- <out:variable name="userCanViewContentInRepository"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canViewContentInRepository'"/><out:with-param name="value" select="$hasCanViewContentInRepositoryCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUpdateRepositoryRules"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseRepository'"/><out:with-param name="value" select="$hasCanUpdateRepositoryRulesCapability"/></out:call-template></out:variable>
- <!-- This var is set for Cognos Insight access -->
- <out:variable name="userCanUseCIValue"><out:call-template name="calUserCapability">
- <out:with-param name="capability" select="'canUseCognosInsight'"/>
- <out:with-param name="value" select="$hasCICapability"/>
- </out:call-template></out:variable>
- <out:variable name="userCanUseCI" select="$userCanUseCIValue='true'"/>
- <out:variable name="userCanUseAdminConsoleValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseAdministrationPortal'"/><out:with-param name="value" select="$hasAdminCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseAdminConsole" select="$userCanUseAdminConsoleValue='true'"/>
- <out:variable name="userCanUseMyActivitiesAndScheduleValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMyActivitiesAndSchedule'"/><out:with-param name="value" select="($userCanUseSched or $userCanUseMonitorActivity)"/></out:call-template></out:variable>
- <out:variable name="userCanUseMyActivitiesAndSchedule" select="$userCanUseMyActivitiesAndScheduleValue='true'"/>
- <out:variable name="userCanUseMyInboxValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMyInbox'"/><out:with-param name="value" select="true()"/></out:call-template></out:variable>
- <out:variable name="userCanUseMyInbox" select="$userCanUseMyInboxValue='true' and $edition!='mid-market'"/>
- <!-- My Data Sets -->
- <out:variable name="userCanUseMyDataSetsValue"><out:call-template name="calUserCapability"><out:with-param name="capability" select="'canUseMyDataSets'"/><out:with-param name="value" select="$hasCanUseMyDataSetsCapability"/></out:call-template></out:variable>
- <out:variable name="userCanUseMyDataSets" select="$userCanUseMyDataSetsValue='true'"/>
- </xsl:template>
- <xsl:template match="pf:utilities">
- <out:template name="parseDocumentDomain">
- <out:param name="url"/>
- <!--
- * Parse and return the value to be used to set the document domain
- * For example, the domain value of "ibm.com" is returned for the "http://myserver1.ibm.com:1234/.." url
- -->
- <out:variable name="server" select="substring-before(substring-after($url, '://'), '/')"/>
- <out:if test="contains($server, '.')">
- <out:variable name="second-part" select="xtsext:substringAfterLast(xtsext:substringBeforeLast($server, '.'), '.')"/>
- <out:if test="$second-part != ''"><out:value-of select="$second-part"/>.</out:if>
- <out:choose>
- <out:when test="contains($server, ':')"><out:value-of select="xtsext:substringAfterLast(substring-before($server,':'), '.')"/></out:when>
- <out:otherwise><out:value-of select="xtsext:substringAfterLast($server, '.')"/></out:otherwise>
- </out:choose>
- </out:if>
- </out:template>
- </xsl:template>
- <!--
- Call this template to assist with inclusion of the dojo library along with any other required libraries
- eg: <pf:dojo>
- <require>com.ibm.cognos.ps.pdfOptions</require>
- </pf:dojo>
- where com.ibm.cognos.ps.pdfOptions is pdfOptions.js within the com.ibm.cognos.ps namespace
- -->
- <xsl:template match="pf:dojo">
- <script language="javascript" src="{'{$webRoot}'}/dojo16/dojo/dojo.js">
- <xsl:if test="@djConfig">
- <xsl:attribute name="djConfig"><xsl:value-of select="@djConfig"/></xsl:attribute>
- </xsl:if>
- </script>
- <script language="javascript" src="{'{$webcontent}'}/{'{$app}'}/js/com/ibm/cognos/ps/dojo/dojoInit.js"/>
- <script language="javascript">
- <xsl:for-each select="require">
- dojo.require("<xsl:value-of select="xtsext:javascriptencode(text())"/>");
- </xsl:for-each>
- </script>
- </xsl:template>
- <xsl:template match="*">
- <xsl:copy>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </xsl:copy>
- </xsl:template>
- <xsl:template match="pf:common-bidi-templates">
- <out:template name="get-bidi-ready-value">
- <out:param name="value" select="''"/>
- <out:choose>
- <out:when test="$isBidiEnabled = 'true'">
- <out:value-of select="xtsext:enforceBTD($value, $baseTextDirection, $productLocale)"/>
- </out:when>
- <out:otherwise>
- <out:value-of select="$value"/>
- </out:otherwise>
- </out:choose>
- </out:template>
- <out:template name="add-bidi-onfocus-event">
- <out:param name="value" select="''"/>
- <out:if test="$isBidiEnabled = 'true'">
- <out:variable name="textDirection">
- <out:value-of select="xtsext:getBTD(string($value), $baseTextDirection, $productLocale)"/>
- </out:variable>
- <out:attribute name="dir">
- <out:value-of select="$textDirection"/>
- </out:attribute>
- <out:if test="$baseTextDirection = 'auto'">
- <out:attribute name="onfocus">
- bidi.onfocus(this)
- </out:attribute>
- </out:if>
- </out:if>
- </out:template>
- </xsl:template>
- </xsl:stylesheet>
|