123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: AGS
- (C) Copyright IBM Corp. 2005, 2008
- US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- -->
- <xts:morphlet version="1.0" xmlns:xts="http://developer.cognos.com/schemas/xts/" messageBase="messages/portal.xml,messages/AGS.xml,messages/portalRL.xml" requiredCapability="canUseEventStudio">
- <!--
- ================================================================================
- Page Renderer
- ================================================================================
- -->
- <xts:block id="page" type="exec" mode="output" processor="XSLT" mimeType="text/html">
- <!-- get the debug logic sheet -->
- <xts:logicsheet path="logicsheets/debuglogic.xslt"/>
- <!-- get the new theme stuff -->
- <xts:logicsheet path="logicsheets/portal.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/dialog/framework.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/dialog/presentation.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/controls/framework.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/controls/presentation.xsl"/>
- <xts:logicsheet path="logicsheets/presentation/layout.xsl"/>
- <!-- apply the form logic -->
- <xts:logicsheet path="logicsheets/formlogic.xslt"/>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xts="http://developer.cognos.com/schemas/xts/" xmlns:lyt="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/layout/" xmlns:pf="http://developer.cognos.com/schemas/xts/pf" xmlns:dp="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/presentation/" xmlns:df="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/framework/" xmlns:cp="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/controls/presentation/" xmlns:cf="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/controls/framework/" xmlns:dbg="http://developer.cognos.com/schemas/xts/logicsheets/xslt/debug/" xmlns:utml="http://developer.cognos.com/schemas/xts/logicsheet/xslt/formlogic/" xmlns:xtsext="xalan://com.cognos.xts.ext.XTSExt" exclude-result-prefixes="xsl xts lyt pf dp df cp cf dbg utml xtsext">
- <xsl:output method="html" version="1.0" encoding="UTF-8" indent="no"/>
- <!-- Global template variables -->
- <pf:variables/>
- <!-- start the output -->
- <xsl:template match="/root">
- <dp:page title="AGENT_STUDIO_WINDOW_TITLE">
- <link href="{$skin_root}/ags/ags.css" type="text/css" rel="stylesheet"/>
- <dp:script>
- <script type="text/javascript" src="../common/framework/ui/CUIStyle.js">//</script>
- <script type="text/javascript" src="../prompting/prompting.js">//</script>
- <script type="text/javascript" src="../prompting/CTreeIE5NS6.js">//</script>
- <script type="text/javascript">
- // get access to the configFrame - the parent window
- var cf = parent.getConfigFrame();
- // keep the items which launched the query - we should be able to run multiple
- // items - the items which have been selected in the tree.
- var items = null;
- // we also have to persist globally the sort/filter/filter type
- var g_sSortOrder = null;
- var filter = null;
- var filter_type = null;
- var case_sensitive = null;
- var search_descendants = null;
- var search_finished = true;
- var startAtPath = null;
- // List objects
- var clistLeft ;
- var clistRight ;
- // define the callback function - response from worker thread
- var callbackFn = function(status)
- {
- }
- function clistEqualityCheck(list, node) {
- var result = false;
- var items = list.getAllItems();
- for (var i=0; items && i < items.length;i++) {
- result = result || items[i].firstChild.nodeValue.localeCompare(node.nodeValue) == 0;
- }
- return result;
- }
- // init function - this will initiate the conversation_frame with the information it need to start up
- function init()
- {
- }
- function closeDialog()
- {
- cf.doClosePopUp();
- }
- // create the URL which starts the conversation
- function sendQuery(callbackFn, method, treeObj)
- {
- // send the query
- cf.doSelectValuesRequest(callbackFn, method, treeObj, g_sSortOrder, filter, filter_type, tracking, conversation);
- }
- function updateValues(displayValues, useValues)
- {
- }
-
- function doSearch()
- {
- filter = null;
- filter_type = null;
- // filter out the filter
- if (document.pform.searchValue.value.length > 0) {
- filter = document.pform.searchValue.value;
- }
-
- // get the filter type
- if (document.pform.search_method[0].checked) {
- filter_type = document.pform.search_method[0].value;
- }
- if (document.pform.search_method[1].checked) {
- filter_type = document.pform.search_method[1].value;
- }
- if (document.pform.search_method[2].checked) {
- filter_type = document.pform.search_method[2].value;
- }
- // sort out the case_insensitive and search_descendants values
- // UI has case insensitive - but actual function requires case sensitive - so have to reverse the logic
- if (document.pform.case_insensitive.checked) {
- case_sensitive = null;
- } else {
- case_sensitive = true;
- }
-
- <xsl:choose>
- <xsl:when test="/root/env/param[@name='searchDescendantsAllowed'] and /root/env/param[@name='searchDescendantsAllowed']='true'">
- if (document.pform.search_descendants.checked) {
- search_descendants = true;
- } else {
- search_descendants = false;
- }
- </xsl:when>
- <xsl:otherwise>
- search_descendants = false;
- </xsl:otherwise>
- </xsl:choose>
-
- // get the path
- if (document.pform.startAtPath.value.length > 0) {
- startAtPath = document.pform.startAtPath.value;
- }
-
- // run the search
- cf.doMemberSearch(startAtPath, filter, filter_type, case_sensitive, search_descendants);
- }
-
- function addItem(selectElemRef, selectedElemRef, i)
- {
- }
-
- function generateMultipleInsert(selectedElemRef)
- {
- }
-
-
- </script>
- </dp:script>
- <link href="{$skin_root}/ags/ags.css" type="text/css" rel="stylesheet"/>
- <utml:form name="pform" method="post" action="{$gateway}">
- <!-- need a hidden input -->
- <utml:input type="hidden" name="startAtPath" id="startAtPath">
- <utml:value>
- <xsl:value-of select="/root/env/param[@name='startAtPath']"/>
- </utml:value>
- </utml:input>
- <!-- hack to specify that we need to build the run options -->
- <dp:header help="false">
- <dp:title>
- <xts:string id="DIALOG_MEMBER_SEARCH_TITLE"/>
- </dp:title>
- <dp:description>
- <xts:string id="DIALOG_MEMBER_SEARCH_DESCRIPTION"/>
- </dp:description>
- <dp:close>
- <a href="#" onclick="closeDialog();">
- <dp:closeMarker/>
- </a>
- </dp:close>
- </dp:header>
- <lyt:layout style="1">
- <lyt:section>
- <!-- do the body -->
- <dp:list>
- <dp:section>
- <dp:label>
- <xts:string id="DIALOG_SEARCH_HEADER"/>
- </dp:label>
- </dp:section>
- <dp:section>
- <dp:text>
- <input type="text" size="60" name="searchValue" id="searchValue"/>
- </dp:text>
- </dp:section>
- </dp:list>
- <!-- do the advanced search features -->
- <dp:box>
- <dp:boxSection valign="top" height="100%">
- <dp:list>
- <dp:section>
- <dp:label>
- <xts:string id="DIALOG_SEARCH_FILTER"/>
- </dp:label>
- </dp:section>
- <dp:section>
- <dp:choice>
- <utml:radio-group name="search_method">
- <utml:default-value>contains</utml:default-value>
- <dp:section1>
- <utml:input type="radio">
- <utml:value>
- <xsl:text>contains</xsl:text>
- </utml:value>
- </utml:input>
- </dp:section1>
- <dp:section2>
- <span style="cursor:default">
- <xts:string id="DIALOG_SEARCH_FILTER_CONTAINS"/>
- </span>
- </dp:section2>
- <dp:section1>
- <utml:input type="radio">
- <utml:value>
- <xsl:text>starts-with</xsl:text>
- </utml:value>
- </utml:input>
- </dp:section1>
- <dp:section2>
- <span style="cursor:default">
- <xts:string id="DIALOG_SEARCH_FILTER_STARTS_WITH"/>
- </span>
- </dp:section2>
- <dp:section1>
- <utml:input type="radio">
- <utml:value>
- <xsl:text>equals</xsl:text>
- </utml:value>
- </utml:input>
- </dp:section1>
- <dp:section2>
- <span style="cursor:default">
- <xts:string id="DIALOG_SEARCH_FILTER_EQUALS"/>
- </span>
- </dp:section2>
- </utml:radio-group>
- </dp:choice>
- </dp:section>
- </dp:list>
- </dp:boxSection>
- <dp:boxSection valign="top" height="100%">
- <dp:list>
- <dp:section>
- <dp:label>
- <xts:string id="DIALOG_SEARCH_OPTIONS_TITLE"/>
- </dp:label>
- </dp:section>
- <dp:section>
- <dp:choice>
- <dp:section1>
- <utml:input type="checkbox" name="case_insensitive" id="case_insensitive" value="true"/>
- </dp:section1>
- <dp:section2>
- <xts:string id="DIALOG_SEARCH_OPTIONS_CASE"/>
- </dp:section2>
- <dp:section1>
- <utml:input type="checkbox" name="search_descendants" id="search_descendants" value="true">
- <utml:read-only>
- <xsl:choose>
- <xsl:when test="/root/env/param[@name='searchDescendantsAllowed'] and /root/env/param[@name='searchDescendantsAllowed']='true'">
- <xsl:text>false</xsl:text>
- </xsl:when>
- <xsl:otherwise>
- <xsl:text>true</xsl:text>
- </xsl:otherwise>
- </xsl:choose>
- </utml:read-only>
- </utml:input>
- </dp:section1>
- <dp:section2>
- <xts:string id="DIALOG_SEARCH_OPTIONS_DESCENDANTS"/>
- </dp:section2>
- </dp:choice>
- </dp:section>
- </dp:list>
- </dp:boxSection>
- </dp:box>
- </lyt:section>
- </lyt:layout>
- <!-- footer -->
- <dp:footer style="width:100%">
- <dp:button>
- <dp:defaultKey>active</dp:defaultKey>
- <dp:defaultAct>doSearch();</dp:defaultAct>
- <a href="#" onclick="doSearch();">
- <dp:buttonText>
- <xts:string id="DIALOG_SEARCH_BUTTON"/>
- </dp:buttonText>
- <dp:buttonImage name="imgSearch">../ags/images/tree/member_search.gif</dp:buttonImage>
- </a>
- </dp:button>
- <df:button df:id="IDS_CANCEL" df:style="href" df:href="#" onclick="closeDialog();"/>
- </dp:footer>
- </utml:form>
- </dp:page>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- <!-- =========================================================================================
- D E B U G B L O C K
- =========================================================================================
- -->
- <xts:block id="debug" type="exec" mode="output" processor="XSLT" condition=".[/root/session/param[@name = 'debug'] = '1']" mandatory="false" mimeType="text/html" dependency="page">
- <!-- Get the debug logicsheet. -->
- <xts:logicsheet path="logicsheets/debuglogic.xslt"/>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:dbg="http://developer.cognos.com/schemas/xts/logicsheets/xslt/debug/" exclude-result-prefixes="dbg">
- <xsl:output method="html" version="1.0" encoding="UTF-8" indent="no"/>
- <xsl:template match="/">
- <dbg:dumpxml select="/root"/>
- </xsl:template>
- </xsl:stylesheet>
- </xts:block>
- </xts:morphlet>
|