123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: ASV
- (C) Copyright IBM Corp. 2005, 2015
- 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:rdsad="http://developer.cognos.com/schemas/xts/rdsad/" xmlns:dp="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/dialog/presentation/" xmlns:cf="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/controls/framework/" xmlns:cp="http://developer.cognos.com/schemas/xts/logicsheets/xslt/presentation/controls/presentation/" xmlns:cm="http://developer.cognos.com/schemas/xts-cm/1/" xmlns:utml="http://developer.cognos.com/schemas/xts/logicsheet/xslt/formlogic/" exclude-result-prefixes="xsl xtsext xts rdsad dp utml cf cp cm">
- <xsl:output method="xml" encoding="UTF-8" indent="no"/>
- <xsl:namespace-alias stylesheet-prefix="out" result-prefix="xsl"/>
- <!--
- This stylesheet (rss.xslt) consists of the following templates:
- rss:conditionDisplay
- rss:emailDisplay
- -->
- <!--
- Template - rss:conditionDisplay:
- -->
- <xsl:template match="rdsad:conditionDisplay">
-
- <out:variable name="metricWatchRule" select="boolean(/root/env/param[@name='m_sub_type'] = 'metric')"/>
- <out:variable name="measureName" select="/root/env/param[@name='m_subData_measure_name']"/>
- <table cellpadding="0" cellspacing="0" border="0" role="presentation">
- <tr>
- <td class="formLabel" nowrap="nowrap">
- <out:text>
- <xts:string id="IDS_CUSTSUB_CONDITION_CONTEXT"/>
- </out:text>
- </td>
- </tr>
- <tr>
- <td>
- <table cellpadding="0" cellspacing="0" border="0" role="radiogroup">
- <tr>
- <td>
- <input type="radio" name="m_sub_type" id="m_sub_type_nonMetric" value="nonMetric" onclick="nonMetricClicked()" role="radio">
- <out:if test="/root/env/param[@name='m_sub_type']='nonMetric' or not(/root/env/param[@name='m_sub_type'])">
- <out:attribute name="checked">
- <out:text>checked</out:text>
- </out:attribute>
- <out:attribute name="aria-checked"><out:text>true</out:text></out:attribute>
- </out:if>
- </input>
- </td>
- <td class="formText" nowrap="nowrap">
- <label for="m_sub_type_nonMetric">
- <xts:string id="IDS_CUSTSUB_CONDITION_REPORT">
- <xts:param name="reportName">
- <out:value-of select="/root/env/param[@name='m_subData_periodical_producer_defaultName']"/>
- </xts:param>
- </xts:string>
- </label>
- </td>
- </tr>
- <tr>
- <td>
- </td>
- <td>
- <out:variable name="operatorDomain">
- <out:value-of select="/root/env/param[@name='m_subData_dtype_domain']"/>
- </out:variable>
- <out:variable name="conditionEnum">
- <out:choose>
- <out:when test="/root/env/param[@name='m_sub_operation']">
- <out:value-of select="/root/env/param[@name='m_sub_operation']"/>
- </out:when>
- <out:otherwise>
- <out:choose>
- <out:when test="$operatorDomain = 'numeric'">
- <out:text>greater_than</out:text>
- </out:when>
- <out:when test="$operatorDomain = 'string'">
- <out:text>contains</out:text>
- </out:when>
- </out:choose>
- </out:otherwise>
- </out:choose>
- </out:variable>
- <!--- have to figure out the initial value of the display and the initlal value of the hidden input -->
- <out:variable name="conditionText">
- <out:call-template name="conditionEnumLongValue">
- <out:with-param name="conditionEnum">
- <out:value-of select="$conditionEnum"/>
- </out:with-param>
- </out:call-template>
- </out:variable>
- <out:variable name="operatorPopup">
- <out:choose>
- <out:when test="$operatorDomain='string'">
- <flyout id="operatorPopup" height="10">
- <items>
- <itemGroup id="operatorGroup">
- <item id="contains">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_CONTAINS"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_CONTAINS" encode="javascript"/>', 'contains');</action>
- </item>
- <item id="begins">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_BEGINS"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_BEGINS" encode="javascript"/>', 'begins');</action>
- </item>
- <item id="ends">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_ENDS"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_ENDS" encode="javascript"/>', 'ends');</action>
- </item>
- <item id="matches">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_MATCH"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_MATCH" encode="javascript"/>', 'match');</action>
- </item>
- <item id="notContains">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_CONTAINS"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_NOT_CONTAINS" encode="javascript"/>', 'not_contains');</action>
- </item>
- <item id="notBegins">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_BEGIN"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_NOT_BEGIN" encode="javascript"/>', 'not_begin');</action>
- </item>
- <item id="notEnds">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_END"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_NOT_END" encode="javascript"/>', 'not_end');</action>
- </item>
- <item id="notMatches">
- <text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_MATCH"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_STRING_NOT_MATCH" encode="javascript"/>', 'not_match');</action>
- </item>
- </itemGroup>
- </items>
- </flyout>
- </out:when>
- <out:when test="$operatorDomain='numeric'">
- <flyout id="operatorPopup" height="10">
- <items>
- <itemGroup id="operatorGroup">
- <item id="greaterThan">
- <text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_GT"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_NUMERIC_GT" encode="javascript"/>', 'greater_than');</action>
- </item>
- <item id="lessThan">
- <text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_LT"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_NUMERIC_LT" encode="javascript"/>', 'less_than');</action>
- </item>
- <item id="greaterThanEqualTo">
- <text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_GTE"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_NUMERIC_GTE" encode="javascript"/>', 'greater_than_equal');</action>
- </item>
- <item id="lessThanEqualTo">
- <text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_LTE"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_NUMERIC_LTE" encode="javascript"/>', 'less_than_equal');</action>
- </item>
- <item id="equal">
- <text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_EQ"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_NUMERIC_EQ" encode="javascript"/>', 'equal');</action>
- </item>
- <item id="notEqual">
- <text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_NEQ"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_NUMERIC_NEQ" encode="javascript"/>', 'not_equal');</action>
- </item>
- <item id="between">
- <text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_BT"/>
- </text>
- <action>setOperator('<xts:string id="IDS_CUSTSUB_NUMERIC_BT" encode="javascript"/>', 'between');</action>
- </item>
- </itemGroup>
- </items>
- </flyout>
- </out:when>
- </out:choose>
- </out:variable>
- <out:call-template name="renderPopup">
- <out:with-param name="flyoutXML">
- <out:copy-of select="$operatorPopup"/>
- </out:with-param>
- <out:with-param name="controlID">operator_span</out:with-param>
- </out:call-template>
- <script type="text/javascript">
- var a11y_messages = new Object;
- function init() {
- setAriaLabelMessages('perfPattern_high');
- setAriaLabelMessages('perfPattern_medium');
- setAriaLabelMessages('perfPattern_low');
- }
- function setAriaLabelMessages(sPerfPattern) {
- if (sPerfPattern == 'perfPattern_high') {
- var aria_label_high_0_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_AVERAGE" encode="javascript"/>';
- var aria_label_high_1_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_GOOD" encode="javascript"/>';
- var aria_label_high_0_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_POOR" encode="javascript"/>';
- var aria_label_high_1_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_AVERAGE" encode="javascript"/>';
- addA11yMessages('m_sub_perfPattern_high_0',aria_label_high_0_lower,aria_label_high_0_upper);
- addA11yMessages('m_sub_perfPattern_high_1',aria_label_high_1_lower,aria_label_high_1_upper);
-
- document.pform.m_sub_perfPattern_high_0.setAttribute('aria-label',aria_label_high_0_upper);
- document.pform.m_sub_perfPattern_high_1.setAttribute('aria-label',aria_label_high_1_upper);
- } else if (sPerfPattern == 'perfPattern_medium') {
- var aria_label_medium_0_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_AVERAGE" encode="javascript"/>';
- var aria_label_medium_1_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_GOOD" encode="javascript"/>';
- var aria_label_medium_2_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_AVERAGE" encode="javascript"/>';
- var aria_label_medium_3_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_POOR" encode="javascript"/>';
- var aria_label_medium_0_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_POOR" encode="javascript"/>';
- var aria_label_medium_1_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_AVERAGE" encode="javascript"/>';
- var aria_label_medium_2_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_GOOD" encode="javascript"/>';
- var aria_label_medium_3_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_AVERAGE" encode="javascript"/>';
-
- addA11yMessages('m_sub_perfPattern_medium_0',aria_label_medium_0_lower,aria_label_medium_0_upper);
- addA11yMessages('m_sub_perfPattern_medium_1',aria_label_medium_1_lower,aria_label_medium_1_upper);
- addA11yMessages('m_sub_perfPattern_medium_2',aria_label_medium_2_lower,aria_label_medium_2_upper);
- addA11yMessages('m_sub_perfPattern_medium_3',aria_label_medium_3_lower,aria_label_medium_3_upper);
-
- document.pform.m_sub_perfPattern_medium_0.setAttribute('aria-label',aria_label_medium_0_upper);
- document.pform.m_sub_perfPattern_medium_1.setAttribute('aria-label',aria_label_medium_1_upper);
- document.pform.m_sub_perfPattern_medium_2.setAttribute('aria-label',aria_label_medium_2_upper);
- document.pform.m_sub_perfPattern_medium_3.setAttribute('aria-label',aria_label_medium_3_upper);
- } else if (sPerfPattern == 'perfPattern_low') {
- var aria_label_low_0_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_GOOD" encode="javascript"/>';
- var aria_label_low_1_lower = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_BELOW_INDICATE_AVERAGE" encode="javascript"/>';
- var aria_label_low_0_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_LOWER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_AVERAGE" encode="javascript"/>';
- var aria_label_low_1_upper = '<xts:string id="IDS_CUSTSUB_CONDITION_A11Y_ENTER_UPPER_BOUNDARY" encode="javascript"><xts:param name="measureName"><out:value-of select="$measureName"/></xts:param></xts:string>. <xts:string id="IDS_CUSTSUB_CONDITION_A11Y_VALUES_ABOVE_INDICATE_POOR" encode="javascript"/>';
-
- addA11yMessages('m_sub_perfPattern_low_0',aria_label_low_0_lower,aria_label_low_0_upper);
- addA11yMessages('m_sub_perfPattern_low_1',aria_label_low_1_lower,aria_label_low_1_upper);
-
- document.pform.m_sub_perfPattern_low_0.setAttribute('aria-label',aria_label_low_0_upper);
- document.pform.m_sub_perfPattern_low_1.setAttribute('aria-label',aria_label_low_1_upper);
- }
- }
- function addA11yMessages(inputId,lowerMessage,upperMessage) {
- var holder = new Object;
- holder.lower=lowerMessage;
- holder.upper=upperMessage;
- a11y_messages[inputId]=holder;
- }
- function setAriaLabelText(inputTextBoxId,upper) {
- var holder=a11y_messages[inputTextBoxId];
- var label="";
- if (upper) {
- label = holder.upper;
- }
- else {
- label = holder.lower;
- }
- var inputEle = document.getElementById(inputTextBoxId);
- inputEle.setAttribute('aria-label',label);
- }
- function _getEventType(e) {
- var evtobj = window.event? event : e;
- return evtobj;
- }
-
- function _getEventKey(e) {
- if (typeof(e.keyCode) == 'number' && e.keyCode != 0) return e.keyCode;
- if (typeof(e.charCode) == 'number' && e.charCode != 0) return e.charCode;
- return 0;
- }
-
- function getConditionType()
- {
- var metric_type_radio_buttons = document.getElementsByName('m_sub_type');
- var metric_type = 'nonMetric';
- for (var i = 0; i < metric_type_radio_buttons.length; i++) {
- if (metric_type_radio_buttons[i].checked) {
- metric_type = metric_type_radio_buttons[i].value;
- }
- }
- return metric_type;
- }
-
- function conditionValidate()
- {
- var metric_type = getConditionType();
-
- var return_value = false;
- if (metric_type == 'nonMetric') {
- return_value = nonMetricConditionValidate();
- } else {
- return_value = metricConditionValidate();
- }
- // this selects the already selected PerfPattern - thereby disabling
- // the other inputs for other patterns before submitting
- if (return_value) {
- selectPerfPattern();
- }
-
- return return_value;
- }
-
- function nonMetricConditionValidate()
- {
- // have to check the conditions
- var v_sMeasureValue = document.getElementsByName('m_sub_measure_value')[0].value;
- var v_sMeasureValue1 = document.getElementsByName('m_sub_measure_value1')[0].value;
- var v_bBetween = (document.getElementsByName('m_sub_operation')[0].value == 'between');
- var v_sDomain = document.getElementsByName('m_subData_dtype_domain')[0].value;
-
- if (v_sMeasureValue.length == 0 || v_sMeasureValue1.length==0 && v_bBetween) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_NO_VALUE" encode="javascript"/>');
- return false;
- }
-
- // only do further checks if we're in the numeric domain
- <out:if test="/root/env/param[@name='m_subData_dtype_domain'] = 'numeric' ">
- // convert each measure value into a number - alert if it fails
- if (!isValidNumber(v_sMeasureValue) || !isValidNumber(v_sMeasureValue1) && v_bBetween) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_NON_NUMERIC_VALUE" encode="javascript"/>');
- return false;
- }
-
- // now need to get the actual values
- v_fMeasureValue = v_sMeasureValue * 1;
- v_fMeasureValue1= v_sMeasureValue1 * 1;
- if (isNaN(v_fMeasureValue) || isNaN(v_fMeasureValue1) && v_bBetween) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_NON_NUMERIC_VALUE" encode="javascript"/>');
- return false;
- }
-
- if (v_bBetween && v_fMeasureValue > v_fMeasureValue1) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_INVALID_ORDER" encode="javascript"/>');
- return false;
- }
- </out:if>
- return true;
- }
-
- function metricConditionValidate()
- {
- // get the value of the selected perfPattern
- var v_sPerfPattern = document.getElementsByName('m_sub_perfPattern')[0].value;
- // this gives the prefix to the variables
- var size = 0;
- if (v_sPerfPattern == 'perfPattern_high') {
- size = 2;
- } else if (v_sPerfPattern == 'perfPattern_medium') {
- size = 4;
- } else if (v_sPerfPattern == 'perfPattern_low') {
- size = 2;
- }
-
- for (var i = 0; i < size-1; i++) {
- var v_sMeasureValue = document.getElementsByName('m_sub_'+v_sPerfPattern+'_'+i)[0].value;
- var v_sMeasureValue1 = document.getElementsByName('m_sub_'+v_sPerfPattern+'_'+(i+1))[0].value;
-
- // have to check that the field is a number and in sequence
- if (v_sMeasureValue.length == 0 || v_sMeasureValue1.length==0) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_NO_VALUE" encode="javascript"/>');
- return false;
- }
-
- // convert each measure value into a number - alert if it fails
- if (!isValidNumber(v_sMeasureValue) || !isValidNumber(v_sMeasureValue1)) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_NON_NUMERIC_VALUE" encode="javascript"/>');
- return false;
- }
-
- // now need to get the actual values
- v_fMeasureValue = v_sMeasureValue * 1;
- v_fMeasureValue1= v_sMeasureValue1 * 1;
- if (isNaN(v_fMeasureValue) || isNaN(v_fMeasureValue1)) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_NON_NUMERIC_VALUE" encode="javascript"/>');
- return false;
- }
-
- if (v_fMeasureValue > v_fMeasureValue1) {
- // send the alert
- alert('<xts:string id="IDS_CUSTSUB_CONDITION_THRESHOLD_ORDER" encode="javascript"/>');
- return false;
- }
- }
- return true;
- }
-
- function isValidNumber(v_sString) {
- return /^[-+]?\d+(\.\d+)?$/.test(v_sString);
- }
-
- function updateSubMeasureLabelAriaLabels() {
- var v_sMeasureValue = document.getElementById('m_sub_measure_value').value;
- var v_sMeasureValue1 = document.getElementById('m_sub_measure_value1').value;
- var sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_GT" encode="javascript"/>';
- var sValue = document.getElementsByName('m_sub_operation')[0].value;
- var ariaLabelValue="";
- switch(sValue) {
- case 'greater_than':
- sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_GT" encode="javascript"/>';
- break;
- case 'less_than':
- sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_LT" encode="javascript"/>';
- break;
- case 'greater_than_equal':
- sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_GTE" encode="javascript"/>';
- break;
- case 'less_than_equal':
- sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_LTE" encode="javascript"/>';
- break;
- case 'equal':
- sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_EQ" encode="javascript"/>';
- break;
- case 'not_equal':
- sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_NEQ" encode="javascript"/>';
- break;
- case 'between':
- sDisplay = '<xts:string id="IDS_CUSTSUB_A11Y_BT" encode="javascript"/>';
- break;
- }
-
- //set the aria label(read by JAWS)
- if (sValue == 'between') {
- ariaLabelValue = '<out:value-of select="$measureName"/> '+sDisplay+'. '+v_sMeasureValue+' <xts:string id="IDS_CUSTSUB_A11Y_THRESHOLDONE_AND_THRESHOLDTWO" encode="javascript"/> '+v_sMeasureValue1+'. <xts:string id="IDS_CUSTSUB_A11Y_PRESS_ENTER_TO_SELECT_OPERATOR" encode="javascript"/>';
- }
- else {
- ariaLabelValue = '<out:value-of select="$measureName"/> '+sDisplay+'. '+v_sMeasureValue+'. <xts:string id="IDS_CUSTSUB_A11Y_PRESS_ENTER_TO_SELECT_OPERATOR" encode="javascript"/>';
- }
-
- //set the aria-label attribute
- document.getElementById('operator_table').setAttribute('aria-label',ariaLabelValue);
- }
-
- function setOperator(sDisplay, sValue)
- {
- // set the value into the hidden input - this value we want to persist
- document.getElementsByName('m_sub_operation')[0].value = sValue;
- // alter the display to the selected element
- document.getElementsByName('operator_text')[0].innerHTML = sDisplay;
- document.getElementById('operator_text_disabled').innerHTML = sDisplay;
- // alter the tooltip as well to be the name of the current operator
- document.getElementsByName('operator_dropdown')[0].alt = sDisplay;
- document.getElementsByName('operator_dropdown')[0].title = sDisplay;
-
- // have to show/hide elements if the operator is 'between'
- if (sValue == 'between') {
- document.getElementsByName('betweenHidingSpan')[0].style.display = 'block';
- if (document.all) {
- // IE just uses block
- document.getElementsByName('betweenHidingRow')[0].style.display = 'block';
- document.getElementsByName('betweenHidingRow')[0].setAttribute('aria-hidden','false');
- }
- else {
- document.getElementsByName('betweenHidingRow')[0].style.display = 'table-row';
- document.getElementsByName('betweenHidingRow')[0].setAttribute('aria-hidden','false');
- }
- } else {
- document.getElementsByName('betweenHidingSpan')[0].style.display = 'none';
- document.getElementsByName('betweenHidingRow')[0].style.display = 'none';
-
- //set aria states for screen readers
- document.getElementsByName('betweenHidingSpan')[0].setAttribute('aria-hidden','true');
- document.getElementsByName('betweenHidingRow')[0].setAttribute('aria-hidden','true');
- }
- updateSubMeasureLabelAriaLabels();
- }
- function selectPerfPattern()
- {
- var selectedPerfPattern = "";
- for (var i = 0; i < document.pform.m_sub_perfPattern.options.length; i++) {
- var option = document.pform.m_sub_perfPattern.options[i];
- if (option.selected) {
- selectedPerfPattern = option.value;
- if (document.all) {
- // IE just uses block
- document.getElementsByName(option.value)[0].style.display = 'block';
- document.getElementsByName(option.value)[0].setAttribute('aria-hidden','false');
- }
- else {
- document.getElementsByName(option.value)[0].style.display = 'table-row';
- document.getElementsByName(option.value)[0].setAttribute('aria-hidden','false');
- }
- }
- else {
- document.getElementsByName(option.value)[0].style.display = 'none';
- document.getElementsByName(option.value)[0].setAttribute('aria-hidden','true');
- }
- }
- // have to disable variables depending on what is selected
- setDisablePerfPatternHigh(selectedPerfPattern != 'perfPattern_high');
- setDisablePerfPatternMedium(selectedPerfPattern != 'perfPattern_medium');
- setDisablePerfPatternLow(selectedPerfPattern != 'perfPattern_low');
- }
-
- function selectDelivery(sDeliveryON, sDeliveryOFF)
- {
- var deliveryOn = document.getElementsByName(sDeliveryON);
- var deliveryOff = document.getElementsByName(sDeliveryOFF);
- if (deliveryOn != null && deliveryOn.length > 0) {
- // turn the one on
- if (document.all) {
- // IE just uses block
- deliveryOn[0].style.display = 'block';
- deliveryOn[0].setAttribute('aria-hidden','false');
- }
- else {
- deliveryOn[0].style.display = 'table-row';
- deliveryOn[0].setAttribute('aria-hidden','false');
- }
- }
- if (deliveryOff != null && deliveryOff.length > 0) {
- // turn the one off
- deliveryOff[0].style.display = 'none';
- deliveryOn[0].setAttribute('aria-hidden','true');
- }
- }
-
- function setDisablePerfPatternHigh(v_bDisable)
- {
- // high performance pattern
- document.pform.m_sub_perfPattern_high_0.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_high_1.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_high_0_include.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_high_1_include.disabled = v_bDisable;
-
- //set aria states for screen readers
- document.pform.m_sub_perfPattern_high_0.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_perfPattern_high_1.setAttribute('aria-disabled',v_bDisable);
-
- // also toggle the tab index property for the up/down
- var tabIndexValue = 0;
- if (v_bDisable) {
- tabIndexValue = -1;
- }
- document.getElementsByName('m_sub_perfPattern_high_0_include_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_high_1_include_img')[0].tabIndex = tabIndexValue;
-
- /*document.getElementsByName('m_sub_perfPattern_high_0_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_high_1_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_high_2_img')[0].tabIndex = tabIndexValue;*/
- }
-
- function setDisablePerfPatternMedium(v_bDisable)
- {
- // medium performance pattern
- document.pform.m_sub_perfPattern_medium_0.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_medium_1.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_medium_2.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_medium_3.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_medium_0_include.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_medium_1_include.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_medium_2_include.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_medium_3_include.disabled = v_bDisable;
-
- //set aria states for screen readers
- document.pform.m_sub_perfPattern_medium_0.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_perfPattern_medium_1.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_perfPattern_medium_2.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_perfPattern_medium_3.setAttribute('aria-disabled',v_bDisable);
-
- // also toggle the tab index property for the up/down
- var tabIndexValue = 0;
- if (v_bDisable) {
- tabIndexValue = -1;
- }
- document.getElementsByName('m_sub_perfPattern_medium_0_include_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_medium_1_include_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_medium_2_include_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_medium_3_include_img')[0].tabIndex = tabIndexValue;
-
- /*document.getElementsByName('m_sub_perfPattern_medium_0_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_medium_1_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_medium_2_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_medium_3_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_medium_4_img')[0].tabIndex = tabIndexValue;*/
- }
-
- function setDisablePerfPatternLow(v_bDisable)
- {
- document.pform.m_sub_perfPattern_low_0.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_low_1.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_low_0_include.disabled = v_bDisable;
- document.pform.m_sub_perfPattern_low_1_include.disabled = v_bDisable;
-
- //set aria states for screen readers
- document.pform.m_sub_perfPattern_low_0.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_perfPattern_low_1.setAttribute('aria-disabled',v_bDisable);
-
- // also toggle the tab index property for the up/down
- var tabIndexValue = 0;
- if (v_bDisable) {
- tabIndexValue = -1;
- }
- document.getElementsByName('m_sub_perfPattern_low_0_include_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_low_1_include_img')[0].tabIndex = tabIndexValue;
- /*document.getElementsByName('m_sub_perfPattern_low_0_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_low_1_img')[0].tabIndex = tabIndexValue;
- document.getElementsByName('m_sub_perfPattern_low_2_img')[0].tabIndex = tabIndexValue;*/
- }
-
- function setDisableNonMetric(v_bDisable)
- {
- document.pform.m_sub_measure_value.disabled = v_bDisable;
- document.pform.m_sub_measure_value1.disabled = v_bDisable;
- document.pform.m_sub_measure_value_inclusive.disabled = v_bDisable;
- document.pform.m_sub_measure_value_inclusive1.disabled = v_bDisable;
-
- //set aria states for screen readers
- document.pform.m_sub_measure_value.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_measure_value1.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_measure_value_inclusive.setAttribute('aria-disabled',v_bDisable);
- document.pform.m_sub_measure_value_inclusive1.setAttribute('aria-disabled',v_bDisable);
-
- // also toggle the tab index property for the up/down
- var tabIndexValue = 0;
- if (v_bDisable) {
- tabIndexValue = -1;
- }
- document.getElementsByName('operator_table')[0].tabIndex = tabIndexValue;
-
- setVisible('operator_text',!v_bDisable);
- setVisible('operator_text_disabled',v_bDisable);
- }
-
- function setVisible(id,isVisible) {
- var value = "";
- if (isVisible) {
- if (document.all) {
- // IE just uses block
- value = 'block';
- }
- else {
- value = 'table-row';
- }
- } else {
- value = 'none';
- }
-
- document.getElementById(id).style.display=value;
- }
- function toggleMetric(vb_metric)
- {
- setDisableNonMetric(vb_metric);
- // what's the value of the perf pattern variable
- var v_sPerfPattern = document.getElementsByName('m_sub_perfPattern')[0].value;
- if (v_sPerfPattern == 'perfPattern_high') {
- setDisablePerfPatternHigh(!vb_metric);
- }
-
- if (v_sPerfPattern == 'perfPattern_medium') {
- setDisablePerfPatternMedium(!vb_metric);
- }
-
- // low performance pattern
- if (v_sPerfPattern == 'perfPattern_low') {
- setDisablePerfPatternLow(!vb_metric);
- }
-
- // then have to toggle the
- document.pform.m_sub_perfPattern.disabled = !vb_metric;
- document.pform.m_sub_perfPattern.setAttribute('aria-disabled',!vb_metric);
-
- // also have to switch the display for delivery
- if (vb_metric) {
- selectDelivery('metric_delivery', 'nonMetric_delivery');
- } else {
- selectDelivery('nonMetric_delivery', 'metric_delivery');
- }
-
- // also disable the context
- doContextCheckboxes(vb_metric);
-
- //set the aria-checked attribute
- var nmChecked = document.getElementById('m_sub_type_nonMetric');
- var mChecked = document.getElementById('m_sub_type_metric');
- nmChecked.setAttribute('aria-checked',nmChecked.checked);
- mChecked.setAttribute('aria-checked',mChecked.checked);
- }
-
- function handleContextCheckbox(evt)
- {
- return true;
-
- /* Fix defect 11383: Not able to change selected Context on Watch Rule when setup to send alert based on thresholds.
- // As this method always will return TRUE then we may not need it, so just commented out fully.
- var returnValue = true;
- var conditionType = getConditionType();
- if (conditionType == 'metric') {
- returnValue = false;
- }
- return returnValue;
- */
- }
-
- function doContextCheckboxes(vb_metric)
- {
- var readOnly = vb_metric;
- <!-- build all the select values for all the rows -->
- <out:for-each select="/root/env/param[starts-with(@name, 'm_subData_defaultValue_row')]">
- <out:variable name="selectName">
- <out:value-of select="concat('m_sub_',substring-after(@name, 'm_subData_defaultValue_'))"/>
- </out:variable>
- if (vb_metric) {
- document.pform.<out:value-of select="$selectName"/>.checked = vb_metric;
- document.pform.<out:value-of select="$selectName"/>.setAttribute('aria-checked',vb_metric);
- }
- </out:for-each>
- <!-- build all the select values for all the columns -->
- <out:for-each select="/root/env/param[starts-with(@name, 'm_subData_defaultValue_column')]">
- <out:variable name="selectName">
- <out:value-of select="concat('m_sub_',substring-after(@name, 'm_subData_defaultValue_'))"/>
- </out:variable>
- if (vb_metric) {
- document.pform.<out:value-of select="$selectName"/>.checked = vb_metric;
- document.pform.<out:value-of select="$selectName"/>.setAttribute('aria-checked',vb_metric);
- }
- </out:for-each>
- <!-- build all the select values for all the sections -->
- <out:for-each select="/root/env/param[starts-with(@name, 'm_subData_defaultValue_section')]">
- <out:variable name="selectName">
- <out:value-of select="concat('m_sub_',substring-after(@name, 'm_subData_defaultValue_'))"/>
- </out:variable>
- if (vb_metric) {
- document.pform.<out:value-of select="$selectName"/>.checked = vb_metric;
- document.pform.<out:value-of select="$selectName"/>.setAttribute('aria-checked',vb_metric);
- }
- </out:for-each>
- }
-
- function nonMetricClicked()
- {
- toggleMetric(false);
- }
-
- function metricClicked()
- {
- toggleMetric(true);
- }
- var TOGGLENORMAL = 0;
- var TOGGLE = 1;
- var PRESSED = 2;
- var OVER = 3;
- var NOTOVER = 4;
-
- function handleRange(imageObject, type)
- {
- var id = imageObject.id;
- //the hidden var
- var inputId = id.slice(0,-4);
- //the text box
- var inputTextBoxId = id.slice(0,-12);
- // get the element
- var inputControl = document.getElementsByName(inputId)[0];
- if (inputControl.value == "true") {
- switch (type) {
- case TOGGLENORMAL:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_down_normal.gif'))"/>";
- inputControl.value = "false";
- setAriaLabelText(inputTextBoxId,false);
- break;
- case TOGGLE:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_down_rollover.gif'))"/>";
- inputControl.value = "false";
- setAriaLabelText(inputTextBoxId,false);
- break;
- case PRESSED:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_up_pressed.gif'))"/>";
- break;
- case OVER:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_up_rollover.gif'))"/>";
- break;
- case NOTOVER:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_up_normal.gif'))"/>";
- break;
- }
- } else if (inputControl.value == "false") {
- switch (type) {
- case TOGGLENORMAL:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_up_normal.gif'))"/>";
- inputControl.value = "true";
- setAriaLabelText(inputTextBoxId,true);
- break;
- case TOGGLE:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_up_rollover.gif'))"/>";
- inputControl.value = "true";
- setAriaLabelText(inputTextBoxId,true);
- break;
- case PRESSED:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_down_pressed.gif'))"/>";
- break;
- case OVER:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_down_rollover.gif'))"/>";
- break;
- case NOTOVER:
- imageObject.src = "<out:value-of select="xtsext:javascriptencode(concat($webcontent, '/portal/images/watchwiz/rangestyle_down_normal.gif'))"/>";
- break;
- }
- }
- // have to update the alt/title attributes
- if (inputControl.value == 'false') {
- imageObject.alt = '<xts:string id="IDS_CUSTSUB_CONDITION_PERF_LOWER" encode="javascript"/>';
- imageObject.title = '<xts:string id="IDS_CUSTSUB_CONDITION_PERF_LOWER" encode="javascript"/>';
- } else {
- imageObject.alt = '<xts:string id="IDS_CUSTSUB_CONDITION_PERF_HIGHER" encode="javascript"/>';
- imageObject.title = '<xts:string id="IDS_CUSTSUB_CONDITION_PERF_HIGHER" encode="javascript"/>';
- }
-
- return true;
- }
-
- function operator_span_handler(evt) {
- var returnValue = false;
- var conditionType = getConditionType();
- if (conditionType == 'nonMetric') {
- returnValue = CCPopupMenu.dropDown(evt,0,0,'operatorPopup');
- }
- return returnValue;
- }
-
- function range_handler(imageObject, type)
- {
- var returnValue = false;
- var conditionType = getConditionType();
- if (conditionType == 'metric') {
- returnValue = handleRange(imageObject, type);
- }
- return returnValue;
- }
- </script>
- <table border="0" cellspacing="0" cellpadding="3" width="100%">
- <tr>
- <td width="100%">
- <table border="0" cellspacing="0" cellpadding="1">
- <tr><td></td></tr>
- <tr>
- <td>
- <table border="0">
- <tr>
- <td class="formText">
- <out:value-of select="/root/env/param[@name='m_subData_measure_name']"/>
- </td>
- <td>
- <div id="operator_span" name="operator_span" style="position: relative; height:20px;z-index: 2">
- <out:variable name="ariaMessage">
- <xts:string id="IDS_CUSTSUB_A11Y_PRESS_ENTER_TO_SELECT_OPERATOR"/>
- </out:variable>
- <out:variable name="greaterThan">
- <xts:string id="IDS_CUSTSUB_A11Y_GT"/>
- </out:variable>
- <table id="operator_table" name="operator_table" summary="" cellspacing="0" cellpadding="0"
- style="position: relative; cursor:pointer;"
- accessKey="1"
- onkeypress="return operator_span_handler(event);"
- onclick="return operator_span_handler(event);">
- <out:attribute name="aria-label">
- <out:value-of select="concat(/root/env/param[@name='m_subData_measure_name'],' ',$greaterThan,' ',/root/env/param[@name='m_sub_measure_value'],'. ',$ariaMessage)"/>
- </out:attribute>
- <out:attribute name="tabIndex">
- <out:choose>
- <out:when test="/root/env/param[@name='m_sub_type']='nonMetric' or not(/root/env/param[@name='m_sub_type'])">
- <out:text>0</out:text>
- </out:when>
- <out:otherwise>-1</out:otherwise>
- </out:choose>
- </out:attribute>
- <tr>
- <td class="formText" nowrap="true">
- <!--a id="operator_text" name="operator_text" style="text-decoration:underline" onmouseover="window.status='';return true;" onmouseout="window.status='';return true;" href="#">
- <out:value-of select="$conditionText"/>
- </a-->
- <span id="operator_text_disabled" class="inactiveHRef">
- <out:if test="/root/env/param[@name='m_sub_type']!='metric'">
- <out:attribute name="style">
- <out:text>display:none;</out:text>
- </out:attribute>
- </out:if>
- <out:value-of select="$conditionText"/>
- </span>
- <span id="operator_text" name="operator_text" class="pathLink" >
- <out:choose>
- <out:when test="/root/env/param[@name='m_sub_type']='metric'">
- <out:attribute name="style">
- <out:text>text-decoration:underline;display:none</out:text>
- </out:attribute>
- </out:when>
- <out:otherwise>
- <out:attribute name="style">
- <out:text>text-decoration:underline</out:text>
- </out:attribute>
- </out:otherwise>
- </out:choose>
- <out:value-of select="$conditionText"/>
- </span>
- </td>
- <td nowrap="true" valign="top">
- <img id="operator_dropdown" style="margin-top:3px;margin-left:5px;" class="flyOutLabelImage" align="absmiddle" name="operator_dropdown" src="{'{$skin_shared_images}'}dropdown_arrow.gif" title="{'{$conditionText}'}" alt="{'{$conditionText}'}"/>
- <input type="hidden" name="m_sub_operation" id="m_sub_operation">
- <out:attribute name="value">
- <out:value-of select="$conditionEnum"/>
- </out:attribute>
- </input>
- </td>
- </tr>
- </table>
- </div>
- </td>
- <td>
- <!--
- Fixed in defect360901: The range value boxes are not visible in high contrast mode in the "Threshold boundaries" area.
- Removed attribute class="portlet-menu" from <input> item.
- -->
- <input role="textbox" aria-multiline="false" type="text" name="m_sub_measure_value" id="m_sub_measure_value" style="padding-left:4px; padding-right:4px" size="12" onblur="updateSubMeasureLabelAriaLabels();">
- <out:attribute name="value">
- <out:value-of select="/root/env/param[@name='m_sub_measure_value']"/>
- </out:attribute>
- <out:if test="$metricWatchRule">
- <out:attribute name="disabled"><out:text>disabled</out:text></out:attribute>
- </out:if>
- </input>
- </td>
- <td class="formText">
- <span name="betweenHidingSpan" id="betweenHidingSpan">
- <out:if test="not($conditionEnum = 'between')">
- <out:attribute name="style">
- <out:text>display:none;</out:text>
- </out:attribute>
- <out:attribute name="aria-hidden"><out:text>true</out:text></out:attribute>
- </out:if>
- <input type="checkbox" role="checkbox" id="m_sub_measure_value_inclusive" name="m_sub_measure_value_inclusive" value="true">
- <out:if test="/root/env/param[@name='m_sub_measure_value_inclusive'] and /root/env/param[@name='m_sub_measure_value_inclusive']='true' ">
- <out:attribute name="checked">
- <out:text>checked</out:text>
- </out:attribute>
- <out:attribute name="aria-checked"><out:text>true</out:text></out:attribute>
- </out:if>
- <out:if test="$metricWatchRule">
- <out:attribute name="disabled"><out:text>disabled</out:text></out:attribute>
- </out:if>
- </input>
- <label for="m_sub_measure_value_inclusive">
- <xts:string id="IDS_CUSTSUB_INCLUDE_VALUE"/>
- </label>
- </span>
- </td>
- </tr>
- <tr name="betweenHidingRow" id="betweenHidingRow">
- <out:if test="not($conditionEnum = 'between')">
- <out:attribute name="style">
- <out:text>display:none;</out:text>
- </out:attribute>
- <out:attribute name="aria-hidden"><out:text>true</out:text></out:attribute>
- </out:if>
- <td/>
- <td class="formText" align="left">
- <out:text>
- <xts:string id="IDS_CUSTSUB_BETWEEN_AND"/>
- </out:text>
- </td>
- <td>
- <!--
- Fixed in defect360901: The range value boxes are not visible in high contrast mode in the "Threshold boundaries" area.
- Removed attribute class="portlet-menu" from <input> item.
- -->
- <input role="textbox" aria-multiline="false" type="text" name="m_sub_measure_value1" id="m_sub_measure_value1" style="padding-left:4px; padding-right:4px" size="12" onblur="updateSubMeasureLabelAriaLabels();">
- <out:attribute name="value">
- <out:value-of select="/root/env/param[@name='m_sub_measure_value1']"/>
- </out:attribute>
- <out:if test="$metricWatchRule">
- <out:attribute name="disabled"><out:text>disabled</out:text></out:attribute>
- </out:if>
- </input>
- </td>
- <td class="formText">
- <input role="checkbox" type="checkbox" id="m_sub_measure_value_inclusive1" name="m_sub_measure_value_inclusive1" value="true">
- <out:if test="/root/env/param[@name='m_sub_measure_value_inclusive1'] and /root/env/param[@name='m_sub_measure_value_inclusive1']='true' ">
- <out:attribute name="checked">
- <out:text>checked</out:text>
- </out:attribute>
- <out:attribute name="aria-checked"><out:text>true</out:text></out:attribute>
- </out:if>
- <out:if test="$metricWatchRule">
- <out:attribute name="disabled"><out:text>disabled</out:text></out:attribute>
- </out:if>
- </input>
- <label for="m_sub_measure_value_inclusive1">
- <xts:string id="IDS_CUSTSUB_INCLUDE_VALUE"/>
- </label>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <out:if test="$operatorDomain='string'">
- <tr>
- <td>
- <table border="0" cellspacing="0" cellpadding="0" role="presentation">
- <tr>
- <td class="formText">
- <input role="checkbox" type="checkbox" id="m_sub_case_insensitive" name="m_sub_case_insensitive" value="true">
- <out:if test="/root/env/param[@name='m_sub_case_insensitive'] and /root/env/param[@name='m_sub_case_insensitive']='true' ">
- <out:attribute name="checked">
- <out:text>checked</out:text>
- </out:attribute>
- <out:attribute name="aria-checked"><out:text>true</out:text></out:attribute>
- </out:if>
- <out:if test="$metricWatchRule">
- <out:attribute name="disabled"><out:text>disabled</out:text></out:attribute>
- </out:if>
- </input>
- <label for="m_sub_case_insensitive">
- <xts:string id="IDS_CUSTSUB_CASE_INSENSITIVE"/>
- </label>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </out:if>
- <tr>
- <td nowrap="nowrap">
- <img height="5" width="1" src="{'{$webcontent}'}/images/space.gif" role="presentation" style="display:block;"/>
- </td>
- </tr>
- <tr>
-
- </tr>
- </table>
- </td>
- </tr>
- </table>
-
- </td>
- </tr>
- <tr>
- <td>
- <input type="radio" name="m_sub_type" id="m_sub_type_metric" value="metric" onclick="metricClicked()" role="radio">
- <out:if test="/root/env/param[@name='m_sub_type']='metric'">
- <out:attribute name="checked">
- <out:text>checked</out:text>
- </out:attribute>
- <out:attribute name="aria-checked">
- <out:text>true</out:text>
- </out:attribute>
- </out:if>
- </input>
- </td>
- <td class="formText" nowrap="nowrap">
- <label for="m_sub_type_metric">
- <out:text><xts:string id="IDS_CUSTSUB_CONDITION_THRESHOLDS"/></out:text>
- </label>
- </td>
- </tr>
- <tr>
- <td>
- </td>
- <td>
- <table border="0" cellspacing="0" cellpadding="3" width="100%" role="presentation">
- <tr>
- <td width="100%">
- <table border="0" cellspacing="0" cellpadding="1" role="presentation">
- <tr>
- </tr>
- <tr>
- <td>
- <table border="0" role="presentation">
- <tr>
- <td id="conditionPerfPatternId" class="formLabel">
- <xts:string id="IDS_CUSTSUB_CONDITION_PERF_PATTERN"/>
- </td>
- </tr>
- <tr>
- <td>
- <select name="m_sub_perfPattern" class="formText" onchange="selectPerfPattern()" role="listbox" aria-labelledby="conditionPerfPatternId">
- <out:if test="not($metricWatchRule)">
- <out:attribute name="disabled"><out:text>disabled</out:text></out:attribute>
- </out:if>
- <option value="perfPattern_high" role="option">
- <out:if test="/root/env/param[@name='m_sub_perfPattern']='perfPattern_high' or not(/root/env/param[@name='m_sub_perfPattern'])">
- <out:attribute name="selected"><out:text>selected</out:text></out:attribute>
- <out:attribute name="aria-selected"><out:text>true</out:text></out:attribute>
- </out:if>
- <xts:string id="IDS_CUSTSUB_CONDITION_PERF_PATTERN1"/>
- </option>
- <option value="perfPattern_medium" role="option">
- <out:if test="/root/env/param[@name='m_sub_perfPattern']='perfPattern_medium' ">
- <out:attribute name="selected"><out:text>selected</out:text></out:attribute>
- <out:attribute name="aria-selected"><out:text>true</out:text></out:attribute>
- </out:if>
- <xts:string id="IDS_CUSTSUB_CONDITION_PERF_PATTERN2"/>
- </option>
- <option value="perfPattern_low" role="option">
- <out:if test="/root/env/param[@name='m_sub_perfPattern']='perfPattern_low' ">
- <out:attribute name="selected"><out:text>selected</out:text></out:attribute>
- <out:attribute name="aria-selected"><out:text>true</out:text></out:attribute>
- </out:if>
- <xts:string id="IDS_CUSTSUB_CONDITION_PERF_PATTERN3"/>
- </option>
- </select>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td>
- </td>
- <td>
- <table border="0" cellspacing="0" cellpadding="3" width="100%" role="presentation">
- <tr>
- <td width="100%">
- <table border="0" cellspacing="0" cellpadding="1" role="presentation">
- <tr>
- </tr>
- <tr>
- <td>
- <table border="0" role="presentation">
- <tr>
- <td class="formLabel">
- <xts:string id="IDS_CUSTSUB_CONDITION_BOUNDARIES"/>
- </td>
- </tr>
- <tr>
- <td>
- <xsl:call-template name="buildThresholdTable">
- <xsl:with-param name="div_id"><xsl:text>perfPattern_high</xsl:text></xsl:with-param>
- <xsl:with-param name="template">
- <row id="high" image="traffic_7_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_GOOD"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_GOOD"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_GOOD"/>
- </out:attribute>
- </row>
- <row id="med" image="traffic_5_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_AVERAGE"/>
- </out:attribute>
- </row>
- <row id="low" image="traffic_3_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_POOR"/>
- </out:attribute>
- </row>
- </xsl:with-param>
- </xsl:call-template>
- <xsl:call-template name="buildThresholdTable">
- <xsl:with-param name="div_id"><xsl:text>perfPattern_medium</xsl:text></xsl:with-param>
- <xsl:with-param name="template">
- <row id="low" image="traffic_3_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_POOR"/>
- </out:attribute>
- </row>
- <row id="med" image="traffic_5_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_AVERAGE"/>
- </out:attribute>
- </row>
- <row id="high" image="traffic_7_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_GOOD"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_GOOD"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_GOOD"/>
- </out:attribute>
- </row>
- <row id="med" image="traffic_5_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_AVERAGE"/>
- </out:attribute>
- </row>
- <row id="low" image="traffic_3_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_POOR"/>
- </out:attribute>
- </row>
- </xsl:with-param>
- </xsl:call-template>
- <xsl:call-template name="buildThresholdTable">
- <xsl:with-param name="div_id"><xsl:text>perfPattern_low</xsl:text></xsl:with-param>
- <xsl:with-param name="template">
- <row id="low" image="traffic_3_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_POOR"/>
- </out:attribute>
- </row>
- <row id="med" image="traffic_5_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_AVERAGE"/>
- </out:attribute>
- </row>
- <row id="high" image="traffic_7_med.gif">
- <out:attribute name="alt"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_GOOD"/></out:attribute>
- <out:attribute name="title"><xts:string id="IDS_CUSTSUB_CONDITION_PERF_GOOD"/></out:attribute>
- <out:attribute name="aria-label">
- <xts:string id="IDS_CUSTSUB_A11Y_STATUS_GOOD"/>
- </out:attribute>
- </row>
- </xsl:with-param>
- </xsl:call-template>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td>
- <table cellpadding="0" cellspacing="0" border="0" role="presentation">
- <tr>
- <td class="formLabel" nowrap="nowrap">
- <out:text>
- <xts:string id="IDS_CUSTSUB_CONDITION_CONTEXT"/>
- </out:text>
- </td>
- </tr>
- <tr>
- <td>
- <table border="0" cellpadding="0" cellspacing="0" role="presentation">
- <!-- build all the select values for all the rows -->
- <out:for-each select="/root/env/param[starts-with(@name, 'm_subData_defaultValue_row')]">
- <out:sort select="substring-after(@name, 'm_subData_defaultValue_row')" order="ascending" data-type="number"/>
- <out:call-template name="buildSelect"/>
- </out:for-each>
- <!-- build all the select values for all the columns -->
- <out:for-each select="/root/env/param[starts-with(@name, 'm_subData_defaultValue_column')]">
- <out:sort select="substring-after(@name, 'm_subData_defaultValue_column')" order="ascending" data-type="number"/>
- <out:call-template name="buildSelect"/>
- </out:for-each>
- <!-- build all the select values for all the sections -->
- <out:for-each select="/root/env/param[starts-with(@name, 'm_subData_defaultValue_section')]">
- <out:sort select="substring-after(@name, 'm_subData_defaultValue_section')" order="ascending" data-type="number"/>
- <out:call-template name="buildSelect"/>
- </out:for-each>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </xsl:template>
-
- <xsl:template name="buildThresholdTable">
- <xsl:param name="template"/>
- <xsl:param name="div_id"/>
-
- <div id="{$div_id}" name="{$div_id}">
- <out:attribute name="style">
- <out:choose>
- <out:when test="not(/root/env/param[@name='m_sub_perfPattern'])">
- <out:if test="'{$div_id}' != 'perfPattern_high' ">
- <out:text>display:none</out:text>
- </out:if>
- </out:when>
- <out:otherwise>
- <out:if test="/root/env/param[@name='m_sub_perfPattern'] != '{$div_id}'">
- <out:text>display:none</out:text>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:attribute>
- <out:attribute name="aria-hidden">
- <out:choose>
- <out:when test="not(/root/env/param[@name='m_sub_perfPattern'])">
- <out:if test="'{$div_id}' != 'perfPattern_high' ">
- <out:text>true</out:text>
- </out:if>
- </out:when>
- <out:otherwise>
- <out:if test="/root/env/param[@name='m_sub_perfPattern'] != '{$div_id}'">
- <out:text>true</out:text>
- </out:if>
- </out:otherwise>
- </out:choose>
- </out:attribute>
- <table width="420px" cellspacing="0" cellpadding="0" border="0" class="cctable" role="presentation">
- <thead id="Header">
- <tr class="tableHeader" style="padding:3px">
- <td nowrap="" height="10" width="30%" valign="center" style="padding:3px" class="tableTitle">
- <xts:string id="IDS_CUSTSUB_CONDITION_MEASURE"/>
- </td>
- <td height="15" width="1" role="presentation">
- <table cellspacing="0" cellpadding="0" border="0">
- <tbody>
- <tr>
- <td class="tableHeaderDivider">
- <img height="15" width="1" alt="" src="{'{$webcontent}'}/images/space.gif" role="presentation"/>
- </td>
- </tr>
- </tbody>
- </table>
- </td>
- <td nowrap="" height="10" width="35%" valign="center" style="padding:3px" class="tableTitle">
- <xts:string id="IDS_CUSTSUB_CONDITION_RANGE"/>
- </td>
- <td height="15" width="1" align="center" role="presentation">
- <table cellspacing="0" cellpadding="0" border="0">
- <tbody>
- <tr>
- <td class="tableHeaderDivider">
- <img height="15" width="1" alt="" src="{'{$webcontent}'}/images/space.gif"/>
- </td>
- </tr>
- </tbody>
- </table>
- </td>
- <td nowrap="" height="10" width="35%" valign="center" style="padding:3px" class="tableTitle">
- <xts:string id="IDS_CUSTSUB_CONDITION_STATUS"/>
- </td>
- </tr>
- </thead>
- <tbody>
- <tr>
- <td class="formText" align="left" style="padding-left:3px"><out:value-of select="/root/env/param[@name='m_subData_measure_name']"/></td>
- <td></td>
- <td class="formText" align="right" valign="bottom"><xts:string id="IDS_CUSTSUB_CONDITION_MAX_VALUE"/></td>
- <td valign="bottom"><img alt="" style="display:block;" width="23" src="{'{$webcontent}'}/portal/images/watchwiz/range_tic.gif" role="presentation"/></td>
- </tr>
- <xsl:variable name="count_rows" select="count($template/row)"/>
- <xsl:for-each select="$template/row">
- <xsl:variable name="pos" select="position()"/>
- <xsl:variable name="id" select="number($count_rows - $pos)"/>
- <xsl:if test="not(position()=1)">
- <tr role="presentation">
- <td></td>
- <td></td>
- <td></td>
- <td><img alt="" style="display:block;" width="23" height="6" src="{'{$webcontent}'}/portal/images/watchwiz/range_tic_mid.gif"/></td>
- </tr>
- </xsl:if>
- <tr>
- <td role="presentation"></td>
- <td role="presentation"></td>
- <td align="right" valign="top">
- <xsl:if test="not(position()=1)">
- <table cellpadding="0" cellspacing="0" role="presentation">
- <tr>
- <td>
- <!--
- Fixed in defect360901: The range value boxes are not visible in high contrast mode in the "Threshold boundaries" area.
- Removed attribute class="portlet-menu" from <input> item.
- -->
- <input role="textbox" aria-multiline="false" type="text" name="m_sub_{$div_id}_{$id}" id="m_sub_{$div_id}_{$id}" style="padding-left:4px; padding-right:4px" size="12">
- <out:attribute name="value">
- <out:value-of select="/root/env/param[@name='m_sub_{$div_id}_{$id}']"/>
- </out:attribute>
- <out:if test="not($metricWatchRule)">
- <out:attribute name="disabled"><out:text>disabled</out:text></out:attribute>
- </out:if>
- </input>
- </td>
- <td>
- <img role="button" id="m_sub_{$div_id}_{$id}_include_img" name="m_sub_{$div_id}_{$id}_include_img" alt="" style="display:block;" onclick="return range_handler(this,TOGGLE);" onmouseover="return range_handler(this,OVER);" onmouseout="return range_handler(this,NOTOVER)" onkeypress="if (_getEventKey(_getEventType(event)) == 32) range_handler(this,TOGGLENORMAL);" onmousedown="return range_handler(this,PRESSED);">
- <out:attribute name="src">
- <out:choose>
- <out:when test="not(/root/env/param[@name='m_sub_{$div_id}_{$id}_include']) or /root/env/param[@name='m_sub_{$div_id}_{$id}_include']='true' ">
- <out:value-of select="concat($webcontent, '/portal/images/watchwiz/rangestyle_up_normal.gif')"/>
- </out:when>
- <out:when test="/root/env/param[@name='m_sub_{$div_id}_{$id}_include']='down' ">
- <out:value-of select="concat($webcontent, '/portal/images/watchwiz/rangestyle_down_normal.gif')"/>
- </out:when>
- </out:choose>
- </out:attribute>
- <out:attribute name="alt">
- <out:choose>
- <out:when test="not(/root/env/param[@name='m_sub_{$div_id}_{$id}_include']) or /root/env/param[@name='m_sub_{$div_id}_{$id}_include']='true' "><xts:string id="IDS_CUSTSUB_CONDITION_PERF_HIGHER"/></out:when>
- <out:when test="/root/env/param[@name='m_sub_{$div_id}_{$id}_include']='down' "><xts:string id="IDS_CUSTSUB_CONDITION_PERF_LOWER"/></out:when>
- </out:choose>
- </out:attribute>
- <out:attribute name="title">
- <out:choose>
- <out:when test="not(/root/env/param[@name='m_sub_{$div_id}_{$id}_include']) or /root/env/param[@name='m_sub_{$div_id}_{$id}_include']='true' "><xts:string id="IDS_CUSTSUB_CONDITION_PERF_HIGHER"/></out:when>
- <out:when test="/root/env/param[@name='m_sub_{$div_id}_{$id}_include']='down' "><xts:string id="IDS_CUSTSUB_CONDITION_PERF_LOWER"/></out:when>
- </out:choose>
- </out:attribute>
- <!--out:attribute name="tabIndex">
- <out:choose>
- <out:when test="$metricWatchRule">
- <out:text>0</out:text>
- </out:when>
- <out:otherwise>
- <out:text>-1</out:text>
- </out:otherwise>
- </out:choose>
- </out:attribute-->
- </img>
- <input id="m_sub_{$div_id}_{$id}_include" name="m_sub_{$div_id}_{$id}_include" type="hidden">
- <out:attribute name="value">
- <out:choose>
- <out:when test="/root/env/param[@name='m_sub_{$div_id}_{$id}_include']">
- <out:value-of select="/root/env/param[@name='m_sub_{$div_id}_{$id}_include']"/>
- </out:when>
- <out:otherwise>
- <out:text>true</out:text>
- </out:otherwise>
- </out:choose>
- </out:attribute>
- </input>
- </td>
- </tr>
- </table>
- </xsl:if>
- </td>
- <td align="right" role="presentation">
- <table cellpadding="0" cellspacing="0">
- <tr><td><img alt="" style="display:block;" src="{'{$webcontent}'}/portal/images/watchwiz/range_top.gif"/></td></tr>
- <tr><td><img alt="" style="display:block;" width="23px" height="15px" src="{'{$webcontent}'}/portal/images/watchwiz/range_resize.gif"/></td></tr>
- <tr><td><img alt="" style="display:block;" src="{'{$webcontent}'}/portal/images/watchwiz/range_middle.gif"/></td></tr>
- <tr><td><img alt="" style="display:block;" width="23px" height="15px" src="{'{$webcontent}'}/portal/images/watchwiz/range_resize.gif"/></td></tr>
- <tr><td><img alt="" style="display:block;" src="{'{$webcontent}'}/portal/images/watchwiz/range_bottom.gif"/></td></tr>
- </table>
- </td>
- <td>
- <img role="img" id="m_sub_{$div_id}_{$id}_img" name="m_sub_{$div_id}_{$id}_img" alt="{@alt}" title="{@title}" src="{'{$webcontent}'}/portal/images/watchwiz/{@image}">
- <!--out:attribute name="tabIndex">
- <out:choose>
- <out:when test="$metricWatchRule">
- <out:text>0</out:text>
- </out:when>
- <out:otherwise>
- <out:text>-1</out:text>
- </out:otherwise>
- </out:choose>
- </out:attribute-->
- <xsl:copy-of select="./*"/>
- </img>
- </td>
- </tr>
- </xsl:for-each>
- <tr role="presentation">
- <td></td>
- <td></td>
- <td class="formText" align="right" valign="top"><xts:string id="IDS_CUSTSUB_CONDITION_MIN_VALUE"/></td>
- <td valign="top"><img alt="" style="display:block;" width="23" src="{'{$webcontent}'}/portal/images/watchwiz/range_tic.gif"/></td>
- </tr>
- </tbody>
- </table>
- </div>
- </xsl:template>
- <!--
- Template - rss:conditionDisplayTemplates - addition templates needed by conditionDisplayCode
- -->
- <xsl:template match="rdsad:conditionDisplayTemplates">
- <out:template name="buildSelect">
- <out:variable name="selectName">
- <out:value-of select="concat('m_sub_',substring-after(@name, 'm_subData_defaultValue_'))"/>
- </out:variable>
- <out:variable name="dataName">
- <out:value-of select="@name"/>
- </out:variable>
- <tr>
- <td nowrap="nowrap" class="formText">
- <input role="checkbox" type="checkbox" value="true" onclick="return handleContextCheckbox(event)" tabindex="0">
- <out:attribute name="name">
- <out:value-of select="$selectName"/>
- </out:attribute>
- <out:attribute name="id">
- <out:value-of select="$selectName"/>
- </out:attribute>
- <out:if test="/root/env/param[@name=$selectName] and /root/env/param[@name=$selectName]='true' ">
- <out:attribute name="checked">
- <out:text>checked</out:text>
- </out:attribute>
- <out:attribute name="aria-checked">
- <out:text>true</out:text>
- </out:attribute>
- </out:if>
- </input>
- </td>
- <td nowrap="nowrap" class="formText">
- <label>
- <out:attribute name="for">
- <out:value-of select="$selectName"/>
- </out:attribute>
- <out:value-of select="/root/env/param[@name=$dataName]" disable-output-escaping="yes"/>
- </label>
- </td>
- </tr>
- <tr>
- <td nowrap="nowrap">
- <img height="5" width="1" src="{'{$webcontent}'}/images/space.gif" role="presentation" style="display:block;"/>
- </td>
- </tr>
- </out:template>
- </xsl:template>
- <!--
- Template - rss:delivery
- -->
- <xsl:template match="rdsad:deliveryDisplay">
- <out:variable name="emailAsAttachment" select="key('env-param', 'm_ro_emailAsAttachment') = 'true'"/>
- <out:variable name="emailAsURL" select="key('env-param', 'm_ro_emailAsURL') = 'true'"/>
- <out:variable name="email_checked" select="/root/env/param[@name='m_subData_emailCB']='true' "/>
- <out:variable name="newsitem_checked" select="/root/env/param[@name='m_subData_newsitemCB']='true' "/>
- <out:variable name="task_checked" select="/root/env/param[@name='m_subData_taskCB']='true' "/>
- <out:variable name="the-object" select="/root/newsitemPath/*[local-name()='queryResponse']/*"/>
- <out:variable name="start-at-path">
- <out:choose>
- <out:when test="starts-with($the-object/*[local-name()='searchPath'], key('session-param', 'e_hp')) or (starts-with($the-object/*[local-name()='searchPath'], '~'))">
- <out:value-of select="concat(key('session-param', 'e_hp'),'/folder')"/>
- </out:when>
- <out:when test="starts-with($the-object/*[local-name()='searchPath'],'/content')">
- <out:value-of select="$defaultContentRoot"/>
- </out:when>
- </out:choose>
- </out:variable>
- <out:variable name="newsitem_path_link">
- <cf:do-the-path-link>
- <cf:param name="familytree">/root/newsitemPath/*[local-name()='queryResponse']/*/*[local-name()='ancestors']</cf:param>
- <cf:param name="familymember">/root/newsitemPath/*[local-name()='queryResponse']/*/*[local-name()='defaultName']</cf:param>
- <cf:param name="home">
- <out:value-of select="$start-at-path"/>
- </cf:param>
- <cf:param name="onlyAncestors">false</cf:param>
- </cf:do-the-path-link>
- </out:variable>
- <out:variable name="displayEmail">
- <xsl:choose>
- <xsl:when test="./display/option[@name='email']/visible">
- <xsl:copy-of select="./display/option[@name='email']/visible/*"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="'false'"/>
- </xsl:otherwise>
- </xsl:choose>
- </out:variable>
- <out:variable name="metricDisplay" select="boolean(/root/env/param[@name='m_sub_type'] = 'metric')"/>
- <script type="text/javascript">
-
- function removeDeliveryCBS()
- {
- var watch_rule_type = document.getElementsByName('m_sub_type');
- var type = 'nonMetric';
- if (watch_rule_type[0].type == 'hidden') {
- type = watch_rule_type[0].value;
- } else {
- for (var i = 0; i < watch_rule_type.length; i++) {
- if (watch_rule_type[i].checked) {
- type = watch_rule_type[i].value;
- }
- }
- }
-
- if (type == 'metric') {
- <out:if test="$displayEmail = 'true' ">
- document.pform.m_subData_emailCB.disabled = true;
- document.pform.m_subData_emailCB.setAttribute('aria-disabled',true);
- </out:if>
- document.pform.m_subData_newsitemCB.disabled = true;
- document.pform.m_subData_taskCB.disabled = true;
- document.pform.m_subData_newsitemCB.setAttribute('aria-disabled',true);
- document.pform.m_subData_taskCB.setAttribute('aria-disabled',true);
- } else {
- <out:if test="$displayEmail = 'true' ">
- document.pform.m_subData_emailCB_poor.disabled = true;
- document.pform.m_subData_emailCB_poor.setAttribute('aria-disabled',true);
- </out:if>
- document.pform.m_subData_newsitemCB_poor.disabled = true;
- document.pform.m_subData_taskCB_poor.disabled = true;
- document.pform.m_subData_newsitemCB_poor.setAttribute('aria-disabled',true);
- document.pform.m_subData_taskCB_poor.setAttribute('aria-disabled',true);
- <out:if test="$displayEmail = 'true' ">
- document.pform.m_subData_emailCB_average.disabled = true;
- document.pform.m_subData_emailCB_average.setAttribute('aria-disabled',true);
- </out:if>
- document.pform.m_subData_newsitemCB_average.disabled = true;
- document.pform.m_subData_taskCB_average.disabled = true;
- document.pform.m_subData_newsitemCB_average.setAttribute('aria-disabled',true);
- document.pform.m_subData_taskCB_average.setAttribute('aria-disabled',true);
-
- <out:if test="$displayEmail = 'true' ">
- document.pform.m_subData_emailCB_good.disabled = true;
- document.pform.m_subData_emailCB_good.setAttribute('aria-disabled',true);
- </out:if>
- document.pform.m_subData_newsitemCB_good.disabled = true;
- document.pform.m_subData_taskCB_good.disabled = true;
- document.pform.m_subData_newsitemCB_good.setAttribute('aria-disabled',true);
- document.pform.m_subData_taskCB_good.setAttribute('aria-disabled',true);
- }
- }
-
- function deliveryValidate()
- {
- var watch_rule_type = document.getElementsByName('m_sub_type');
- var type = 'nonMetric';
- if (watch_rule_type[0].type == 'hidden') {
- type = watch_rule_type[0].value;
- } else {
- for (var i = 0; i < watch_rule_type.length; i++) {
- if (watch_rule_type[i].checked) {
- type = watch_rule_type[i].value;
- }
- }
- }
-
- // find out if we're displaying a metric or not
- <out:choose>
- <out:when test="$displayEmail = 'true' ">
- if (type == 'metric') {
- // have to check that both of the delivery options are not checked
- var email_delivery = (document.pform.m_subData_emailCB_poor.checked==true ||
- document.pform.m_subData_emailCB_average.checked==true ||
- document.pform.m_subData_emailCB_good.checked==true);
- var newsitem_delivery = (document.pform.m_subData_newsitemCB_poor.checked==true ||
- document.pform.m_subData_newsitemCB_average.checked==true ||
- document.pform.m_subData_newsitemCB_good.checked==true);
- var task_delivery = (document.pform.m_subData_taskCB_poor.checked==true ||
- document.pform.m_subData_taskCB_average.checked==true ||
- document.pform.m_subData_taskCB_good.checked==true);
-
- if (!(email_delivery || newsitem_delivery || task_delivery)) {
- alert("<xts:string id="IDS_CUSTSUB_DELIVERY_NO_DELIVERY_METHOD" encode="javascript"/>");
- }
-
- return email_delivery || newsitem_delivery || task_delivery;
- } else {
- // have to check that both of the delivery options are not checked
- var email_delivery = (document.pform.m_subData_emailCB.checked==true);
- var newsitem_delivery = (document.pform.m_subData_newsitemCB.checked==true);
- var task_delivery = (document.pform.m_subData_taskCB.checked==true);
-
- if (!(email_delivery || newsitem_delivery || task_delivery)) {
- alert("<xts:string id="IDS_CUSTSUB_DELIVERY_NO_DELIVERY_METHOD" encode="javascript"/>");
- }
-
- return email_delivery || newsitem_delivery || task_delivery;
- }
- </out:when>
- <out:otherwise>
- if (type == 'metric') {
- // only have to test that the newsitem delivery option is checked
- var newsitem_delivery = (document.pform.m_subData_newsitemCB_poor.checked==true ||
- document.pform.m_subData_newsitemCB_average.checked==true ||
- document.pform.m_subData_newsitemCB_good.checked==true);
- var task_delivery = (document.pform.m_subData_taskCB_poor.checked==true ||
- document.pform.m_subData_taskCB_average.checked==true ||
- document.pform.m_subData_taskCB_good.checked==true);
-
- if (!(newsitem_delivery || task_delivery )) {
- alert("<xts:string id="IDS_CUSTSUB_DELIVERY_NO_DELIVERY_METHOD" encode="javascript"/>");
- }
-
- return newsitem_delivery || task_delivery;
- } else {
- // only have to test that the newsitem delivery option is checked
- var newsitem_delivery = (document.pform.m_subData_newsitemCB.checked==true);
- var task_delivery = (document.pform.m_subData_taskCB.checked==true);
-
- if (!(newsitem_delivery || task_delivery)) {
- alert("<xts:string id="IDS_CUSTSUB_DELIVERY_NO_DELIVERY_METHOD" encode="javascript"/>");
- }
-
- return newsitem_delivery || task_delivery;
- }
- </out:otherwise>
- </out:choose>
- }
- </script>
-
- <xsl:call-template name="buildDeliveryTable">
- <xsl:with-param name="metricDisplay" select="true()"/>
- <xsl:with-param name="div_id" select="'metric'"/>
- </xsl:call-template>
- <xsl:call-template name="buildDeliveryTable">
- <xsl:with-param name="metricDisplay" select="false()"/>
- <xsl:with-param name="div_id" select="'nonMetric'"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template name="buildDeliveryTable">
- <xsl:param name="metricDisplay"/>
- <xsl:param name="div_id"/>
- <span>
- <table width="100%" cellspacing="0" cellpadding="2" border="0" class="cctable" name="{$div_id}_delivery" id="{$div_id}_delivery" role="grid">
- <out:attribute name="style">
- <out:if test="not(/root/env/param[@name='m_sub_type'] = '{$div_id}') ">
- <out:text>display:none</out:text>
- </out:if>
- </out:attribute>
- <out:attribute name="aria-hidden">
- <out:if test="not(/root/env/param[@name='m_sub_type'] = '{$div_id}') ">
- <out:text>true</out:text>
- </out:if>
- </out:attribute>
- <thead id="Header" role="rowgroup">
- <tr class="tableHeader" role="row">
- <th nowrap="" height="10" width="20%" valign="center" style="padding-left: 2px; padding-top: 2px; color: #444444; font-weight: bold;" colspan="2" role="columnheader"><xts:string id="IDS_TITLE_ALERT_ALERTS"/></th>
- <th height="15" width="1" role="presentation">
- <table cellspacing="0" cellpadding="0" border="0">
- <tbody>
- <tr>
- <td class="tableHeaderDivider">
- <img height="15" width="1" alt="" src="{'{$webcontent}'}/images/space.gif"/>
- </td>
- </tr>
- </tbody>
- </table>
- </th>
- <th nowrap="" height="10" width="70%" valign="center" style="padding-left: 2px; padding-top: 2px; color: #444444; font-weight: bold;" role="columnheader"><xts:string id="IDS_TITLE_ALERT_DETAILS"/></th>
- <th height="15" width="1" role="presentation">
- <table cellspacing="0" cellpadding="0" border="0" role="presentation">
- <tbody>
- <tr>
- <td class="tableHeaderDivider">
- <img height="15" width="1" alt="" src="{'{$webcontent}'}/images/space.gif"/>
- </td>
- </tr>
- </tbody>
- </table>
- </th>
- <th nowrap="" height="10" width="100" align="right" style="padding-left: 2px; padding-top: 4px; color: #444444; font-weight: bold; display:block;" role="columnheader">
- <xts:string id="IDS_TITLE_ALERT_ALERT"/>
- </th>
- <th width="16" role="columnheader">
- <xsl:choose>
- <xsl:when test="$metricDisplay">
- <img height="16" width="16" role="img">
- <out:attribute name="src"><out:value-of select="$webcontent"/>/portal/images/watchwiz/traffic_3_sm.gif</out:attribute>
- <out:attribute name="alt">
- <xts:string id="IDS_CUSTSUB_CONDITION_PERF_POOR"/>
- </out:attribute>
- </img>
- </xsl:when>
- <xsl:otherwise>
- <script language="JavaScript">
- function selectAllOptions()
- {
- var checked = document.pform.m_subData_allOptions.checked;
-
- if (document.pform.m_subData_emailCB) {
- document.pform.m_subData_emailCB.checked = checked;
- document.pform.m_subData_emailCB.setAttribute('aria-checked',checked);
- }
- document.pform.m_subData_newsitemCB.checked = checked;
- document.pform.m_subData_taskCB.checked = checked;
- document.pform.m_subData_newsitemCB.setAttribute('aria-checked',checked);
- document.pform.m_subData_taskCB.setAttribute('aria-checked',checked);
- }
- </script>
- <utml:input role="checkbox" type="checkbox" name="m_subData_allOptions" value="true" utml:track="false" utml:update="false" onclick="selectAllOptions();">
- <out:attribute name="aria-label">
- <xts:string id="IDS_TITLE_ALERT_A11Y_ALERTS"/>
- </out:attribute>
- </utml:input>
- </xsl:otherwise>
- </xsl:choose>
- </th>
- <th width="16" role="columnheader">
- <xsl:if test="$metricDisplay">
- <img role="img" height="16" width="16">
- <out:attribute name="src"><out:value-of select="$webcontent"/>/portal/images/watchwiz/traffic_5_sm.gif</out:attribute>
- <out:attribute name="alt">
- <xts:string id="IDS_CUSTSUB_CONDITION_PERF_AVERAGE"/>
- </out:attribute>
- </img>
- </xsl:if>
- </th>
- <th width="16" role="columnheader">
- <xsl:if test="$metricDisplay">
- <img role="img" height="16" width="16">
- <out:attribute name="src"><out:value-of select="$webcontent"/>/portal/images/watchwiz/traffic_7_sm.gif</out:attribute>
- <out:attribute name="alt">
- <xts:string id="IDS_CUSTSUB_CONDITION_PERF_GOOD"/>
- </out:attribute>
- </img>
- </xsl:if>
- </th>
- <th nowrap="" height="10" width="100" role="presentation" style="display:block;"></th>
- </tr>
- </thead>
- <tbody role="rowgroup">
- <xsl:for-each select="./display/option">
- <xsl:call-template name="buildRow">
- <xsl:with-param name="metricDisplay" select="$metricDisplay"/>
- </xsl:call-template>
- </xsl:for-each>
- </tbody>
- </table>
- </span>
- </xsl:template>
-
- <xsl:template name="buildRow">
- <xsl:param name="metricDisplay"/>
- <xsl:variable name="option_name" select="./@name"/>
- <out:variable name="displayRow_{@name}">
- <xsl:copy-of select="./visible/child::node()"/>
- </out:variable>
- <out:if test="$displayRow_{@name} = 'true'">
- <xsl:variable name="id" select="generate-id(.)"/>
- <tr style="height: 1px;" role="row">
- <out:variable name="title">
- <xsl:copy-of select="./title/child::node()"/>
- </out:variable>
- <td valign="middle" align="left" width="1" role="gridcell">
- <xsl:copy-of select="./icon/child::node()"/>
- </td>
- <td nowrap="" height="10" valign="center" class="tableText" width="20%" role="gridcell">
- <span><out:value-of select="$title"/></span>
- </td>
- <td height="15" width="1" role="presentation">
- <img height="15" width="1" alt="" src="{'{$webcontent}'}/images/space.gif"/>
- </td>
- <td nowrap="" height="10" valign="center" class="tableText" role="gridcell">
- <span>
- <xsl:if test="./description/path">
- <xsl:copy-of select="./description/path/child::node()"/>
- </xsl:if>
- <xsl:copy-of select="./description/text/child::node()"/>
- <img height="5" width="10" alt="" src="{'{$webcontent}'}/images/space.gif" role="presentation"/>
- <script language="JavaScript">
- function utmlA_<xsl:value-of select="$id"/>()
- {
- <xsl:value-of select="./link/href"/>
- document.pform.m.value = '<xsl:copy-of select="./link/target/child::node()"/>';
- <xsl:if test="not($metricDisplay)">
- <xsl:value-of select="concat('document.pform.m_subData_', $option_name, 'CB.checked=true;')"/>
- <xsl:value-of select="concat('document.pform.m_subData_', $option_name, 'CB.setAttribute("aria-checked",true)')"/>
- </xsl:if>
- document.pform.submit();
- }
- </script>
- <a role="link" formname="pform" href="javascript:utmlA_{$id}()" onmouseout="window.status='';return true;" onmouseover="window.status='';return true;">
- <out:attribute name="aria-label">
- <xsl:copy-of select="./link/ariaLabel/child::node()"/>
- </out:attribute>
- <xsl:copy-of select="./link/text/child::node()"/>
- </a>
- </span>
- </td>
- <td height="15" width="1" role="presentation">
- <img height="15" width="1" alt="" src="{'{$webcontent}'}/images/space.gif"/>
- </td>
- <td nowrap="" height="10" width="100" align="right" style="padding-left: 2px; padding-top: 2px;" class="tableTitle" role="presentation"></td>
- <td width="16" role="gridcell">
- <xsl:choose>
- <xsl:when test="$metricDisplay">
- <utml:input role="checkbox" type="checkbox" name="m_subData_{$option_name}CB_poor" value="true" utml:track="false">
- <out:attribute name="aria-label"><xts:string id="IDS_CHECKBOX_ALERT_POOR"/></out:attribute>
- </utml:input>
- </xsl:when>
- <xsl:otherwise>
- <utml:input role="checkbox" type="checkbox" name="m_subData_{$option_name}CB" value="true" utml:track="false">
- <out:attribute name="aria-label">
- <out:value-of select="$title"/> <xts:string id="IDS_TITLE_ALERT_A11Y_ALERT"/>
- </out:attribute>
- </utml:input>
- </xsl:otherwise>
- </xsl:choose>
- </td>
- <td width="16" role="gridcell">
- <xsl:if test="$metricDisplay">
- <utml:input role="checkbox" type="checkbox" name="m_subData_{$option_name}CB_average" value="true" utml:track="false">
- <out:attribute name="aria-label"><xts:string id="IDS_CHECKBOX_ALERT_AVERAGE"/></out:attribute>
- </utml:input>
- </xsl:if>
- </td>
- <td width="16" role="gridcell">
- <xsl:if test="$metricDisplay">
- <utml:input role="checkbox" type="checkbox" name="m_subData_{$option_name}CB_good" value="true" utml:track="false">
- <out:attribute name="aria-label"><xts:string id="IDS_CHECKBOX_ALERT_GOOD"/></out:attribute>
- </utml:input>
- </xsl:if>
- </td>
- <td nowrap="" height="10" width="100" role="presentation"></td>
- </tr>
- </out:if>
- </xsl:template>
-
- <xsl:template match="rdsad:enumTemplates">
- <!-- template to convert the operator into the long string form -->
- <out:template name="conditionEnumLongValue">
- <out:param name="conditionEnum"/>
- <out:choose>
- <out:when test="$conditionEnum = 'greater_than'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_GT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'less_than'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_LT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'greater_than_equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_GTE"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'less_than_equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_LTE"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_EQ"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_NEQ"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'between'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_BT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'contains'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_CONTAINS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'begins'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_BEGINS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'ends'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_ENDS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'match'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_MATCH"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_contains'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_CONTAINS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_begin'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_BEGIN"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_end'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_END"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_match'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_MATCH"/>
- </out:text>
- </out:when>
- </out:choose>
- </out:template>
- <!-- template to convert the operator into the long string form -->
- <out:template name="conditionEnumShortValue">
- <out:param name="conditionEnum"/>
- <out:choose>
- <out:when test="$conditionEnum = 'greater_than'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_GT_SHORT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'less_than'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_LT_SHORT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'greater_than_equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_GTE_SHORT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'less_than_equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_LTE_SHORT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_EQ_SHORT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_equal'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_NEQ_SHORT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'between'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_NUMERIC_BT_SHORT"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'contains'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_CONTAINS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'begins'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_BEGINS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'ends'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_ENDS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'match'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_MATCH"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_contains'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_CONTAINS"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_begin'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_BEGIN"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_end'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_END"/>
- </out:text>
- </out:when>
- <out:when test="$conditionEnum = 'not_match'">
- <out:text>
- <xts:string id="IDS_CUSTSUB_STRING_NOT_MATCH"/>
- </out:text>
- </out:when>
- </out:choose>
- </out:template>
- </xsl:template>
- <xsl:template match="*">
- <xsl:copy>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </xsl:copy>
- </xsl:template>
- </xsl:stylesheet>
|