123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221 |
- /*
- *+------------------------------------------------------------------------+
- *| Licensed Materials - Property of IBM
- *|
- *| IBM Cognos Products: PS
- *|
- *| (C) Copyright IBM Corp. 2011
- *|
- *| US Government Users Restricted Rights - Use, duplication or
- *| disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- *|
- *+------------------------------------------------------------------------+
- */
- function C_XmlSerializer(n){
- this.m_nRoot=n;
- };
- C_XmlSerializer.prototype.F_ToString=function(){
- var d=this.m_nRoot.nodeType==U_XML.K_iNODE_DOCUMENT?this.m_nRoot:this.m_nRoot.ownerDocument;
- if(d.m_oHALDefaultAttributeLookup){
- this.m_oElements=d.m_oHALDefaultAttributeLookup;
- }else{
- this.m_oElements=C_XmlSerializer.F_ParseDefaultAttributes(d);
- d.m_oHALDefaultAttributeLookup=this.m_oElements;
- }
- this.m_oStringStream=new C_StringStream();
- this.f_serialize(this.m_nRoot);
- return this.m_oStringStream.F_ToString();
- };
- C_XmlSerializer.prototype.f_serializeElement=function(n){
- var _1=n.nodeName;
- var _2=this.m_oElements[_1];
- this.m_oStringStream.F_Write("<");
- this.m_oStringStream.F_Write(_1);
- var nl=n.attributes;
- var _3=nl.length;
- for(var i=0;i<_3;i++){
- var _4=nl.item(i);
- var _5=_4.name;
- var _6=_4.value;
- if(_2&&_2[_5]&&(_2[_5]===_6)){
- continue;
- }
- this.m_oStringStream.F_Write(" ");
- this.m_oStringStream.F_Write(_5);
- this.m_oStringStream.F_Write("=\"");
- this.m_oStringStream.F_Write(this.f_encodeAttributeValue(_6));
- this.m_oStringStream.F_Write("\"");
- }
- var nl=n.selectNodes("* | text() | comment()");
- var _3=nl.length;
- this.f_writeOpeningTagCloseBracket(_1,_3);
- for(var i=0;i<_3;i++){
- var _7=nl.item(i);
- this.f_serialize(_7);
- }
- this.f_writeClosingTag(_1,_3);
- };
- C_XmlSerializer.prototype.f_serialize=function(n){
- switch(n.nodeType){
- case U_XML.K_iNODE_TEXT:
- this.m_oStringStream.F_Write(this.f_encode(n.nodeValue));
- break;
- case U_XML.K_iNODE_COMMENT:
- this.m_oStringStream.F_Write("<!--");
- this.m_oStringStream.F_Write(n.nodeValue);
- this.m_oStringStream.F_Write("-->");
- break;
- case U_XML.K_iNODE_CDATA_SECTION:
- this.m_oStringStream.F_Write("<"+"![CDATA[");
- this.m_oStringStream.F_Write(n.nodeValue);
- this.m_oStringStream.F_Write("]"+"]>");
- break;
- default:
- this.f_serializeElement(n);
- }
- };
- C_XmlSerializer.prototype.f_encode=function(s){
- return s.F_XMLEncode();
- };
- C_XmlSerializer.prototype.f_encodeAttributeValue=function(s){
- return s.F_XMLEncode();
- };
- C_XmlSerializer.prototype.f_writeOpeningTagCloseBracket=function(_8,_9){
- this.m_oStringStream.F_Write((_9>0)?">":"/>");
- };
- C_XmlSerializer.prototype.f_writeClosingTag=function(_a,_b){
- if(_b>0){
- this.m_oStringStream.F_Write("</");
- this.m_oStringStream.F_Write(_a);
- this.m_oStringStream.F_Write(">");
- }
- };
- C_XmlSerializer.F_ParseDefaultAttributes=function(d){
- var _c={};
- if(!d.doctype){
- return _c;
- }
- var _d=d.doctype.xml.split("<!ATTLIST ");
- var _e=_d.length;
- for(var i=1;i<_e;i++){
- var a2=_d[i].split(">");
- var a3=a2[0].split(/\r?\n/);
- if(a3.length>1){
- var _f=a3[0];
- var o={};
- for(var j=0;j<a3.length;j++){
- var a4=a3[j].F_Trim();
- var _10=C_XmlSerializer.f_parseAttributeValue(a4);
- if(_10){
- var _11=a4.split(/\s+/)[0];
- o[_11]=_10;
- }
- }
- _c[_f]=o;
- }
- }
- return _c;
- };
- C_XmlSerializer.f_parseAttributeValue=function(_12){
- var _13=null;
- var _14=_12.F_Trim();
- var _15=_14.lastIndexOf("\"");
- if(_15!=-1){
- _14=_14.substring(0,_15);
- _15=_14.lastIndexOf("\"");
- if(_15!=-1){
- _13=_14.substring(_15+1,_14.length);
- }
- }
- return _13;
- };
- var G_CCHL={};
- G_CCHL.M_oOptions={name:"cchl",path:"",imagePath:""};
- if(window["G_CCHLOptions"]){
- for(var s in G_CCHLOptions){
- G_CCHL.M_oOptions[s]=G_CCHLOptions[s];
- }
- }
- G_HAL.F_AddLibrary("cchl",G_CCHL.M_oOptions);
- G_CCHL.M_sPath=G_HAL.M_oLibraries["cchl"]["path"];
- G_CCHL.M_sImagePath=G_HAL.M_oLibraries["cchl"]["imagePath"]||(G_CCHL.M_sPath+"cchl/images/");
- G_CCHL.M_sProductLocale="";
- G_CCHL.M_sContentLocale="";
- G_CCHL.M_sGatewayURL="";
- G_CCHL.F_Init=function(_16,_17,_18,_19,_1a){
- G_CCHL.M_sProductLocale=_17;
- G_CCHL.M_sContentLocale=_18;
- G_CCHL.M_sGatewayURL=_16;
- if(window["G_ResManager"]){
- G_ResManager.F_SetLocale(_17);
- }
- if(window["G_BusServer"]){
- G_BusServer.F_SetCafContextId(_19);
- G_BusServer.F_SetRoutingServerGroup(_1a);
- }
- };
- G_CCHL.m_oIncludeMacros={includes:{"cchl/C_BusRequest.js":["cchl/G_BusServer.js","hal/C_Error.js"],"cchl/G_BusServer.js":["hal/U_CookieJar.js"],"cchl/C_PromptControl.js":["cchl/C_ParameterValue.js","hal/U_CoolButton.js"],"cchl/C_PromptBaseTextBox.js":["hal/G_ResManager.js","hal/C_ListView.js","cchl/U_PromptInputParser.js","cchl/C_SimpleValue.js","cchl/C_SimpleValue.js"],"cchl/C_PromptRange.js":["cchl/C_PromptBaseTextBox.js"],"cchl/C_PromptTextBox.js":["cchl/C_PromptRange.js"],"cchl/C_PromptBaseDateTextBox.js":["cchl/C_PromptBaseTextBox.js","cchl/C_PromptBaseDateCalendar.js","cchl/dialogs/D_PromptCalendar.js","cchl/C_DateValue.js"],"C_PromptBaseDateCalendar":["cchl/C_DateValue.js"],"cchl/C_PromptDate.js":["cchl/C_PromptBaseDateTextBox.js","cchl/C_PromptRange.js"],"cchl/C_PromptBaseTimeTextBox.js":["cchl/C_PromptBaseTextBox.js","cchl/C_TimeValue.js"],"cchl/C_PromptTime.js":["cchl/C_PromptBaseTimeTextBox.js","cchl/C_PromptClockUI.js","cchl/C_PromptRange.js"],"cchl/C_PromptDateTime.js":["cchl/C_PromptBaseDateTime.js","cchl/C_PromptRange.js"],"cchl/C_PromptBaseDateTime.js":["cchl/C_PromptBaseTimeTextBox.js","cchl/C_PromptClockUI.js","cchl/C_PromptBaseDateTextBox.js","cchl/C_DateTimeValue.js"],"cchl/C_PromptBaseIntervalTextBox.js":["cchl/C_PromptBaseTextBox.js","cchl/C_IntervalValue.js"],"cchl/C_PromptInterval.js":["cchl/C_PromptBaseIntervalTextBox.js","cchl/C_PromptRange.js","cchl/C_IntervalValue.js"],"cchl/C_ListViewRange.js":["hal/G_ResManager.js"],"cchl/C_ListViewConditional.js":["hal/G_ResManager.js","cchl/C_Condition.js"],"cchl/U_PromptInputParser.js":["hal/D_XmlError.js"],"cchl/C_ParameterValue.js":["cchl/U_PromptInputParser.js"],"cchl/dialogs/D_Border.js":["cchl/dialogs/D_Color.js"],"cchl/C_ModelTree.js":["hal/C_TreeView.js"],"cchl/C_ReportRequest.js":["cchl/C_RoutingServerGroupRequest.js"],"cchl/C_AngleChooser.js":["cchl/C_CanvasLink.js"]},prerequisites:{"cchl/C_BusRequest.js":["hal/C_SoapRequest.js"],"cchl/dialogs/D_Color.js":["hal/C_Dialog.js"],"cchl/dialogs/D_Font.js":["hal/C_Dialog.js"],"cchl/dialogs/D_About.js":["hal/C_Dialog.js"],"cchl/dialogs/D_Border.js":["hal/C_Dialog.js"],"cchl/dialogs/D_Margin.js":["hal/C_Dialog.js"],"cchl/dialogs/D_Padding.js":["hal/C_Dialog.js"],"cchl/dialogs/D_Color.js":["hal/C_Dialog.js"],"cchl/dialogs/D_PromptCalendar.js":["hal/C_MultiScriptRequest.js","hal/C_Dialog.js"],"cchl/C_PromptBaseTextBox.js":["cchl/C_PromptBaseControl.js"],"cchl/C_PromptRange.js":["cchl/C_PromptBaseControl.js"],"cchl/C_PromptBaseDateTextBox.js":["cchl/C_PromptBaseControl.js"],"cchl/C_PromptBaseDateCalendar.js":["cchl/C_PromptBaseControl.js"],"cchl/C_PromptTextBox.js":["cchl/C_PromptPublicControl.js"],"cchl/C_PromptDate.js":["cchl/C_PromptPublicControl.js"],"cchl/C_PromptTime.js":["cchl/C_PromptPublicControl.js"],"cchl/C_PromptBaseTimeTextBox.js":["cchl/C_PromptBaseControl.js"],"cchl/C_PromptPublicControl.js":["cchl/C_PromptControl.js"],"cchl/C_PromptBaseControl.js":["cchl/C_PromptControl.js"],"cchl/C_PromptBaseDateTime.js":["cchl/C_PromptBaseControl.js"],"cchl/C_PromptDateTime.js":["cchl/C_PromptPublicControl.js"],"cchl/C_PromptBaseIntervalTextBox.js":["cchl/C_PromptBaseControl.js"],"cchl/C_PromptInterval.js":["cchl/C_PromptPublicControl.js"],"cchl/dialogs/D_PromptDateTime.js":["hal/C_MultiScriptRequest.js","hal/C_Dialog.js"],"cchl/dialogs/D_PromptTextBox.js":["hal/C_MultiScriptRequest.js","hal/C_Dialog.js"],"cchl/dialogs/D_PromptInterval.js":["hal/C_MultiScriptRequest.js","hal/C_Dialog.js"],"cchl/dialogs/D_DetailedMsgBox.js":["hal/C_MultiScriptRequest.js","hal/C_Dialog.js"],"cchl/C_SimpleValue.js":["cchl/C_ParameterValue.js"],"cchl/C_IntervalValue.js":["cchl/C_ParameterValue.js"],"cchl/C_DateValue.js":["cchl/C_ParameterValue.js"],"cchl/C_TimeValue.js":["cchl/C_ParameterValue.js"],"cchl/C_DateTimeValue.js":["cchl/C_ParameterValue.js"],"cchl/C_ModelCache.js":["cchl/C_MetadataRequest.js"],"cchl/C_MetadataRequest.js":["cchl/C_BusRequest.js"]}};
- function C_BusRequest(_1b,_1c,_1d){
- this.F_ConstructBaseClass(_1b,G_CCHL.M_sGatewayURL,_1c);
- this.m_sRequest=_1d;
- this.m_sRequestSoapAction=_1c;
- this.m_docResponse=null;
- this.m_bProcessResponse=true;
- this.m_bServerPrompting=true;
- this.m_sPromptReport="";
- this.m_bAsyncBusRequest=false;
- this.m_sRoutingServerGroup=null;
- this.m_bUseDefaultRoutingServerGroup=false;
- this.m_bIsLoggingOn=false;
- this.m_bIsPrompting=false;
- this.m_sFollowOnRequestSOAPAction=C_BusRequest.K_sSOAPAction_reportService_absolute;
- this.m_sCancelRequestSOAPAction=C_BusRequest.K_sSOAPAction_reportService_control;
- this.m_aNamespaces=[];
- this.F_AddNamespace(C_BusRequest.k_sBIBusNamespaceDecl);
- this.F_AddNamespace(C_BusRequest.k_sBIBusRNSNamespaceDecl);
- };
- C_BusRequest.F_Extends(C_SoapRequest);
- C_BusRequest.K_sPrimaryWaitThreshold=5;
- C_BusRequest.K_sSecondaryWaitThreshold=30;
- C_BusRequest.m_sLastRequest="";
- C_BusRequest.m_sLastResponse="";
- C_BusRequest.m_aBusTracking=[];
- C_BusRequest.F_GetLastRequest=function(){
- return this.m_sLastRequest;
- };
- C_BusRequest.F_GetLastResponse=function(){
- return this.m_sLastResponse;
- };
- C_BusRequest.F_ReleaseAllTracking=function(){
- var _1e=this.m_aBusTracking.length;
- var _1f="<rns1:release>"+"<bus:conversation xsi:type=\"bus:asynchRequest\">"+"</bus:conversation>"+"</rns1:release>";
- for(var i=0;i<_1e;++i){
- var _20=new C_BusRequest(null,C_BusRequest.K_sSOAPAction_reportService_control,_1f);
- _20.m_bAsync=false;
- _20.F_Send();
- }
- };
- C_BusRequest.prototype.F_GetResponse=function(){
- return this.m_docResponse;
- };
- C_BusRequest.prototype.F_IsPrompting=function(){
- return this.m_bIsPrompting;
- };
- C_BusRequest.prototype.F_IsLoggingOn=function(){
- return this.m_bIsLoggingOn;
- };
- C_BusRequest.prototype.F_SetLocale=function(_21,_22){
- this.m_sProductLocale=_21;
- this.m_sContentLocale=_22;
- };
- C_BusRequest.prototype.F_SetNoResponseProcessing=function(){
- this.m_bProcessResponse=false;
- };
- C_BusRequest.prototype.F_SetNoServerPrompting=function(){
- this.m_bServerPrompting=false;
- };
- C_BusRequest.prototype.F_SetRoutingServerGroup=function(_23){
- this.m_sRoutingServerGroup=_23;
- };
- C_BusRequest.prototype.F_SetUseDefaultRoutingServerGroup=function(_24){
- this.m_bUseDefaultRoutingServerGroup=_24;
- };
- C_BusRequest.prototype.F_SetAsyncBusRequest=function(_25,_26,_27,_28,_29){
- this.m_bAsyncBusRequest=true;
- this.m_sWaitMethod=_25;
- this.m_sCancelMethod=_26;
- this.m_sGetOutputMethod=_27;
- this.m_sFollowOnRequestSOAPAction=_28?_28:this.m_sFollowOnRequestSOAPAction;
- this.m_sCancelRequestSOAPAction=_29?_29:this.m_sCancelRequestSOAPAction;
- };
- C_BusRequest.prototype.F_SetPromptReport=function(_2a){
- this.m_sPromptReport=_2a;
- };
- C_BusRequest.F_CreateContext=function(_2b){
- var _2c={};
- _2c.m_eType=_2b;
- return _2c;
- };
- C_BusRequest.K_sSOAPAction_reportService="http://developer.cognos.com/schemas/reportService/1";
- C_BusRequest.K_sSOAPAction_reportService_high="http://developer.cognos.com/schemas/reportService/1.high";
- C_BusRequest.K_sSOAPAction_reportService_absolute="http://developer.cognos.com/schemas/reportService/1.absolute";
- C_BusRequest.K_sSOAPAction_reportService_session="http://developer.cognos.com/schemas/reportService/1.session";
- C_BusRequest.K_sSOAPAction_reportService_control="http://developer.cognos.com/schemas/reportService/1.session";
- C_BusRequest.K_sSOAPAction_contentManagerService="http://developer.cognos.com/schemas/bibus/3#contentManagerService";
- C_BusRequest.K_sSOAPAction_systemService="http://developer.cognos.com/schemas/bibus/3#systemService";
- C_BusRequest.k_sBIBusNamespace="http://developer.cognos.com/schemas/bibus/3";
- C_BusRequest.k_sBIBusNamespaceDecl="xmlns:bus='"+C_BusRequest.k_sBIBusNamespace+"/'";
- C_BusRequest.k_sBIBusRNSNamespaceDecl="xmlns:rns1='http://developer.cognos.com/schemas/reportService/1'";
- C_BusRequest.prototype.F_AddNamespace=function(_2d){
- this.m_aNamespaces.push(_2d);
- };
- C_BusRequest.prototype.F_Send=function(){
- this.f_sendSoapRequest(this.f_createSoapRequest(this.m_sRequest,this.m_sProductLocale,this.m_sContentLocale),this.m_sRequestSoapAction);
- };
- C_BusRequest.prototype.f_sendSoapRequest=function(_2e,_2f){
- C_BusRequest.m_sLastRequest=_2e;
- C_BusRequest.m_sLastResponse="";
- this.F_SetSoapAction(_2f);
- this.F_SetRequestBody(_2e);
- C_BusRequest.superClass.F_Send.call(this);
- };
- C_BusRequest.prototype.F_IsReadyToProcess=function(){
- if(!C_BusRequest.superClass.F_IsReadyToProcess.call(this)){
- return false;
- }
- delete this.m_oFollowOnState;
- if(this.F_GetError()){
- return !this.m_bPendingAbort;
- }
- var _30=this.F_GetResponseText();
- var _31=U_XML.F_LoadString(null,_30,false,true);
- this.m_docResponse=_31;
- if(!_31||!_31.documentElement){
- return !this.m_bPendingAbort;
- }
- this.m_docResponse.setProperty("SelectionNamespaces","xmlns:SOAP-ENV='http://schemas.xmlsoap.org/soap/envelope/' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' "+this.m_aNamespaces.join(" "));
- C_BusRequest.m_sLastResponse=_31.xml;
- var _32=_31.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/SOAP-ENV:Fault");
- if(_32&&!this.m_bPendingAbort){
- if(this.m_bServerPrompting&&this.m_oListener&&G_BusServer.F_AuthenticationRequired(_31)){
- this.m_bLoggingOn=true;
- if(G_BusServer.F_Logon(this,_31)){
- delete this.m_docResponse;
- return false;
- }
- this.m_bLoggingOn=false;
- this.F_SetNewErrorRes("IDS_CCHL_INITIATE_LOGON_FAILED");
- }
- return true;
- }
- var _33=_31.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Header/bus:biBusHeader/bus:tracking");
- if(_33){
- var _34=_33.xml;
- if(this.m_bPendingAbort){
- this.m_bPendingAbort=false;
- var _35=(_31.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result[bus:status='working' or bus:status='stillWorking']")!=null);
- this.m_oFollowOnState=this.f_createFollowOnState(_31,_34,_35);
- this.F_Abort();
- return false;
- }
- C_BusRequest.m_aBusTracking.push(_34);
- if(this.m_bAsyncBusRequest){
- if(_31.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result[bus:status='complete'][bus:details/item/bus:status='responseReady']")){
- delete this.m_docResponse;
- this.f_sendFollowOnRequest(this.m_sGetOutputMethod,_31,_34,false);
- return false;
- }else{
- if(_31.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result[bus:status='working' or bus:status='stillWorking']")){
- delete this.m_docResponse;
- this.f_sendFollowOnRequest(this.m_sWaitMethod,_31,_34,true);
- return false;
- }
- }
- }
- }
- if(this.m_bPendingAbort){
- this.f_forcePendingAbortOnClient();
- return false;
- }
- if(this.m_bServerPrompting&&this.m_oListener&&G_BusServer.F_RequiresServerPrompting(_31)){
- this.m_bIsPrompting=true;
- if(G_BusServer.F_DoPrompting(this,_31,this.m_sPromptReport)){
- delete this.m_docResponse;
- return false;
- }
- this.m_bIsPrompting=false;
- this.F_SetNewErrorRes("IDS_CCHL_INITIATE_SERVERPROMTING_FAILED");
- return true;
- }
- return true;
- };
- C_BusRequest.prototype.F_ProcessResponse=function(){
- C_BusRequest.superClass.F_ProcessResponse.call(this);
- if(this.F_GetError()){
- this.m_docResponse=null;
- return;
- }
- if(this.m_docResponse&&this.m_docResponse.documentElement){
- var _36=this.m_docResponse.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/SOAP-ENV:Fault");
- if(_36){
- this.F_SetError(new C_BusSoapFault(this.m_docResponse));
- this.m_docResponse=null;
- }
- }else{
- var _37=[];
- var _38=this.F_GetResponseText();
- if(_38){
- _37.push(_38);
- }else{
- _37.push(G_ResManager.F_GetString("IDS_CCHL_HTTP_UNKNOWN_RESPONSE"));
- _37.push("\r\n");
- _37.push("Gateway URL: "+G_CCHL.M_sGatewayURL);
- _37.push("Document URL: "+document.URL);
- var _39=this.F_GetStatusText();
- if(_39){
- _37.push("HTTP Status Text: "+_39);
- }
- }
- this.m_docResponse=null;
- this.F_SetNewErrorRes("IDS_CCHL_XMLHTTPERROR",_37.join("\r\n"));
- }
- };
- C_BusRequest.prototype.f_sendFollowOnRequest=function(_3a,_3b,_3c,_3d){
- G_Debug.F_Print("C_BusRequest.f_sendFollowOnRequest : "+_3a);
- this.m_oFollowOnState=this.f_createFollowOnState(_3b,_3c,_3d);
- var _3e="<"+_3a+">"+"<bus:conversation xsi:type=\"bus:asynchRequest\">"+this.m_oFollowOnState.m_sConversation+"</bus:conversation>"+"<bus:parameterValues SOAP-ENC:arrayType=\"bus:parameterValue[]\" xsi:type=\"SOAP-ENC:Array\"/>"+"<bus:options SOAP-ENC:arrayType=\"bus:option[]\" xsi:type=\"SOAP-ENC:Array\"/>"+"</"+_3a+">";
- this.f_sendSoapRequest(this.f_createSoapRequest(_3e,this.m_sProductLocale,this.m_sContentLocale),this.m_sFollowOnRequestSOAPAction);
- };
- C_BusRequest.prototype.F_Abort=function(){
- if(this.m_bAsyncBusRequest&&!this.m_oFollowOnState&&!this.m_bCompleted){
- G_Debug.F_Print("C_BusRequest pending abort");
- this.m_bPendingAbort=true;
- var _3f=this;
- setTimeout(function(){
- _3f.f_forcePendingAbortOnClient();
- },10000);
- if(this.m_oListener&&this.m_oListener.F_Request_OnAborted){
- this.m_oListener.F_Request_OnAborted(this);
- }
- return;
- }
- C_BusRequest.superClass.F_Abort.call(this);
- if(this.m_oFollowOnState&&this.m_oFollowOnState.m_bCancellable){
- this.f_cancelRequest();
- }
- };
- C_BusRequest.prototype.f_forcePendingAbortOnClient=function(){
- if(this.m_bPendingAbort){
- G_Debug.F_Print("C_BusRequest pending abort forced on client");
- this.m_bCompleted=true;
- this.m_bPendingAbort=false;
- C_BusRequest.superClass.F_Abort.call(this);
- }
- };
- C_BusRequest.prototype.f_createFollowOnState=function(_40,_41,_42){
- var _43=[];
- var nl=_40.selectNodes("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result/bus:primaryRequest/*");
- for(var i=0;i<nl.length;i++){
- _43.push(nl.item(i).xml);
- }
- var _44=_43.join("");
- var _45={"m_sConversation":_44,"m_sBusTracking":_41,"m_bCancellable":_42};
- return _45;
- };
- C_BusRequest.prototype.f_cancelRequest=function(){
- G_Debug.F_Print("C_BusRequest cancelling request on server");
- var _46=this.m_oFollowOnState.m_sConversation;
- var _47=this.m_oFollowOnState.m_sBusTracking;
- delete this.m_oFollowOnState;
- C_BusRequest.m_aBusTracking.push(_47);
- var _48="<"+this.m_sCancelMethod+">"+"<bus:conversation xsi:type=\"bus:asynchRequest\">"+_46+"</bus:conversation>"+"</"+this.m_sCancelMethod+">";
- var _49=new C_BusRequest(null,this.m_sCancelRequestSOAPAction,_48);
- _49.F_Send();
- };
- C_BusRequest.prototype.F_OnServerLogonComplete=function(_4a){
- this.m_bIsLoggingOn=false;
- if(_4a){
- this.F_Send();
- return;
- }
- this.F_SetNewErrorRes("IDS_CCHL_REQUEST_CANCELLED_LOGON");
- this.m_docResponse=null;
- this.m_oListener.F_Request_OnComplete(this);
- };
- C_BusRequest.prototype.F_OnServerPromptingComplete=function(){
- this.m_bIsPrompting=false;
- if(G_BusServer.F_HasParameterValues()){
- var _4b=this.m_sRequest;
- var _4c=_4b.indexOf("<bus:parameterValues");
- var _4d=_4b.indexOf("</bus:parameterValues>");
- if(_4c!=-1&&_4d!=-1){
- _4b=_4b.substring(0,_4c)+G_BusServer.F_GetParameterValues()+_4b.substring(_4d+22);
- }else{
- if(_4c!=-1&&_4d==-1){
- v_sParamsStart=_4b.slice(_4c);
- _4d=v_sParamsStart.indexOf("/>");
- _4b=_4b.substring(0,_4c)+G_BusServer.F_GetParameterValues()+_4b.substring(_4c+_4d+2);
- }else{
- G_Debug.F_Alert("Could not replace params in request");
- }
- }
- this.m_sRequest=_4b;
- this.F_Send();
- return;
- }
- this.F_SetNewErrorRes("IDS_CCHL_REQUEST_CANCELLED_PROMPTING");
- this.m_docResponse=null;
- this.m_oListener.F_Request_OnComplete(this);
- };
- C_BusRequest.prototype.f_createSoapRequest=function(_4e,_4f,_50){
- var _51=G_BusServer.F_GetAuthenticityToken();
- var _52=false;
- var _53=null;
- if(this.m_bUseDefaultRoutingServerGroup){
- _53="";
- _52=true;
- }else{
- _53=(this.m_sRoutingServerGroup===null)?G_BusServer.F_GetRoutingServerGroup():this.m_sRoutingServerGroup;
- _52=Boolean(_53);
- }
- var _54=G_BusServer.F_GetCafContextId();
- var _55=(C_BusRequest.m_aBusTracking.length>0)?C_BusRequest.m_aBusTracking.pop():"";
- var _56="<SOAP-ENV:Envelope SOAP-ENV:encodingStyle=\"http://schemas.xmlsoap.org/soap/encoding/\" xmlns:SOAP-ENV=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:SOAP-ENC=\"http://schemas.xmlsoap.org/soap/encoding/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\" "+this.m_aNamespaces.join(" ")+">"+"<SOAP-ENV:Header>"+"<bus:biBusHeader xsi:type=\"bus:biBusHeader\">"+(_51?("<bus:CAM xsi:type=\"bus:CAM\">"+"<authenticityToken xsi:type=\"xsd:base64Binary\">"+G_BusServer.F_GetAuthenticityToken()+"</authenticityToken>"+"</bus:CAM>"):"")+(_54?("<bus:CAF xsi:type=\"bus:CAF\">"+"<contextID xsi:type=\"xsd:string\">"+_54+"</contextID>"+"</bus:CAF>"):"")+"<bus:userPreferenceVars SOAP-ENC:arrayType=\"bus:userPreferenceVar[]\" xsi:type=\"SOAP-ENC:Array\">"+"<item>"+"<bus:name xsi:type=\"xsd:string\">productLocale</bus:name>"+"<bus:value xsi:type=\"xsd:string\">"+(_4f?_4f:G_CCHL.M_sProductLocale)+"</bus:value>"+"</item>"+"<item>"+"<bus:name xsi:type=\"xsd:string\">contentLocale</bus:name>"+"<bus:value xsi:type=\"xsd:string\">"+(_50?_50:G_CCHL.M_sContentLocale)+"</bus:value>"+"</item>"+"</bus:userPreferenceVars>"+"<bus:dispatcherTransportVars xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:dispatcherTransportVar[]\">"+"<item xsi:type=\"bus:dispatcherTransportVar\">"+"<name xsi:type=\"xsd:string\">rs</name>"+"<value xsi:type=\"xsd:string\">true</value>"+"</item>"+"</bus:dispatcherTransportVars>"+_55+(_52?("<bus:routing xsi:type=\"bus:routingInfo\">"+"<routingServerGroup xsi:type=\"xsd:string\">"+_53.F_XMLEncode()+"</routingServerGroup>"+"</bus:routing>"):"")+"</bus:biBusHeader>"+"</SOAP-ENV:Header>"+"<SOAP-ENV:Body>"+_4e+"</SOAP-ENV:Body>"+"</SOAP-ENV:Envelope>";
- return _56;
- };
- function C_BusSoapFault(_57){
- this.m_sErrorSummary="";
- this.m_sErrorDetails="";
- this.m_sErrorCode="";
- _57.setProperty("SelectionNamespaces","xmlns:SOAP-ENV='http://schemas.xmlsoap.org/soap/envelope/' "+C_BusRequest.k_sBIBusNamespaceDecl);
- var _58=_57.selectSingleNode("//SOAP-ENV:Fault");
- var nl=_58.selectNodes(".//bus:messageString | .//messageString | .//bus:message[not(*)] | .//message[not(*)]");
- if(nl.length>0){
- var _59=nl.item(0).text;
- var i=_59.indexOf(" ");
- this.m_sErrorSummary=(i>0)?_59.substring(i+1):_59;
- this.m_sErrorCode=(i>0)?_59.substring(0,i):"";
- var _5a=[];
- for(var j=1;j<nl.length;++j){
- _5a.push(nl.item(j).text);
- }
- this.m_sErrorDetails=_5a.join("\r\n");
- }else{
- var _5b=_58.selectSingleNode("faultstring | SOAP-ENV:faultstring");
- if(_5b){
- this.m_sErrorSummary=_5b.text;
- }
- var _5c=_58.selectSingleNode("faultcode | SOAP-ENV:faultcode");
- if(_5c){
- this.m_sErrorCode=_5c.text;
- }
- }
- if(!this.m_sErrorSummary){
- this.m_sErrorSummary=G_ResManager.F_GetString("IDS_CCHL_UNRECOGNIZED_SOAP_FAULT");
- this.m_sErrorDetails=_58.xml;
- }
- };
- C_BusSoapFault.prototype.F_GetErrorSummary=function(){
- return this.m_sErrorSummary;
- };
- C_BusSoapFault.prototype.F_GetErrorDetails=function(){
- return this.m_sErrorDetails;
- };
- C_BusSoapFault.prototype.F_GetErrorCode=function(){
- return this.m_sErrorCode;
- };
- function C_FolderContentsRequest(_5d,_5e){
- var _5f="<bus:query>"+"<search>"+_5e.F_XMLEncode()+"/*[permission('read') or permission('write') or permission('traverse') or permission('execute')]</search>"+"<sortBy xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:sort[]\">"+"<item xsi:type=\"bus:sort\">"+"<propName xsi:type=\"bus:propEnum\">usage</propName>"+"<order xsi:type=\"bus:orderEnum\">ascending</order>"+"</item>"+"<item xsi:type=\"bus:sort\">"+"<propName xsi:type=\"bus:propEnum\">displaySequence</propName>"+"<order xsi:type=\"bus:orderEnum\">descending</order>"+"</item>"+"<item xsi:type=\"bus:sort\">"+"<propName xsi:type=\"bus:propEnum\">defaultName</propName>"+"<order xsi:type=\"bus:orderEnum\">ascending</order>"+"</item>"+"</sortBy>"+"<properties xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:propEnum[]\">"+"<item>defaultName</item>"+"<item>searchPath</item>"+"<item>permissions</item>"+"<item>userInterfaces</item>"+"<item>shown</item>"+"<item>storeID</item>"+"</properties>"+"</bus:query>";
- this.F_ConstructBaseClass(_5d,C_BusRequest.K_sSOAPAction_contentManagerService,_5f);
- };
- C_FolderContentsRequest.F_Extends(C_BusRequest);
- var G_BusServer={};
- G_BusServer.k_iPollPromptWindow=1000;
- G_BusServer.m_aLogonListeners=[];
- G_BusServer.m_oPromptListeners={};
- G_BusServer.m_oPromptWindows={};
- G_BusServer.m_iPromptId=0;
- G_BusServer.m_iLastPromptTimeoutId=-1;
- G_BusServer.f_setNoParameterValues=function(){
- this.m_sParameterValues="<bus:parameterValues "+C_BusRequest.k_sBIBusNamespaceDecl+" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:SOAP-ENC=\"http://schemas.xmlsoap.org/soap/encoding/\" SOAP-ENC:arrayType=\"bus:parameterValue[]\" xsi:type=\"SOAP-ENC:Array\">"+"</bus:parameterValues>";
- };
- G_BusServer.f_setNoParameterValues();
- G_BusServer.m_aParametersListeners=[];
- G_BusServer.F_AddParametersListener=function(_60){
- this.m_aParametersListeners.push(_60);
- };
- G_BusServer.f_getPromptId=function(){
- return ++this.m_iPromptId;
- };
- G_BusServer.F_SetCafContextId=function(_61){
- this.m_sCafContextId=_61;
- };
- G_BusServer.F_GetCafContextId=function(){
- return this.m_sCafContextId;
- };
- G_BusServer.m_sRoutingServerGroup="";
- G_BusServer.F_SetRoutingServerGroup=function(_62){
- this.m_sRoutingServerGroup=_62?_62:"";
- };
- G_BusServer.F_GetRoutingServerGroup=function(){
- return this.m_sRoutingServerGroup;
- };
- G_BusServer.F_Logon=function(_63,_64){
- this.m_aLogonListeners.push(_63);
- var _65=G_CCHL.M_sGatewayURL+"?b_action=xts.run&m=portal/close.xts";
- if(_64){
- _64.setProperty("SelectionNamespaces",C_BusRequest.k_sBIBusNamespaceDecl);
- var _66=_64.selectNodes(".//*[self::bus:biBusHeader | self::biBusHeader]//*[self::bus:displayObjects | self::displayObjects]/item[(type | bus:type) ='hidden']");
- for(var i=0;i<_66.length;i++){
- var _67=_66.item(i).selectSingleNode("bus:name | name").text;
- var _68=_66.item(i).selectSingleNode("bus:value | value").text;
- _65=_65+"&"+_67+"="+_68;
- }
- _65+="&md.callBack=data";
- }else{
- var _65=G_CCHL.M_sGatewayURL+"?b_action=xts.run&m=portal/close.xts&h_CAM_action=logonAs&md.callBack=data";
- }
- if(this.m_aLogonListeners.length>1){
- return true;
- }
- var _69=U_DOM.F_ShowEventBlocker(10000);
- _69.onmousedown=G_BusServer.F_OnLogonBlockerMouseDown;
- this.m_oLogonWindow=window.open(_65,"_blank","directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640");
- if(U_DOM.F_WindowOpenWasBlocked(this.m_oLogonWindow)){
- return false;
- }
- setTimeout("G_BusServer.f_checkLogonWindowState()",G_BusServer.k_iPollPromptWindow);
- return true;
- };
- function ccModalCallBack(_6a){
- var _6b=false;
- if(_6a=="ok"){
- _6b=true;
- }
- G_BusServer.f_onLogonComplete(_6b);
- };
- G_BusServer.F_OnLogonBlockerMouseDown=function(){
- if(G_BusServer.m_oLogonWindow&&!G_BusServer.m_oLogonWindow.closed){
- G_BusServer.m_oLogonWindow.focus();
- return;
- }
- U_DOM.F_HideEventBlocker();
- G_Debug.F_Print("G_BusServer.F_OnLogonBlockerMouseDown: blocker was up, yet no logon window");
- };
- G_BusServer.f_onLogonComplete=function(_6c){
- U_DOM.F_HideEventBlocker();
- setTimeout("G_BusServer.f_onAfterLogonComplete("+_6c+")",0);
- if(G_BusServer.m_oLogonWindow&&!G_BusServer.m_oLogonWindow.closed){
- G_BusServer.m_oLogonWindow.close();
- }
- delete G_BusServer.m_oLogonWindow;
- G_BusServer.m_oLogonWindow=null;
- };
- G_BusServer.f_onAfterLogonComplete=function(_6d){
- for(var i=0;i<this.m_aLogonListeners.length;i++){
- if(this.m_aLogonListeners[i]&&this.m_aLogonListeners[i].F_OnServerLogonComplete){
- this.m_aLogonListeners[i].F_OnServerLogonComplete(_6d);
- }
- }
- this.m_aLogonListeners.F_Clear();
- };
- G_BusServer.f_checkLogonWindowState=function(){
- if(G_BusServer.m_oLogonWindow){
- if(G_BusServer.m_oLogonWindow.closed){
- G_BusServer.f_onLogonComplete();
- }else{
- setTimeout("G_BusServer.f_checkLogonWindowState()",G_BusServer.k_iPollPromptWindow);
- }
- }
- };
- G_BusServer.F_Logoff=function(){
- var _6e=new C_BusRequest(null,C_BusRequest.K_sSOAPAction_contentManagerService,"<bus:logoff/>");
- _6e.F_Send();
- U_CookieJar.F_DeleteCookie("cam_passport",U_DOM.F_GetBasePath());
- };
- G_BusServer.F_AuthenticationRequired=function(_6f){
- var _70=_6f.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Header/bus:biBusHeader");
- if(_70&&_70.selectSingleNode(".//bus:errorCodeString[text() = 'camAuthUserRecoverable'] | .//errorCodeString[text() = 'camAuthUserRecoverable']")){
- return _70.selectSingleNode(".//bus:promptInfo | .//promptInfo")!=null;
- }
- return false;
- };
- G_BusServer.F_RequiresServerPrompting=function(_71){
- return (_71&&_71.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result/bus:details/item[bus:status='prompting']"));
- };
- G_BusServer.F_DoPrompting=function(_72,_73,_74){
- G_HAL.F_VerifyDependencies("G_ResManager");
- var _75=document;
- var _76=_75.getElementById("CCHL_formServerPrompting");
- if(!_76){
- var _77=G_ResManager.F_GetResource("CCHL_formServerPrompting").text;
- var div=_75.body.appendChild(_75.createElement("DIV"));
- div.innerHTML=_77;
- _76=_75.getElementById("CCHL_formServerPrompting");
- }
- var _78=_73.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result/bus:primaryRequest");
- var _79=_73.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result/bus:details/item/bus:outputPages/item");
- var _7a=_73.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Header/bus:biBusHeader/bus:tracking/bus:conversationContext");
- if(!(_78&&_79&&_7a)){
- return false;
- }
- _76.action=G_CCHL.M_sGatewayURL;
- _76.conversation.value=(_78&&!_74)?_78.xml:"";
- _76.htmlFragment.value=(_79&&!_74)?_79.text:"";
- _76.specification.value=_74?_74:"";
- _76.method.value=_74?"collectParameterValuesSpecification":"";
- _76.tracking.value=(_7a&&!_74)?_7a.xml:"";
- var _7b=this.f_getPromptId();
- _76.clientContext.value=_7b;
- var _7c=this.F_GetCafContextId();
- if(_7c){
- _76.cafcontextid.value=_7c;
- }
- _76.target="winPrompt_"+(new Date()).getTime();
- this.f_setNoParameterValues();
- if(D_Progress.F_IsActiveDialog()){
- D_Progress.F_DisableCancel();
- }
- var _7d=U_DOM.F_ShowEventBlocker(10000);
- _7d.onmousedown=G_BusServer.F_OnPromptBlockerMouseDown;
- this.m_oPromptListeners[_7b]=_72;
- this.m_oPromptWindows[_7b]=window.open(G_HAL.F_GetFileURL("hal/blank.htm"),_76.target,"directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=400,width=630");
- if(U_DOM.F_WindowOpenWasBlocked(this.m_oPromptWindows[_7b])){
- return false;
- }
- this.m_oPromptWindows[_7b].focus();
- _76.submit();
- this.m_iLastPromptTimeoutId=setTimeout("G_BusServer.f_checkPromptingWindowState('"+_7b+"')",G_BusServer.k_iPollPromptWindow);
- return true;
- };
- G_BusServer.F_OnPromptBlockerMouseDown=function(){
- for(var s in G_BusServer.m_oPromptWindows){
- G_BusServer.m_oPromptWindows[s].focus();
- return;
- }
- U_DOM.F_HideEventBlocker();
- G_Debug.F_Print("G_BusServer.F_OnPromptBlockerMouseDown: blocker was up, yet no prompt window");
- };
- G_BusServer.f_checkPromptingWindowState=function(_7e){
- if(this.m_oPromptWindows[_7e]){
- var _7f=false;
- try{
- _7f=this.m_oPromptWindows[_7e].closed;
- }
- catch(e){
- _7f=true;
- }
- if(_7f){
- delete this.m_oPromptWindows[_7e];
- if(U_Object.F_IsEmpty(this.m_oPromptWindows)){
- U_DOM.F_HideEventBlocker();
- }else{
- for(var s in this.m_oPromptWindows){
- this.m_oPromptWindows[s].focus();
- break;
- }
- }
- setTimeout("G_BusServer.f_fireOnPromptingComplete('"+_7e+"')",0);
- }else{
- this.m_iLastPromptTimeoutId=setTimeout("G_BusServer.f_checkPromptingWindowState('"+_7e+"')",G_BusServer.k_iPollPromptWindow);
- }
- }
- };
- G_BusServer.F_GetParameterValues=function(){
- return this.m_sParameterValues;
- };
- G_BusServer.F_SetParameterValues=function(_80){
- var _81=_80.replace(/bus:parameters(\W)/g,"bus:parameterValues$1");
- var _82=U_XML.F_LoadString(null,_81);
- var _83=U_XML.F_LoadString(null,this.m_sParameterValues);
- if(_82&&_83&&_82.documentElement.xml!=_83.documentElement.xml){
- this.m_sParameterValues=_81;
- this.f_fireOnParametersChange();
- return true;
- }
- return false;
- };
- G_BusServer.F_HasParameterValues=function(){
- var _84=U_XML.F_LoadString(D_XmlError,this.m_sParameterValues);
- return (_84.documentElement.text!="");
- };
- G_BusServer.F_ClearParameterValues=function(){
- this.f_setNoParameterValues();
- this.f_fireOnParametersChange();
- };
- G_BusServer.F_ClearNonCredentialParameterValues=function(){
- if(this.F_HasParameterValues()){
- var _85=this.F_GetParameterValues();
- var _86=U_XML.F_LoadString(D_XmlError,_85,false);
- _86.setProperty("SelectionNamespaces",C_BusRequest.k_sBIBusNamespaceDecl);
- var _87=false;
- var _88=_86.documentElement.selectNodes("item[not(starts-with(./bus:name,'credential'))]");
- for(var i=0;i<_88.length;i++){
- _86.documentElement.removeChild(_88.item(i));
- _87=true;
- }
- if(_87){
- this.m_sParameterValues=U_XML.F_SerializeNode(_86.documentElement);
- this.f_fireOnParametersChange();
- }
- }
- };
- G_BusServer.f_fireOnParametersChange=function(){
- for(var i=0;i<this.m_aParametersListeners.length;i++){
- if(this.m_aParametersListeners[i]&&this.m_aParametersListeners[i].F_OnServerParametersChange){
- this.m_aParametersListeners[i].F_OnServerParametersChange();
- }
- }
- };
- G_BusServer.f_fireOnPromptingComplete=function(_89){
- if(this.m_oPromptListeners[_89]&&this.m_oPromptListeners[_89].F_OnServerPromptingComplete){
- this.m_oPromptListeners[_89].F_OnServerPromptingComplete();
- }
- delete this.m_oPromptListeners[_89];
- };
- function pdsCallback(_8a){
- if(_8a.state!="Cancel"){
- G_BusServer.m_sParameterValues="<bus:parameterValues "+C_BusRequest.k_sBIBusNamespaceDecl+" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:SOAP-ENC=\"http://schemas.xmlsoap.org/soap/encoding/\" SOAP-ENC:arrayType=\"bus:parameterValue[]\" xsi:type=\"SOAP-ENC:Array\">"+(_8a.parameters?_8a.parameters.join(""):"")+"</bus:parameterValues>";
- setTimeout("G_BusServer.f_fireOnParametersChange()",0);
- }
- var _8b=_8a.v_sClientContext;
- if(!_8b){
- G_Debug.F_Print("Error: Prompting returned with no client context. Will attempt to inform any listener that can be found");
- for(var s in G_BusServer.m_oPromptWindows){
- _8b=s;
- }
- }
- if(G_BusServer.m_iLastPromptTimeoutId!=-1){
- window.clearTimeout(G_BusServer.m_iLastPromptTimeoutId);
- G_BusServer.m_iLastPromptTimeoutId=-1;
- }
- setTimeout("G_BusServer.f_fireOnPromptingComplete('"+_8b+"')",0);
- delete G_BusServer.m_oPromptWindows[_8b];
- if(U_Object.F_IsEmpty(G_BusServer.m_oPromptWindows)){
- U_DOM.F_HideEventBlocker();
- }else{
- for(var s in G_BusServer.m_oPromptWindows){
- G_BusServer.m_oPromptWindows[s].focus();
- break;
- }
- }
- };
- G_BusServer.F_GetAuthenticityToken=function(){
- if(!this.m_sAuthenticityToken){
- try{
- this.m_sAuthenticityToken=(new CAMAuthenticityTokenSession()).generate();
- }
- catch(e){
- alert("Exception thrown by CAMAuthenticityTokenSession"+"\n\n Make sure you've included the camcrypto javascript files:"+"\n camcrypto/base64.js"+"\n camcrypto/camcryptoutil.js"+"\n camcrypto/sha1.js"+"\n camcrypto/authtoken.js");
- }
- }
- return this.m_sAuthenticityToken;
- };
- function C_RunReportRequest(_8c,_8d,_8e,_8f,_90){
- var _91="";
- if(_8e&&_8e!=""){
- _91="<item xsi:type=\"bus:runOptionData\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">data</bus:name>"+"<bus:value xsi:type=\"bus:dataEnum\">"+_8e+"</bus:value>"+"</item>";
- }
- var _92="<item xsi:type=\"bus:runOptionAnyURI\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">outputLocation</bus:name>"+"<bus:value xsi:type=\"xsd:string\">http://developer.cognos.com/ceba/constants/temporaryObjectLocationEnum#serverFileSystem</bus:value>"+"</item>";
- if(_90){
- _92="";
- }
- var _93="<rns1:runSpecification>"+"<bus:specification xsi:type=\"bus:reportServiceReportSpecification\">"+"<bus:value xsi:type=\"bus:specification\">"+_8d.F_XMLEncode()+"</bus:value>"+"</bus:specification>"+G_BusServer.F_GetParameterValues()+"<bus:options SOAP-ENC:arrayType=\"bus:option[]\" xsi:type=\"SOAP-ENC:Array\">"+"<item xsi:type=\"bus:asynchOptionInt\">"+"<bus:name xsi:type=\"bus:asynchOptionEnum\">primaryWaitThreshold</bus:name>"+"<bus:value xsi:type=\"xsd:int\">"+C_BusRequest.K_sPrimaryWaitThreshold+"</bus:value>"+"</item>"+"<item xsi:type=\"bus:asynchOptionInt\">"+"<bus:name xsi:type=\"bus:asynchOptionEnum\">secondaryWaitThreshold</bus:name>"+"<bus:value xsi:type=\"xsd:int\">"+C_BusRequest.K_sSecondaryWaitThreshold+"</bus:value>"+"</item>"+"<item xsi:type=\"bus:runOptionStringArray\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">outputFormat</bus:name>"+"<bus:value xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"xsd:string[1]\">"+"<item>"+(_8f?_8f:"XHTML")+"</item>"+"</bus:value>"+"</item>"+"<item xsi:type=\"bus:runOptionAnyURI\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">xslURL</bus:name>"+"<bus:value xsi:type=\"xsd:string\">null.xsl</bus:value>"+"</item>"+"<item xsi:type=\"bus:runOptionString\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">promptFormat</bus:name>"+"<bus:value xsi:type=\"xsd:string\">HTMLFragment</bus:value>"+"</item>"+"<item xsi:type=\"bus:runOptionBoolean\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">prompt</bus:name>"+"<bus:value xsi:type=\"xsd:boolean\">false</bus:value>"+"</item>"+_91+_92+"</bus:options>"+"</rns1:runSpecification>";
- C_RunReportRequest.m_sLastRequest=_93;
- C_RunReportRequest.m_sLastResponse="";
- this.m_nReportProperties=null;
- this.F_ConstructBaseClass(_8c,C_BusRequest.K_sSOAPAction_reportService,_93);
- this.F_SetContext(this.e_RequestOutput);
- this.F_SetAsyncBusRequest("rns1:wait","rns1:cancel","rns1:getOutput");
- };
- C_RunReportRequest.F_Extends(C_BusRequest);
- C_RunReportRequest.prototype.F_ProcessResponse=function(){
- C_RunReportRequest.superClass.F_ProcessResponse.call(this);
- var _94=this.F_GetResponse();
- if(!_94){
- return;
- }
- C_RunReportRequest.m_sLastResponse=this.F_GetResponseText();
- var n=_94.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*//bus:outputPages/item");
- this.m_sReportOutput=U_XML.F_GetNodeText(n);
- };
- C_RunReportRequest.prototype.F_GetReportOutput=function(){
- return this.m_sReportOutput;
- };
- function C_MetadataRequest(_95,_96){
- C_MetadataRequest.m_sLastRequest=_96;
- C_MetadataRequest.m_sLastResponse="";
- this.m_aMetadataResponses=null;
- var _97="<rns1:runSpecification>"+"<bus:specification xsi:type=\"bus:reportServiceMetadataSpecification\">"+"<bus:value xsi:type=\"bus:specification\">"+_96.F_XMLEncode()+"</bus:value>"+"</bus:specification>"+G_BusServer.F_GetParameterValues()+"<bus:options SOAP-ENC:arrayType=\"bus:option[]\" xsi:type=\"SOAP-ENC:Array\">"+"<item xsi:type=\"bus:asynchOptionInt\">"+"<bus:name xsi:type=\"bus:asynchOptionEnum\">primaryWaitThreshold</bus:name>"+"<bus:value xsi:type=\"xsd:int\">"+C_BusRequest.K_sPrimaryWaitThreshold+"</bus:value>"+"</item>"+"<item xsi:type=\"bus:asynchOptionInt\">"+"<bus:name xsi:type=\"bus:asynchOptionEnum\">secondaryWaitThreshold</bus:name>"+"<bus:value xsi:type=\"xsd:int\">"+C_BusRequest.K_sSecondaryWaitThreshold+"</bus:value>"+"</item>"+"<item xsi:type=\"bus:runOptionBoolean\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">prompt</bus:name>"+"<bus:value xsi:type=\"xsd:boolean\">false</bus:value>"+"</item>"+"</bus:options>"+"</rns1:runSpecification>";
- this.F_ConstructBaseClass(_95,C_BusRequest.K_sSOAPAction_reportService_session,_97);
- this.F_SetAsyncBusRequest("rns1:wait","rns1:cancel","rns1:getOutput");
- };
- C_MetadataRequest.F_Extends(C_BusRequest);
- C_MetadataRequest.F_GetLastRequest=function(){
- return this.m_sLastRequest?this.m_sLastRequest:"";
- };
- C_MetadataRequest.F_GetLastResponse=function(){
- return this.m_sLastResponse?this.m_sLastResponse:"";
- };
- C_MetadataRequest.prototype.F_ProcessResponse=function(){
- C_MetadataRequest.superClass.F_ProcessResponse.call(this);
- var _98=this.F_GetResponse();
- if(!_98){
- return;
- }
- var nl=_98.selectNodes("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result/bus:details/item/bus:metadata");
- if(nl.length==0){
- this.F_SetNewErrorRes("IDS_CCHL_BAD_MA_RESPONSE");
- return;
- }
- var _99=[];
- var _9a=[];
- _9a.push("<root>");
- for(var i=0;i<nl.length;i++){
- _9a.push("<response index=\""+i+"\">");
- var _9b=nl.item(i).text;
- var d=U_XML.F_LoadString(null,_9b);
- if(!d){
- this.F_SetNewErrorRes("IDS_CCHL_BAD_MA_RESPONSE",_9b);
- return;
- }
- _99.push(d.documentElement);
- _9a.push(d.documentElement.xml);
- _9a.push("</response>");
- }
- _9a.push("</root>");
- C_MetadataRequest.m_sLastResponse=_9a.join("");
- this.m_aMetadataResponses=_99;
- };
- C_MetadataRequest.prototype.F_GetMetadataResponses=function(){
- return this.m_aMetadataResponses;
- };
- C_MetadataRequest.prototype.F_GetMetadataResponse=function(){
- var a=this.F_GetMetadataResponses();
- return a?a[0]:null;
- };
- function C_ModelCache(){
- this.m_sModelPath="";
- this.m_sModelLocale="";
- this.m_sPackageName="";
- this.m_sPackagePath="";
- this.m_sModificationTime="";
- this.m_sRoutingServerGroup="";
- this.m_iMemberDisplayCountLimit=NaN;
- this.m_aListeners=[];
- this.m_bModelEnabled=false;
- this.f_initCache();
- };
- C_ModelCache.prototype.f_initCache=function(){
- this.m_oFunctionProperty={};
- this.m_oSupportsOperation={};
- this.m_oSupportsSuppression={};
- this.m_bContainsHierarchies=false;
- this.m_docModelCache=U_XML.F_CreateDocument();
- var _9c=this.m_docModelCache.appendChild(this.m_docModelCache.createElement("modelCache"));
- this.m_nModelRootCache=_9c.appendChild(this.m_docModelCache.createElement("modelRootCache"));
- this.m_nRootMembersCache=_9c.appendChild(this.m_docModelCache.createElement("rootMembersCache"));
- this.m_nChildrenCache=_9c.appendChild(this.m_docModelCache.createElement("childrenCache"));
- this.m_nMembersCache=_9c.appendChild(this.m_docModelCache.createElement("membersCache"));
- this.m_oAncestorInfoCache={};
- };
- C_ModelCache.prototype.F_SetModel=function(_9d,_9e,_9f,_a0,_a1,_a2,_a3){
- var _a4=!this.m_bModelEnabled;
- var _a5=(this.m_sModelPath!=_9d)||(this.m_sModelLocale!=_9e);
- this.m_sModelPath=_9d;
- this.m_sModelLocale=_9e;
- this.m_sPackageName=_9f;
- this.m_sPackagePath=_a0;
- this.m_sModificationTime=_a1;
- this.m_sRoutingServerGroup=_a3;
- this.m_iMemberDisplayCountLimit=_a2;
- if(_a5){
- this.F_ClearModelCache();
- }else{
- if(this.m_bModelEnabled){
- return;
- }
- }
- this.m_bModelEnabled=true;
- this.f_fireEvent("F_ModelCache_OnModelChanged");
- if(_a4&&!_a5&&this.F_GetModelRootResponses()){
- this.f_fireEvent("F_ModelCache_OnModelRootLoaded");
- }
- };
- C_ModelCache.prototype.F_DisableModel=function(){
- this.m_bModelEnabled=false;
- this.f_fireEvent("F_ModelCache_OnCacheCleared");
- this.f_fireEvent("F_ModelCache_OnModelChanged");
- this.f_fireEvent("F_ModelCache_OnModelRootLoaded");
- };
- C_ModelCache.prototype.F_ToString=function(){
- var _a6=this.m_docModelCache.documentElement;
- _a6.setAttribute("modelPath",this.m_sModelPath);
- _a6.setAttribute("modelLocale",this.m_sModelLocale);
- _a6.setAttribute("packageName",this.m_sPackageName);
- _a6.setAttribute("packagePath",this.m_sPackagePath);
- _a6.setAttribute("modificationTime",this.m_sModificationTime);
- _a6.setAttribute("memberDisplayCountLimit",this.m_iMemberDisplayCountLimit.toString());
- return _a6.xml;
- };
- C_ModelCache.prototype.F_IsCurrentModel=function(_a7,_a8){
- return ((_a7==this.m_sModelPath)&&(_a8==this.m_sModelLocale));
- };
- C_ModelCache.prototype.F_AddModelLoadedListener=function(_a9){
- this.m_aListeners.F_PushUnique(_a9);
- };
- C_ModelCache.prototype.F_RemoveModelLoadedListener=function(_aa){
- this.m_aListeners.F_RemoveItem(_aa);
- };
- C_ModelCache.prototype.F_LoadXML=function(_ab){
- this.F_ClearModelCache();
- this.m_docModelCache=U_XML.F_LoadString(null,_ab,false,false);
- if(!this.m_docModelCache){
- return;
- }
- var _ac=this.m_docModelCache.documentElement;
- this.m_nModelRootCache=_ac.selectSingleNode("modelRootCache");
- this.m_nRootMembersCache=_ac.selectSingleNode("rootMembersCache");
- this.m_nChildrenCache=_ac.selectSingleNode("childrenCache");
- this.m_nMembersCache=_ac.selectSingleNode("membersCache");
- this.m_sModelPath=_ac.getAttribute("modelPath");
- this.m_sModelLocale=_ac.getAttribute("modelLocale");
- this.m_sPackageName=_ac.getAttribute("packageName");
- this.m_sPackagePath=_ac.getAttribute("packagePath");
- this.m_sModificationTime=_ac.getAttribute("modificationTime");
- this.m_iMemberDisplayCountLimit=_ac.getAttribute("memberDisplayCountLimit");
- this.m_bModelEnabled=true;
- this.f_fireEvent("F_ModelCache_OnModelChanged");
- this.f_fireEvent("F_ModelCache_OnModelRootLoaded");
- };
- C_ModelCache.prototype.F_IsMultiDimensionalSource=function(){
- return Boolean(this.m_nModelRootCache.selectSingleNode(".//*[self::dimension | self::hierarchy | self::member]"));
- };
- C_ModelCache.prototype.F_ClearModelCache=function(){
- this.f_initCache();
- this.f_fireEvent("F_ModelCache_OnCacheCleared");
- };
- C_ModelCache.prototype.f_fireEvent=function(_ad){
- this.m_aListeners.F_CallEach(_ad,this);
- };
- C_ModelCache.prototype.F_GetMember=function(_ae){
- return this.m_nMembersCache.selectSingleNode(".//*[not(self::searchResult) and @_ref="+_ae.F_ToXPathString()+"]");
- };
- C_ModelCache.prototype.F_GetMembers=function(_af,_b0){
- if(!_b0){
- alert("F_GetMembers requires a max members parameter");
- return null;
- }
- var _b1=this.m_nMembersCache.selectSingleNode("*[not(self::searchResult) and @_ref="+_af.F_ToXPathString()+"]");
- if(_b1){
- var _b2=_b1.selectNodes("member").length;
- var _b3=_b1.getAttribute("maxMembers");
- var _b4=_b3?parseInt(_b3,10):Number.POSITIVE_INFINITY;
- if(_b0<=_b4||_b2<_b4){
- return _b1;
- }
- }
- return null;
- };
- C_ModelCache.prototype.F_CacheMembersResponse=function(_b5,_b6){
- if(_b6!=Number.POSITIVE_INFINITY){
- _b5.setAttribute("maxMembers",_b6);
- }
- var n=U_XML.F_ImportNode(this.m_docModelCache,_b5,true);
- this.m_nMembersCache.appendChild(n);
- this.f_flagMembersWithNoChildren();
- return n;
- };
- C_ModelCache.prototype.f_flagMembersWithNoChildren=function(){
- if(!this.m_bUpdatingCache){
- U_XML.F_SetNodeAttributeValues(this.m_nMembersCache.selectNodes("*/member[not(@hasChildren) and ../../member[not(member)]/@_path = @_path]"),"hasChildren","false");
- }
- };
- C_ModelCache.prototype.F_GetSearchMembers=function(_b7,_b8,_b9,_ba){
- if(!_b8){
- alert("F_GetMembers requires a max members parameter");
- return;
- }
- var _bb=this.m_nMembersCache.selectSingleNode("searchResult[@_path="+_b7.F_ToXPathString()+" and @descendants='"+(_b9?"true":"false")+"' and @constraints="+(_ba?_ba.F_ToXPathString():"''")+"]");
- if(_bb){
- var _bc=_bb.selectNodes("member").length;
- var _bd=parseInt(_bb.getAttribute("maxMembers"));
- if(_b8<=_bd||_bc<_bd){
- return _bb;
- }
- }
- return null;
- };
- C_ModelCache.prototype.F_CacheSearchMembersResponse=function(_be,_bf,_c0,_c1){
- _be.setAttribute("maxMembers",_bf);
- _be.setAttribute("descendants",(_c0?"true":"false"));
- _be.setAttribute("constraints",_c1);
- var n=U_XML.F_ImportNode(this.m_docModelCache,_be,true);
- this.m_nMembersCache.appendChild(n);
- n=U_XML.F_SetNodeName(n,"searchResult");
- this.f_flagMembersWithNoChildren();
- return n;
- };
- C_ModelCache.prototype.F_GetChildren=function(_c2){
- return this.m_nChildrenCache.selectSingleNode("*[*[@_path="+_c2.F_ToXPathString()+"]]");
- };
- C_ModelCache.prototype.F_CacheChildrenResponse=function(_c3){
- var n=U_XML.F_ImportNode(this.m_docModelCache,_c3,true);
- this.m_nChildrenCache.appendChild(n);
- return n;
- };
- C_ModelCache.prototype.F_GetModelRootResponses=function(){
- var nl=this.m_nModelRootCache.selectNodes("*");
- var _c4=nl.length;
- if(_c4==0){
- return null;
- }
- var _c5=[];
- for(var i=0;i<_c4;i++){
- _c5.push(nl.item(i).cloneNode(true));
- }
- return _c5;
- };
- C_ModelCache.prototype.F_GetDimensionalMetadataRoot=function(){
- return this.m_nModelRootCache.selectSingleNode("*[1]");
- };
- C_ModelCache.prototype.F_IsMeasureDimension=function(_c6){
- return (_c6&&_c6.nodeName=="dimension"&&_c6.getAttribute("type")=="measure");
- };
- C_ModelCache.prototype.F_GetDimensionalMetadata=function(_c7){
- return this.m_nModelRootCache.selectSingleNode("*[1]//*[@_ref="+_c7.F_ToXPathString()+"]");
- };
- C_ModelCache.prototype.F_CacheModelRootResponse=function(_c8){
- U_XML.F_RemoveNodes(this.m_nModelRootCache,"*");
- var _c9=_c8?_c8.length:0;
- if(_c9>0){
- for(var i=0;i<_c9;i++){
- var n=U_XML.F_ImportNode(this.m_docModelCache,_c8[i],true);
- this.m_nModelRootCache.appendChild(n);
- }
- this.m_bContainsHierarchies=Boolean(_c8[C_ModelRootRequest.K_eResponse_MemberTreeMetadata].selectSingleNode(".//hierarchy/@_ref"));
- }
- this.f_fireEvent("F_ModelCache_OnModelRootLoaded");
- };
- C_ModelCache.prototype.F_GetMemberMetadata=function(_ca){
- var _cb=this.F_GetModelRootResponses()[C_ModelRootRequest.K_eResponse_MemberTreeMetadata];
- return _cb?_cb.selectSingleNode(".//*[@_ref="+_ca.F_ToXPathString()+"]"):null;
- };
- C_ModelCache.prototype.F_GetSiblingHierarchyRootMembers=function(_cc){
- var _cd=this.m_nModelRootCache.selectSingleNode(".//hierarchy[@_ref="+_cc.F_ToXPathString()+"]");
- return _cd.selectNodes("../hierarchy/member");
- };
- C_ModelCache.prototype.F_GetRootMembersResponses=function(){
- var nl=this.m_nRootMembersCache.selectNodes("*");
- var _ce=nl.length;
- if(_ce==0){
- return null;
- }
- var _cf=[];
- for(var i=0;i<_ce;i++){
- _cf.push(nl.item(i).cloneNode(true));
- }
- return _cf;
- };
- C_ModelCache.prototype.F_CacheRootMembersResponse=function(_d0){
- var _d1=[];
- U_XML.F_RemoveNodes(this.m_nRootMembersCache,"*");
- var _d2=_d0?_d0.length:0;
- for(var i=0;i<_d2;i++){
- var n=U_XML.F_ImportNode(this.m_docModelCache,_d0[i],true);
- this.m_nRootMembersCache.appendChild(n);
- _d1.push(n);
- }
- return _d1;
- };
- C_ModelCache.prototype.F_GetFunctionProperty=function(_d3){
- var _d4=this.m_oFunctionProperty[_d3];
- if(_d4!=undefined){
- return _d4;
- }
- var _d5=this.F_GetModelRootResponses();
- if(!_d5){
- G_Debug.F_Print("F_GetFunctionProperty("+_d3+") is undefined. Metadata is required.");
- return;
- }
- var _d6=_d5[C_ModelRootRequest.K_eResponse_Operations];
- var _d7=_d6.selectSingleNode(_d3+"/@value");
- var _d4=_d7?_d7.value:"";
- this.m_oFunctionProperty[_d3]=_d4;
- return _d4;
- };
- C_ModelCache.prototype.F_SupportsSuppression=function(_d8){
- var _d9=this.m_oSupportsSuppression[_d8];
- if(_d9!=undefined){
- return _d9;
- }
- var _da=this.F_GetModelRootResponses();
- if(!_da){
- G_Debug.F_Print("F_SupportsSuppression("+_d8+") is undefined. Metadata is required.");
- return;
- }
- var _db=_da[C_ModelRootRequest.K_eResponse_MemberTreeMetadata];
- var _dc=Boolean(_db.selectSingleNode(".//package[@"+_d8+"='false']"));
- this.m_oSupportsSuppression[_d8]=!_dc;
- return !_dc;
- };
- C_ModelCache.prototype.F_SupportsOperation=function(_dd){
- var _de=this.m_oSupportsOperation[_dd];
- if(_de!=undefined){
- return _de;
- }
- var _df=this.F_GetModelRootResponses();
- if(!_df){
- G_Debug.F_Print("F_SupportsOperation("+_dd+") is undefined. Metadata is required.");
- return;
- }
- var _e0=_df[C_ModelRootRequest.K_eResponse_Operations];
- var _de=Boolean(_e0.selectSingleNode(".//function[@id='"+_dd+"' and (@qosLevel='OK' or @qosLevel='limited' or @qosLevel='restricted')]"));
- this.m_oSupportsOperation[_dd]=_de;
- return _de;
- };
- C_ModelCache.prototype.F_GetModelPath=function(){
- return this.m_sModelPath;
- };
- C_ModelCache.prototype.F_GetModelLocale=function(){
- return this.m_sModelLocale;
- };
- C_ModelCache.prototype.F_GetPackageName=function(){
- return this.m_sPackageName;
- };
- C_ModelCache.prototype.F_GetPackagePath=function(){
- return this.m_sPackagePath;
- };
- C_ModelCache.prototype.F_GetModificationTime=function(){
- return this.m_sModificationTime;
- };
- C_ModelCache.prototype.F_GetRoutingServerGroup=function(){
- return this.m_sRoutingServerGroup;
- };
- C_ModelCache.prototype.F_GetMemberDisplayCountLimit=function(){
- return this.m_iMemberDisplayCountLimit;
- };
- C_ModelCache.prototype.F_ModelEnabled=function(){
- return this.m_bModelEnabled;
- };
- C_ModelCache.prototype.F_ContainsHierarchies=function(){
- return this.m_bContainsHierarchies;
- };
- C_ModelCache.m_sOperations="<Functions authoringLocale=\"@AUTHORING_LOCALE@\">"+"<Properties>"+"<Property name=\"/@listSeparator\"/>"+"<Property name=\"/@decimalSeparator\"/>"+"<Property name=\"./group\"/>"+"<Property name=\"group/@\"/>"+"<Property name=\"./function\"/>"+"<Property name=\"function/@id\"/>"+"<Property name=\"function/@name\"/>"+"<Property name=\"function/@qosLevel\"/>"+"</Properties>"+"<Constraint Condition=\"FDS[@type='operation']\"/>"+"</Functions>";
- C_ModelCache.m_sQueryFunctions="<Functions authoringLocale=\"@AUTHORING_LOCALE@\">"+"<Properties>"+"<Property name=\"./group\"/>"+"<Property name=\"group/@id\"/>"+"<Property name=\"group/@name\"/>"+"<Property name=\"group/@qosLevel\"/>"+"<Property name=\"./function\"/>"+"<Property name=\"function/@id\"/>"+"<Property name=\"function/@name\"/>"+"<Property name=\"function/@tip\"/>"+"<Property name=\"function/@syntax\"/>"+"<Property name=\"function/@example.1\"/>"+"<Property name=\"function/@result.1\"/>"+"<Property name=\"function/@resultdata.1\"/>"+"<Property name=\"function/@example.2\"/>"+"<Property name=\"function/@result.2\"/>"+"<Property name=\"function/@resultdata.2\"/>"+"<Property name=\"function/@example.3\"/>"+"<Property name=\"function/@result.3\"/>"+"<Property name=\"function/@resultdata.3\"/>"+"<Property name=\"function/@example.4\"/>"+"<Property name=\"function/@result.4\"/>"+"<Property name=\"function/@resultdata.4\"/>"+"<Property name=\"function/@example.5\"/>"+"<Property name=\"function/@result.5\"/>"+"<Property name=\"function/@resultdata.5\"/>"+"<Property name=\"function/@dropText\"/>"+"<Property name=\"function/@type\"/>"+"<Property name=\"function/@qosLevel\"/>"+"<Property name=\"function/@datasourceQueryType\"/>"+"</Properties>"+"<Constraints>"+"<Constraint Condition=\"FDS[@type='function']\"/>"+"<Constraint Condition=\"FDS[@type='operator']\"/>"+"<Constraint Condition=\"FDS[@type='literal']\"/>"+"<Constraint Condition=\"FDS[@type='summary']\"/>"+"<Constraint Condition=\"FDS[@context='tabular']\"/>"+"<Constraint Condition=\"FDS[@context='crosstab']\"/>"+"</Constraints>"+"</Functions>";
- C_ModelCache.m_sReportFunctions="<Functions authoringLocale=\"@AUTHORING_LOCALE@\">"+"<Properties>"+"<Property name=\"./group\"/>"+"<Property name=\"group/@id\"/>"+"<Property name=\"group/@name\"/>"+"<Property name=\"./function\"/>"+"<Property name=\"function/@id\"/>"+"<Property name=\"function/@name\"/>"+"<Property name=\"function/@tip\"/>"+"<Property name=\"function/@syntax\"/>"+"<Property name=\"function/@example.1\"/>"+"<Property name=\"function/@result.1\"/>"+"<Property name=\"function/@resultdata.1\"/>"+"<Property name=\"function/@example.2\"/>"+"<Property name=\"function/@result.2\"/>"+"<Property name=\"function/@resultdata.2\"/>"+"<Property name=\"function/@example.3\"/>"+"<Property name=\"function/@result.3\"/>"+"<Property name=\"function/@resultdata.3\"/>"+"<Property name=\"function/@example.4\"/>"+"<Property name=\"function/@result.4\"/>"+"<Property name=\"function/@resultdata.4\"/>"+"<Property name=\"function/@example.5\"/>"+"<Property name=\"function/@result.5\"/>"+"<Property name=\"function/@resultdata.5\"/>"+"<Property name=\"function/@dropText\"/>"+"<Property name=\"function/@type\"/>"+"</Properties>"+"<Constraints>"+"<Constraint Condition=\"FDS[@type='function']\"/>"+"<Constraint Condition=\"FDS[@type='operator']\"/>"+"<Constraint Condition=\"FDS[@type='literal']\"/>"+"<Constraint Condition=\"FDS[@context='CRX']\"/>"+"</Constraints>"+"</Functions>";
- C_ModelCache.m_sMetadataChildren="<Metadata authoringLocale=\"@AUTHORING_LOCALE@\" xml:lang=\"\" Depth=\"@DEPTH@\" start_atPath=\"@MODELPATH@\" no_collections=\"1\" _enumLabels=\"1\">"+"<Properties>"+"<Property name=\"*/@name\"/>"+"<Property name=\"*/@_path\"/>"+"<Property name=\"*/@_ref\"/>"+"<Property name=\"*/@isNamespace\"/>"+"<Property name=\"*/@screenTip\"/>"+"<Property name=\"*/@description\"/>"+"<Property name=\"*/@calcType\"/>"+"<Property name=\"*/@parentChild\"/>"+"<Property name=\"*/@_IntrinsicPropertiesOff\"/>"+"<Property name=\"./dimension\"/>"+"<Property name=\"dimension/@type\"/>"+"<Property name=\"./queryItem\"/>"+"<Property name=\"queryItem/@datatype\"/>"+"<Property name=\"queryItem/@currency\"/>"+"<Property name=\"queryItem/@usage\"/>"+"<Property name=\"queryItem/@regularAggregate\"/>"+"<Property name=\"queryItem/@promptType\"/>"+"<Property name=\"queryItem/@promptFilterItemRef\"/>"+"<Property name=\"queryItem/@promptDisplayItemRef\"/>"+"<Property name=\"queryItem/@promptUseItemRef\"/>"+"<Property name=\"queryItem/@promptCascadeOnRef\"/>"+"<Property name=\"queryItem/@unSortable\"/>"+"<Property name=\"queryItem/@displayType\"/>"+"<Property name=\"./calculation\"/>"+"<Property name=\"calculation/@currency\"/>"+"<Property name=\"calculation/@usage\"/>"+"<Property name=\"calculation/@regularAggregate\"/>"+"<Property name=\"calculation/@promptType\"/>"+"<Property name=\"calculation/@promptFilterItemRef\"/>"+"<Property name=\"calculation/@promptDisplayItemRef\"/>"+"<Property name=\"calculation/@promptUseItemRef\"/>"+"<Property name=\"calculation/@promptCascadeOnRef\"/>"+"<Property name=\"calculation/@unSortable\"/>"+"<Property name=\"calculation/@displayType\"/>"+"<Property name=\"calculation/@calcType\"/>"+"<Property name=\"calculation/@hierarchies\"/>"+"<Property name=\"calculation/@dimensions\"/>"+"<Property name=\"./measure\"/>"+"<Property name=\"measure/@datatype\"/>"+"<Property name=\"measure/@currency\"/>"+"<Property name=\"measure/@isHierarchical\"/>"+"<Property name=\"measure/@regularAggregate\"/>"+"<Property name=\"./folder\"/>"+"<Property name=\"./measureFolder\"/>"+"<Property name=\"./querySubject\"/>"+"<Property name=\"./queryItemFolder\"/>"+"<Property name=\"./filter\"/>"+"<Property name=\"./hierarchy\"/>"+"<Property name=\"./hierarchyFolder\"/>"+"<Property name=\"./level\"/>"+"</Properties>"+"</Metadata>";
- function C_ModelRootRequest(_e1,_e2){
- this.m_oModelCache=_e1;
- var _e3=C_ModelRootRequest.M_sRequest;
- _e3=_e3.replace(/@MODEL@/g,this.m_oModelCache.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _e3=_e3.replace("@MODELPATH@","");
- _e3=_e3.replace(/@AUTHORING_LOCALE@/g,this.m_oModelCache.F_GetModelLocale().F_XMLEncode());
- _e3=_e3.replace("@DEPTH@","2");
- this.F_ConstructBaseClass(_e2,_e3);
- };
- C_ModelRootRequest.F_Extends(C_MetadataRequest);
- C_ModelRootRequest.prototype.F_ProcessResponse=function(){
- C_ModelRootRequest.superClass.F_ProcessResponse.call(this);
- this.m_aModelRootResponses=this.F_GetMetadataResponses();
- if(this.m_aModelRootResponses){
- var _e4=this.m_aModelRootResponses[C_ModelRootRequest.K_eResponse_MemberTreeMetadata];
- if(_e4){
- var d=_e4.ownerDocument;
- var _e5=_e4.selectNodes(".//dimension");
- var _e6=_e5.length;
- this.m_oModelCache.m_bUpdatingCache=true;
- for(var _e7=0;_e7<_e6;_e7++){
- var _e8=_e5.item(_e7);
- var _e9=_e8.getAttribute("_ref");
- var nl=_e8.selectNodes(".//hierarchy[@multiRoot='0' and @rootCaption and @rootCaption!='' and @rootMUN and @rootMUN!='']");
- var _ea=nl.length;
- for(var i=0;i<_ea;i++){
- var _eb=nl.item(i);
- var _ec=_eb.getAttribute("rootCaption");
- var _ed=_eb.getAttribute("rootMUN");
- var _ee=_eb.appendChild(d.createElement("member"));
- _ee.setAttribute("memberCaption",_ec);
- _ee.setAttribute("memberUniqueName",_ed);
- _ee.setAttribute("_path",_ed);
- _ee.setAttribute("_ref",_ed);
- _ee.setAttribute("dimensionUniqueName",_e9);
- _ee.setAttribute("hierarchyUniqueName",_eb.getAttribute("_ref"));
- var _ef=_eb.selectSingleNode("level");
- if(_ef){
- _ee.setAttribute("levelUniqueName",_ef.getAttribute("_ref"));
- }
- this.m_oModelCache.F_CacheMembersResponse(_eb,Number.POSITIVE_INFINITY);
- }
- }
- this.m_oModelCache.m_bUpdatingCache=false;
- this.m_oModelCache.f_flagMembersWithNoChildren();
- }
- }
- this.m_oModelCache.F_CacheModelRootResponse(this.m_aModelRootResponses);
- };
- C_ModelRootRequest.prototype.F_GetModelRootResponses=function(){
- return this.m_aModelRootResponses;
- };
- C_ModelRootRequest.m_sMemberTreeMetadata="<Metadata authoringLocale=\"@AUTHORING_LOCALE@\" xml:lang=\"\" Depth=\"\" start_atPath=\"\" no_collections=\"1\" _enumLabels=\"1\">"+"<Properties>"+"<Property name=\"/@modelSearchPath\"/>"+"<Property name=\"*/@name\"/>"+"<Property name=\"*/@isNamespace\"/>"+"<Property name=\"*/@screenTip\"/>"+"<Property name=\"*/@hierarchies\"/>"+"<Property name=\"*/@dimensions\"/>"+"<Property name=\"*/@_ref\"/>"+"<Property name=\"*/@_path\"/>"+"<Property name=\"*/@usage\"/>"+"<Property name=\"*/@description\"/>"+"<Property name=\"./dataSource\"/>"+"<Property name=\"dataSource/@cubeDescription\"/>"+"<Property name=\"dataSource/@cubePath\"/>"+"<Property name=\"dataSource/@cubeCreatedOn\"/>"+"<Property name=\"dataSource/@cubeDataUpdatedOn\"/>"+"<Property name=\"dataSource/@cubeSchemaUpdatedOn\"/>"+"<Property name=\"dataSource/@cubeIsOptimized\"/>"+"<Property name=\"dataSource/@cubeDefaultMeasure\"/>"+"<Property name=\"dataSource/@cubeCurrentPeriod\"/>"+"<Property name=\"./dimension\"/>"+"<Property name=\"dimension/@type\"/>"+"<Property name=\"dimension/@membersRollup\"/>"+"<Property name=\"./hierarchy\"/>"+"<Property name=\"hierarchy/@parentChild\"/>"+"<Property name=\"hierarchy/@multiRoot\"/>"+"<Property name=\"hierarchy/@rootCaption\"/>"+"<Property name=\"hierarchy/@rootMUN\"/>"+"<Property name=\"./level\"/>"+"<Property name=\"./calculation\"/>"+"<Property name=\"calculation/@currency\"/>"+"<Property name=\"calculation/@usage\"/>"+"<Property name=\"calculation/@regularAggregate\"/>"+"<Property name=\"calculation/@promptType\"/>"+"<Property name=\"calculation/@promptFilterItemRef\"/>"+"<Property name=\"calculation/@promptDisplayItemRef\"/>"+"<Property name=\"calculation/@promptUseItemRef\"/>"+"<Property name=\"calculation/@promptCascadeOnRef\"/>"+"<Property name=\"calculation/@unSortable\"/>"+"<Property name=\"calculation/@displayType\"/>"+"<Property name=\"calculation/@calcType\"/>"+"<Property name=\"./folder\"/>"+"<Property name=\"./hierarchyFolder\"/>"+"<Property name=\"./package\"/>"+"<Property name=\"package/@isAccessToNullSuppressionOptionsAllowed\"/>"+"<Property name=\"package/@isMultiEdgeNullSuppressionAllowed\"/>"+"<Property name=\"package/@isNullSuppressionAllowed\"/>"+"</Properties>"+"</Metadata>";
- C_ModelRootRequest.M_sRequest="<metadataRequest connection=\"@MODEL@\">"+C_ModelRootRequest.m_sMemberTreeMetadata+C_ModelCache.m_sOperations+C_ModelCache.m_sMetadataChildren+C_ModelCache.m_sQueryFunctions+C_ModelCache.m_sReportFunctions+"</metadataRequest>";
- C_ModelRootRequest.K_eResponse_MemberTreeMetadata=0;
- C_ModelRootRequest.K_eResponse_Operations=1;
- C_ModelRootRequest.K_eResponse_MetadataRoot=2;
- C_ModelRootRequest.K_eResponse_QueryFunctions=3;
- C_ModelRootRequest.K_eResponse_ReportFunctions=4;
- function C_MembersRequest(_f0,_f1,_f2,_f3){
- this.m_oModelCache=_f0;
- if(!_f3){
- alert("C_MembersRequest requires a max members parameter");
- return;
- }
- this.m_iMaxMembers=_f3;
- this.m_nMembersRoot=null;
- var _f4=C_MembersRequest.M_sRequest.replace(/@MODEL@/g,this.m_oModelCache.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _f4=_f4.replace(/@MODELPATH@/g,_f2.replace(/\$/g,"$$$$").F_XMLEncode());
- _f4=_f4.replace("@AUTHORING_LOCALE@",this.m_oModelCache.F_GetModelLocale().F_XMLEncode());
- _f4=_f4.replace("@RESULTCOUNT@",this.m_iMaxMembers);
- this.F_ConstructBaseClass(_f1,_f4);
- };
- C_MembersRequest.F_Extends(C_MetadataRequest);
- C_MembersRequest.prototype.F_ProcessResponse=function(){
- C_MembersRequest.superClass.F_ProcessResponse.call(this);
- var _f5=this.F_GetMetadataResponse();
- if(_f5){
- var _f6=_f5.selectSingleNode("member | level | hierarchy | dimension");
- if(_f6){
- this.m_nMembersRoot=this.m_oModelCache.F_CacheMembersResponse(_f6,this.m_iMaxMembers);
- }
- }
- };
- C_MembersRequest.prototype.F_GetMembersResponse=function(){
- return this.m_nMembersRoot;
- };
- C_MembersRequest.M_sRequest="<metadataRequest connection=\"@MODEL@\">"+"<Metadata authoringLocale=\"@AUTHORING_LOCALE@\" xml:lang=\"\" Depth=\"2\" start_atRef=\"@MODELPATH@\" ResultStart=\"0\" ResultCount=\"@RESULTCOUNT@\">"+"<Properties>"+"<Property name=\"./@_RootMembers\"/>"+"<Property name=\"*/@name\"/>"+"<Property name=\"*/@_path\"/>"+"<Property name=\"*/@_ref\"/>"+"<Property name=\"*/@dimensionUniqueName\"/>"+"<Property name=\"*/@hierarchyUniqueName\"/>"+"<Property name=\"*/@levelUniqueName\"/>"+"<Property name=\"*/@memberUniqueName\"/>"+"<Property name=\"*/@memberCaption\"/>"+"<Property name=\"*/@levelNumber\"/>"+"<Property name=\"*/@levelLabel\"/>"+"<Property name=\"*/@parentUniqueName\"/>"+"<Property name=\"*/@currencyCode\"/>"+"<Property name=\"*/@_IntrinsicPropertiesOff\"/>"+"<Property name=\"*/@parentChild\"/>"+"<Property name=\"./folder\"/>"+"<Property name=\"./dimension\"/>"+"<Property name=\"./hierarchy\"/>"+"<Property name=\"./hierarchyFolder\"/>"+"<Property name=\"./level\"/>"+"<Property name=\"./member\"/>"+"</Properties>"+"</Metadata>"+"</metadataRequest>";
- function C_ChildrenMetadataRequest(_f7,_f8,_f9){
- this.m_oModelCache=_f7;
- this.m_nChildrenResponse=null;
- var _fa=C_ChildrenMetadataRequest.M_sRequest;
- _fa=_fa.replace(/@MODEL@/g,this.m_oModelCache.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _fa=_fa.replace(/@MODELPATH@/g,_f9.replace(/\$/g,"$$$$").F_XMLEncode());
- _fa=_fa.replace("@AUTHORING_LOCALE@",this.m_oModelCache.F_GetModelLocale().F_XMLEncode());
- _fa=_fa.replace("@DEPTH@","2");
- this.F_ConstructBaseClass(_f8,_fa);
- };
- C_ChildrenMetadataRequest.F_Extends(C_MetadataRequest);
- C_ChildrenMetadataRequest.prototype.F_ProcessResponse=function(){
- C_ChildrenMetadataRequest.superClass.F_ProcessResponse.call(this);
- var _fb=this.F_GetMetadataResponse();
- if(_fb){
- this.m_nChildrenResponse=this.m_oModelCache.F_CacheChildrenResponse(_fb);
- }
- };
- C_ChildrenMetadataRequest.prototype.F_GetChildrenResponse=function(){
- return this.m_nChildrenResponse;
- };
- function C_AllChildrenMetadataRequest(_fc,_fd,_fe){
- this.m_oModelCache=_fc;
- this.m_nChildrenResponse=null;
- var _ff=C_ChildrenMetadataRequest.M_sRequest;
- _ff=_ff.replace(/@MODEL@/g,this.m_oModelCache.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _ff=_ff.replace(/@MODELPATH@/g,_fe.replace(/\$/g,"$$$$").F_XMLEncode());
- _ff=_ff.replace("@AUTHORING_LOCALE@",this.m_oModelCache.F_GetModelLocale().F_XMLEncode());
- _ff=_ff.replace("@DEPTH@","");
- this.F_ConstructBaseClass(_fd,_ff);
- };
- C_AllChildrenMetadataRequest.F_Extends(C_MetadataRequest);
- C_AllChildrenMetadataRequest.prototype.F_ProcessResponse=function(){
- C_AllChildrenMetadataRequest.superClass.F_ProcessResponse.call(this);
- this.m_nChildrenResponse=this.F_GetMetadataResponse();
- };
- C_AllChildrenMetadataRequest.prototype.F_GetChildrenResponse=function(){
- return this.m_nChildrenResponse;
- };
- C_ChildrenMetadataRequest.M_sRequest="<metadataRequest connection=\"@MODEL@\">"+C_ModelCache.m_sMetadataChildren+"</metadataRequest>";
- function C_LevelMetadataRequest(_100,_101,_102){
- this.m_oModelCache=_100;
- this.m_nChildrenResponse=null;
- var _103=C_LevelMetadataRequest.M_sRequest;
- _103=_103.replace(/@MODEL@/g,this.m_oModelCache.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _103=_103.replace(/@MODELPATH@/g,_102.replace(/\$/g,"$$$$").F_XMLEncode());
- _103=_103.replace("@AUTHORING_LOCALE@",this.m_oModelCache.F_GetModelLocale().F_XMLEncode());
- this.F_ConstructBaseClass(_101,_103);
- };
- C_LevelMetadataRequest.F_Extends(C_MetadataRequest);
- C_LevelMetadataRequest.prototype.F_ProcessResponse=function(){
- C_LevelMetadataRequest.superClass.F_ProcessResponse.call(this);
- var _104=this.F_GetMetadataResponse();
- if(_104){
- this.m_nChildrenResponse=this.m_oModelCache.F_CacheChildrenResponse(_104);
- }
- };
- C_LevelMetadataRequest.prototype.F_GetChildrenResponse=function(){
- return this.m_nChildrenResponse;
- };
- C_LevelMetadataRequest.M_sRequest="<metadataRequest connection=\"@MODEL@\">"+"<Metadata authoringLocale=\"@AUTHORING_LOCALE@\" xml:lang=\"\" Depth=\"2\" start_atPath=\"@MODELPATH@\" no_collections=\"1\" _enumLabels=\"1\">"+"<Properties>"+"<Property name=\"*/@name\"/>"+"<Property name=\"*/@_path\"/>"+"<Property name=\"*/@_ref\"/>"+"<Property name=\"*/@isNamespace\"/>"+"<Property name=\"*/@screenTip\"/>"+"<Property name=\"*/@description\"/>"+"<Property name=\"*/@calcType\"/>"+"<Property name=\"*/@parentChild\"/>"+"<Property name=\"*/@_IntrinsicPropertiesOff\"/>"+"<Property name=\"./queryItem\"/>"+"<Property name=\"queryItem/@datatype\"/>"+"<Property name=\"queryItem/@currency\"/>"+"<Property name=\"queryItem/@usage\"/>"+"<Property name=\"queryItem/@regularAggregate\"/>"+"<Property name=\"queryItem/@promptType\"/>"+"<Property name=\"queryItem/@promptFilterItemRef\"/>"+"<Property name=\"queryItem/@promptDisplayItemRef\"/>"+"<Property name=\"queryItem/@promptUseItemRef\"/>"+"<Property name=\"queryItem/@promptCascadeOnRef\"/>"+"<Property name=\"queryItem/@unSortable\"/>"+"<Property name=\"queryItem/@displayType\"/>"+"<Property name=\"./calculation\"/>"+"<Property name=\"calculation/@currency\"/>"+"<Property name=\"calculation/@usage\"/>"+"<Property name=\"calculation/@regularAggregate\"/>"+"<Property name=\"calculation/@promptType\"/>"+"<Property name=\"calculation/@promptFilterItemRef\"/>"+"<Property name=\"calculation/@promptDisplayItemRef\"/>"+"<Property name=\"calculation/@promptUseItemRef\"/>"+"<Property name=\"calculation/@promptCascadeOnRef\"/>"+"<Property name=\"calculation/@unSortable\"/>"+"<Property name=\"calculation/@displayType\"/>"+"<Property name=\"calculation/@calcType\"/>"+"<Property name=\"./measure\"/>"+"<Property name=\"measure/@isHierarchical\"/>"+"<Property name=\"./dimension\"/>"+"<Property name=\"dimension/@type\"/>"+"<Property name=\"./folder\"/>"+"<Property name=\"./measureFolder\"/>"+"<Property name=\"./querySubject\"/>"+"<Property name=\"./queryItemFolder\"/>"+"<Property name=\"./filter\"/>"+"<Property name=\"./hierarchy\"/>"+"<Property name=\"./hierarchyFolder\"/>"+"<Property name=\"./level\"/>"+"</Properties>"+"</Metadata>"+"</metadataRequest>";
- function C_MembersSearchRequest(_105,_106,_107,_108,_109,_10a){
- this.m_oModelCache=_105;
- if(!_108){
- alert("C_MembersSearchRequest requires a max members parameter");
- return;
- }
- this.m_iMaxMembers=_108;
- this.m_bDescendants=Boolean(_109);
- this.m_sConstraints=_10a;
- var _10b=C_MembersSearchRequest.M_sRequest.replace(/@MODEL@/g,_105.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _10b=_10b.replace(/@MODELPATH@/g,_107.replace(/\$/g,"$$$$").F_XMLEncode());
- _10b=_10b.replace("@AUTHORING_LOCALE@",_105.F_GetModelLocale().F_XMLEncode());
- _10b=_10b.replace("@RESULTCOUNT@",this.m_iMaxMembers);
- _10b=_10b.replace("@CONSTRAINTS@",_10a?_10a:"");
- _10b=_10b.replace("@DEPTH@",_109?"":"2");
- if(_109){
- _10b=_10b.replace("<Property name=\"./@_RootMembers\"/>","");
- }
- this.m_nSearchResponse=null;
- this.F_ConstructBaseClass(_106,_10b);
- };
- C_MembersSearchRequest.F_Extends(C_MetadataRequest);
- C_MembersSearchRequest.prototype.F_ProcessResponse=function(){
- C_MembersSearchRequest.superClass.F_ProcessResponse.call(this);
- var _10c=this.F_GetMetadataResponse();
- if(_10c){
- var _10d=_10c.selectSingleNode("member | level | hierarchy | dimension");
- if(_10d){
- this.m_nSearchResponse=this.m_oModelCache.F_CacheSearchMembersResponse(_10d,this.m_iMaxMembers,this.m_bDescendants,this.m_sConstraints);
- }
- }
- };
- C_MembersSearchRequest.prototype.F_GetSearchResponse=function(){
- return this.m_nSearchResponse;
- };
- C_MembersSearchRequest.M_sRequest="<metadataRequest connection=\"@MODEL@\">"+"<Metadata authoringLocale=\"@AUTHORING_LOCALE@\" xml:lang=\"\" Depth=\"@DEPTH@\" start_atPath=\"@MODELPATH@\" ResultStart=\"0\" ResultCount=\"@RESULTCOUNT@\">"+"<Properties>"+"<Property name=\"./@_RootMembers\"/>"+"<Property name=\"*/@name\"/>"+"<Property name=\"*/@_path\"/>"+"<Property name=\"*/@_ref\"/>"+"<Property name=\"*/@dimensionUniqueName\"/>"+"<Property name=\"*/@hierarchyUniqueName\"/>"+"<Property name=\"*/@levelUniqueName\"/>"+"<Property name=\"*/@memberUniqueName\"/>"+"<Property name=\"*/@memberCaption\"/>"+"<Property name=\"*/@levelNumber\"/>"+"<Property name=\"*/@levelLabel\"/>"+"<Property name=\"*/@parentUniqueName\"/>"+"<Property name=\"*/@currencyCode\"/>"+"<Property name=\"*/@_IntrinsicPropertiesOff\"/>"+"<Property name=\"*/@parentChild\"/>"+"<Property name=\"./folder\"/>"+"<Property name=\"./dimension\"/>"+"<Property name=\"./hierarchy\"/>"+"<Property name=\"./hierarchyFolder\"/>"+"<Property name=\"./level\"/>"+"<Property name=\"./member\"/>"+"</Properties>"+"@CONSTRAINTS@"+"</Metadata>"+"</metadataRequest>";
- function C_MeasuresSearchRequest(_10e,_10f,_110,_111,_112,_113){
- if(!_111){
- alert("C_MembersSearchRequest requires a max members parameter");
- return;
- }
- this.m_bDescendants=Boolean(_112);
- var _114=C_MeasuresSearchRequest.M_sRequest.replace(/@MODEL@/g,_10e.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _114=_114.replace(/@MODELPATH@/g,_110.replace(/\$/g,"$$$$").F_XMLEncode());
- _114=_114.replace("@AUTHORING_LOCALE@",_10e.F_GetModelLocale().F_XMLEncode());
- _114=_114.replace("@RESULTCOUNT@",this.m_iMaxMeasures);
- _114=_114.replace("@CONSTRAINTS@",_113?_113:"");
- _114=_114.replace("@DEPTH@",_112?"":"2");
- this.F_ConstructBaseClass(_10f,_114);
- };
- C_MeasuresSearchRequest.F_Extends(C_MetadataRequest);
- C_MeasuresSearchRequest.prototype.F_ProcessResponse=function(){
- C_MeasuresSearchRequest.superClass.F_ProcessResponse.call(this);
- this.m_nSearchResponse=null;
- var _115=this.F_GetMetadataResponse();
- if(_115){
- this.m_nSearchResponse=_115.cloneNode(false);
- var _116=_115.selectSingleNode("dimension");
- if(_116){
- var _117=this.m_nSearchResponse.appendChild(_116.cloneNode(false));
- var _118=_115.selectNodes(".//measure");
- for(var i=0;i<_118.length;i++){
- _117.appendChild(_118.item(i).cloneNode(false));
- }
- }
- }
- };
- C_MeasuresSearchRequest.prototype.F_GetSearchResponse=function(){
- return this.m_nSearchResponse;
- };
- C_MeasuresSearchRequest.M_sRequest="<metadataRequest connection=\"@MODEL@\">"+"<Metadata authoringLocale=\"@AUTHORING_LOCALE@\" xml:lang=\"\" Depth=\"@DEPTH@\" start_atPath=\"@MODELPATH@\" no_collections=\"1\" _enumLabels=\"1\">"+"<Properties>"+"<Property name=\"*/@name\"/>"+"<Property name=\"*/@_path\"/>"+"<Property name=\"*/@_ref\"/>"+"<Property name=\"*/@isNamespace\"/>"+"<Property name=\"*/@screenTip\"/>"+"<Property name=\"*/@description\"/>"+"<Property name=\"*/@parentChild\"/>"+"<Property name=\"*/@_IntrinsicPropertiesOff\"/>"+"<Property name=\"./dimension\"/>"+"<Property name=\"dimension/@type\"/>"+"<Property name=\"./queryItem\"/>"+"<Property name=\"queryItem/@datatype\"/>"+"<Property name=\"queryItem/@currency\"/>"+"<Property name=\"queryItem/@usage\"/>"+"<Property name=\"queryItem/@regularAggregate\"/>"+"<Property name=\"queryItem/@promptType\"/>"+"<Property name=\"queryItem/@promptFilterItemRef\"/>"+"<Property name=\"queryItem/@promptDisplayItemRef\"/>"+"<Property name=\"queryItem/@promptUseItemRef\"/>"+"<Property name=\"queryItem/@promptCascadeOnRef\"/>"+"<Property name=\"queryItem/@unSortable\"/>"+"<Property name=\"queryItem/@displayType\"/>"+"<Property name=\"./calculation\"/>"+"<Property name=\"calculation/@currency\"/>"+"<Property name=\"calculation/@usage\"/>"+"<Property name=\"calculation/@regularAggregate\"/>"+"<Property name=\"calculation/@promptType\"/>"+"<Property name=\"calculation/@promptFilterItemRef\"/>"+"<Property name=\"calculation/@promptDisplayItemRef\"/>"+"<Property name=\"calculation/@promptUseItemRef\"/>"+"<Property name=\"calculation/@promptCascadeOnRef\"/>"+"<Property name=\"calculation/@unSortable\"/>"+"<Property name=\"calculation/@displayType\"/>"+"<Property name=\"calculation/@calcType\"/>"+"<Property name=\"./measure\"/>"+"<Property name=\"measure/@isHierarchical\"/>"+"<Property name=\"measure/@datatype\"/>"+"<Property name=\"measure/@currency\"/>"+"<Property name=\"measure/@regularAggregate\"/>"+"<Property name=\"./folder\"/>"+"<Property name=\"./measureFolder\"/>"+"<Property name=\"./querySubject\"/>"+"<Property name=\"./queryItemFolder\"/>"+"<Property name=\"./filter\"/>"+"<Property name=\"./hierarchy\"/>"+"<Property name=\"./hierarchyFolder\"/>"+"<Property name=\"./level\"/>"+"</Properties>"+"@CONSTRAINTS@"+"</Metadata>"+"</metadataRequest>";
- C_ModelCache.prototype.F_GetAncestorInfo=function(_119,_11a){
- return this.m_oAncestorInfoCache[_119+" "+_11a];
- };
- C_ModelCache.prototype.f_cacheAncestorInfo=function(_11b,_11c,_11d,_11e){
- var _11f={};
- _11f.M_sMUN=_11d;
- _11f.M_sMemberCaption=_11e;
- this.m_oAncestorInfoCache[_11b+" "+_11c]=_11f;
- return _11f;
- };
- function C_MemberAncestorRequest(_120,_121,_122,_123){
- this.m_oModelCache=_120;
- this.m_sMUN=_122;
- this.m_iDistance=_123;
- var _124=_122;
- for(var i=0;i<_123;++i){
- _124="parent("+_124+")";
- }
- var _125=G_ResManager.F_GetResource("CCHL_ReportAncestor").text;
- _125=_125.replace("@XMLNS@",G_ReportSpec.F_GetServerSupportedReportSpecNamespace());
- _125=_125.replace(/@MODEL@/g,this.m_oModelCache.F_GetModelPath().replace(/\$/g,"$$$$").F_XMLEncode());
- _125=_125.replace("@ANCESTOREXPR@",_124.F_XMLEncode());
- this.F_ConstructBaseClass(_121,_125,null,"XML");
- };
- C_MemberAncestorRequest.F_Extends(C_RunReportRequest);
- C_MemberAncestorRequest.prototype.F_ProcessResponse=function(){
- C_MemberAncestorRequest.superClass.F_ProcessResponse.call(this);
- var _126=this.F_GetReportOutput();
- if(_126){
- var d=U_XML.F_LoadString(null,_126);
- if(!d){
- this.F_SetNewErrorRes("IDS_CCHL_BAD_ANCESTOR_RESPONSE",_126);
- return;
- }
- d.setProperty("SelectionNamespaces","xmlns:xx='http://developer.cognos.com/schemas/xmldata/1/'");
- var nl=d.documentElement.selectNodes(".//xx:value");
- if(nl.length==2){
- this.m_oAncestorInfo=this.m_oModelCache.f_cacheAncestorInfo(this.m_sMUN,this.m_iDistance,nl.item(0).text,nl.item(1).text);
- }else{
- this.m_oAncestorInfo=this.m_oModelCache.f_cacheAncestorInfo(this.m_sMUN,this.m_iDistance,null,null);
- }
- }
- };
- C_MemberAncestorRequest.prototype.F_GetAncestorInfo=function(){
- return this.m_oAncestorInfo;
- };
- var D_ManagePersonalData={};
- D_ManagePersonalData.F_Show=function(_127,_128,_129){
- this.m_oExternalListener=_129;
- this.m_sModelPath=_128;
- this.m_iMaxExtFiles=0;
- var _12a=G_ResManager.F_GetString("IDS_TITLE_MANAGE_PERSONALDATA");
- this.M_fnSuper_Show(_127,this,_12a);
- };
- D_ManagePersonalData.F_Dialog_OnBeforeVisible=function(){
- this.m_oAvailable=new C_ListView(this.F_GetDlgItem("divAvailable"),G_ResManager.F_GetResource("EmptyMultiSelectList"),this);
- this.m_oToolbar=new C_Toolbar(this.F_GetDlgItem("divToolbar"),this.F_GetResource("ToolbarManagePersonalData"),this);
- this.m_oAvailable.F_SelectByIndex(0);
- this.f_setButtonState();
- this.m_bPackageNameChanged=false;
- };
- D_ManagePersonalData.F_Dialog_OnAfterVisible=function(){
- this.f_getPersonalData();
- };
- D_ManagePersonalData.F_Request_OnComplete=function(_12b){
- if(this.pdWorkingDialog){
- this.pdWorkingDialog.hide();
- }
- var _12c=_12b.F_GetError();
- if(_12c){
- pd.messageBox(pd.statics.MB_ERROR,PDMSG.ERR.IDS_ERR_PACKAGE_PUBLISH,_12c.m_sErrorCode+" "+_12c.m_sErrorSummary,_12c.m_sErrorDetails?_12c.m_sErrorDetails:null);
- return;
- }
- if(_12b.constructor==C_PersonalDataRequest||_12b.constructor==C_PersonalDataSyncRequest){
- var _12d=_12b.F_GetResponseXMLString();
- this.m_oOuputXML=_12b.F_GetResponseXML();
- switch(_12b.F_GetRequestType()){
- case "getPersonalData":
- if(_12c){
- this.m_docInputXML=U_XML.F_LoadString(null,"<input><pdCollection><baseModelSearchPath>"+this.m_sModelPath+"</baseModelSearchPath></pdCollection></input>");
- }else{
- G_Debug.F_Print("getPersonalData response = "+_12d);
- var _12e=_12d.replace(/<output>/g,"<addPersonalData><input>").replace(/<\/output>/g,"</input></addPersonalData>").replace(/<targetPackageSearchPath>/g,"<baseModelSearchPath>").replace(/<\/targetPackageSearchPath>/g,"</baseModelSearchPath>");
- this.m_docInputXML=U_XML.F_LoadString(null,_12e);
- var _12f=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/baseModelSearchPath").item(0);
- if(_12f.text==""){
- _12f.text=this.m_sModelPath;
- }
- var _130=_12f.text;
- var i=_130.lastIndexOf("/model");
- var _131=(i>=0)?_130.substr(0,i):_130;
- var _132=_131+"/model[last()]";
- _12f.text=_132;
- this.f_getGovernorSettings();
- var _133=this.f_populateAvailable();
- this.f_setButtonState();
- if(_133==0&&(this.m_nMaxExtFiles>0)){
- this.m_bEditingPublishedPackage=false;
- this.m_sBasePackageName=G_Model.F_GetPackageName();
- D_AddPersonalWizard.F_Show(this,this.m_bEditingPublishedPackage,this.m_sModelPath);
- }else{
- this.m_bEditingPublishedPackage=true;
- this.m_sBasePackageName=this.f_extractPackageNameFromXPath(this.m_docInputXML.selectSingleNode("/addPersonalData/input/pdCollection/baseModelSearchPath"));
- }
- if(this.m_bEditingPublishedPackage){
- this.m_sTargetPath=G_Model.F_GetPackagePath().replace("/package[@name='"+G_Model.F_GetPackageName()+"']","");
- this.m_sTargetName=G_Model.F_GetPackageName();
- }else{
- this.m_sTargetPath="~/folder";
- this.m_sTargetName=G_Model.F_GetPackageName()+G_ResManager.F_GetString("IDS_EXTERNAL_DATA_FILE_ADDITION");
- }
- this.f_updatePackageName();
- }
- break;
- case "addPersonalData":
- this.F_Hide();
- var _134=this.m_oOuputXML.selectNodes("/output/personalPackagePath").item(0);
- G_App.F_ResetModel(_134.text,this.f_displayExternalDataAvailableMessage.F_CreateMethodCallback(this));
- break;
- case "addLOBData":
- location.href=g_pd_backURL;
- break;
- }
- }else{
- if(_12b.constructor==C_FolderContentsRequest){
- var _135=_12b.F_GetResponse();
- this.f_checkPackageNameBeforePublishing(_135);
- }
- }
- };
- D_ManagePersonalData.f_extractPackageNameFromXPath=function(_136){
- var _137="";
- if(_136){
- var _138=_136.text.lastIndexOf("package[@name='");
- _137=_136.text.substring(_138+15);
- var _139=_137.indexOf("']");
- _137=_137.substring(0,_139);
- }
- return _137;
- };
- D_ManagePersonalData.f_displayExternalDataAvailableMessage=function(){
- G_Toolbox.F_DisplayMessagePopup("manage_external_data.gif",null,"IDS_TOOLTIP_MANAGE_EXTERNAL_DATA",null,"IDS_TOOLTIPDESC_EXTERNAL_DATA_READY");
- };
- D_ManagePersonalData.F_Dialog_OnAfterHide=function(){
- this.m_oAvailable.F_Detach();
- this.m_oToolbar.F_Detach();
- delete this.m_oToolbar;
- delete this.m_oAvailable;
- delete this.m_aAllowedExisting;
- };
- D_ManagePersonalData.F_OnOK=function(){
- if(this.m_bPackageNameChanged||!this.m_bEditingPublishedPackage){
- G_Debug.F_Print("Package name needs to be checked for uniqueness");
- this.f_checkPackageNameOnOK();
- return;
- }else{
- G_Debug.F_Print("Package just edited");
- this.f_performOnOK();
- }
- };
- D_ManagePersonalData.f_performOnOK=function(){
- if(G_Model.F_IsMultiDimensionalSource()){
- var fn=D_ManagePersonalData.f_publishPackage.F_CreateMethodCallback(this);
- var _13a=this.m_sTargetName?this.m_sTargetName:"";
- var _13b=this.f_getSafeExternalFileName();
- var _13c=this.f_getSafeReportName();
- var _13d=this.m_sBasePackageName?this.m_sBasePackageName:"";
- var _13e=G_ResManager.F_GetString("IDS_MSG_OLAPEXTDATA_WARNING",_13a,_13b,_13c,_13d);
- D_MsgBox.F_Show(null,_13e,null,D_MsgBox.K_iWarning,D_MsgBox.K_iOKOnly,fn,null,null,"dlgPackagesPersonalData");
- return;
- }else{
- if(this.F_hasReportData()){
- var fn=D_ManagePersonalData.f_publishPackage.F_CreateMethodCallback(this);
- var _13a=this.m_sTargetName?this.m_sTargetName:"";
- var _13b=this.f_getSafeExternalFileName();
- var _13c=this.f_getSafeReportName();
- var _13d=this.m_sBasePackageName?this.m_sBasePackageName:"";
- var _13e=G_ResManager.F_GetString("IDS_MSG_REPORTEXTDATA_WARNING",_13a,_13b,_13c,_13d);
- D_MsgBox.F_Show(null,_13e,null,D_MsgBox.K_iWarning,D_MsgBox.K_iOKOnly,fn,null,null,"dlgPackagesPersonalData");
- return;
- }
- }
- if(this.m_docInputXML){
- this.f_publishPackage();
- return;
- }
- this.M_fnSuper_OnOK();
- };
- D_ManagePersonalData.f_checkPackageNameOnOK=function(){
- var _13f=new C_FolderContentsRequest(this,this.m_sTargetPath);
- _13f.F_Send();
- };
- D_ManagePersonalData.f_checkPackageNameBeforePublishing=function(_140){
- var _141=[];
- var _142=G_ContentManager.F_ProcessCmResponse(_140);
- if(_142){
- var nl=_142.selectNodes("item");
- var _143=nl.length;
- for(var i=0;i<_143;i++){
- var _144=nl.item(i);
- var _145=_144.selectSingleNode("defaultName/value").text;
- _141.push(_145.toLowerCase());
- }
- }
- if(_141.indexOf(this.m_sTargetName.toLowerCase())!=-1){
- D_ManagePersonalData.pd_packageOverwriteConfirm();
- }else{
- this.f_publishPackage();
- }
- };
- D_ManagePersonalData.f_getSafeExternalFileName=function(){
- var _146="";
- var _147=this.m_docInputXML.selectSingleNode("/addPersonalData/input/pdCollection/pdSpec/dataSet/sourcePath");
- if(_147){
- _146=_147.text;
- }
- return _146;
- };
- D_ManagePersonalData.f_getSafeReportName=function(){
- var _148=G_ResManager.F_GetString("IDS_MSG_EXTDATA_NO_REPORT_PARAM");
- var _149=this.m_docInputXML.selectSingleNode("/addPersonalData/input/pdCollection/pdSpec/reportExtract/reportSubject/@name");
- if(_149){
- _148=_149.value;
- }
- return _148;
- };
- D_ManagePersonalData.F_hasReportData=function(){
- return Boolean(this.m_docInputXML&&this.m_docInputXML.selectSingleNode("//reportExtract"));
- };
- D_ManagePersonalData.f_publishPackage=function(_14a){
- this.pdWorkingDialog=pd.workingDialog(PDMSG.IPT.IDS_IPT_CREATING_PACKAGE);
- var _14a=_14a||"addLOBData";
- var _14b=this.m_docInputXML.selectSingleNode("/"+_14a+"/input/pdCollection/targetPath");
- if(!_14b){
- var _14c=this.m_docInputXML.selectSingleNode("/"+_14a+"/input/pdCollection");
- _14b=U_XML.F_AppendChild(_14c,"targetPath");
- }
- _14b.text=this.m_sTargetPath;
- var _14d=this.m_docInputXML.selectSingleNode("/"+_14a+"/input/pdCollection/targetName");
- if(!_14d){
- var _14c=this.m_docInputXML.selectSingleNode("/"+_14a+"/input/pdCollection");
- _14d=U_XML.F_AppendChild(_14c,"targetName");
- }
- _14d.text=this.m_sTargetName;
- G_Debug.F_Print("publish request XML = "+U_XML.F_SerializeNode(this.m_docInputXML.documentElement));
- var _14e=new C_PersonalDataRequest(this,U_XML.F_SerializeNode(this.m_docInputXML.documentElement),_14a);
- C_BusRequest.F_ReleaseAllTracking();
- _14e.F_Send();
- };
- D_ManagePersonalData.F_OnCancel=function(){
- this.M_fnSuper_OnCancel();
- };
- D_ManagePersonalData.F_ListView_OnItemClick=function(_14f,_150,_151){
- this.f_setButtonState();
- };
- D_ManagePersonalData.F_OnDeleteClick=function(){
- var _152=this.F_GetPersonalDataItemName();
- var _153=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec/personalData");
- if(_153){
- for(var i=0;i<_153.length;i++){
- var _154=_153.item(i).getAttribute("name").F_XMLDecode();
- if(_152==_154){
- var _155=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec").item(i);
- _155.parentNode.removeChild(_155);
- break;
- }
- }
- }
- this.f_populateAvailable();
- this.f_setButtonState();
- };
- D_ManagePersonalData.F_OnAddPersonalData=function(){
- D_AddPersonalWizard.F_Show(this,this.m_bEditingPublishedPackage,this.m_sModelPath);
- };
- D_ManagePersonalData.F_OnEditClick=function(){
- this.f_modifyPersonalData(this.m_oAvailable.F_GetSelectedListItem().getAttribute("label"));
- };
- D_ManagePersonalData.F_Dialog_OnCommit=function(_156){
- if(_156==this){
- if(this.m_oExternalListener){
- this.m_oExternalListener.F_Dialog_OnCommit(this);
- }
- }else{
- if(_156==D_ContentManager){
- if(this.m_sTargetPath!=D_ContentManager.F_GetSaveDirectory()){
- this.m_sTargetPath=D_ContentManager.F_GetSaveDirectory();
- this.m_bPackageNameChanged=true;
- }
- if(this.m_sTargetName!=D_ContentManager.F_GetSaveFileName()){
- this.m_sTargetName=D_ContentManager.F_GetSaveFileName();
- this.m_bPackageNameChanged=true;
- }
- this.f_updatePackageName();
- G_Debug.F_Print("Package chosen: path '"+this.m_sTargetPath+"', name '"+this.m_sTargetName+"'");
- }else{
- this.f_populateAvailable();
- this.f_setButtonState();
- }
- }
- };
- D_ManagePersonalData.F_GetPersonalDataItemName=function(){
- return this.m_oAvailable.F_GetSelectedListItem().getAttribute("label");
- };
- D_ManagePersonalData.F_OnKeyDown=function(e){
- e=e||window.event;
- if(e.keyCode==U_DOM.K_iKeyDelete&&this.m_oAvailable.F_GetSelectedListItems().length>0){
- this.F_OnDeleteClick();
- }
- this.M_fnSuper_OnKeyDown(e);
- };
- D_ManagePersonalData.f_updatePackageName=function(){
- this.F_GetDlgItem("txtPackageName").value=this.m_sTargetName;
- };
- D_ManagePersonalData.f_pickPackagePath=function(){
- var _157={"package":true,"folder":true};
- D_ContentManager.F_ShowSave(this,_157,this.m_sTargetPath,this.m_sTargetName);
- };
- D_ManagePersonalData.f_setButtonState=function(){
- var _158=0;
- if(this.m_docInputXML){
- var _159=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec/personalData");
- if(_159){
- _158=_159.length;
- }
- }
- this.m_oToolbar.F_SetButtonEnabled("btnManagePersonalDataAdd",_158<this.m_nMaxExtFiles);
- var _15a=this.m_oAvailable.F_GetSelectedListItems();
- this.m_oToolbar.F_SetButtonEnabled("btnManagePersonalDataDelete",_15a.length>0);
- this.m_oToolbar.F_SetButtonEnabled("btnManagePersonalDataEdit",_15a.length==1);
- };
- D_ManagePersonalData.f_getPersonalData=function(){
- var _15b="<getPersonalData><input><modelSearchPath>"+this.m_sModelPath.F_XMLEncode()+"</modelSearchPath></input></getPersonalData>";
- var _15c=new C_PersonalDataSyncRequest(this,_15b,"getPersonalData");
- D_Progress.F_SendRequest(_15c,this.F_GetDialogWindow(),G_ResManager.F_GetString("IDS_MSG_GET_EXTERNAL_DATA"));
- };
- D_ManagePersonalData.f_addPersonalData=function(_15d,_15e){
- this.m_oPDSpecsXML=_15d;
- var _15f=_15d.selectNodes("/pdSpec").item(0);
- if(_15e){
- var _160=this.F_GetPersonalDataItemName();
- var _161=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec/personalData");
- if(_161){
- for(var i=0;i<_161.length;i++){
- var _162=_161.item(i).getAttribute("name").F_XMLDecode();
- if(_160==_162){
- var _163=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec").item(i);
- _163.parentNode.removeChild(_163);
- break;
- }
- }
- }
- }
- var _164=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection").item(0);
- _164.appendChild(U_XML.F_ImportNode(this.m_docInputXML,_15f,true));
- G_Debug.F_Print("this.m_docInputXML = "+this.m_docInputXML.xml);
- this.f_populateAvailable();
- this.f_setButtonState();
- };
- D_ManagePersonalData.f_populateAvailable=function(){
- this.m_oAvailable.F_Clear();
- var _165;
- if(this.m_docInputXML){
- _165=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec/personalData");
- if(_165){
- for(var i=0;i<_165.length;i++){
- var _166=_165.item(i).getAttribute("name").F_XMLDecode();
- var _167=this.m_oAvailable.F_AppendNewListItem();
- _167.setAttribute("label",_166);
- _167.setAttribute("value",_166);
- }
- }
- }
- this.m_oAvailable.F_Draw();
- this.m_oAvailable.F_SelectByIndex(0);
- if(_165){
- return _165.length;
- }
- };
- D_ManagePersonalData.f_modifyPersonalData=function(_168){
- var _169="";
- if(this.m_docInputXML){
- var _16a=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec/personalData");
- if(_16a){
- for(var i=0;i<_16a.length;i++){
- var _16b=_16a.item(i).getAttribute("name").F_XMLDecode();
- if(_168==_16b){
- _169=this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec").item(i);
- var _16c=U_XML.F_SerializeNode(this.m_docInputXML.selectNodes("/addPersonalData/input/pdCollection/pdSpec").item(i));
- var _16d=U_XML.F_LoadString(null,_16c);
- D_AddPersonalWizard.F_Show(this,this.m_bEditingPublishedPackage,this.m_sModelPath,_16d);
- break;
- }
- }
- }
- }
- };
- D_ManagePersonalData.f_getGovernorSettings=function(){
- this.m_nMaxExtFiles=0;
- if(this.m_docInputXML){
- var _16e=this.m_docInputXML.selectNodes("/addPersonalData/input/governors/governor");
- if(_16e){
- for(var i=0;i<_16e.length;i++){
- var _16f=_16e.item(i).getAttribute("name");
- if(_16f=="maxPersonalDataSources"){
- var _170=_16e.item(i).childNodes[0].nodeValue;
- this.m_nMaxExtFiles=parseInt(_170);
- }
- }
- var x=this.m_docInputXML.getElementsByTagName("governors")[0];
- if(x){
- x.parentNode.removeChild(x);
- }
- }
- }
- };
- function C_PersonalDataRequest(_171,_172,_173){
- C_PersonalDataRequest.m_sLastRequest=_172;
- C_PersonalDataRequest.m_sLastResponse="";
- this.m_aMetadataResponses=null;
- this.m_sPDResponseXMLString="";
- this.m_nPDResponse=null;
- this.m_sRequestType=_173;
- var _174=this.f_buildBusRequest(_172);
- this.F_ConstructBaseClass(_171,C_PersonalDataRequest.K_sSOAPAction_metadataService,_174);
- this.f_setupAsync();
- this.F_AddNamespace(C_PersonalDataRequest.k_sBIBusMDNamespaceDecl);
- };
- C_PersonalDataRequest.F_Extends(C_BusRequest);
- C_PersonalDataRequest.K_sPrimaryWaitThreshold=30;
- C_PersonalDataRequest.K_sSecondaryWaitThreshold=30;
- C_PersonalDataRequest.K_sSOAPAction_metadataService_high="http://www.ibm.com/xmlns/prod/cognos/metadataService/201610/.high";
- C_PersonalDataRequest.K_sSOAPAction_metadataService_absolute="http://www.ibm.com/xmlns/prod/cognos/metadataService/201610/.absolute";
- C_PersonalDataRequest.K_sSOAPAction_metadataService_control="http://www.ibm.com/xmlns/prod/cognos/metadataService/201610/.session";
- C_PersonalDataRequest.K_sSOAPAction_metadataService="http://www.ibm.com/xmlns/prod/cognos/metadataService/201610/";
- C_PersonalDataRequest.k_sBIBusMDNamespaceDecl="xmlns:md1='http://developer.cognos.com/schemas/metadataService/3'";
- C_PersonalDataRequest.prototype.f_buildBusRequest=function(_175){
- var _176="<md1:runSpecification>"+"<bus:specification xsi:type=\"bus:metadataServiceSpecification\">"+"<bus:value xsi:type=\"bus:specification\">"+_175.F_XMLEncode()+"</bus:value>"+"</bus:specification>"+G_BusServer.F_GetParameterValues()+"<bus:options SOAP-ENC:arrayType=\"bus:option[]\" xsi:type=\"SOAP-ENC:Array\">"+"<item xsi:type=\"bus:asynchOptionInt\">"+"<bus:name xsi:type=\"bus:asynchOptionEnum\">primaryWaitThreshold</bus:name>"+"<bus:value xsi:type=\"xsd:int\">"+C_PersonalDataRequest.K_sPrimaryWaitThreshold+"</bus:value>"+"</item>"+"<item xsi:type=\"bus:asynchOptionInt\">"+"<bus:name xsi:type=\"bus:asynchOptionEnum\">secondaryWaitThreshold</bus:name>"+"<bus:value xsi:type=\"xsd:int\">"+C_PersonalDataRequest.K_sSecondaryWaitThreshold+"</bus:value>"+"</item>"+"<item xsi:type=\"bus:runOptionBoolean\">"+"<bus:name xsi:type=\"bus:runOptionEnum\">prompt</bus:name>"+"<bus:value xsi:type=\"xsd:boolean\">false</bus:value>"+"</item>"+"</bus:options>"+"</md1:runSpecification>";
- return _176;
- };
- C_PersonalDataRequest.prototype.f_setupAsync=function(){
- this.F_SetAsyncBusRequest("md1:wait","md1:cancel","md1:getOutput",C_PersonalDataRequest.K_sSOAPAction_metadataService_absolute,C_PersonalDataRequest.K_sSOAPAction_metadataService_control);
- };
- C_PersonalDataRequest.F_GetLastRequest=function(){
- return this.m_sLastRequest?this.m_sLastRequest:"";
- };
- C_PersonalDataRequest.F_GetLastResponse=function(){
- return this.m_sLastResponse?this.m_sLastResponse:"";
- };
- C_PersonalDataRequest.prototype.F_ProcessResponse=function(){
- C_PersonalDataRequest.superClass.F_ProcessResponse.call(this);
- var _177=this.F_GetResponse();
- this.m_aMetadataResponses=this.F_GetResponse();
- if(!_177){
- return;
- }
- var _178=_177.selectNodes("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/bus:result/details/item/data");
- if(_178.length>0){
- var _179=new Base64();
- this.m_sPDResponseXMLString=this.f_utf8ByteStringToString(_179.decode64(_178.item(0).text));
- this.m_nPDResponse=U_XML.F_LoadString(null,this.m_sPDResponseXMLString);
- }
- };
- C_PersonalDataRequest.prototype.f_utf8ByteStringToString=function(_17a){
- var _17b=[];
- var _17c=_17a.length;
- for(var i=0;i<_17c;){
- var _17d=_17a.charCodeAt(i++);
- if(_17d<128){
- _17b.push(String.fromCharCode(_17d));
- continue;
- }
- var _17e=_17a.charCodeAt(i++);
- if((_17d>191)&&(_17d<224)){
- _17b.push(String.fromCharCode(((_17d&31)<<6)|(_17e&63)));
- continue;
- }
- var _17f=_17a.charCodeAt(i++);
- _17b.push(String.fromCharCode(((_17d&15)<<12)|((_17e&63)<<6)|(_17f&63)));
- }
- return _17b.join("");
- };
- C_PersonalDataRequest.prototype.F_GetRequestType=function(){
- return this.m_sRequestType?this.m_sRequestType:"";
- };
- C_PersonalDataRequest.prototype.F_GetResponseXMLString=function(){
- return this.m_sPDResponseXMLString?this.m_sPDResponseXMLString:"";
- };
- C_PersonalDataRequest.prototype.F_GetResponseXML=function(){
- return this.m_nPDResponse?this.m_nPDResponse:null;
- };
- C_PersonalDataRequest.prototype.F_GetMetadataResponses=function(){
- return this.m_aMetadataResponses;
- };
- C_PersonalDataRequest.prototype.F_GetMetadataResponse=function(){
- var a=this.F_GetMetadataResponses();
- return a?a[0]:null;
- };
- function C_PersonalDataSyncRequest(_180,_181,_182){
- this.F_ConstructBaseClass(_180,_181,_182);
- };
- C_PersonalDataSyncRequest.F_Extends(C_PersonalDataRequest);
- C_PersonalDataSyncRequest.prototype.f_buildBusRequest=function(_183){
- var _184=_183;
- return _184;
- };
- C_PersonalDataSyncRequest.prototype.f_setupAsync=function(){
- };
- C_PersonalDataSyncRequest.prototype.F_ProcessResponse=function(){
- C_PersonalDataRequest.superClass.F_ProcessResponse.call(this);
- var _185=this.F_GetResponse();
- if(!_185){
- return;
- }
- var _186=_185.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/output");
- if(_186){
- this.m_sPDResponseXMLString=U_XML.F_SerializeNode(_186);
- this.m_nPDResponse=_186;
- }else{
- this.m_sPDResponseXMLString="";
- this.m_nPDResponse=null;
- }
- };
- var D_AddPersonalWizard={};
- D_AddPersonalWizard.F_Show=function(_187,_188,_189,_18a){
- if(G_BrowserInfo.M_bIsIE&&!U_DOM.F_IsVmlSupported()){
- F_MsgBoxRes("IDS_MSG_NO_VML");
- return;
- }
- this.m_oDocUploadResponse=null;
- this.m_sModelPath=_189;
- this.m_oPecXML=_18a;
- this.m_bIsModify=_18a!=null;
- this.m_bEditingPublishedPackage=_188;
- this.m_sQueryName="";
- this.m_sProcessResponse="";
- this.M_fnSuper_Show(null,_187,G_ResManager.F_GetString("IDS_TITLE_ADDPERSONAL_DATA"));
- };
- D_AddPersonalWizard.K_iSelectDataPage=0;
- D_AddPersonalWizard.K_iLinksPage=1;
- D_AddPersonalWizard.K_iDataAttribPage=2;
- D_AddPersonalWizard.K_iLinkAttribPage=3;
- D_AddPersonalWizard.K_iOneToMany=0;
- D_AddPersonalWizard.K_iOneToOne=1;
- D_AddPersonalWizard.K_iOptToMany=2;
- D_AddPersonalWizard.K_iOptToOne=3;
- D_AddPersonalWizard.F_Dialog_OnInit=function(){
- this.m_divExternalQSItems=this.F_GetDlgItem("divExternalItems");
- this.m_divLeft=this.m_divExternalQSItems;
- this.m_divLinks=this.F_GetDlgItem("divLinks");
- this.m_divLinks.onmousedown=new Function("D_AddPersonalWizard.f_selectLink(-1)");
- this.m_divExistingQSItems=this.F_GetDlgItem("divExistingItems");
- this.m_divRight=this.m_divExistingQSItems;
- if(!G_BrowserInfo.M_bIsIE){
- this.m_elSvg=this.m_divLinks.appendChild(document.createElementNS("http://www.w3.org/2000/svg","svg"));
- this.m_elSvg.style.height="180px";
- this.m_elSvg.style.width="150px";
- }
- this.m_nlCardinalityLabels=G_ResManager.F_GetResource("cardinality").selectNodes("listItems/listItem");
- this.m_radAllValUniqueExternal=this.F_GetDlgItem("radAllValueUniqueExternal");
- this.m_radMorethanOnceExternal=this.F_GetDlgItem("radValueMoreThanOnceExternal");
- this.m_radAllValUniqueExisting=this.F_GetDlgItem("radAllValueUniqueExisting");
- this.m_radMorethanOnceExisting=this.F_GetDlgItem("radValueMoreThanOnceExisting");
- this.m_radExternalExcludeMissingValues=this.F_GetDlgItem("radExternalExcludeMissingValues");
- this.m_radExternalIncludeMissingValues=this.F_GetDlgItem("radExternalIncludeMissingValues");
- this.m_radExistingExcludeMissingValues=this.F_GetDlgItem("radExistingExcludeMissingValues");
- this.m_radExistingIncludeMissingValues=this.F_GetDlgItem("radExistingIncludeMissingValues");
- this.m_spanExternalCardinality=this.F_GetDlgItem("spanExternalCardinality");
- this.m_spanExistingCardinality=this.F_GetDlgItem("spanExistingCardinality");
- this.m_aTipText=[];
- this.m_aTipText[D_AddPersonalWizard.K_iSelectDataPage]="IDS_WIZ_ADDPERSONAL_SUBTITLE_SELECT_FILE";
- this.m_aTipText[D_AddPersonalWizard.K_iLinksPage]="IDS_WIZ_ADDPERSONAL_SUBTITLE_SELECT_MAPPINGITEMS";
- this.m_aTipText[D_AddPersonalWizard.K_iDataAttribPage]="IDS_WIZ_ADDPERSONAL_SUBTITLE_SPECIFY_ATTRIBUTE";
- this.m_aTipText[D_AddPersonalWizard.K_iLinkAttribPage]="IDS_WIZ_ADDPERSONAL_SUBTITLE_DISABLED_MAPPINGOPTIONS";
- this.m_nCurrentCard=D_AddPersonalWizard.K_iSelectDataPage;
- };
- D_AddPersonalWizard.F_Dialog_OnBeforeVisible=function(){
- this.m_bReadIncomingMappings=true;
- this.m_bReadIncomingMappingOptions=true;
- this.m_bExternalSourceChanged=true;
- var _18b="NavigationListNew";
- if(this.m_bIsModify){
- _18b="NavigationList";
- }
- this.m_oNavigationList=new C_ListView(this.F_GetDlgItem("divNavigationList"),this.F_GetResource(_18b),this);
- var _18c=this.m_oNavigationList.F_FindListItemByIndex(0);
- _18c.setAttribute("html","<strong>1.</strong> "+G_ResManager.F_GetString("IDS_LBL_SELECTDATA"));
- _18c=this.m_oNavigationList.F_FindListItemByIndex(1);
- _18c.setAttribute("html","<strong>2.</strong> "+G_ResManager.F_GetString("IDS_LBL_DATAMAPPING"));
- _18c=this.m_oNavigationList.F_FindListItemByIndex(2);
- _18c.setAttribute("html","<strong>3.</strong> "+G_ResManager.F_GetString("IDS_LBL_DATAATTRIBUTE"));
- _18c=this.m_oNavigationList.F_FindListItemByIndex(3);
- _18c.setAttribute("html","<strong>4.</strong> "+G_ResManager.F_GetString("IDS_LBL_MAPPINGOPTIONS"));
- this.m_oNavigationList.F_Draw();
- var _18d=this.m_oNavigationList.F_GetContainer();
- var _18e=_18d.getElementsByTagName("TD");
- var _18f=_18e.length;
- for(var i=0;i<_18f;i++){
- var _190=_18e.item(i);
- _190.style.whiteSpace="normal";
- }
- this.m_oDeck=new C_Deck(this.F_GetDlgItem("deckMain"),this);
- this.F_GetDlgItem("btnBack").style.display=this.m_bIsModify?"none":"";
- this.F_GetDlgItem("btnNext").style.display=this.m_bIsModify?"none":"";
- this.F_GetDlgItem("btnFinish").style.display=this.m_bIsModify?"none":"";
- this.F_GetDlgItem("btnOK").style.display=this.m_bIsModify?"":"none";
- this.f_updateButtonStates();
- this.m_oLvColumns=new C_ListView(this.F_GetDlgItem("divListViewColumns"),this.F_GetResource("Choose_Column_List"),this);
- this.F_GetDlgItem("inFileName").value="";
- this.F_GetDlgItem("pdmForm").reset();
- this.m_oComboDataType=new C_ComboBox(this.F_GetDlgItem("tblDataType"),G_ResManager.F_GetResource("ComboBox_DataType"),null,this);
- this.m_oComboAggration=new C_ComboBox(this.F_GetDlgItem("tblAggration"),G_ResManager.F_GetResource("ComboBox_Aggration"),null,this);
- this.m_oComboScale=new C_ComboBox(this.F_GetDlgItem("tblDecimal"),G_ResManager.F_GetResource("ComboBox_Decimal"),null,this);
- this.m_oComboJoinFilterType=new C_ComboBox(this.F_GetDlgItem("tblComboJoinFilterType"),G_ResManager.F_GetResource("ComboBox_JoinFilterType"),null,this);
- this.m_oComboJoinFilterType.F_SetValue("in","IDS_LBL_JOINFILTERTYPE");
- this.m_oComboJoinFilterType.F_SetTooltip(null,"IDS_LBL_JOINFILTERTYPE");
- this.F_SetEnableDataItemAttribute(false);
- this.m_iCurrentSelectItemAttribute=-1;
- this.m_sFolderName="";
- this.m_oExistingQSList=new C_ListView(this.m_divExistingQSItems,null,this);
- this.m_nExistingQSListItems=this.m_oExistingQSList.F_GetListItemsNode();
- this.m_oExternalQSList=new C_ListView(this.m_divExternalQSItems,null,this);
- this.m_nExternalQSListItems=this.m_oExternalQSList.F_GetListItemsNode();
- this.m_oNavigationList.F_SelectByIndex(0,true);
- this.m_nCurrentCard=D_AddPersonalWizard.K_iSelectDataPage;
- this.f_updateTipText(D_AddPersonalWizard.K_iSelectDataPage);
- };
- D_AddPersonalWizard.F_Dialog_OnAfterVisible=function(){
- if(this.m_oPecXML){
- this.F_SetColumnList(this.m_oPecXML,true);
- }
- };
- D_AddPersonalWizard.F_Deck_OnBeforeCardVisible=function(_191,_192,_193,_194){
- switch(_194){
- case D_AddPersonalWizard.K_iDataAttribPage:
- if(!this.m_oLvColumnsDataItem){
- U_Utils.F_ShowLoadingMessage(this.F_GetDlgItem("divListViewColumnDataitem"));
- }
- break;
- case D_AddPersonalWizard.K_iLinksPage:
- if(this.m_oExistingQSList&&this.m_oExistingQSList.F_GetListItems().length==0){
- var _195=G_Model.F_IsMultiDimensionalSource();
- if(_195){
- this.F_GetDlgItem("lblExistingQuerySubject").innerText=G_ResManager.F_GetString("IDS_LBL_EXISTING_REPORT");
- }else{
- this.F_GetDlgItem("lblExistingQuerySubject").innerText=G_ResManager.F_GetString("IDS_LBL_EXISTING_QS_OR_REP");
- }
- }
- this.f_updateLinkButtons();
- break;
- }
- this.f_updateTipText(_194);
- };
- D_AddPersonalWizard.f_EnsureValidLinks=function(){
- if(this.m_bReadIncomingMappings){
- this.f_restoreExistingQSOrReport(this.m_oPecXML);
- this.f_setupLinkAttributesPage();
- this.m_bReadIncomingMappings=false;
- return;
- }
- if(this.m_aLinks&&(this.m_aLinks.length)&&(this.m_aLinks.length>0)){
- var nl=this.m_oLvColumns.F_GetCheckedListItems();
- for(var i=0;i<this.m_aLinks.length;i++){
- var _196=this.m_aLinks[i];
- var _197=_196.M_sLeftDataItem;
- var j=0;
- for(j=0;j<nl.length;j++){
- var n=nl.item(j);
- var _198=n.getAttribute("name");
- if(_198==_197){
- break;
- }
- }
- if(j<nl.length){
- continue;
- }
- if(_196.M_elPolyLine){
- _196.M_elPolyLine.parentNode.removeChild(_196.M_elPolyLine);
- _196.M_elLeftRect.parentNode.removeChild(_196.M_elLeftRect);
- _196.M_elRightRect.parentNode.removeChild(_196.M_elRightRect);
- }
- this.m_aLinks.splice(i,1);
- i--;
- }
- }
- };
- D_AddPersonalWizard.F_Deck_OnAfterCardVisible=function(_199,_19a,_19b,_19c){
- if(this.m_nCurrentCard==D_AddPersonalWizard.K_iSelectDataPage){
- this.f_EnsureValidLinks();
- }
- this.m_nCurrentCard=_19c;
- switch(_19c){
- case D_AddPersonalWizard.K_iSelectDataPage:
- this.m_bExternalSourceChanged=true;
- break;
- case D_AddPersonalWizard.K_iDataAttribPage:
- if(!this.m_oLvColumnsDataItem){
- this.m_oLvColumnsDataItem=new C_ListView(this.F_GetDlgItem("divListViewColumnDataitem"),this.F_GetResource("Column_Attribute_List"),this);
- }
- this.F_SetDataItemAttributesList();
- break;
- case D_AddPersonalWizard.K_iLinkAttribPage:
- case D_AddPersonalWizard.K_iLinksPage:
- if(this.m_bExternalSourceChanged){
- var _19d=null;
- if(this.m_oPecXML){
- _19d=this.m_oPecXML.selectSingleNode("/pdSpec/personalData");
- }
- this.f_setExternalQuerySubject(_19d);
- this.m_bExternalSourceChanged=false;
- this.F_eraseLinks(false);
- }
- if(_19c==D_AddPersonalWizard.K_iLinksPage){
- this.f_refreshLinksControl();
- }
- if(this.m_bReadIncomingMappings){
- this.f_restoreExistingQSOrReport(this.m_oPecXML);
- this.f_setupLinkAttributesPage();
- }
- if(_19c==D_AddPersonalWizard.K_iLinkAttribPage){
- this.f_updateLinkAttributes();
- }
- if(this.m_oPecXML&&this.m_bIsModify){
- var _19e=this.m_oPecXML.selectSingleNode("/pdSpec/relationship/joinFilterType");
- var _19f=_19e?_19e.text:"none";
- this.m_oComboJoinFilterType.F_SelectByValue(_19f);
- }
- break;
- }
- this.f_updateButtonStates();
- };
- D_AddPersonalWizard.f_setupLinkAttributesPage=function(){
- if(!this.m_oColExternalLink){
- this.m_oColExternalLink=new C_ListView(this.F_GetDlgItem("divListViewColumnExternalDataitem"),this.F_GetResource("Normal_Column_List"),this);
- }
- if(!this.m_oColExistingLink){
- this.m_oColExistingLink=new C_ListView(this.F_GetDlgItem("divListViewColumnExistingDataitem"),this.F_GetResource("Normal_Column_List"),this);
- }
- if(this.m_bReadIncomingMappingOptions){
- this.f_updateLinkAttributes(this.m_oPecXML);
- this.m_bReadIncomingMappingOptions=false;
- }
- };
- D_AddPersonalWizard.f_refreshLinksControl=function(){
- this.f_setSelectedIndexToFirstLink();
- this.f_updateLinks();
- this.f_showSelectedLink();
- };
- D_AddPersonalWizard.f_updateTipText=function(_1a0){
- var _1a1=G_ResManager.F_GetString(this.m_aTipText[_1a0]);
- this.f_setTipText(_1a1);
- };
- D_AddPersonalWizard.f_setTipText=function(_1a2){
- this.F_GetDlgItem("divInfoBox").innerHTML=_1a2;
- };
- D_AddPersonalWizard.f_updateLinkButtons=function(){
- var _1a3=this.m_nExternalQSListItems&&this.m_nExternalQSListItems.selectSingleNode("listItem")!=null;
- var _1a4=this.m_nExistingQSListItems&&this.m_nExistingQSListItems.selectSingleNode("listItem")!=null;
- this.F_SetButtonEnabled("btnNewLink",_1a3&&_1a4);
- var _1a5=this.m_iSelectedLink!=null&&this.m_iSelectedLink!=-1;
- this.F_SetButtonEnabled("btnDeleteLink",_1a5);
- };
- D_AddPersonalWizard.f_setExternalQuerySubject=function(_1a6){
- this.m_oExternalQSList.F_Clear();
- this.m_nExternalQSListItems=this.m_oExternalQSList.F_GetListItemsNode();
- if(_1a6){
- this.F_GetDlgItem("txtExternalQuerySubject").value=_1a6.getAttribute("name");
- this.F_GetDlgItem("txtExternalQuerySubject").title=_1a6.getAttribute("name");
- U_Utils.F_ShowLoadingMessage(this.m_divExternalQSItems);
- this.f_populateExternalQSMembers(_1a6);
- }
- };
- D_AddPersonalWizard.f_populateExternalQSMembers=function(_1a7){
- if(!_1a7){
- this.m_divExternalQSItems.innerHTML="";
- return false;
- }
- var nl=_1a7.selectNodes("item");
- var d=this.m_nExternalQSListItems.ownerDocument;
- var _1a8=nl.length;
- var _1a9=0;
- var _1aa=this.m_oLvColumns.F_GetCheckedListItems();
- for(var i=0;i<_1a8;i++){
- var n=nl.item(i);
- var _1ab=n.getAttribute("name");
- if(_1a9<_1aa.length&&_1ab==_1aa.item(_1a9).getAttribute("label")){
- this.f_appendExternalDataNode(d,this.m_nExistingQSListItems,n);
- _1a9++;
- }
- }
- this.m_oExternalQSList.F_Draw();
- this.f_updateLinkButtons();
- };
- D_AddPersonalWizard.f_restoreExistingLinks=function(_1ac){
- var _1ad=[];
- if(_1ac){
- var _1ae=_1ac.selectSingleNode("/pdSpec/relationship");
- if(_1ae){
- var _1af=_1ae.selectNodes("expression/relPart");
- var _1b0=_1af.length;
- var nl=this.m_oLvColumns.F_GetCheckedListItems();
- for(var i=0;i<_1b0;i++){
- var _1b1=_1af.item(i);
- var _1b2=_1b1.selectNodes("itemRef");
- if(!_1b2||_1b2.length!=2){
- continue;
- }
- var _1b3=_1b2.item(0).selectSingleNode("text()").nodeValue;
- var j;
- for(j=0;j<nl.length;j++){
- var n=nl.item(j);
- var _1b4=n.getAttribute("name");
- if(_1b4==_1b3){
- break;
- }
- }
- if(j<nl.length){
- var _1b5={};
- _1ad.push(_1b5);
- _1b5.M_sLeftDataItem=_1b2.item(0).selectSingleNode("text()").nodeValue;
- _1b5.M_sRightDataItem=_1b2.item(1).selectSingleNode("text()").nodeValue;
- }
- }
- }
- }
- return _1ad;
- };
- D_AddPersonalWizard.f_pickObject=function(){
- var _1b6=G_Model.F_IsMultiDimensionalSource();
- if(_1b6){
- this.f_pickReport();
- }else{
- if(!this.m_oMenuPopupSet){
- this.m_oMenuPopupSet=new C_MenuPopupSet(G_ResManager.F_GetResource("MenuPopupPickObject"),this);
- }
- var _1b7=C_Toolbar.F_GetDropDownPos("D_AddPersonalWizard_btnBrowse",false);
- this.m_oMenuPopupSet.F_ShowMenuPopup("D_AddPersonalWizard_Popup",_1b7.left,_1b7.top);
- }
- };
- D_AddPersonalWizard.f_chooseExistingQuerySubject=function(){
- var _1b8=G_ResManager.F_GetString("IDS_TITLE_CHOOSE_QUERYSUBJECT");
- var _1b9={};
- _1b9["modelSubject"]=true;
- D_ChooseModelItem.F_Show(this.F_GetDialogWindow(),function(){
- D_AddPersonalWizard.f_onExistingQuerySubjectPicked();
- },null,_1b8,"",_1b9,false);
- };
- D_AddPersonalWizard.f_restoreExistingQSOrReport=function(_1ba){
- this.f_clearExistingItemsList();
- var _1bb=null;
- var _1bc=null;
- if(_1ba){
- var _1bd=_1ba.selectSingleNode("/pdSpec/relationship/targetModelPath");
- if(_1bd){
- var _1be=_1bd.selectSingleNode("text()");
- var _1bf=_1be.nodeValue;
- if(!this.m_bEditingPublishedPackage&&_1bf.indexOf("[Model].")>=0){
- _1bf=_1bf.substr(8);
- }
- var _1c0=G_Model.F_GetChildren(_1bf);
- if(_1c0){
- _1bb=_1c0.selectSingleNode("querySubject");
- }else{
- var _1c1=new C_AllChildrenMetadataRequest(G_Model,new C_RequestListenerRedirect(this,"f_onExistingQSMetadataRequestComplete"),_1bf);
- _1c1.F_Send();
- }
- }else{
- var _1bc=_1ba.selectSingleNode("/pdSpec/reportExtract/reportSearchPath");
- }
- }
- if(_1bb){
- var _1c2=_1bb.getAttribute("_path");
- var _1c3=_1bb.getAttribute("name");
- this.f_setExistingQuerySubject(_1c2,_1c3);
- }else{
- if(_1bc){
- var _1c4=_1bc.text;
- var _1c5=_1ba.selectSingleNode("/pdSpec/reportExtract/reportSubject/@name").value;
- this.f_setExistingReport(_1c4,_1c5);
- }
- }
- };
- D_AddPersonalWizard.f_onExistingQSMetadataRequestComplete=function(_1c6){
- var _1c7=_1c6.F_GetError();
- if(_1c7){
- F_ShowError(_1c7);
- return;
- }
- var _1c8=_1c6.F_GetMetadataResponse();
- var _1c9=_1c8.selectSingleNode("querySubject");
- if(_1c9){
- var _1ca=_1c9.getAttribute("_path");
- var _1cb=_1c9.getAttribute("name");
- this.f_setExistingQuerySubject(_1ca,_1cb);
- }
- };
- D_AddPersonalWizard.f_pickReport=function(){
- var _1cc={};
- _1cc["report"]=true;
- _1cc["reportView"]=true;
- _1cc["query"]=false;
- _1cc["reportTemplate"]=false;
- _1cc["analysis"]=false;
- D_ContentManager.F_ShowOpen(this,_1cc);
- };
- D_AddPersonalWizard.F_Dialog_OnCommit=function(){
- var _1cd=D_ContentManager.F_GetOpenFilePath();
- var _1ce=D_ContentManager.F_GetOpenFileName();
- this.f_setExistingReport(_1cd,_1ce);
- };
- D_AddPersonalWizard.f_onExistingQuerySubjectPicked=function(){
- var _1cf=D_ChooseModelItem.F_GetQueryItemPath();
- var _1d0=D_ChooseModelItem.F_GetQueryItemLabel();
- this.f_setExistingQuerySubject(_1cf,_1d0);
- };
- D_AddPersonalWizard.f_clearExistingItemsList=function(){
- this.m_oExistingQSList.F_Clear();
- this.m_nExistingQSListItems=this.m_oExistingQSList.F_GetListItemsNode();
- this.F_GetDlgItem("txtExistingQuerySubject").value="";
- this.F_GetDlgItem("txtExistingQuerySubject").title="";
- this.m_sExistingQuerySubjectPath=null;
- this.m_sExistingReportPath=null;
- this.m_nExistingReportExtract=null;
- };
- D_AddPersonalWizard.f_setExistingQuerySubject=function(_1d1,_1d2){
- this.f_clearExistingItemsList();
- if(_1d1&&_1d2){
- this.m_sExistingQuerySubjectPath=_1d1;
- this.F_GetDlgItem("txtExistingQuerySubject").value=_1d2;
- this.F_GetDlgItem("txtExistingQuerySubject").title=this.m_sExistingQuerySubjectPath;
- this.F_GetDlgItem("lblExistingQuerySubject").innerText=G_ResManager.F_GetString("IDS_LBL_EXISTING_QUERY_SUBJECT");
- var _1d3=this.m_sExistingQuerySubjectPath;
- var _1d4=new C_AllChildrenMetadataRequest(G_Model,this,_1d3);
- _1d4.F_Send();
- U_Utils.F_ShowLoadingMessage(this.m_divExistingQSItems);
- }
- };
- D_AddPersonalWizard.f_setExistingReport=function(_1d5,_1d6){
- this.f_clearExistingItemsList();
- if(_1d5&&_1d6){
- this.m_sExistingReportPath=_1d5;
- this.F_GetDlgItem("txtExistingQuerySubject").value=_1d6;
- this.F_GetDlgItem("txtExistingQuerySubject").title=_1d5;
- this.F_GetDlgItem("lblExistingQuerySubject").innerText=G_ResManager.F_GetString("IDS_LBL_EXISTING_REPORT");
- var _1d7="<processExtractReport><input><reportSearchPath>"+this.m_sExistingReportPath.F_XMLEncode()+"</reportSearchPath></input></processExtractReport>";
- var _1d8=new C_PersonalDataSyncRequest(this,_1d7,"processExtractReport");
- _1d8.F_Send();
- U_Utils.F_ShowLoadingMessage(this.m_divExistingQSItems);
- }
- };
- D_AddPersonalWizard.f_populateExistingReportItems=function(_1d9){
- if(!_1d9){
- this.m_divExistingQSItems.innerHTML="";
- return false;
- }
- this.m_nExistingReportExtract=_1d9;
- var nl=this.m_nExistingReportExtract.selectNodes("reportSubject/item");
- var d=this.m_nExistingQSListItems.ownerDocument;
- var _1da=nl.length;
- for(var i=0;i<_1da;i++){
- var n=nl.item(i);
- var _1db=this.f_appendReportNode(d,this.m_nExistingQSListItems,n);
- }
- this.m_oExistingQSList.F_Draw();
- this.f_updateLinkButtons();
- };
- D_AddPersonalWizard.f_filterExistingQSMembers=function(_1dc){
- if(!_1dc){
- this.m_divExistingQSItems.innerHTML="";
- return false;
- }
- var _1dd=_1dc.selectSingleNode("querySubject");
- var _1de="<getQuerySubjectData><input><modelSearchPath>"+this.m_sModelPath.F_XMLEncode()+"</modelSearchPath>"+U_XML.F_SerializeNode(_1dd)+"</input></getQuerySubjectData>";
- var _1df=new C_PersonalDataSyncRequest(this,_1de,"getQuerySubjectData");
- _1df.F_Send();
- U_Utils.F_ShowLoadingMessage(this.m_divExistingQSItems);
- U_Utils.F_ShowLoadingMessage(this.F_GetDlgItem("divListViewColumnExternalDataitem"));
- U_Utils.F_ShowLoadingMessage(this.F_GetDlgItem("divListViewColumnExistingDataitem"));
- };
- D_AddPersonalWizard.f_populateExistingQSMembers=function(_1e0){
- if(!_1e0){
- this.m_divExistingQSItems.innerHTML="";
- return false;
- }
- var nl=_1e0.selectNodes(".//queryItem | .//calculation");
- var d=this.m_nExistingQSListItems.ownerDocument;
- var _1e1=nl.length;
- for(var i=0;i<_1e1;i++){
- var n=nl.item(i);
- var _1e2=this.f_appendMetadataNode(d,this.m_nExistingQSListItems,n);
- }
- this.m_oExistingQSList.F_Draw();
- this.f_updateLinkButtons();
- return true;
- };
- D_AddPersonalWizard.f_appendReportNode=function(d,_1e3,_1e4){
- var n=_1e3.appendChild(d.createElement("listItem"));
- var _1e5=_1e4.getAttribute("name");
- if(_1e5){
- n.setAttribute("name",_1e5);
- n.setAttribute("label",_1e5);
- }
- var _1e6=_1e4.getAttribute("ID");
- if(_1e6){
- n.setAttribute("_ref",_1e6);
- n.setAttribute("_path",_1e6);
- }
- n.setAttribute("nodeName","modelItem");
- switch(_1e4.getAttribute("usage")){
- case "identifier":
- n.setAttribute("smallIcon","queryItem_identifier.gif");
- break;
- case "fact":
- n.setAttribute("smallIcon","queryItem_fact.gif");
- n.setAttribute("isMeasure","true");
- n.setAttribute("isOLAPMeasure","false");
- var _1e7=_1e4.getAttribute("regularAggregate");
- switch(_1e7){
- case "sum":
- _1e7="total";
- break;
- case "min":
- _1e7="minimum";
- break;
- case "max":
- _1e7="maximum";
- break;
- case "avg":
- _1e7="average";
- break;
- case "count":
- case "calculated":
- case "countDistinct":
- case "standardDeviation":
- case "variance":
- case "median":
- case "automatic":
- break;
- default:
- _1e7="";
- break;
- }
- if(_1e7){
- n.setAttribute("modelAggregate",_1e7);
- }
- break;
- default:
- n.setAttribute("smallIcon","metadata_attribute.gif");
- break;
- }
- U_XML.F_CopyAttributes(n,_1e4,["usage","datatype"]);
- return n;
- };
- D_AddPersonalWizard.f_appendMetadataNode=function(d,_1e8,_1e9){
- var n=_1e8.appendChild(d.createElement("listItem"));
- var _1ea=_1e9.getAttribute("name");
- if(_1ea){
- n.setAttribute("name",_1ea);
- n.setAttribute("label",_1ea);
- }
- U_XML.F_CopyAttributes(n,_1e9,["_ref","_path","description"]);
- var _1eb=_1e9.getAttribute("screenTip");
- if(_1eb||_1ea){
- n.setAttribute("tooltip",_1eb?(_1ea+" - "+_1eb):_1ea);
- }
- var _1ec=_1e9.getAttribute("linkable");
- if(_1ec!=null){
- if(_1ec=="false"){
- n.setAttribute("selectable","false");
- n.setAttribute("smallIcon","bad_item.gif");
- return n;
- }
- }
- var _1ed=_1e9.nodeName;
- switch(_1ed){
- case "queryItem":
- case "calculation":
- var _1ee=n.parentNode;
- var _1ef=_1ee.getAttribute("nodeName");
- var _1f0=G_App.F_getPackageTreeSettingsFull();
- if((_1ef=="level")&&!_1f0.F_GetValue(C_PackageTreeSettings.K_iMemberProperties)){
- n.parentNode.removeChild(n);
- break;
- }
- var _1f1=(_1ed=="calculation");
- n.setAttribute("nodeName","modelItem");
- switch(_1ef){
- case "hierarchy":
- case "level":
- n.setAttribute("nodeName","memberProperty");
- var _1f2=_1ee.getAttribute("name");
- if(_1ef=="level"){
- n.setAttribute("LUN",_1ee.getAttribute("_ref"));
- n.setAttribute("HUN",_1ee.parentNode.getAttribute("_ref"));
- }else{
- n.setAttribute("HUN",_1ee.getAttribute("_ref"));
- }
- n.setAttribute("parentName",_1f2);
- n.setAttribute("parentLabel",_1f2);
- break;
- }
- switch(_1e9.getAttribute("usage")){
- case "identifier":
- n.setAttribute("smallIcon",_1f1?"calculation_identifier.gif":"queryItem_identifier.gif");
- break;
- case "fact":
- n.setAttribute("selectable","false");
- n.setAttribute("smallIcon","fact_bad.gif");
- n.setAttribute("isMeasure","true");
- n.setAttribute("isOLAPMeasure","false");
- var _1f3=_1e9.getAttribute("regularAggregate");
- switch(_1f3){
- case "sum":
- _1f3="total";
- break;
- case "min":
- _1f3="minimum";
- break;
- case "max":
- _1f3="maximum";
- break;
- case "avg":
- _1f3="average";
- break;
- case "count":
- case "calculated":
- case "countDistinct":
- case "standardDeviation":
- case "variance":
- case "median":
- case "automatic":
- break;
- default:
- _1f3="";
- break;
- }
- if(_1f3){
- n.setAttribute("modelAggregate",_1f3);
- }
- break;
- default:
- n.setAttribute("smallIcon",_1f1?"calculation_attribute.gif":"metadata_attribute.gif");
- break;
- }
- if(_1f1){
- var _1f4=_1e9.getAttribute("calcType");
- switch(_1f4){
- case "namedSet":
- n.setAttribute("nodeName","namedSet");
- n.setAttribute("smallIcon","calcType_"+_1f4+".gif");
- U_XML.F_CopyAttributes(n,_1e9,["hierarchies","dimensions"]);
- break;
- case "macros":
- n.setAttribute("smallIcon","calcType_"+_1f4+".gif");
- break;
- }
- }
- U_XML.F_CopyAttributes(n,_1e9,["currency","usage","datatype","displayType","unSortable","promptType","promptDisplayItemRef","promptUseItemRef","promptFilterItemRef","promptCascadeOnRef","regularAggregate","calcType"]);
- break;
- }
- return n;
- };
- D_AddPersonalWizard.f_appendExternalDataNode=function(d,_1f5,_1f6){
- var n=this.m_nExternalQSListItems.appendChild(d.createElement("listItem"));
- var _1f7=_1f6.getAttribute("name");
- if(_1f7){
- n.setAttribute("name",_1f7);
- n.setAttribute("label",_1f7);
- }
- U_XML.F_CopyAttributes(n,_1f6,["ID","usage"]);
- var _1f8=_1f6.getAttribute("screenTip");
- if(_1f8||_1f7){
- n.setAttribute("tooltip",_1f8?(_1f7+" - "+_1f8):_1f7);
- }
- switch(_1f6.getAttribute("usage")){
- case "identifier":
- case "Identifier":
- n.setAttribute("smallIcon","queryItem_identifier.gif");
- break;
- case "fact":
- case "Fact":
- n.setAttribute("smallIcon","queryItem_fact.gif");
- n.setAttribute("isMeasure","true");
- n.setAttribute("isOLAPMeasure","false");
- var _1f9=_1f6.getAttribute("regularAggregate");
- switch(_1f9){
- case "sum":
- _1f9="total";
- break;
- case "min":
- _1f9="minimum";
- break;
- case "max":
- _1f9="maximum";
- break;
- case "avg":
- _1f9="average";
- break;
- case "count":
- case "calculated":
- case "countDistinct":
- case "standardDeviation":
- case "variance":
- case "median":
- case "automatic":
- break;
- default:
- _1f9="";
- break;
- }
- if(_1f9){
- n.setAttribute("modelAggregate",_1f9);
- }
- break;
- default:
- n.setAttribute("smallIcon","metadata_attribute.gif");
- break;
- }
- return n;
- };
- D_AddPersonalWizard.f_updateButtonStates=function(){
- };
- D_AddPersonalWizard.F_OnBack=function(){
- if(this.m_oDeck.F_HasBack()){
- this.m_oNavigationList.F_SelectByIndex(this.m_oDeck.F_GetIndex()-1,true);
- }
- };
- D_AddPersonalWizard.F_OnNext=function(){
- if(this.m_oDeck.F_HasNext()){
- this.m_oNavigationList.F_SelectByIndex(this.m_oDeck.F_GetIndex()+1,true);
- }
- };
- D_AddPersonalWizard.F_OnFinish=function(){
- if(!this.m_oPecXML){
- return;
- }
- this.f_buildpdSpecitem(this.m_oPecXML);
- D_ManagePersonalData.f_addPersonalData(this.m_oPecXML,this.m_bIsModify);
- this.F_Hide();
- };
- D_AddPersonalWizard.f_localEditLinksOnly=function(_1fa){
- var _1fb=_1fa.selectSingleNode("/pdSpec/relationship");
- if(_1fb){
- var nl=this.m_oLvColumns.F_GetCheckedListItems();
- var _1fc=_1fb.selectNodes("expression/relPart");
- var _1fd=_1fc.length;
- var nl=this.m_oLvColumns.F_GetCheckedListItems();
- for(var i=0;i<_1fd;i++){
- var _1fe=_1fc.item(i);
- var _1ff=_1fe.selectNodes("itemRef");
- if(!_1ff||_1ff.length!=2){
- _1fe.parentNode.removeChild(_1fe);
- continue;
- }
- var _200=_1ff.item(0).selectSingleNode("text()").nodeValue;
- var j;
- for(j=0;j<nl.length;j++){
- var n=nl.item(j);
- var _201=n.getAttribute("name");
- if(_201==_200){
- break;
- }
- }
- if(j<nl.length){
- continue;
- }
- _1fe.parentNode.removeChild(_1fe);
- }
- }
- };
- D_AddPersonalWizard.f_buildpdSpecitem=function(_202){
- var _203=this.m_oLvColumns.F_GetListItems();
- var _204=_202.selectNodes("/pdSpec/personalData/item");
- var _205=_202.selectNodes("/pdSpec/dataSet/name");
- var _206=_205.item(0).text;
- if(this.F_GetDlgItem("txtText").value!=_206){
- _205.item(0).text=this.F_GetDlgItem("txtText").value;
- var _207=_202.selectNodes("/pdSpec/personalData");
- _207.item(0).setAttribute("name",this.F_GetDlgItem("txtText").value);
- _207.item(0).setAttribute("ID","["+this.F_GetDlgItem("txtText").value+"]");
- for(var i=0;i<_204.length;i++){
- var _208=_204.item(i).getAttribute("ID");
- var sID=_208.replace("["+_206+"]","["+this.F_GetDlgItem("txtText").value+"]");
- _204.item(i).setAttribute("ID",sID);
- }
- var _209=_202.selectNodes("/pdSpec/relationship/expression/relPart");
- for(var i=0;i<_209.length;i++){
- var _20a=_209.item(i).selectSingleNode("itemRef");
- if(_20a){
- var _208=_20a.text;
- var _20b=_208.replace("["+_206+"]","["+this.F_GetDlgItem("txtText").value+"]");
- _20a.text=_20b;
- }
- }
- var nl=this.m_oLvColumns.F_GetListItems();
- for(var i=0;i<nl.length;i++){
- var _20c=nl.item(i);
- var _20d=_20c.getAttribute("name");
- var _20e=_20d.replace("["+_206+"]","["+this.F_GetDlgItem("txtText").value+"]");
- _20c.setAttribute("name",_20e);
- }
- if(this.m_aLinks){
- for(var i=0;i<this.m_aLinks.length;i++){
- var _20f=this.m_aLinks[i];
- var _20d=_20f.M_sLeftDataItem;
- var _20e=_20d.replace("["+_206+"]","["+this.F_GetDlgItem("txtText").value+"]");
- _20f.M_sLeftDataItem=_20e;
- }
- }
- }
- for(var i=0;i<_204.length;i++){
- var n=_204.item(i);
- var _210=_203.item(i).getAttribute("checked");
- if(_210=="true"){
- n.setAttribute("hidden","false");
- }else{
- n.setAttribute("hidden","true");
- }
- }
- U_XML.F_RemoveNode(_202,"/pdSpec/dataSet/accessDirectly");
- var _211=U_XML.F_AppendChild(_202.selectNodes("/pdSpec/dataSet").item(0),"accessDirectly");
- if(this.F_GetDlgItem("chkAlwaysTryToLoad").checked==true){
- _211.text="true";
- }else{
- _211.text="false";
- }
- if(this.m_bReadIncomingMappings){
- this.f_localEditLinksOnly(_202);
- return;
- }
- this.f_EnsureValidLinks();
- if(this.m_nExistingReportExtract){
- U_XML.F_RemoveNode(_202,"/pdSpec/reportExtract");
- var _212=U_XML.F_AppendChild(_202.selectNodes("/pdSpec").item(0),"reportExtract");
- var _213=this.m_nExistingReportExtract.selectSingleNode("reportSearchPath");
- if(_213){
- var _214=U_XML.F_AppendChild(_212,"reportSearchPath");
- _214.text=_213.text;
- U_XML.F_CopyAttributes(_214,_213);
- }
- var _215=this.m_nExistingReportExtract.selectSingleNode("reportSubject");
- if(_215){
- var _216=U_XML.F_AppendChild(_212,"reportSubject");
- _216.text=_215.text;
- U_XML.F_CopyAttributes(_216,_215);
- var _217=_215.selectNodes("item");
- if(_217){
- var _218=_217.length;
- for(var i=0;i<_218;i++){
- var _219=_217.item(i);
- var _21a=U_XML.F_AppendChild(_216,"item");
- _21a.text=_219.text;
- U_XML.F_CopyAttributes(_21a,_219);
- }
- }
- }
- }else{
- U_XML.F_RemoveNode(_202,"/pdSpec/reportExtract");
- }
- U_XML.F_RemoveNode(_202,"/pdSpec/relationship");
- if(this.m_aLinks&&(this.m_aLinks.length)&&(this.m_aLinks.length>0)){
- var _21b=U_XML.F_AppendChild(_202.selectNodes("/pdSpec").item(0),"relationship");
- if(this.m_sExistingQuerySubjectPath){
- _21b.setAttribute("target","baseModel");
- var _21c=U_XML.F_AppendChild(_21b,"targetModelPath");
- var _21d=this.m_sExistingQuerySubjectPath;
- if(_21d.indexOf("[Model].")!=0){
- _21d="[Model]."+_21d;
- }
- _21c.text=_21d;
- }else{
- _21b.setAttribute("target","reportExtract");
- }
- var _21e=U_XML.F_AppendChild(_21b,"sourceCardinality");
- if(this.m_radAllValUniqueExternal.checked==true){
- U_XML.F_AppendChild(_21e,"maxCard").text="one";
- }else{
- U_XML.F_AppendChild(_21e,"maxCard").text="many";
- }
- if(this.m_radExternalExcludeMissingValues.checked==true){
- U_XML.F_AppendChild(_21e,"minCard").text="one";
- }else{
- U_XML.F_AppendChild(_21e,"minCard").text="zero";
- }
- var _21f=U_XML.F_AppendChild(_21b,"targetCardinality");
- if(this.m_radAllValUniqueExisting.checked==true){
- U_XML.F_AppendChild(_21f,"maxCard").text="one";
- }else{
- U_XML.F_AppendChild(_21f,"maxCard").text="many";
- }
- if(this.m_radExistingExcludeMissingValues.checked==true){
- U_XML.F_AppendChild(_21f,"minCard").text="one";
- }else{
- U_XML.F_AppendChild(_21f,"minCard").text="zero";
- }
- var _220=U_XML.F_AppendChild(_21b,"expression");
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=0;i<this.m_aLinks.length;i++){
- var _221=U_XML.F_AppendChild(_220,"relPart");
- var _20f=this.m_aLinks[i];
- var _222=_20f.M_sLeftDataItem.split("].[");
- var _223=_222[0].replace("[","");
- if(_223!=this.F_GetDlgItem("txtText").value){
- var _224=_20f.M_sLeftDataItem.replace("["+_223+"]","["+this.F_GetDlgItem("txtText").value+"]");
- U_XML.F_AppendChild(_221,"itemRef").text=_224;
- }else{
- U_XML.F_AppendChild(_221,"itemRef").text=_20f.M_sLeftDataItem;
- }
- U_XML.F_AppendChild(_221,"compOpr").text="eq";
- U_XML.F_AppendChild(_221,"itemRef").text=_20f.M_sRightDataItem;
- if(i+1<this.m_aLinks.length){
- U_XML.F_AppendChild(_220,"logicalOpr").text="and";
- }
- }
- }
- var _225=U_XML.F_AppendChild(_21b,"joinFilterType");
- _225.text=this.m_oComboJoinFilterType.F_GetValue();
- }
- };
- D_AddPersonalWizard.F_Request_OnComplete=function(_226){
- var _227=(_226.constructor==C_PersonalDataRequest)||(_226.constructor==C_PersonalDataSyncRequest);
- var _228=_226.F_GetError();
- if(_228){
- F_ShowError(_228);
- if(_227){
- switch(_226.F_GetRequestType()){
- case "processExtractReport":
- this.f_clearExistingItemsList();
- this.m_divExistingQSItems.innerHTML="";
- break;
- }
- }
- return;
- }
- if(_227){
- var _229=_226.F_GetResponseXMLString();
- var _22a=_226.F_GetResponseXML();
- switch(_226.F_GetRequestType()){
- case "getPersonalData":
- if(_228){
- this.m_oInputXML=U_XML.F_LoadString(null,"<input><pdCollection><baseModelSearchPath>"+this.m_sModelPath+"</baseModelSearchPath></pdCollection></input>");
- }else{
- var _22b=_229.replace(/<output>/g,"<addPersonalData><input>").replace(/<\/output>/g,"</input></addPersonalData>").replace(/<targetPackageSearchPath>/g,"<baseModelSearchPath>").replace(/<\/targetPackageSearchPath>/g,"</baseModelSearchPath>");
- this.m_oInputXML=U_XML.F_LoadString(null,_22b);
- var _22c=this.m_oInputXML.selectNodes("/addPersonalData/input/pdCollection/baseModelSearchPath").item(0);
- if(_22c.text==""){
- _22c.text=this.m_sModelPath;
- }
- }
- break;
- case "processExtractReport":
- var _22d=_22a.selectSingleNode("reportExtract");
- this.f_populateExistingReportItems(_22d);
- this.m_aLinks=this.f_restoreExistingLinks(this.m_oPecXML);
- this.f_refreshLinksControl();
- this.m_bReadIncomingMappingOptions=true;
- this.f_setupLinkAttributesPage();
- break;
- case "getQuerySubjectData":
- var _22e=_22a.selectSingleNode("querySubject");
- this.f_populateExistingQSMembers(_22e);
- if(this.m_aLinks&&(this.m_aLinks.length)&&(this.m_aLinks.length>0)){
- this.F_eraseLinks(true);
- }else{
- this.m_aLinks=this.f_restoreExistingLinks(this.m_oPecXML);
- }
- this.f_refreshLinksControl();
- this.m_bReadIncomingMappingOptions=true;
- this.f_setupLinkAttributesPage();
- break;
- }
- }else{
- if(_226.constructor==C_LevelMetadataRequest||_226.constructor==C_AllChildrenMetadataRequest){
- this.f_filterExistingQSMembers(_226.F_GetMetadataResponse());
- }
- }
- };
- D_AddPersonalWizard.F_Request_OnAborted=function(_22f){
- };
- D_AddPersonalWizard.F_FindSelectItemInProcessResponse=function(_230){
- this.m_iCurrentSelectItemAttribute=-1;
- var _231=_230.getAttribute("label");
- var _232=_230.selectNodes("subItem").item(0).getAttribute("serverDatatype");
- var _233=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- for(var i=0;i<_233.length;i++){
- var _234=_233.item(i);
- if((_234.getAttribute("name")==_231)&&(_234.getAttribute("datatype")==_232)){
- this.m_iCurrentSelectItemAttribute=i;
- }
- }
- };
- D_AddPersonalWizard.F_SetEnableDataItemAttribute=function(_235){
- this.m_oComboDataType.F_SetEnabled(_235);
- this.m_oComboAggration.F_SetEnabled(_235);
- this.m_oComboScale.F_SetEnabled(_235);
- };
- D_AddPersonalWizard.F_SetEnableDecimalDataItemAttribute=function(_236){
- this.m_oComboScale.F_SetEnabled(_236);
- };
- D_AddPersonalWizard.F_UpdataDataItemAttributeCombox=function(_237){
- if(_237<0||_237>this.m_oPecXML.selectNodes("/pdSpec/personalData/item").length){
- return;
- }
- var _238=this.m_oPecXML.selectNodes("/pdSpec/personalData/item").item(_237);
- var _239=this.F_GetItemDataType(_238);
- this.m_oComboDataType.F_SelectByValue(_239,true);
- if((_239=="Integer")||(_239=="Decimal")){
- if(null!=_238.getAttribute("regularAggregate")){
- this.m_oComboAggration.F_SelectByValue(_238.getAttribute("regularAggregate"),true);
- }
- }else{
- this.m_oComboAggration.F_SetEnabled(false);
- }
- if(this.F_GetItemDataType(_238)!="Decimal"){
- this.m_oComboScale.F_SetEnabled(false);
- }
- if(this.F_GetItemScale(_238)!=null){
- var _23a=this.F_GetItemScale(_238);
- if((_23a>=0)&&(_23a<8)){
- this.m_oComboScale.F_SelectByValue(_23a,true);
- }
- }
- };
- D_AddPersonalWizard.F_ComboBox_OnChange=function(_23b,_23c){
- if(_23b==this.m_oComboJoinFilterType){
- this.m_oComboJoinFilterType.F_SetTooltip(null,"IDS_LBL_JOINFILTERTYPE");
- return;
- }
- if(this.m_iCurrentSelectItemAttribute<0){
- return;
- }
- var _23d=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- switch(_23b){
- case this.m_oComboDataType:
- this.F_SetItemDataType(this.m_iCurrentSelectItemAttribute,_23c.getAttribute("value"));
- break;
- case this.m_oComboAggration:
- this.F_SetItemAggregate(this.m_iCurrentSelectItemAttribute,_23c.getAttribute("value"));
- break;
- case this.m_oComboScale:
- if(_23c.getAttribute("scale")!=""){
- _23d.item(this.m_iCurrentSelectItemAttribute).setAttribute("scale",_23c.getAttribute("value"));
- }
- break;
- }
- var _23e=-1;
- var _23f=this.m_oLvColumnsDataItem.F_GetSingleSelectedListItem();
- if(_23f){
- var nl=this.m_oLvColumnsDataItem.F_GetListItems();
- var _240=nl.length;
- for(var i=0;i<_240;i++){
- if(_23f==nl.item(i)){
- _23e=i;
- }
- }
- }
- this.F_SetDataItemAttributesList();
- if(_23e>=0){
- this.m_oLvColumnsDataItem.F_SelectByIndex(_23e,true);
- }
- };
- D_AddPersonalWizard.F_ListView_OnItemClick=function(_241,_242,_243){
- switch(_241.F_GetId()){
- case "D_AddPersonalWizard_divListViewColumnDataitem":
- this.F_SetEnableDataItemAttribute(true);
- var _244=_241.F_GetSelectedListItem();
- this.F_FindSelectItemInProcessResponse(_244);
- this.F_UpdataDataItemAttributeCombox(this.m_iCurrentSelectItemAttribute);
- break;
- case "D_AddPersonalWizard_divNavigationList":
- var _245=_242.getAttribute("value");
- var _246=G_ResManager.F_GetString(_242.getAttribute("idsLabel"));
- var _247=_241.F_GetListViewNode().selectSingleNode("listItems/listItem[@value='"+_245+"']");
- this.F_GetDlgItem("divTitle").innerText=_246;
- this.m_oDeck.F_SetIndex(U_XML.F_GetIndex(_247));
- break;
- case "D_AddPersonalWizard_divExternalItems":
- case "D_AddPersonalWizard_divExistingItems":
- this.f_LinkedList_OnItemClick(_241,_242,_243);
- break;
- }
- };
- D_AddPersonalWizard.F_Dialog_OnAfterHide=function(){
- this.m_oLvColumns.F_Detach();
- delete this.m_oLvColumns;
- if(this.m_oLvColumnsDataItem){
- this.m_oLvColumnsDataItem.F_Detach();
- delete this.m_oLvColumnsDataItem;
- }
- this.m_oDeck.F_Detach();
- delete this.m_oDeck;
- this.m_oComboDataType.F_Detach();
- delete this.m_oComboDataType;
- this.m_oComboAggration.F_Detach();
- delete this.m_oComboAggration;
- this.m_oComboScale.F_Detach();
- delete this.m_oComboScale;
- this.m_oComboJoinFilterType.F_Detach();
- delete this.m_oComboJoinFilterType;
- if(this.m_oNavigationList){
- this.m_oNavigationList.F_Detach();
- delete this.m_oNavigationList;
- }
- if(this.m_oExistingQSList){
- this.m_oExistingQSList.F_Detach();
- delete this.m_oExistingQSList;
- }
- if(G_BrowserInfo.M_bIsIE){
- this.m_divLinks.innerHTML="";
- }else{
- U_DOM.F_RemoveAllChildren(this.m_elSvg);
- }
- if(this.m_oExternalQSList){
- this.m_oExternalQSList.F_Detach();
- delete this.m_oExternalQSList;
- }
- if(this.m_oColExternalLink){
- this.m_oColExternalLink.F_Detach();
- delete this.m_oColExternalLink;
- }
- if(this.m_oColExistingLink){
- this.m_oColExistingLink.F_Detach();
- delete this.m_oColExistingLink;
- }
- if(this.m_oMenuPopupSet){
- this.m_oMenuPopupSet.F_Detach();
- delete this.m_oMenuPopupSet;
- }
- D_ChooseModelItem.F_ClearModelTree();
- this.m_aLinks=[];
- };
- D_AddPersonalWizard.f_cleanupCanvases=function(){
- if(this.m_oCanvas){
- this.m_oCanvas.F_Detach();
- delete this.m_oCanvas;
- this.m_oCanvas=null;
- }
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=0;i<this.m_aLinks.length;i++){
- if(this.m_aLinks[i]&&this.m_aLinks[i].M_elPolyLine){
- this.m_aLinks[i].M_elPolyLine.F_Detach();
- delete this.m_aLinks[i].M_elPolyLine;
- this.m_aLinks[i].M_elPolyLine=null;
- }
- }
- }
- };
- D_AddPersonalWizard.F_OnKeyPress=function(){
- };
- D_AddPersonalWizard.F_OnSpecifyNameKeyPress=function(e){
- e=e||window.event;
- if(e.ctrlKey){
- return;
- }
- var _248=e.keyCode;
- if(!G_BrowserInfo.M_bIsIE){
- _248=e.charCode;
- if(_248==0){
- return;
- }
- }
- var _249=String.fromCharCode(_248);
- var _24a=/[#&"'\[\]]/;
- if(_24a.test(_249)){
- e.returnValue=false;
- if(G_BrowserInfo.M_bIsIE){
- e.keyCode=0;
- }
- e.cancelBubble=true;
- if(G_HAL.M_oLibraries["hal"]["enableAccessibility"]){
- F_MsgBox(G_ResManager.F_GetString("IDS_AC_INVALID_KEYSTROKE",_249));
- }
- }
- };
- D_AddPersonalWizard.f_GetFilePath=function(){
- var _24b=this.F_GetDlgItem("inFileName").value;
- if(G_BrowserInfo.M_bIsFirefox&&!this.f_IsGoodFilePath(_24b)){
- try{
- netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
- _24b=this.F_GetDlgItem("inFileName").value;
- }
- catch(e){
- }
- }
- return _24b;
- };
- D_AddPersonalWizard.f_IsGoodFilePath=function(_24c){
- return ((_24c.indexOf("C:\\fakepath\\")==-1)&&((_24c.split("\\").length>1)||(_24c.split("/").length>1)));
- };
- D_AddPersonalWizard.f_SelectFileChange=function(){
- this.m_bExternalSourceChanged=true;
- var _24d=this.f_GetFilePath();
- var _24e=this.F_GetDlgItem("chkAlwaysTryToLoad");
- if(this.f_IsGoodFilePath(_24d)){
- _24e.disabled=false;
- }else{
- _24e.disabled=true;
- _24e.checked=false;
- }
- var _24f=_24d.split(".");
- var _250="";
- if((_24f[_24f.length-1]=="xml")||(_24f[_24f.length-1]=="XML")){
- _250="XML";
- }else{
- if((_24f[_24f.length-1]=="xls")||(_24f[_24f.length-1]=="XLS")){
- _250="Excel2003";
- }else{
- if((_24f[_24f.length-1]=="xlsx")||(_24f[_24f.length-1]=="XLSX")){
- _250="Excel2003";
- }else{
- if((_24f[_24f.length-1]=="csv")||(_24f[_24f.length-1]=="CSV")){
- _250="CSV";
- }else{
- _250="CSV";
- }
- }
- }
- }
- this.m_sQueryNameItem="yyy";
- var _251=this.F_GetDlgItem("pdmForm");
- var _252="<input><dataSet type=\""+_250+"\">";
- _252+="<name>"+this.F_GetDlgItem("txtText").value.F_XMLEncode()+"</name>";
- _252+="<sourcePath>"+_24d.F_XMLEncode()+"</sourcePath></dataSet>";
- _252+="<baseModelSearchPath>"+this.m_sModelPath.F_XMLEncode()+"</baseModelSearchPath>";
- _251.inSpec.value=_252+"</input>";
- F_SubmitUpload(_251);
- this.m_sFolderName="";
- _251.action=G_CCHL.M_sGatewayURL+"/metadataUIService?pid=pdm_process&c=processPersonalData";
- _251.submit();
- D_Progress.F_Show(null,G_ResManager.F_GetString("IDS_LBL_PROCESSEXTERNALDATA"));
- };
- D_AddPersonalWizard.F_ProcessResponse=function(_253){
- if(_253){
- this.m_sProcessResponse=_253;
- }
- this.m_oPecXML=U_XML.F_LoadString(null,this.m_sProcessResponse);
- if(this.m_oPecXML){
- var _254=this.m_oPecXML.selectNodes("/pdSpec/dataSet/name").item(0);
- _254.text=_254.text.F_XMLDecode();
- this.m_sFolderName=_254.text;
- }
- this.f_updateButtonStates();
- return this.m_oPecXML;
- };
- D_AddPersonalWizard.F_GetItemDataType=function(_255){
- var _256=_255.getAttribute("datatype");
- if(_256=="int32"){
- return "Integer";
- }
- if(_256=="characterLength16"){
- return "Text";
- }
- if(_256=="date"){
- return "Date";
- }
- if(_256=="dateTime"){
- return "DateTime";
- }
- if(_256=="decimal"){
- return "Decimal";
- }
- if(_256=="float32"){
- return "Decimal";
- }
- if(_256=="float64"){
- return "Decimal";
- }
- if(_256=="boolean"){
- return "Boolean";
- }
- if(_256=="int16"){
- return "Integer";
- }
- if(_256=="int64"){
- return "Integer";
- }
- return "unknown";
- };
- D_AddPersonalWizard.F_GetItemDataTypeLabel=function(_257){
- return G_ResManager.F_GetString("IDS_PDA_DTYPE_"+this.F_GetItemDataType(_257));
- };
- D_AddPersonalWizard.F_SetItemAsIdentifier=function(_258){
- var _259=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- var _25a=-1;
- for(var i=0;i<_259.length;i++){
- var _25b=_259.item(i).getAttribute("ID");
- if(_25b==_258){
- _25a=i;
- break;
- }
- }
- if(_25a==-1){
- return;
- }
- _259.item(_25a).setAttribute("regularAggregate","unsupported");
- _259.item(_25a).setAttribute("semiAggregate","unsupported");
- _259.item(_25a).setAttribute("usage","identifier");
- this.m_oComboAggration.F_SelectByValue("unsupported",true);
- this.m_oComboAggration.F_SetEnabled(false);
- };
- D_AddPersonalWizard.f_resetItemData=function(_25c){
- var _25d=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- var _25e=null;
- var _25f=-1;
- for(var i=0;i<_25d.length;i++){
- var _260=_25d.item(i).getAttribute("ID");
- if(_260==_25c){
- _25f=i;
- _25e=_25d.item(i);
- break;
- }
- }
- if(_25f==-1){
- return;
- }
- var _261=this.F_GetItemDataType(_25e);
- this.F_SetItemDataType(_25f,_261);
- };
- D_AddPersonalWizard.F_SetItemDataType=function(i,_262){
- var _263=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- this.F_SetEnableDecimalDataItemAttribute(false);
- if(_262=="Integer"){
- _263.item(i).setAttribute("datatype","int32");
- _263.item(i).setAttribute("regularAggregate","unsupported");
- _263.item(i).setAttribute("semiAggregate","unsupported");
- _263.item(i).setAttribute("usage","attribute");
- _263.item(i).setAttribute("length","4");
- _263.item(i).removeAttribute("scale");
- _263.item(i).removeAttribute("precision");
- this.m_oComboAggration.F_SelectByValue("unsupported",true);
- this.m_oComboAggration.F_SetEnabled(true);
- return;
- }
- if(_262=="Text"){
- _263.item(i).setAttribute("datatype","characterLength16");
- _263.item(i).setAttribute("regularAggregate","unsupported");
- _263.item(i).setAttribute("semiAggregate","unsupported");
- _263.item(i).setAttribute("usage","attribute");
- _263.item(i).setAttribute("length","-1");
- _263.item(i).removeAttribute("scale");
- _263.item(i).removeAttribute("precision");
- this.m_oComboAggration.F_SelectByValue("unsupported",true);
- return;
- }
- if(_262=="Decimal"){
- _263.item(i).setAttribute("datatype","decimal");
- _263.item(i).setAttribute("regularAggregate","unsupported");
- _263.item(i).setAttribute("semiAggregate","unsupported");
- _263.item(i).setAttribute("usage","attribute");
- _263.item(i).setAttribute("scale","2");
- this.m_oComboAggration.F_SelectByValue("unsupported",true);
- this.m_oComboScale.F_SelectByValue("2",true);
- this.F_SetEnableDecimalDataItemAttribute(true);
- return;
- }
- if(_262=="Date"){
- _263.item(i).setAttribute("datatype","date");
- _263.item(i).setAttribute("regularAggregate","unsupported");
- _263.item(i).setAttribute("semiAggregate","unsupported");
- _263.item(i).setAttribute("usage","attribute");
- this.m_oComboAggration.F_SelectByValue("unsupported",true);
- return;
- }
- if(_262=="DateTime"){
- _263.item(i).setAttribute("datatype","dateTime");
- _263.item(i).setAttribute("regularAggregate","unsupported");
- _263.item(i).setAttribute("semiAggregate","unsupported");
- _263.item(i).setAttribute("usage","attribute");
- this.m_oComboAggration.F_SelectByValue("unsupported",true);
- return;
- }
- };
- D_AddPersonalWizard.F_GetItemAggregate=function(_264){
- var vAgg=_264.getAttribute("regularAggregate");
- if(vAgg!="unsupported"){
- switch(vAgg){
- case "sum":
- return G_ResManager.F_GetString("IDS_TOPBOTTOM_SUM");
- case "average":
- return G_ResManager.F_GetString("IDS_SUMMARY_average");
- case "automatic":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_AUTO");
- case "count":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_COUNT");
- case "maximum":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_MAX");
- case "minimum":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_MIN");
- case "median":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_median");
- case "countDistinct":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_countDistinct");
- case "countNoZero":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_countNoZero");
- case "variance":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_variance");
- case "standardDeviation":
- return G_ResManager.F_GetString("IDS_PROPVAL_AGGR_standardDeviation");
- }
- }
- return "";
- };
- D_AddPersonalWizard.F_SetItemAggregate=function(i,_265){
- var _266=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- var _267=_266.item(i).getAttribute("usage");
- if(_267!="identifier"){
- if(_265=="unsupported"){
- _266.item(i).setAttribute("usage","attribute");
- }else{
- _266.item(i).setAttribute("usage","fact");
- }
- }
- _266.item(i).setAttribute("regularAggregate",_265);
- _266.item(i).setAttribute("semiAggregate",_265);
- };
- D_AddPersonalWizard.F_GetItemScale=function(_268){
- if(this.F_GetItemDataType(_268)=="Decimal"){
- var _269=_268.getAttribute("scale");
- if(_269){
- return _269;
- }
- }
- return "";
- };
- D_AddPersonalWizard.F_GetItemPrecision=function(_26a){
- if(this.F_GetItemDataType(_26a)=="Decimal"){
- var _26b=_26a.getAttribute("precision");
- if(_26b){
- return _26b;
- }
- }
- return "";
- };
- D_AddPersonalWizard.F_SetDataItemAttributesList=function(){
- if(this.m_sProcessResponse==""&&(!this.m_oPecXML)){
- this.m_oLvColumnsDataItem.F_Clear();
- this.m_oLvColumnsDataItem.F_Draw();
- return;
- }
- var _26c=0;
- var _26d=this.m_oLvColumns.F_GetCheckedListItems();
- this.m_oLvColumnsDataItem.F_Clear();
- var _26e=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- var _26f=null;
- for(var i=0;i<_26e.length;i++){
- var _270=_26e.item(i);
- var _271=_270.getAttribute("name");
- if(_26c>=_26d.length){
- break;
- }
- if(_271==_26d.item(_26c).getAttribute("label")){
- var _272;
- _272=this.m_oLvColumnsDataItem.F_AppendNewListItem();
- if(_26f==null){
- _26f=_272;
- }
- _272.setAttribute("label",_271);
- var _273=U_XML.F_AppendChild(_272,"subItem");
- _273.setAttribute("label",this.F_GetItemDataTypeLabel(_270));
- _273.setAttribute("serverDatatype",_270.getAttribute("datatype"));
- U_XML.F_AppendChild(_272,"subItem").setAttribute("label",this.F_GetItemAggregate(_270));
- if(this.F_GetItemScale(_270)!=null){
- U_XML.F_AppendChild(_272,"subItem").setAttribute("label",this.F_GetItemScale(_270));
- }else{
- U_XML.F_AppendChild(_272,"subItem").setAttribute("label","");
- }
- _26c++;
- }
- }
- this.m_oLvColumnsDataItem.F_Draw();
- if(_26f){
- this.m_oLvColumnsDataItem.F_SelectListItem(_26f,true);
- }
- };
- D_AddPersonalWizard.F_SetColumnList=function(_274,_275){
- var _276=this.m_bIsModify?_274:U_XML.F_LoadString(null,this.m_sProcessResponse);
- this.m_aColumnsList=[];
- var _277=_276.selectNodes("/pdSpec/personalData/item");
- if(_275){
- var _278=_276.selectNodes("/pdSpec/dataSet/accessDirectly").item(0);
- if(_278){
- this.F_GetDlgItem("chkAlwaysTryToLoad").checked=_278.text=="true";
- }else{
- this.F_GetDlgItem("chkAlwaysTryToLoad").checked=false;
- }
- }
- var _279=_276.selectNodes("/pdSpec/dataSet/name").item(0);
- if(_279){
- this.F_GetDlgItem("txtText").value=_279.text.replace(/[#&"'\[\]]/g,"");
- }
- for(var i=0;i<_277.length;i++){
- this.m_aColumnsList[i]=[];
- var _27a=_277.item(i).getAttribute("name");
- var _27b=_277.item(i).getAttribute("ID");
- var _27c=_277.item(i).getAttribute("hidden");
- this.m_aColumnsList[i].m_sLabel=_27a;
- this.m_aColumnsList[i].m_sName=_27b;
- if(_27c&&(_27c=="true")){
- this.m_aColumnsList[i].m_sSelected="false";
- }else{
- this.m_aColumnsList[i].m_sSelected="true";
- }
- }
- this.m_oLvColumns.F_Clear();
- for(var i=0;i<this.m_aColumnsList.length;i++){
- var _27d;
- _27d=this.m_oLvColumns.F_AppendNewListItem();
- _27d.setAttribute("label",this.m_aColumnsList[i].m_sLabel);
- _27d.setAttribute("name",this.m_aColumnsList[i].m_sName);
- _27d.setAttribute("checked",this.m_aColumnsList[i].m_sSelected);
- }
- this.m_oLvColumns.F_Draw();
- };
- D_AddPersonalWizard.F_OnSelectAll=function(){
- this.m_oLvColumns.F_CheckAll();
- this.m_oLvColumns.F_Draw();
- };
- D_AddPersonalWizard.F_OnDeselectAll=function(){
- this.m_oLvColumns.F_UncheckAll();
- this.m_oLvColumns.F_Draw();
- };
- D_AddPersonalWizard.F_ListView_OnDragStart=function(_27e,_27f,_280){
- this.m_oDragInfo={};
- this.m_oDragInfo.v_nSourceItem=_27f[0];
- this.m_oDragInfo.v_oSourceList=_27e;
- if(_27e==this.m_oExternalQSList){
- this.m_oDragInfo.v_oTargetList=this.m_oExistingQSList;
- }else{
- this.m_oDragInfo.v_oTargetList=this.m_oExternalQSList;
- }
- G_DragDrop.F_Start(null,this,this.m_oDragInfo.v_nSourceItem,G_DragDrop.eEffectLink,_280);
- };
- D_AddPersonalWizard.F_OnDragCancel=function(){
- this.m_oDragInfo.v_oTargetList.F_EndDragDropFeedback();
- this.m_oDragInfo={};
- };
- D_AddPersonalWizard.F_OnDragDrop=function(e,_281,_282,_283){
- this.m_oDragInfo.v_oTargetList.F_EndDragDropFeedback();
- if(_282==G_DragDrop.eEffectNone){
- return;
- }
- var _284=null;
- var _285=this.m_oDragInfo.v_oTargetList.F_DragInfoHitTest(e.clientX,e.clientY);
- if(_285&&_285.nNode!=null){
- _284=_285.nNode;
- }
- if(_284==null||this.m_oDragInfo.v_nSourceItem==null){
- return;
- }
- this.m_oDragInfo.v_oSourceList.F_SelectListItem(this.m_oDragInfo.v_nSourceItem,false);
- this.m_oDragInfo.v_oTargetList.F_SelectListItem(_284,false);
- this.F_NewLink();
- };
- D_AddPersonalWizard.F_OnDragOver=function(e,_286,_287,_288,_289){
- var _28a=G_DragDrop.eEffectLink;
- var _28b=this.m_oDragInfo.v_oTargetList.F_DragInfoHitTest(e.clientX,e.clientY);
- if(_28b){
- this.m_oDragInfo.v_oTargetList.F_SelectListItem(_28b.nNode,false);
- }
- return (_28a&_287);
- };
- D_AddPersonalWizard.F_OnDragStart=function(){
- this.f_selectLink(-1);
- this.m_oDragInfo.v_oSourceList.F_SelectListItem(this.m_oDragInfo.v_nSourceItem,false);
- return true;
- };
- D_AddPersonalWizard.F_OnDragComplete=function(_28c){
- this.m_oDragInfo={};
- };
- D_AddPersonalWizard.f_setSelectedIndexToFirstLink=function(){
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=0;i<this.m_aLinks.length;i++){
- if(this.m_aLinks[i]){
- this.m_iSelectedLink=i;
- return;
- }
- }
- }
- this.m_iSelectedLink=-1;
- };
- D_AddPersonalWizard.f_updateLinks=function(){
- if(this.m_oCanvas){
- this.m_oCanvas.F_Clear();
- }
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=0;i<this.m_aLinks.length;i++){
- this.f_updateLink(this.m_aLinks[i],i);
- }
- }
- };
- D_AddPersonalWizard.f_updateLink=function(_28d,i){
- if(!_28d){
- return;
- }
- if(!_28d.M_nLeftListItem){
- _28d.M_nLeftListItem=C_ListView.F_FindListItem(this.m_oExternalQSList.F_GetListViewNode(),"ID",_28d.M_sLeftDataItem);
- }
- if(!_28d.M_nRightListItem){
- _28d.M_nRightListItem=C_ListView.F_FindListItem(this.m_oExistingQSList.F_GetListViewNode(),"_ref",_28d.M_sRightDataItem);
- }
- var d=document;
- var _28e=d.getElementById(_28d.M_nLeftListItem.getAttribute("htmlId")).cells.item(0);
- var _28f=_28e.offsetHeight;
- var _290=U_XML.F_GetIndex(_28d.M_nLeftListItem);
- var _291=U_XML.F_GetIndex(_28d.M_nRightListItem);
- var _292=this.m_divLinks.offsetWidth;
- var _293=_28f/2;
- var _294=_28f*_290;
- var _295=_28f*_291;
- var _296=_294+_293-this.m_divLeft.scrollTop;
- var _297=_295+_293-this.m_divRight.scrollTop;
- var _296=this.m_divLeft.offsetTop+_294+_293-this.m_divLeft.scrollTop;
- if(_296<this.m_divLeft.offsetTop){
- _296=this.m_divLeft.offsetTop-_293;
- }
- if(_296>(this.m_divLeft.offsetTop+this.m_divLeft.offsetHeight)){
- _296=this.m_divLeft.offsetTop+this.m_divLeft.offsetHeight+_293;
- }
- _296-=this.m_divLinks.offsetTop;
- var _297=this.m_divRight.offsetTop+_295+_293-this.m_divRight.scrollTop;
- if(_297<this.m_divRight.offsetTop){
- _297=this.m_divRight.offsetTop-_293;
- }
- if(_297>(this.m_divRight.offsetTop+this.m_divRight.offsetHeight)){
- _297=this.m_divRight.offsetTop+this.m_divRight.offsetHeight+_293;
- }
- _297-=this.m_divLinks.offsetTop;
- if(!_28d.M_elPolyLine){
- var fn=this.f_asyncSelectLink.F_CreateMethodCallback(this,i);
- if(G_BrowserInfo.M_bIsIE){
- _28d.M_elPolyLine=this.m_divLinks.appendChild(d.createElement("<v:polyline points=\"0px,0px,10px,10px,20px,20px,30px,30px\" strokecolor=\"#C0C0C0\" strokeweight=\"1px\" filled=\"false\" style=\"position:absolute\"></v:polyline>"));
- _28d.M_elPolyLine.onmousedown=fn;
- var _298="<v:rect strokecolor=\"#C0C0C0\" strokeweight=\"0px\" filled=\"true\" fillcolor=\"#C0C0C0\" style=\"position:absolute; left:0px; top:0px; width:8px; height:8px\"></v:rect>";
- _28d.M_elLeftRect=this.m_divLinks.appendChild(d.createElement(_298));
- _28d.M_elLeftRect.onmousedown=fn;
- _28d.M_elRightRect=this.m_divLinks.appendChild(d.createElement(_298));
- _28d.M_elRightRect.onmousedown=fn;
- _28d.M_elRightRect.style.left=(_292-8)+"px";
- }else{
- _28d.M_elPolyLine=this.m_elSvg.appendChild(d.createElementNS("http://www.w3.org/2000/svg","polyline"));
- _28d.M_elPolyLine.setAttribute("points","0,0 10,10 20,20 30,30");
- _28d.M_elPolyLine.setAttribute("fill","none");
- _28d.M_elPolyLine.setAttribute("stroke","#C0C0C0");
- _28d.M_elPolyLine.setAttribute("stroke-width","1px");
- _28d.M_elPolyLine.onmousedown=fn;
- _28d.M_elLeftRect=this.m_elSvg.appendChild(d.createElementNS("http://www.w3.org/2000/svg","rect"));
- _28d.M_elLeftRect.setAttribute("stroke","#C0C0C0");
- _28d.M_elLeftRect.setAttribute("stroke-width","0px");
- _28d.M_elLeftRect.setAttribute("fill","#C0C0C0");
- _28d.M_elLeftRect.setAttribute("width","8px");
- _28d.M_elLeftRect.setAttribute("height","8px");
- _28d.M_elLeftRect.setAttribute("y","0");
- _28d.M_elLeftRect.setAttribute("x","0");
- _28d.M_elLeftRect.onmousedown=fn;
- _28d.M_elRightRect=this.m_elSvg.appendChild(d.createElementNS("http://www.w3.org/2000/svg","rect"));
- _28d.M_elRightRect.setAttribute("stroke","#C0C0C0");
- _28d.M_elRightRect.setAttribute("stroke-width","0px");
- _28d.M_elRightRect.setAttribute("fill","#C0C0C0");
- _28d.M_elRightRect.setAttribute("width","8px");
- _28d.M_elRightRect.setAttribute("height","8px");
- _28d.M_elRightRect.setAttribute("y","0");
- _28d.M_elRightRect.setAttribute("x",(_292-8).toString());
- _28d.M_elRightRect.onmousedown=fn;
- }
- }
- if(G_BrowserInfo.M_bIsIE){
- _28d.M_elPolyLine.points.item(0).value="0px,"+_296+"px";
- _28d.M_elPolyLine.points.item(1).value="16px,"+_296+"px";
- _28d.M_elPolyLine.points.item(2).value=(_292-16)+"px,"+_297+"px";
- _28d.M_elPolyLine.points.item(3).value=_292+"px,"+_297+"px";
- _28d.M_elLeftRect.style.top=(_296-4)+"px";
- _28d.M_elRightRect.style.top=(_297-4)+"px";
- }else{
- _28d.M_elPolyLine.setAttribute("points","0,"+_296+" "+"16,"+_296+" "+(_292-16)+","+_297+" "+_292+","+_297);
- _28d.M_elLeftRect.setAttribute("y",(_296-4).toString());
- _28d.M_elRightRect.setAttribute("y",(_297-4).toString());
- }
- };
- D_AddPersonalWizard.f_isLineSelected=function(_299,v_iX,v_iY){
- if(!_299){
- return false;
- }
- return _299.M_elPolyLine.F_IsOnLine(v_iX,v_iY);
- };
- D_AddPersonalWizard.f_asyncSelectLink=function(i){
- setTimeout(this.f_selectLink.F_CreateMethodCallback(this,i),0);
- };
- D_AddPersonalWizard.f_selectLink=function(i){
- this.m_iSelectedLink=i;
- this.f_showSelectedLink();
- this.f_updateLinkButtons();
- };
- D_AddPersonalWizard.f_getLink=function(_29a,_29b){
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=0;i<this.m_aLinks.length;i++){
- var _29c=this.m_aLinks[i];
- if((_29c.M_sLeftDataItem==_29a)&&(_29c.M_sRightDataItem==_29b)){
- return _29c;
- }
- }
- }
- return null;
- };
- D_AddPersonalWizard.f_showSelectedLink=function(){
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=0;i<this.m_aLinks.length;i++){
- var _29d=this.m_aLinks[i];
- if(_29d){
- var _29e=(i==this.m_iSelectedLink)?"highlight":"#C0C0C0";
- if(G_BrowserInfo.M_bIsIE){
- _29d.M_elPolyLine.strokeweight=(i==this.m_iSelectedLink)?"3px":"1px";
- _29d.M_elPolyLine.strokecolor=_29e;
- _29d.M_elLeftRect.fillcolor=_29e;
- _29d.M_elLeftRect.strokecolor=_29e;
- _29d.M_elRightRect.fillcolor=_29e;
- _29d.M_elRightRect.strokecolor=_29e;
- }else{
- _29d.M_elPolyLine.setAttribute("stroke-width",(i==this.m_iSelectedLink)?"4px":"2px");
- _29d.M_elPolyLine.setAttribute("stroke",_29e);
- _29d.M_elLeftRect.setAttribute("fill",_29e);
- _29d.M_elLeftRect.setAttribute("stroke",_29e);
- _29d.M_elRightRect.setAttribute("fill",_29e);
- _29d.M_elRightRect.setAttribute("strokecolor",_29e);
- }
- }
- }
- if(this.m_iSelectedLink==-1){
- this.m_oExternalQSList.F_ClearSelections();
- this.m_oExistingQSList.F_ClearSelections();
- }else{
- var _29d=this.m_aLinks[this.m_iSelectedLink];
- this.m_oExternalQSList.F_SelectListItem(C_ListView.F_FindListItem(this.m_oExternalQSList.F_GetListViewNode(),"ID",_29d.M_sLeftDataItem),false);
- this.m_oExistingQSList.F_SelectListItem(C_ListView.F_FindListItem(this.m_oExistingQSList.F_GetListViewNode(),"_ref",_29d.M_sRightDataItem),false);
- }
- }
- };
- D_AddPersonalWizard.F_eraseLinks=function(_29f){
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=this.m_aLinks.length-1;i>=0;i--){
- var _2a0=this.m_aLinks[i];
- if(_2a0){
- _2a0.M_nLeftListItem=null;
- _2a0.M_nRightListItem=null;
- this.m_iSelectedLink=i;
- if(_2a0.M_elPolyLine){
- _2a0.M_elPolyLine.parentNode.removeChild(_2a0.M_elPolyLine);
- _2a0.M_elLeftRect.parentNode.removeChild(_2a0.M_elLeftRect);
- _2a0.M_elRightRect.parentNode.removeChild(_2a0.M_elRightRect);
- _2a0.M_elPolyLine=null;
- _2a0.M_elLeftRect=null;
- _2a0.M_elRightRect=null;
- }
- if(_29f){
- this.m_aLinks.splice(this.m_iSelectedLink,1);
- }
- }
- }
- }
- };
- D_AddPersonalWizard.F_ListView_OnScroll=function(_2a1){
- if(_2a1==this.m_oExternalQSList||_2a1==this.m_oExistingQSList){
- this.f_updateLinks();
- }
- };
- D_AddPersonalWizard.F_AlignLinkTypes=function(_2a2){
- var _2a3=_2a2.M_sLeftDataItem;
- var _2a4=null;
- var _2a5=this.m_oPecXML.selectNodes("/pdSpec/personalData/item");
- var _2a6=-1;
- for(var i=0;i<_2a5.length;i++){
- var _2a7=_2a5.item(i).getAttribute("ID");
- if(_2a7==_2a3){
- _2a6=i;
- break;
- }
- }
- if(_2a6==-1){
- return;
- }
- _2a4=_2a5.item(_2a6);
- var _2a8=null;
- if(this.m_nExistingReportExtract){
- var nl=this.m_nExistingReportExtract.selectNodes("reportSubject/item");
- var _2a9=nl.length;
- var i=0;
- for(i=0;i<_2a9;i++){
- var n=nl.item(i);
- if(_2a2.M_sRightDataItem==n.getAttribute("ID")){
- _2a8=n;
- break;
- }
- }
- }
- if(this.m_nExistingQSListItems){
- var nl=this.m_nExistingQSListItems.selectNodes("queryItem | calculation");
- var _2a9=nl.length;
- var i=0;
- for(i=0;i<_2a9;i++){
- var n=nl.item(i);
- if(_2a2.M_sRightDataItem==n.getAttribute("ID")){
- _2a8=n;
- break;
- }
- }
- }
- if(_2a8==null){
- return;
- }
- var _2aa=this.F_GetItemDataType(_2a8);
- var _2ab=this.F_GetItemDataType(_2a4);
- if(_2aa!=_2ab){
- if(((_2aa=="Integer")||(_2aa=="Text"))&&((_2ab=="Integer")||(_2ab=="Text"))){
- this.F_SetItemDataType(_2a6,_2aa);
- }
- }
- this.F_SetItemAsIdentifier(_2a2.M_sLeftDataItem);
- };
- D_AddPersonalWizard.f_LinkedList_OnItemClick=function(_2ac,_2ad,_2ae){
- if(!G_BrowserInfo.M_bIsIE&&!G_HAL.M_oLibraries["hal"]["enableAccessibility"]){
- this.F_SetFocusToDefaultButton();
- }
- if(this.m_iSelectedLink==-1){
- return;
- }
- if(_2ad.getAttribute("selectable")=="false"){
- return;
- }
- var _2af=this.m_aLinks[this.m_iSelectedLink];
- if(_2ac.F_GetId()=="D_AddPersonalWizard_divExternalItems"){
- var _2b0=_2af.M_sLeftDataItem;
- _2af.M_sLeftDataItem=_2ad.getAttribute("ID");
- _2af.M_nLeftListItem=null;
- if(this.f_countLinks(_2b0)<1){
- this.f_resetItemData(_2b0);
- }
- }else{
- _2af.M_sRightDataItem=_2ad.getAttribute("_ref");
- _2af.M_nRightListItem=null;
- }
- this.F_AlignLinkTypes(_2af);
- this.f_updateLink(_2af,this.m_iSelectedLink);
- this.f_showSelectedLink();
- this.m_bReadIncomingMappingOptions=true;
- };
- D_AddPersonalWizard.f_countLinks=function(_2b1){
- var _2b2=0;
- if(this.m_aLinks&&this.m_aLinks.length){
- for(var i=this.m_aLinks.length-1;i>=0;i--){
- var _2b3=this.m_aLinks[i];
- if(_2b3&&(_2b3.M_sLeftDataItem==_2b1)){
- _2b2++;
- }
- }
- }
- return _2b2;
- };
- D_AddPersonalWizard.f_onKeyDown=function(e){
- if(this.m_oDeck.F_GetIndex()==D_AddPersonalWizard.K_iLinksPage){
- e=e||window.event;
- if((e.keyCode==U_DOM.K_iKeyDelete)&&(this.m_iSelectedLink!=-1)){
- this.f_removeLink(this.m_iSelectedLink);
- }
- }
- this.M_fnSuper_OnKeyDown(e);
- };
- D_AddPersonalWizard.f_removeLink=function(_2b4){
- if(_2b4<0||_2b4>=this.m_aLinks.length){
- return;
- }
- var _2b5=this.m_aLinks[_2b4];
- _2b5.M_elPolyLine.parentNode.removeChild(_2b5.M_elPolyLine);
- _2b5.M_elLeftRect.parentNode.removeChild(_2b5.M_elLeftRect);
- _2b5.M_elRightRect.parentNode.removeChild(_2b5.M_elRightRect);
- this.m_aLinks.splice(_2b4,1);
- if(_2b4==this.m_iSelectedLink){
- this.f_setSelectedIndexToFirstLink();
- }
- this.f_showSelectedLink();
- this.f_updateLinkAttributes();
- this.f_updateLinkButtons();
- };
- D_AddPersonalWizard.F_NewLink=function(){
- var _2b6={};
- var _2b7=this.m_oExternalQSList.F_GetSelectedListItem();
- if(_2b7==null||this.m_iSelectedLink!=-1){
- _2b7=C_ListView.F_FindListItemByIndex(this.m_oExternalQSList.F_GetListViewNode(),0);
- }
- _2b6.M_sLeftDataItem=_2b7.getAttribute("ID");
- var _2b8=this.m_oExistingQSList.F_GetSelectedListItem();
- if(_2b8==null||this.m_iSelectedLink!=-1){
- var _2b9=this.m_oExistingQSList.F_GetListItems();
- var _2ba=_2b9.length;
- for(var i=0;i<_2ba;i++){
- var _2bb=_2b9.item(i);
- if(_2bb.getAttribute("selectable")!="false"){
- _2b8=_2bb;
- break;
- }
- }
- if(_2b8==null){
- return;
- }
- }
- _2b6.M_sRightDataItem=_2b8.getAttribute("_ref");
- this.m_aLinks.push(_2b6);
- if(this.m_aLinks.length==1){
- this.f_setDefaultLinkAttributes();
- }
- this.m_iSelectedLink=this.m_aLinks.length-1;
- this.f_updateLink(_2b6,this.m_iSelectedLink);
- this.F_AlignLinkTypes(_2b6);
- this.f_showSelectedLink();
- this.f_updateLinkButtons();
- };
- D_AddPersonalWizard.F_DeleteLink=function(){
- if(this.m_iSelectedLink!=-1){
- this.f_removeLink(this.m_iSelectedLink);
- }
- };
- D_AddPersonalWizard.f_onExternalValueClicked=function(){
- if(this.m_radAllValUniqueExternal.checked==true){
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExisting,true);
- }else{
- if(this.m_radMorethanOnceExternal.checked==true){
- this.m_radAllValUniqueExisting.checked=true;
- this.m_radMorethanOnceExisting.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExisting,false);
- }
- }
- this.f_updateMappingControlStates();
- };
- D_AddPersonalWizard.f_onExistingValueClicked=function(){
- if(this.m_radAllValUniqueExisting.checked==true){
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExternal,true);
- }else{
- if(this.m_radMorethanOnceExisting.checked==true){
- this.m_radAllValUniqueExternal.checked=true;
- this.m_radMorethanOnceExternal.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExternal,false);
- }
- }
- this.f_updateMappingControlStates();
- };
- D_AddPersonalWizard.f_updateMappingControlStates=function(){
- var _2bc=D_AddPersonalWizard.K_iOneToOne;
- var _2bd=D_AddPersonalWizard.K_iOneToOne;
- if(this.m_radAllValUniqueExternal.checked==true){
- if(this.m_radExternalExcludeMissingValues.checked==true){
- _2bc=D_AddPersonalWizard.K_iOneToOne;
- }else{
- _2bc=D_AddPersonalWizard.K_iOptToOne;
- }
- }else{
- if(this.m_radExternalExcludeMissingValues.checked==true){
- _2bc=D_AddPersonalWizard.K_iOneToMany;
- }else{
- _2bc=D_AddPersonalWizard.K_iOptToMany;
- }
- }
- if(this.m_radAllValUniqueExisting.checked==true){
- if(this.m_radExistingExcludeMissingValues.checked==true){
- _2bd=D_AddPersonalWizard.K_iOneToOne;
- }else{
- _2bd=D_AddPersonalWizard.K_iOptToOne;
- }
- }else{
- if(this.m_radExistingExcludeMissingValues.checked==true){
- _2bd=D_AddPersonalWizard.K_iOneToMany;
- }else{
- _2bd=D_AddPersonalWizard.K_iOptToMany;
- }
- }
- this.m_spanExternalCardinality.innerHTML=this.m_nlCardinalityLabels.item(_2bc).getAttribute("label");
- this.m_spanExistingCardinality.innerHTML=this.m_nlCardinalityLabels.item(_2bd).getAttribute("label");
- this.m_spanExternalCardinality.style.visibility=this.m_spanExternalCardinality.innerHTML?"visible":"hidden";
- this.m_spanExistingCardinality.style.visibility=this.m_spanExistingCardinality.innerHTML?"visible":"hidden";
- };
- D_AddPersonalWizard.f_updateLinkAttributes=function(_2be){
- this.m_oColExternalLink.F_Clear();
- this.m_oColExistingLink.F_Clear();
- if(this.m_aLinks&&(this.m_aLinks.length)&&(this.m_aLinks.length>0)){
- this.m_aTipText[D_AddPersonalWizard.K_iLinkAttribPage]="IDS_WIZ_ADDPERSONAL_SUBTITLE_SELECT_MAPPINGOPTIONS";
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExisting,true);
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExternal,true);
- U_DOM.F_SetRadioButtonEnabled(this.m_radAllValUniqueExisting,true);
- U_DOM.F_SetRadioButtonEnabled(this.m_radAllValUniqueExternal,true);
- U_DOM.F_SetRadioButtonEnabled(this.m_radExternalExcludeMissingValues,true);
- U_DOM.F_SetRadioButtonEnabled(this.m_radExternalIncludeMissingValues,true);
- U_DOM.F_SetRadioButtonEnabled(this.m_radExistingExcludeMissingValues,true);
- U_DOM.F_SetRadioButtonEnabled(this.m_radExistingIncludeMissingValues,true);
- this.f_updateLinks();
- for(var i=0;i<this.m_aLinks.length;i++){
- var _2bf;
- var _2c0=this.m_aLinks[i];
- _2bf=this.m_oColExternalLink.F_AppendNewListItem();
- _2bf.setAttribute("label",_2c0.M_nLeftListItem.getAttribute("label"));
- _2bf.setAttribute("selectable","false");
- var _2c1=this.m_oColExistingLink.F_AppendNewListItem();
- _2c1.setAttribute("label",_2c0.M_nRightListItem.getAttribute("label"));
- _2c1.setAttribute("selectable","false");
- }
- this.m_oColExternalLink.F_Draw();
- this.m_oColExistingLink.F_Draw();
- }else{
- if(!this.m_bReadIncomingMappingOptions){
- this.m_aTipText[D_AddPersonalWizard.K_iLinkAttribPage]="IDS_WIZ_ADDPERSONAL_SUBTITLE_DISABLED_MAPPINGOPTIONS";
- this.m_radMorethanOnceExisting.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExisting,false);
- this.m_radMorethanOnceExternal.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radMorethanOnceExternal,false);
- this.m_radAllValUniqueExisting.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radAllValUniqueExisting,false);
- this.m_radAllValUniqueExternal.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radAllValUniqueExternal,false);
- this.m_radExternalExcludeMissingValues.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radExternalExcludeMissingValues,false);
- this.m_radExternalIncludeMissingValues.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radExternalIncludeMissingValues,false);
- this.m_radExistingExcludeMissingValues.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radExistingExcludeMissingValues,false);
- this.m_radExistingIncludeMissingValues.checked=false;
- U_DOM.F_SetRadioButtonEnabled(this.m_radExistingIncludeMissingValues,false);
- this.m_spanExternalCardinality.innerHTML="";
- this.m_spanExistingCardinality.innerHTML="";
- this.m_spanExternalCardinality.style.visibility="hidden";
- this.m_spanExistingCardinality.style.visibility="hidden";
- this.m_oColExternalLink.F_Draw();
- this.m_oColExistingLink.F_Draw();
- this.f_updateTipText(this.m_nCurrentCard);
- return;
- }
- }
- if(_2be){
- var _2c2=_2be.selectSingleNode("pdSpec/relationship/sourceCardinality/maxCard");
- if(_2c2&&_2c2.text=="many"){
- this.m_radAllValUniqueExternal.checked=false;
- this.m_radMorethanOnceExternal.checked=true;
- }else{
- this.m_radAllValUniqueExternal.checked=true;
- this.m_radMorethanOnceExternal.checked=false;
- }
- var _2c3=_2be.selectSingleNode("pdSpec/relationship/sourceCardinality/minCard");
- if(_2c3&&_2c3.text=="zero"){
- this.m_radExternalExcludeMissingValues.checked=false;
- this.m_radExternalIncludeMissingValues.checked=true;
- }else{
- this.m_radExternalExcludeMissingValues.checked=true;
- this.m_radExternalIncludeMissingValues.checked=false;
- }
- var _2c4=_2be.selectSingleNode("pdSpec/relationship/targetCardinality/maxCard");
- if(_2c4&&_2c4.text=="many"){
- this.m_radAllValUniqueExisting.checked=false;
- this.m_radMorethanOnceExisting.checked=true;
- }else{
- this.m_radAllValUniqueExisting.checked=true;
- this.m_radMorethanOnceExisting.checked=false;
- }
- var _2c5=_2be.selectSingleNode("pdSpec/relationship/targetCardinality/minCard");
- if(_2c5&&_2c5.text=="zero"){
- this.m_radExistingExcludeMissingValues.checked=false;
- this.m_radExistingIncludeMissingValues.checked=true;
- }else{
- this.m_radExistingExcludeMissingValues.checked=true;
- this.m_radExistingIncludeMissingValues.checked=false;
- }
- }
- this.f_updateTipText(this.m_nCurrentCard);
- this.f_updateMappingControlStates();
- };
- D_AddPersonalWizard.f_setDefaultLinkAttributes=function(){
- this.m_radAllValUniqueExternal.checked=true;
- this.m_radMorethanOnceExternal.checked=false;
- this.m_radAllValUniqueExisting.checked=true;
- this.m_radMorethanOnceExisting.checked=false;
- this.m_radExternalExcludeMissingValues.checked=true;
- this.m_radExternalIncludeMissingValues.checked=false;
- this.m_radExistingExcludeMissingValues.checked=true;
- this.m_radExistingIncludeMissingValues.checked=false;
- };
- var G_ContentManager={};
- G_ContentManager.m_sLastDocumentRequest="";
- G_ContentManager.m_sLastDocumentResponse="";
- G_ContentManager.K_eTypeReport="report";
- G_ContentManager.K_eTypeReportTemplate="reportTemplate";
- G_ContentManager.K_eTypeInteractiveReport="interactiveReport";
- G_ContentManager.F_GetLastDocumentRequest=function(){
- return this.m_sLastDocumentRequest;
- };
- G_ContentManager.F_GetLastDocumentResponse=function(){
- return this.m_sLastDocumentResponse;
- };
- G_ContentManager.F_GetReportType=function(){
- if(U_Report.F_IsApplication(G_ReportSpec.F_GetReportNode())){
- return G_ContentManager.K_eTypeInteractiveReport;
- }else{
- if(G_ReportSpec.F_IsTemplate()){
- return G_ContentManager.K_eTypeReportTemplate;
- }else{
- return G_ContentManager.K_eTypeReport;
- }
- }
- };
- G_ContentManager.F_ValidateName=function(_2c6){
- if(!_2c6){
- F_MsgBoxRes("IDS_FILENAME_EMPTY");
- return false;
- }
- switch(_2c6){
- case "~":
- case "~~":
- F_MsgBoxRes("IDS_SQUIGGLE_NAME");
- return false;
- }
- return true;
- };
- G_ContentManager.F_PromptForNewFolder=function(_2c7,_2c8,_2c9){
- D_InputBox.F_SelectDefaultText(true);
- D_InputBox.F_Show(_2c7,G_ResManager.F_GetString("IDS_LBL_NAME"),G_ResManager.F_GetString("IDS_TITLE_NEWFOLDER"),_2c8,null,function(){
- var s=D_InputBox.F_GetText();
- if(s){
- _2c9(s);
- }
- });
- };
- G_ContentManager.F_PromptForRename=function(_2ca,_2cb,_2cc){
- D_InputBox.F_SelectDefaultText(true);
- D_InputBox.F_Show(_2ca,G_ResManager.F_GetString("IDS_LBL_NAME"),G_ResManager.F_GetString("IDS_TITLE_RENAME"),_2cb,null,function(){
- var s=D_InputBox.F_GetText();
- if(s){
- _2cc(s);
- }
- });
- };
- G_ContentManager.F_ConfirmDelete=function(_2cd,_2ce,_2cf){
- D_MsgBox.F_Show(_2cd,G_ResManager.F_GetString("IDS_MSG_CONFIRMDELETE"),null,D_MsgBox.K_iWarning,D_MsgBox.K_iOKCancel,_2cf);
- };
- G_ContentManager.F_SendPaperSizesRequest=function(_2d0,_2d1){
- if(this.m_nPaperSizesResponse){
- _2d1.F_ContentManager_OnPaperSizesLoaded();
- return;
- }
- var _2d2="<bus:query>"+"<search>/configuration/pageDefinition</search>"+"<properties xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:propEnum[]\">"+"<item>defaultName</item>"+"<item>searchPath</item>"+"<item>width</item>"+"<item>height</item>"+"<item>unit</item>"+"</properties>"+"</bus:query>";
- var _2d3=C_BusRequest.F_CreateContext(this.e_RequestPaperSize);
- _2d3.m_oListener=_2d1;
- var _2d4=new C_BusRequest(this,C_BusRequest.K_sSOAPAction_contentManagerService,_2d2);
- _2d4.F_SetContext(_2d3);
- D_Progress.F_SendRequest(_2d4,_2d0,G_ResManager.F_GetString("IDS_MSG_LOADING_PAGESIZES"));
- };
- G_ContentManager.e_RequestPaperSize=1;
- G_ContentManager.F_Request_OnComplete=function(_2d5){
- var _2d6=_2d5.F_GetError();
- if(_2d6){
- F_ShowError(_2d6);
- }
- var _2d7=_2d5.F_GetContext();
- var _2d8=_2d5.F_GetResponse();
- switch(_2d7.m_eType){
- case this.e_RequestPaperSize:
- this.m_nPaperSizesResponse=_2d8?_2d8.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/queryResult"):null;
- _2d7.m_oListener.F_ContentManager_OnPaperSizesLoaded();
- break;
- }
- };
- G_ContentManager.F_GetPaperSizeLabel=function(_2d9){
- if(this.m_nPaperSizesResponse){
- var n=this.m_nPaperSizesResponse.selectSingleNode("item[searchPath/value/text()="+_2d9.F_ToXPathString()+"]/defaultName/value");
- if(n){
- return n.text;
- }
- }
- return _2d9;
- };
- G_ContentManager.F_AddPaperSizesToListView=function(_2da,_2db){
- U_Utils.F_AddDefaultListItem(_2da.F_GetListViewNode());
- if(_2db){
- var _2dc=_2da.F_AppendNewListItem();
- _2dc.setAttribute("idsLabel","IDS_PROPVAL_CUSTOM");
- _2dc.setAttribute("value","custom");
- }
- if(this.m_nPaperSizesResponse){
- var nl=this.m_nPaperSizesResponse.selectNodes("item");
- for(var i=0;i<nl.length;++i){
- var _2dd=nl.item(i);
- var _2de=_2dd.selectSingleNode("defaultName/value").text;
- var _2df=_2dd.selectSingleNode("searchPath/value").text;
- var _2dc=_2da.F_AppendNewListItem();
- _2dc.setAttribute("label",_2de);
- _2dc.setAttribute("value",_2df);
- _2dc.setAttribute("width",_2dd.selectSingleNode("width/value").text);
- _2dc.setAttribute("height",_2dd.selectSingleNode("height/value").text);
- _2dc.setAttribute("unit",_2dd.selectSingleNode("unit/value").text);
- }
- }
- };
- G_ContentManager.F_CreateGetConnectionsRequest=function(_2e0){
- var _2e1="<bus:query>"+"<search>//dataSource[@shown='true'][permission('read') or permission('write') or permission('traverse') or permission('execute')]</search>"+"<sortBy xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:sort[1]\">"+"<item xsi:type=\"bus:sort\">"+"<propName xsi:type=\"bus:propEnum\">defaultName</propName>"+"<order xsi:type=\"bus:orderEnum\">ascending</order>"+"</item>"+"</sortBy>"+"<properties xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:propEnum[]\">"+"<item>defaultName</item>"+"</properties>"+"</bus:query>";
- return new C_BusRequest(_2e0,C_BusRequest.K_sSOAPAction_contentManagerService,_2e1);
- };
- G_ContentManager.F_ProcessCmResponse=function(_2e2){
- return _2e2?_2e2.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/queryResult"):null;
- };
- G_ContentManager.F_CreateSaveDocumentRequest=function(_2e3,_2e4,_2e5,_2e6,_2e7,_2e8,_2e9){
- var _2ea="bus:"+_2e7;
- var _2eb=U_Report.F_GetXML(_2e4);
- var _2ec="";
- if(_2e8){
- _2ec="<rns1:add>"+"<parentPath>"+_2e5.F_XMLEncode()+"</parentPath>"+"<object xsi:type=\""+_2ea+"\">"+"<defaultName>"+"<value xsi:type=\"xsd:string\">"+_2e6.F_XMLEncode()+"</value>"+"</defaultName>"+"<specification>"+"<value xsi:type=\"xsd:string\" xml:space=\"preserve\">"+_2eb.F_XMLEncode()+"</value>"+"</specification>"+"<parameters xsi:type=\"bus:parameterValueArrayProp\" SOAP-ENC:arrayType=\"bus:parameterValue[]\">"+"<value xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:parameterValue[]\"/>"+"</parameters>"+"</object>"+"<options xsi:type=\"bus:addOptions\">"+"<updateAction xsi:type=\"bus:updateActionEnum\">"+(_2e9?"fail":"replace")+"</updateAction>"+"</options>"+"</rns1:add>";
- }else{
- var _2ed=(_2e6.indexOf("\"")==-1)?"\"":"'";
- _2ec="<rns1:update>"+"<object xsi:type=\""+_2ea+"\">"+"<searchPath>"+"<value xsi:type=\"xsd:string\">"+_2e5.F_XMLEncode()+"/"+_2e7+"[@name="+_2ed+_2e6.F_XMLEncode()+_2ed+"]</value>"+"</searchPath>"+"<specification>"+"<value xsi:type=\"xsd:string\" xml:space=\"preserve\">"+_2eb.F_XMLEncode()+"</value>"+"</specification>"+"<parameters xsi:type=\"bus:parameterValueArrayProp\" SOAP-ENC:arrayType=\"bus:parameterValue[]\">"+"<value xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:parameterValue[]\"/>"+"</parameters>"+"</object>"+"<options xsi:type=\"bus:updateOptions\"/>"+"</rns1:update>";
- }
- G_ContentManager.m_sLastDocumentRequest=_2ec;
- G_ContentManager.m_sLastDocumentResponse="";
- return new C_BusRequest(_2e3,C_BusRequest.K_sSOAPAction_reportService,_2ec);
- };
- function C_AddCMObjectRequest(_2ee,_2ef,_2f0,_2f1,_2f2,_2f3){
- this.m_sNewPath="";
- var _2f4="";
- if(!_2f2){
- _2f2="fail";
- }
- if(_2f3){
- _2f4="<specification xsi:type=\"bus:anyTypeProp\">"+"<value xsi:type=\"xsd:string\">"+_2f3.F_XMLEncode()+"</value>"+"</specification>";
- }
- var _2f5="<bus:add>"+"<search>"+_2ef.F_XMLEncode()+"</search>"+"<objects SOAP-ENC:arrayType=\"bus:baseClass[1]\">"+"<item xsi:type=\""+_2f1+"\">"+"<defaultName xsi:type=\"bus:stringProp\">"+"<value xsi:type=\"xsd:string\">"+_2f0.F_XMLEncode()+"</value>"+"</defaultName>"+_2f4+"</item>"+"</objects>"+"<options xsi:type=\"bus:addOptions\">"+"<updateAction xsi:type=\"bus:updateActionEnum\">"+_2f2+"</updateAction>"+"</options>"+"</bus:add>";
- G_ContentManager.m_sLastDocumentRequest=_2f5;
- G_ContentManager.m_sLastDocumentResponse="";
- this.F_ConstructBaseClass(_2ee,C_BusRequest.K_sSOAPAction_contentManagerService,_2f5);
- };
- C_AddCMObjectRequest.F_Extends(C_BusRequest);
- C_AddCMObjectRequest.prototype.F_GetNewPath=function(){
- return this.m_sNewPath;
- };
- C_AddCMObjectRequest.prototype.F_ProcessResponse=function(){
- C_AddCMObjectRequest.superClass.F_ProcessResponse.call(this);
- var _2f6=this.F_GetResponse();
- if(_2f6){
- var _2f7=_2f6.selectSingleNode(".//addResult/item/searchPath/value");
- this.m_sNewPath=_2f7.text;
- }
- };
- G_ContentManager.F_CreateRenameObjectRequest=function(_2f8,_2f9,_2fa,_2fb){
- if(_2fa=="folder"){
- var _2fc="<bus:update>"+"<objects xsi:type=\"SOAP-ENC:Array\" SOAP-ENC:arrayType=\"bus:baseClass[1]\">"+"<item xsi:type=\"bus:"+_2fa+"\">"+"<defaultName>"+"<value xsi:type=\"xsd:string\">"+_2fb.F_XMLEncode()+"</value>"+"</defaultName>"+"<bus:searchPath>"+"<value xsi:type=\"xsd:string\">"+_2f9.F_XMLEncode()+"</value>"+"</bus:searchPath>"+"</item>"+"</objects>"+"<options xsi:type=\"bus:updateOptions\"/>"+"</bus:update>";
- G_ContentManager.m_sLastDocumentRequest=_2fc;
- G_ContentManager.m_sLastDocumentResponse="";
- return new C_BusRequest(_2f8,C_BusRequest.K_sSOAPAction_contentManagerService,_2fc);
- }
- var _2fc="<bus:update>"+"<object xsi:type=\"bus:"+_2fa+"\">"+"<searchPath>"+"<value xsi:type=\"xsd:string\">"+_2f9.F_XMLEncode()+"</value>"+"</searchPath>"+"<defaultName>"+"<value xsi:type=\"xsd:string\">"+_2fb.F_XMLEncode()+"</value>"+"</defaultName>"+"</object>"+"<options xsi:type=\"bus:updateOptions\"/>"+"</bus:update>";
- G_ContentManager.m_sLastDocumentRequest=_2fc;
- G_ContentManager.m_sLastDocumentResponse="";
- return new C_BusRequest(_2f8,C_BusRequest.K_sSOAPAction_reportService,_2fc);
- };
- G_ContentManager.F_CreateDeleteObjectRequest=function(_2fd,_2fe){
- var _2ff="<bus:delete>"+"<search>"+_2fe.F_XMLEncode()+"</search>"+"<options xsi:type=\"bus:deleteOptions\">"+"<force xsi:type=\"xsd:boolean\">true</force>"+"<recursive xsi:type=\"xsd:boolean\">true</recursive>"+"</options>"+"</bus:delete>";
- G_ContentManager.m_sLastDocumentRequest=_2ff;
- G_ContentManager.m_sLastDocumentResponse="";
- return new C_BusRequest(_2fd,C_BusRequest.K_sSOAPAction_contentManagerService,_2ff);
- };
- G_ContentManager.F_UpdateRequestSucceed=function(_300){
- G_ContentManager.m_sLastDocumentResponse=_300?_300.xml:"";
- return (_300!=null);
- };
- var G_Model=new C_ModelCache();
- G_Model.m_aListeners=[];
- G_Model.F_ReloadModel=function(_301){
- if(!this.F_ModelEnabled()){
- return;
- }
- if(this.F_GetModelRootResponses()){
- this.F_ClearModelCache();
- }
- this.m_aListeners.F_CallEach("F_Model_OnLoad");
- var _302=new C_ModelRootRequest(this,this);
- _302.F_SetContext(_301);
- D_Progress.F_SendRequest(_302,null,G_ResManager.F_GetString("IDS_MSG_LOADING_MODEL"),G_UserDataSettings.F_GetValue("LoadingModelDialogDelay"));
- };
- G_Model.F_Request_OnComplete=function(_303){
- switch(_303.constructor){
- case C_ModelRootRequest:
- this.m_aListeners.F_CallEach("F_Model_OnLoadComplete");
- var _304=_303.F_GetError();
- var _305=_303.F_GetContext();
- if(_304){
- F_ShowError(_304,_305);
- return;
- }
- if(_305){
- _305();
- }
- break;
- }
- };
- G_Model.F_Request_OnAborted=function(_306){
- this.m_aListeners.F_CallEach("F_Model_OnAbortLoad");
- };
- G_Model.F_AddListener=function(_307){
- this.m_aListeners.push(_307);
- };
- G_Model.F_RemoveListener=function(_308){
- this.m_aListeners.F_RemoveItem(_308);
- };
- G_Model.F_CreateSharedSetsReportRequest=function(_309,_30a,_30b,_30c){
- return new C_SharedSetsStoreIDAndPathReportRequest(_309,_30a,_30b,_30c);
- };
- G_Model.f_getAllSharedSetsPackagesAndReports=function(_30d){
- return U_SharedSets.F_GetAllModelsAndReports();
- };
- G_Model.f_setAllSharedSetsPackagesAndReports=function(_30e){
- G_UserDataSettings.F_SetValue("SharedSetsCache",_30e.F_GetSharedSetsDoc().xml,false);
- };
- G_Model.F_GetSharedSetProperties=function(d){
- return U_SharedSets.F_GetSharedSetProperties(d.documentElement);
- };
|