_of7.js 24 KB

123456
  1. // Licensed Materials - Property of IBM
  2. // IBM Cognos Products: rs
  3. // (C) Copyright IBM Corp. 2003, 2022.
  4. // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  5. define([],function(){"use strict";function _kzf(_arg){this._ufg=_arg;}_kzf.prototype._ujl=function(){var _0um=Q.defer();_5ml._jll(["_g8j"],function(_g8j){for(var i=0; i<this._ufg.length; i++){var _zpi=this._ufg[i];if(_zpi.nodeName=="vcSlotMeasureGroup"||_zpi.nodeName=="vcSlotData"&&_7hn._ij8(_zpi, ".//vcSlotMeasureGroup")){Application._28j(_frh._c6j("IDS_MSG_UNSUPPORTED_MEASUREGROUP_COPY"), {'type':'warning'});return false;}if(_qgn._bsh&&_zpi.nodeName=="list"){return false;}}if(_qkk._qik("EnableExternalClipboard")){Application._28j(_frh._c6j("IDS_MSG_REPORT_ASSETS_COPIED", this._ufg.length), {'type':'success'});}_g8j._de().then(function(){var _g4f=null;switch(_38g._g0n){case _j8j:case _ov9:case _kyc:_g4f=[];_g4f.push(_erh._q77(this._ufg[0]));break;case _kv9:_g4f=[];for(var i=0;i<this._ufg.length;i++){_g4f.push(_erh._q77(this._ufg[i]));}break;default:var _szb=_gth._mh2(this._ufg);var _qjd=_m9g._mh2(this._ufg);var _wpg=_szb.concat(_qjd);_g4f=_ath._r67(this._ufg, true);_g4f=_g4f&&_g4f.concat(_wpg); } if(_g4f){_4aj._3bb(_g4f);_0um.resolve(true);}_0um.resolve(false);}.bind(this));}.bind(this));return _0um.promise;};function _1mh(_arg){this._ufg=_arg;}_1mh.prototype._ujl=function(){return(new _kzf(this._ufg))._ujl().then(function(_q0c){if(!_q0c){return;}if(_38g._g0n==_k8j){_6aj._ybb();var _zyk=true;for(var i=0;i<this._ufg.length;i++){if(!_6aj._jnh(this._ufg[i])){_zyk=false;break;}}if(_zyk){_6aj._iee(true);}else{_6aj._5c7();}}else{_erh._ybb();if(_ath._b1g(this._ufg, false, false)){_erh._iee(true);}else{_erh._5c7();}}}.bind(this));};function _0ce(_zpi){this._93i=_zpi;}_0ce.prototype._ujl=function(_fsj,_2yl){var _0um=Q.defer();if(_qkk._qik("TurnCopyPasteBetweenInstancesOn")){_5ml._jll(["_g8j"],function(_g8j){_g8j._1c().then(function(_p1e){if(_4aj._om(_p1e)){this._j93(_p1e, _fsj, _2yl);}else{this._k93(_fsj, _2yl);}return _0um.resolve(true);}.bind(this));}.bind(this));}else{this._k93(_fsj, _2yl);return _0um.resolve(true);}return _0um.promise;};_0ce.prototype._k93=function(_fsj,_2yl){console.log("PasteInternalClipboard");var _3u2 =[];var _g4f=_4aj._z6b();if(!_g4f){var _men=_4aj._fkl();if(_men){var _k2k=_7th._477( "textItem", _cgm._iab( _men ).replace( /\t/g, "" ) );_g4f=[];_g4f.push(_k2k);}}if(!_g4f){_67j("IDS_MSG_CLIPBOARD_EMPTY");return;}switch(_38g._g0n){case _j8j:_erh._ybb();var _5ka=true;var _ibn=_erh._e5j(_g4f[0], true);_o42._2ph(_ypn._jf8(), _ibn, this._93i, _nkk.eLocationInside, _2yl, _5ka);var _83m=_erh._vtc();var _aec=_7hn._x5g(_ibn, "descendant-or-self::*/@refDataStore");for(var i=0; i<_aec.length; i++){var _y8e=_7hn._fkl(_aec.item(i));var _tli=_4y9._6fe(_83m, _y8e);var _zvd=_4y9._j5b(_83m, _tli);var _ci3=_7hn._x5g(_ibn, ".//*[@refDataStore=" + _cgm._zxc(_y8e) + "]");_8qn._433(_ci3, "refDataStore", _zvd.getAttribute("name"));}_erh._iee(true); break;case _ov9:_erh._ybb();var n=_38g._g0n._2ph(_ypn._jf8(), _erh._e5j(_g4f[0], true), this._93i, _nkk.eLocationInside);if(n){_8l8._7je(n.getAttribute("iid"));_erh._iee(true);}else{_ypn._rfm._f5g( _frh._c6j( "IDS_NO_PASTE_OBJECT", _frh._c6j( "IDS_EL_" + _g4f[0].nodeName ) ) );_erh._5c7();}break;case _kv9:_erh._ybb();var n=null;var _8cn=_38g._g0n;var _b2m=_ypn._jf8();if(this._93i){_g4f.reverse();}for(var i=0;i<_g4f.length;i++){var n=_8cn._2ph(_b2m, _erh._e5j(_g4f[i], true), this._93i, _nkk.eLocationAfter);if(!n){break;}}if(n){_8l8._7je(n.getAttribute("iid"));_erh._iee(true);}else{_ypn._rfm._f5g( _frh._c6j( "IDS_NO_PASTE_OBJECT", _frh._c6j( "IDS_EL_" + _g4f[0].nodeName ) ) );_erh._5c7();}break;case _kyc:var _j3m=_erh._e5j(_g4f[0], true);_dk2._2ph(_ypn._jf8(), _j3m, this._93i, _nkk.eLocationInside);break;case _k8j:for(var i=0;i<_g4f.length;i++){_g4f[i]=_erh._e5j(_g4f[i], true);}_6aj._ce4(_g4f, this._93i, _fsj, _2yl);break;default:if(Application.SharedState.Get("isLocked")&&_geb._rsh[this._93i.nodeName] &&(_fsj==_ath._6me)){_gem( _frh._c6j( "IDS_NO_PASTE_OBJECT", _frh._c6j( "IDS_EL_" + _g4f[0].nodeName ) ) );return;}var _wpg=_4y9._n77(_g4f);var _83m=_erh._vtc();var _e06=new Map();_wpg.forEach(function(_tli){_e06.set(_tli.getAttribute("name"), _tli);});_g4f.filter(function(_lun){return _lun.nodeName=="listControl";}).forEach(function(_nif){var _tli=_e06.get(_nif.getAttribute("refDataStore"));_vzm._6dm(_tli);_m0n._bqh(_wpg, _tli); _m0n._bqh(_g4f, _tli);var _zvd=_4y9._j5b(_83m, _tli);_nif.setAttribute("refDataStore", _zvd.getAttribute("name"));},this);var _6s6=_gth._i41(_g4f);var _kna=0;for(var i=0;i<_6s6.length;++i){var _t8n=_6s6[i];switch(_t8n.nodeName){case "vizControl":var _mri=_7hn._x5g(_t8n, "vcDataSets/vcDataSet");var _83m=_erh._vtc();for(var id=0; id<_mri.length;++id){var _74l=_mri.item(id);var _axi=_74l.getAttribute("refDataStore");if(_axi){var _tli=_wpg[_kna];_m0n._bqh(_g4f, _tli);var _zvd=_4y9._j5b(_83m, _tli);var _l7e=_zvd.getAttribute("name");_74l.setAttribute("refDataStore", _l7e);_kna++;} }break;case "vcSlotData":case "vcSlotDsColumn":case "rcExtraDsColumn":var _tli=_wpg[_kna];_m0n._bqh(_g4f, _tli);var _zvd=_erh._e5j(_tli, true);_3u2.push(_zvd);_kna++;break;case "lcExtraColumn":alert("Todd TBD _of7");break;}}if(_ath._ho3(new _4mh(_g4f, null, _3u2), this._93i, _fsj)){this._i5d(_g4f);}break;} };_0ce.prototype._i5d=function(_g4f){var _83m=_erh._vtc();var _d15=_83m.selectNodes(".//listColumnRowSpan");for(var i=0; i<_d15.length; i++){var _wx6=_d15.item(i);var _5wf=_wx6.getAttribute("refDataItem");var _j9n=_8qn._12g(_wx6, "list");var _gni=_j9n.selectSingleNode("./listGroups/listGroup[@refDataItem=" + _cgm._zxc(_5wf) + "]");if(!_gni){_5hn._7hk(_j9n, _5wf);}}};_0ce.prototype._j93=function(_p1e,_fsj,_2yl){if(!_p1e){_67j("IDS_MSG_CLIPBOARD_EMPTY");return;}switch(_p1e.type){case "DASHBOARD":case "EXPLORE":case "STORY":_5ml._jll(["_o0d"],function(_o0d){_o0d._j67(_p1e).then(function(_g07){var _cx6=_g07.report;var _cr6=_g07.warnings;var _6zb=[];var nl=_cx6.selectNodes(".//list | .//crosstab | .//viz | .//vizControl | .//singleton");for(var i=0; i<nl.length; i++){var _n9e="iid"+i;nl.item(i).setAttribute("iid", _n9e);_6zb.push(_n9e);}this._lk5(_cx6, _6zb, _p1e.type, _cr6, _fsj, _2yl); }.bind(this));}.bind(this));break;case "REPORT":var _0yd=_8qn._kph(null, _p1e.spec).selectSingleNode("report");this._lk5(_0yd, _p1e.selectionIids, _p1e.type, null, _fsj, _2yl); break;default:Application._28j(_frh._c6j("IDS_MSG_UNSUPPORTED_EXTERNAL_ASSET") + ": " + _p1e.type, {type: "warning"});break;} };_0ce.prototype._m81=function(){return ['queries', 'reportDataStores', 'namedConditionalStyles', 'reportVariables', 'appVariables'];};_0ce.prototype._no=function(){return ['reportPages'];};_0ce.prototype._6k=function(_och,_wch,_rx7,_fsj,_2yl,_gd2){if(this._8o2(_och)){this._28(_och, _wch, _rx7);this._38(_och, _wch, _fsj, _2yl, _gd2);}else{this._a3(_och, _wch);}};_0ce.prototype._lk5=function(_0yd,_6zb,_xjh,_cr6,_fsj,_2yl){var _8sa=_erh._vtc();var _6ae=_r7g._j7b(_8sa.getAttribute("expressionLocale"));var _w9e=_r7g._j7b(_0yd.getAttribute("expressionLocale"));if(_w9e&&_6ae&&_w9e!=_6ae){Application._28j(_frh._c6j("IDS_MSG_COPY_PASTE_LOCALE_WARNING", _w9e, _6ae), {type:'info'});}if(!this._d01(_0yd, _6zb)){return;}var _fyd=_8sa.cloneNode(true);if(this._93i&&this._93i.nodeName=="pageBody"&&_6zb.length>1){_8fm._jgn("_255", this, _0yd, _fyd, _6zb, _xjh, _cr6, _fsj, _2yl);}else{this._zl3(_0yd, _fyd, _6zb, _xjh, _cr6, _fsj, _2yl);}};_0ce.prototype._4m4=function(_83m){var _o8i=_agm._an3(_83m);var _lnj=[];for(var i=0; i<_o8i.length;++i){_lnj.push(_1ke._avc(_o8i[i]));} return _lnj;};_0ce.prototype._zoe=function(_83m){var _o8i=[];var _bud=_7hn._ij8(_83m, "modelPath");if(_bud){_o8i.push(_bud);}var nl=_7hn._x5g(_83m, ".//query/source/metadataPath");for(var i=0; i<nl.length;++i){_o8i.push(nl.item(i));}return _o8i;};_0ce.prototype._go7=function(_o8i){var _y1l=0, _kvj=0;var _iqg=[];for(var i=0; i<_o8i.length;++i){var _30k=_o8i[i];var _lzi=_30k.getAttribute("type");if(_lzi=="module"){_y1l++;}else{_kvj++;}var _kzi=_7hn._fkl(_30k)||_30k.getAttribute("path");if(_iqg.indexOf(_kzi)===-1){_iqg.push(_kzi);}}if(_kvj>0&&_y1l>0){_2dm._jgn(null, _frh._c6j("IDS_MSG_UNSUPPORTED_MIX_DATASOURCE") + ":\n" + _iqg.join("\n"));return false; }return true;};_0ce.prototype._da2=function(_o8i){var _azg=0, _yyg=0;var _iqg=[];for(var i=0; i<_o8i.length;++i){var _30k=_o8i[i];var _kzi=_7hn._fkl(_30k)||_30k.getAttribute("path");if(_iqg.indexOf(_kzi)===-1){_iqg.push(_kzi);}var _4ui=_1ke._wfe(_kzi);if(!_4ui||_4ui.error||!_4ui.packageInfo){continue;}if(_4ui.packageInfo.isCQM){_yyg++;}else{_azg++;} }if(_yyg>0&&_azg>0||_yyg>1){_2dm._jgn(null, _frh._c6j("IDS_MSG_UNSUPPORTED_MIX_DATASOURCE") + ":\n" + _iqg.join("\n"));return false;}return true;};_0ce.prototype._zl3=function(_0yd, _fyd, _6zb, _xjh, _cr6, _fsj, _2yl, _gd2){var _rx7=this._m81();var _oyb=this._no();this._ja(_0yd, _fyd, _rx7, _oyb);var _1x7=['modelPath'].concat(_rx7);var _och=this._m4d(_0yd, _6zb, _1x7);var _wch=this._p4d(_fyd, _1x7);this._6k(_och, _wch, _rx7, _fsj, _2yl, _gd2);var _659=this._zoe(_fyd);if(!this._go7(_659)){return;}_5ml._jll(["_og4"],function(_og4){var _hia=_og4._ec4(_fyd);var _lr6=this._4m4(_fyd);_5ml._fll(Q.all([Q.all(_lr6), Q.all(_hia)])).done(function(){if(!this._da2(_659)){return;}if(_cr6&&_cr6.length>0){var _jxm=_frh._c6j("IDS_MSG_COPY_PASTE_WARNING", this._f01(_xjh));_8fm._jgn("_m57", null, _jxm, _cr6, null, _2dm._2qn);}_erh._sn9(_fyd, true);}.bind(this));}.bind(this));};_0ce.prototype._f01=function(_xjh){switch(_xjh){case "EXPLORE":return _frh._c6j("IDS_LBL_EXPLORATION");case "DASHBOARD":return _frh._c6j("IDS_LBL_DASHBOARD");case "STORY":return _frh._c6j("IDS_LBL_STORY");}};_0ce.prototype._d01=function(_0yd,_6zb){if(!_0yd||!_6zb){_67j("IDS_MSG_CLIPBOARD_EMPTY");return false; }if(_agm._vuc(_erh._vtc())!=_agm._vuc(_0yd)){Application._28j(_frh._c6j("IDS_MSG_UNSUPPORTED_PASTE_TO_REPORT"), {type: "warning"});return false; }for(var i=0; i<_6zb.length; i++){var _zpi=_7hn._ij8(_0yd, ".//*[@iid='" + _6zb[i] + "']");if(!this._en4(_zpi)){return false;}}return true;};_0ce.prototype._5j1=function(_vdn){switch(_vdn){case "list":case "crosstab":case "viz":case "vizControl":case "listControl":case "mapChart":case "singleton":case "repeater":case "repeaterTable":case "block":case "conditionalBlocks":case "layoutComponentRef":case "textItem":case "richTextItem":case "HTMLItem":case "textBox":case "tableCell":case "pageHeader":case "pageFooter":case "page":case "pageSet":case "bookletItem":case "vizDataSet":case "customControl":case "fieldSet":case "queryFilterBlock":case "selectValue":case "selectWithSearch":case "selectDateTime":case "selectDate":case "selectTime":case "selectInterval":case "selectWithTree":case "generatedPrompt":case "promptButton":case "hyperlink":case "TOCEntry":case "TOC":case "image":case "date":case "time":case "pageNumber":case "rowNumber":case "asOfTime":case "button":case "bookmark":case "CMMMap":case "appList":return true;}if(_geb._nml.indexOf(_vdn)!==-1){return true;}if(_j9g._89j.indexOf(_vdn)!==-1){return true;}return false;};_0ce.prototype._gv1=function(_vdn){switch(_vdn){case "query":case "dataItem":case "dataItemMember":case "dataItemMemberProperty":case "dataItemCalculatedMember":case "dataItemSet":case "dataItemChildrenSet":case "dataItemSetExpression":case "dataItemLevelSet":case "dataItemHierarchySet":case "dataItemNamedSet":case "dataItemTuple":case "dataItemMeasure":case "dataItemCalculatedMeasure":case "dataItemMeasurePercentage":case "dataItemMemberSet":case "dataItemListSummary":case "dataItemEdgeSummary":case "dataItemDimensionalEdgeSummary":case "dataItemCustomGroup":case "detailFilter":return true;}return false;};_0ce.prototype._zw3=function(_zpi){if(this._5j1(_zpi.nodeName)){return true;}switch(_zpi.nodeName){case "table":case "pageBody":return true;}return false;};_0ce.prototype._8o2=function(_och){for(var i=0; i<_och._3ob.length; i++){var _zpi=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");if(this._zw3(_zpi)){return true;}}return false;};_0ce.prototype._en4=function(_zpi){if(this._5j1(_zpi.nodeName)||this._gv1(_zpi.nodeName)){return true;}switch(_zpi.nodeName){case "table":case "pageBody":var _oz5=_8qn._x5g(_zpi, ".//", ["contents"], "/*");for(var i=0; i<_oz5.length; i++){if(!this._en4(_oz5.item(i))){return false;}}break;default:return false;}return true;};_0ce.prototype._ja=function(_0yd, _clf, _rx7, _oyb){for(var i=0; i<_rx7.length; i++){this._yu3(_0yd, _clf, _rx7[i], true);}for(var i=0; i<_oyb.length; i++){this._yu3(_0yd, _clf, _oyb[i]);}};_0ce.prototype._yu3=function(_0yd,_clf,_1f2,_9ci){var _z5f=_8qn._fde(null, _8qn._x5g(_0yd, ".//", [_1f2], "/*/@name"));var _36f=_8qn._fde(null, _8qn._x5g(_clf, ".//", [_1f2], "/*/@name"));var _lw4=_z5f.filter(function(x){ return _36f.indexOf(x)!==-1; });if(_lw4.length===0){return;}var _yfl=_9ci?this._bm4(_1f2):undefined;var _c44=_36f.concat(_z5f);this._1a1(_lw4, _c44, _0yd, _1f2, _yfl);};_0ce.prototype._bm4=function(_vdn){var _yfl;switch(_vdn){case "queries":_yfl="refQuery";break;case "reportDataStores":_yfl="refDataStore";break;case "namedConditionalStyles":_yfl="refConditionalStyle";break;case "reportVariables":_yfl="refVariable";break;case "appVariables":_yfl="refAppVariable";break;}return _yfl;};_0ce.prototype._1a1=function(_lw4,_c44,_0yd,_1f2,_vdn){for(var i=0; i<_lw4.length; i++){var _527=_lw4[i];var _jlc=_8qn._wh2(_c44, _527, true);_c44.push(_jlc);var _q4l=(_1f2!=="reportPages" ?_7hn._ij8(_0yd, _1f2+"/*[@name=" + _cgm._zxc(_527) + "]"):undefined);switch(_1f2){case "queries":_6aj._p5g(_q4l, _jlc);break;case "reportPages":_7hn._ij8(_0yd, ".//reportPages/*[@name=" + _cgm._zxc(_527) + "]").setAttribute("name", _jlc);break;case "appVariables":_7hn._ij8(_0yd, ".//appVariables/*[@name=" + _cgm._zxc(_527) + "]").setAttribute("name", _jlc);break;default:_q4l.setAttribute("name", _jlc);_8qn._433(_7hn._x5g(_0yd, ".//*[@" + _vdn + "=" + _cgm._zxc(_527) + "]"),_vdn, _jlc);}}};_0ce.prototype._m4d=function(_0yd,_6zb,_1x7){var _och={_irl: _0yd,_3ob: _6zb};for(var i=0; i<_1x7.length; i++){var _q4l=_7hn._ij8(_0yd, ".//"+_1x7[i]);if(_q4l){_och[_1x7[i]]=_erh._q77(_q4l);}}if(_6zb.length===1){var _u05=_7hn._ij8(_0yd, ".//*[@iid='" + _6zb[0] + "']");if(_u05.nodeName==="pageBody"){_och._3ob=[];var nlSourceContainers=_7hn._x5g(_u05, "./contents/*");for(var i=0; i<nlSourceContainers.length; i++){_och._3ob.push(nlSourceContainers.item(i).getAttribute("iid"));}}}return _och;};_0ce.prototype._p4d=function(_clf,_1x7){var _202=_dth._l7b(_clf, this._93i);var _wch={_irl: _clf,_93i: _202};for(var i=0; i<_1x7.length; i++){_wch[_1x7[i]]=_7hn._ij8(_clf, ".//"+_1x7[i]);}return _wch;};_0ce.prototype._28=function(_och,_wch,_rx7){for(var i=0; i<_rx7.length; i++){var _edk=_rx7[i]; if(_och[_edk]){switch(_edk){case 'queries':this._h71(_och, _wch);break;case 'reportDataStores':this._zn(_och, _wch);break;case 'namedConditionalStyles':this._93(_och, _wch);break;case 'reportVariables':this._ff(_och, _wch);break;case 'appVariables':this._1t(_och, _wch);break;} }}};_0ce.prototype._93=function(_och,_wch){var _km1=[];for(var i=0; i<_och._3ob.length; i++){var _zpi=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");var _p74=_7hn._x5g(_zpi, "descendant-or-self::*/@refConditionalStyle");for(var j=0; j<_p74.length; j++){var _q35=_7hn._fkl(_p74.item(j));if(_km1.indexOf(_q35)===-1){_km1.push(_q35);}}}if(_km1.length>0){if(!_wch.namedConditionalStyles){_wch.namedConditionalStyles=_erh._u0g(_wch._irl, "namedConditionalStyles");}for(var i=0; i<_km1.length; i++){var _d31=_7hn._ij8(_och.namedConditionalStyles, "*[@name=" + _cgm._zxc(_km1[i]) + "]");if(_d31){_wch.namedConditionalStyles.appendChild(_erh._woh(_d31, true));}}}};_0ce.prototype._ff=function(_och,_wch){var _0s6=[];for(var i=0; i<_och._3ob.length; i++){var _zpi=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");var _yzd=_7hn._x5g(_zpi, "descendant-or-self::*/@refVariable");for(var j=0; j<_yzd.length; j++){var _8wf=_7hn._fkl(_yzd.item(j));if(_0s6.indexOf(_8wf)===-1){_0s6.push(_8wf);}}}if(_0s6.length>0){if(!_wch.reportVariables){_wch.reportVariables=_erh._u0g(_wch._irl, "reportVariables");}for(var i=0; i<_0s6.length; i++){var _c74=_7hn._ij8(_och.reportVariables, "*[@name=" + _cgm._zxc(_0s6[i]) + "]");if(_c74){_wch.reportVariables.appendChild(_erh._woh(_c74, true));}}}};_0ce.prototype._1t=function(_och,_wch){var _0s6=[];for(var i=0; i<_och._3ob.length; i++){var _zpi=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");var _yzd=_7hn._x5g(_zpi, "descendant-or-self::*/@refAppVariable");for(var j=0; j<_yzd.length; j++){var _8wf=_7hn._fkl(_yzd.item(j));if(_0s6.indexOf(_8wf)===-1){_0s6.push(_8wf);}}}if(_0s6.length>0){if(!_wch.appVariables){_wch.appVariables=_erh._u0g(_erh._h56(_wch._irl, "appProperties"), "appVariables");}for(var i=0; i<_0s6.length; i++){var _3z6=_7hn._ij8(_och.appVariables, "*[@name=" + _cgm._zxc(_0s6[i]) + "]");if(_3z6){_wch.appVariables.appendChild(_erh._woh(_3z6, true));}}}};_0ce.prototype._ps3=function(_gdk, _w6l, _yx7, _3e, _77){if(_yx7.indexOf(_gdk)===-1){_yx7.push(_gdk);var _1lf=_7hn._ij8(_w6l, "query[@name='" + _gdk + "']");if(_7hn._ij8(_1lf, "source/metadataPath")){_3e.push(_1lf);}else{_77.push(_1lf);}var _7f9=_7hn._x5g(_1lf, "source//queryRef");for(var i=0; i<_7f9.length; i++){var _f26=_7f9.item(i).getAttribute("refQuery");this._ps3(_f26, _w6l, _yx7, _3e, _77);}}};_0ce.prototype._h71=function(_och,_wch){var _yx7=[];var _77=[];var _3e=[];for(var i=0; i<_och._3ob.length; i++){var _zpi=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");if(this._zw3(_zpi)){var _0si=_7hn._x5g(_zpi, "descendant-or-self::*/@refQuery");for(var j=0; j<_0si.length; j++){var _gdk=_7hn._fkl(_0si.item(j));this._ps3(_gdk, _och.queries, _yx7, _3e, _77);} }}this._q52(_och, _wch, _yx7, _3e, _77);};_0ce.prototype._zn=function(_och,_wch){var _mw4=[];for(var i=0; i<_och._3ob.length; i++){var _zpi=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");if(this._zw3(_zpi)){var _aec=_7hn._x5g(_zpi, "descendant-or-self::*/@refDataStore");for(var j=0; j<_aec.length; j++){var _y8e=_7hn._fkl(_aec.item(j));_mw4.push(_y8e);} }}if(_mw4.length>0){if(!_wch.reportDataStores){_wch.reportDataStores=_erh._u0g(_wch._irl, "reportDataStores");}var _yx7=[];var _77=[];var _3e=[];for(var i=0; i<_mw4.length; i++){var _zh3=_7hn._ij8(_och.reportDataStores, "*[@name=" + _cgm._zxc(_mw4[i]) + "]");if(_zh3){_wch.reportDataStores.appendChild(_erh._woh(_zh3, true));var _0si=_7hn._x5g(_zh3, "descendant-or-self::*/@refQuery");for(var j=0; j<_0si.length; j++){var _gdk=_7hn._fkl(_0si.item(j));this._ps3(_gdk, _och.queries, _yx7, _3e, _77);} }}this._q52(_och, _wch, _yx7, _3e, _77);}};_0ce.prototype._l2=function(_3e,_wch){for(var i=0; i<_3e.length; i++){_wch.queries.appendChild(_erh._woh(_3e[i], true)); } };_0ce.prototype._71=function(_77,_3e,_och,_wch){if(!_wch.modelPath&&_och.modelPath){var _wni=_erh._woh(_och.modelPath, true);if(_77.length>0){for(var i=0; i<_77.length; i++){_wch.queries.appendChild(_erh._woh(_77[i], true)); } }else{_7hn._qll(_wni, _7hn._ij8(_3e[0], "source/metadataPath").getAttribute("path"));}_wch.modelPath=_wni; _wch._irl.appendChild(_wni);}else if(_wch.modelPath&&_och.modelPath&&_7hn._fkl(_wch.modelPath)!==_7hn._fkl(_och.modelPath)){for(var i=0; i<_77.length; i++){var _4sa=_wch.queries.appendChild(_erh._woh(_77[i], true)); _8qn._cqh(_4sa, "source/model");var _rvd=_8qn._u0g(_7hn._ij8(_4sa, "source"), "metadataPath");_rvd.setAttribute("path", _7hn._fkl(_och.modelPath));var _rk9=_och.modelPath.getAttribute("type");if(_rk9){_rvd.setAttribute("type", _rk9);}} }else{for(var i=0; i<_77.length; i++){_wch.queries.appendChild(_erh._woh(_77[i], true));} }};_0ce.prototype._q52=function(_och, _wch, _yx7, _3e, _77){if(_yx7.length>0){if(!_wch.queries){_wch.queries=_erh._u0g(_wch._irl, "queries");}this._l2(_3e, _wch);this._71(_77, _3e, _och, _wch);}};_0ce.prototype._a3=function(_och,_wch){var _yx7=[];var _77=[];var _3e=[];for(var i=0; i<_och._3ob.length; i++){var _zpi=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");if(this._zw3(_zpi)){continue;}if(_zpi.nodeName==='query'){var _z0j=_zpi.getAttribute('name');this._ps3(_z0j, _och.queries, _yx7, _3e, _77); }else if(_r0d._5sh.indexOf(_zpi.nodeName)!==-1){var _elf=this._aw3(_wch);if(!_elf){continue;}var _g74=_7hn._ij8(_elf, "selection");_g74.appendChild(_erh._woh(_zpi, true));}else if(_zpi.nodeName==='detailFilter'){var _elf=this._aw3(_wch);if(!_elf){continue;}var _c9c=_erh._h56(_elf, "detailFilters");_c9c.appendChild(_erh._woh(_zpi, true));}else{continue;}}this._q52(_och, _wch, _yx7, _3e, _77);};_0ce.prototype._aw3=function(_wch){var _fsm;if(_wch._93i&&_wch._93i.nodeName==='query'){_fsm=_wch._93i;}else{var n=_k8j._p3g();if(n&&n.nodeName==='query'){_fsm=_7hn._ij8(_wch.queries, "./query[@name='" + n.getAttribute('name') + "']");}}return _fsm;};_0ce.prototype._f1=function(_yy5,_wch){if(_wch._93i.nodeName==='vizDataSet'||_wch._93i.nodeName==='viz'){var _hqi=_7hn._ij8(_wch._93i, "ancestor-or-self::viz[1]");if(_8qn._12g(_yy5, "viz").getAttribute("type")!==_hqi.getAttribute("type")){Application._28j(_frh._c6j("IDS_MSG_COPY_PASTE_BETWEEN_DIFF_VIZ_TYPE"), {type: "warning"});return;}var _o58;if(_wch._93i.nodeName==='vizDataSet'){_o58=_wch._93i;}else if(_wch._93i.nodeName==='viz'){_o58=_7hn._ij8(_wch._93i, ".//vizDataSet");}if(_o58){var _5z6=_o58.parentNode;_5z6.removeChild(_o58);_5z6.appendChild(_erh._woh(_yy5, true)); }}else{return; }};_0ce.prototype._s71=function(_yy5){var _5lh="";var _6z5=_7hn._x5g(_yy5, "ancestor::*[@refQuery]");for(var i=0; i<_6z5.length; i++){var _j28=_6z5.item(i);if(_j28.nodeName=="singleton"){continue;}var _gdk=_j28.getAttribute("refQuery");_5lh="\nObject '" + _j28.nodeName + "' references query '" + _gdk + "'";}if(_5lh){_vzm._ozm(_5lh);}};_0ce.prototype._38=function(_och,_wch,_fsj,_2yl,_gd2){var _dnf, _hsd;if(_wch._93i.nodeName=="table"){_dnf=_wch._93i.selectNodes("tableRows/tableRow/tableCells/tableCell");_hsd=_wch._93i.selectNodes("tableRows/tableRow[1]/tableCells/tableCell").length;}for(var i=0; i<_och._3ob.length; i++){var _yy5=_7hn._ij8(_och._irl, ".//*[@iid='" + _och._3ob[i] + "']");if(!_yy5){_67j("IDS_MSG_CLIPBOARD_EMPTY");return;}this._s71(_yy5);switch(_yy5.nodeName){case "vizDataSet":this._f1(_yy5, _wch);break;case "page":case "pageSet":case "bookletItem":var _kkf=_7hn._ij8(_wch._irl, "layouts/layout/reportPages");if(!_kkf){var _b2m=_7hn._ij8(_wch._irl, "layouts/layout");_kkf=_erh._u0g(_b2m, "reportPages");}_kkf.appendChild(_erh._woh(_yy5, true));break;default:if(_dnf){_wch._93i=_dnf.item(i);if(_gd2){if(_yy5.nodeName=="vizControl"){var _cz6=_erh._h56(_yy5, "vizPropertyValues");var _28l=_7hn._ij8(_cz6, "./vizPropertyLengthValue[@name='vcWidth']");if(!_28l){_28l=_erh._u0g(_cz6, "vizPropertyLengthValue");_28l.setAttribute("name", "vcWidth");}_7hn._qll(_28l, "100%"); }var _lsm=_erh._h56(_wch._93i, "style");var _tkn=_erh._h56(_lsm, "CSS");_tkn.setAttribute("value", _tkn.getAttribute("value") + ";width:" + Math.round(100/_hsd) + "%"); }}_ath._vge(new _4mh(_erh._q77(_yy5)), _wch._93i, _fsj);break;}}};function _8pc(){}_8pc.prototype._ujl=function(){this._nhj=_8qn._dhe('<listView view="nativeRadio">' +'<listItems>'+'<listItem value="before" idsLabel="IDS_LBL_INSERT_BEFORE"/>' +'<listItem value="after" idsLabel="IDS_LBL_INSERT_AFTER"/>' +'<listItem value="inside" idsLabel="IDS_LBL_INSERT_INSIDE"/>' +'</listItems>'+'</listView>').documentElement;_8fm._jgn( "_wcm", null, _frh._c6j( "IDS_TITLE_PASTE_TO" ), this._nhj, this );};_8pc.prototype._io9=function(_e5m){var _mzj=this._nhj.selectSingleNode("listItems/listItem[@selected='true']");var _1yl;switch(_mzj.getAttribute("value")){case "before":_1yl=_ath._5me;break;case "after":_1yl=_ath._r9g;break;default:_1yl=_ath._6me;}setTimeout(_ypn._p5j.bind(_ypn, _1yl), 0);};var _of7={};_of7._rpn=function(_arg){(new _1mh(_arg))._ujl();};_of7._vfn=function(_arg){(new _kzf(_arg))._ujl();};_of7._nzm=function(_zpi,_fsj,_2yl){(new _0ce(_zpi))._ujl(_fsj, _2yl);};_of7._dll=function(){(new _8pc())._ujl();};_of7._b9=function(_0yd,_fyd){var _v0e=new _0ce();var _rx7=_v0e._m81();var _oyb=_v0e._no();_v0e._ja(_0yd, _fyd, _rx7, _oyb);};return _of7;});