var frameLoaded=new Array();var xcookie;if(!window.Node){window.Node=new Object();Node.ELEMENT_NODE=1;Node.ATTRIBUTE_NODE=2;Node.TEXT_NODE=3;Node.CDATA_SECTION_NODE=4;Node.ENTITY_REFERENCE_NODE=5;Node.ENTITY_NODE=6;Node.PROCESSING_INSTRUCTION_NODE=7;Node.COMMENT_NODE=8;Node.DOCUMENT_NODE=9;Node.DOCUMENT_TYPE_NODE=10;Node.DOCUMENT_FRAGMENT_NODE=11;Node.NOTATION_NODE=12}if(window.Node&&Node.prototype&&!Node.prototype.contains){Node.prototype.contains=function(a){return !!(this.compareDocumentPosition(a)&16)}}function comparePosition(d,c){return d.compareDocumentPosition?d.compareDocumentPosition(c):d.contains?(d!=c&&d.contains(c)&&16)+(d!=c&&c.contains(d)&&8)+(d.sourceIndex>=0&&c.sourceIndex>=0?(d.sourceIndex<c.sourceIndex&&4)+(d.sourceIndex>c.sourceIndex&&2):1)+0:0}String.prototype.startsWith=function(a){return this.indexOf(a)==0};String.prototype.endsWith=function(b){var a=new RegExp(b+"$");return a.test(this)};function trim(a){while(a.substring(0,1)==" "){a=a.substring(1,a.length)}while(a.substring(a.length-1,a.length)==" "){a=a.substring(0,a.length-1)}return a}String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"")};String.prototype.ltrim=function(){return this.replace(/^\s+/,"")};String.prototype.rtrim=function(){return this.replace(/\s+$/,"")};String.prototype.plainText=function(){return this.replace(/<\/?[^>]+(>|$)/g," ")};Math.bezierPoint=function(e,d){var f=e.length;var c=[];for(var b=0;b<f;++b){c[b]=[e[b][0],e[b][1]]}for(var a=1;a<f;++a){for(b=0;b<f-a;++b){c[b][0]=(1-d)*c[b][0]+d*c[parseInt(b+1,10)][0];c[b][1]=(1-d)*c[b][1]+d*c[parseInt(b+1,10)][1]}}return[c[0][0],c[0][1]]};var Browser={};var agent=navigator.userAgent;Browser.w3c=(document.getElementById)?true:false;Browser.ns4=(document.layers)?true:false;Browser.ie=(typeof ActiveXObject!="undefined")?true:false;Browser.ie4=(Browser.ie&&!this.w3c)?true:false;Browser.ie5=(Browser.ie&&this.w3c)?true:false;Browser.ie7=(Browser.ie&&!window.opera&&window.XMLHttpRequest)?true:false;Browser.lt_ie7=Browser.ie&&!Browser.ie7;Browser.opera=typeof opera!="undefined"?true:false;Browser.opera8=false;Browser.opera9=false;if(Browser.opera){var versionindex=agent.indexOf("Opera")+6;var ver=agent.substring(versionindex);var v=parseFloat(ver);if(v>8&&v<8.5){Browser.opera8=true}if(v>=9){Browser.opera9=true}}Browser.android=agent.indexOf("Android")!=-1?true:false;if(document.attachEvent&&!Browser.opera){Browser.ie55=true}Browser.gecko=(agent.indexOf("Gecko")!=-1&&agent.indexOf("Safari")==-1&&agent.indexOf("Konqueror")==-1)?true:false;Browser.firefox3=(agent.indexOf("Firefox/3."))!=-1?true:false;Browser.firefox4=(agent.indexOf("Firefox/4."))!=-1?true:false;Browser.webkit=(agent.indexOf("WebKit")!=-1)?true:false;Browser.safari=(agent.indexOf("Safari")!=-1)?true:false;Browser.chrome=(agent.indexOf("Chrome"))!=-1?true:false;Browser.s60Browser=(Browser.webkit&&navigator.userAgent.indexOf("Series60/3.1")!=-1||navigator.userAgent.indexOf("Symbian")!=-1)?true:false;Browser.maemo=(Browser.w3c&&agent.indexOf("Maemo")>=0)?true:false;Browser.penBased=Browser.maemo||Browser.s60Browser?true:false;Browser.joystickBased=Browser.s60Browser?true:false;Browser.mobileSafari=agent.indexOf("Mobile")!=-1&&agent.indexOf("Safari")!=-1;Browser.iPhone=Browser.mobileSafari&&agent.indexOf("iPhone")!=-1;Browser.iPod=Browser.mobileSafari&&agent.indexOf("iPod")!=-1;Browser.iPad=Browser.mobileSafari&&agent.indexOf("iPad")!=-1;Browser.palm=agent.indexOf("webOS")!=-1;Browser.palmApp=Browser.palm&&(document.location.href.indexOf("file:")==0);Browser.touchDesktop=Browser.iPad;var mobileCookie=readCookie("mobile_mode");Browser.mobile=Browser.palm||Browser.android||(Browser.mobileSafari&&!Browser.iPad)||Browser.s60Browser||(mobileCookie!=null&&trim(mobileCookie)=="true")?true:false;var lastRequest;function postRequest(l,b,g,i,h,c,q,s){if(b==null){throw new Error("postRequest url parameter is null")}if(b=="about:blank"){throw new Error("postRequest url parameter is: "+b)}b=trim(b);if(b.length==0){throw new Error("postRequest url parameter is empty")}this.XMLHTTP=["Msxml2.XMLHTTP.6.0","Msxml2.XMLHTTP.5.0","Msxml2.XMLHTTP.4.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"];this.newActiveXObject=function(e){if(navigator.userAgent.indexOf("Mac")>=0&&navigator.userAgent.indexOf("MSIE")>=0){alert("we are sorry, you browser does not support AJAX, please upgrade or switch to another browser");return null}var w;for(var u=0;u<e.length;u++){try{w=new ActiveXObject(e[u]);break}catch(t){}}return w};function m(){if(!lastRequest){return false}switch(lastRequest.readyState){case 1:case 2:case 3:return true;break;default:return false;break}}var j;var o=document.location.href.indexOf("addLineItem.html?")!=-1;if(!s){LoadingIndicator.show(h)}if(typeof XMLHttpRequest!="undefined"&&window.XMLHttpRequest){try{j=new XMLHttpRequest();if(!Browser.opera8&&!Browser.s60Browser){if(typeof(j.overrideMimeType)!="undefined"&&j.overrideMimeType){j.overrideMimeType("text/xml")}}}catch(p){}}if(!j&&window.ActiveXObject){j=this.newActiveXObject(this.XMLHTTP)}if(!j&&window.createRequest){try{j=window.createRequest()}catch(p){}}if(!s&&m(lastRequest)){return}this.lastRequest=j;var n=cloneEvent(l);j.onreadystatechange=function(){var x;if(j.readyState!=4){return}if(!s){LoadingIndicator.hide()}var A;try{x=j.status;var B=j.responseXML;if(B&&B.baseURI){b=B.baseURI}}catch(y){alert("error occured when submitting request to the server: "+y);if(A){x=302}else{if(j.responseText.length>10){x=200}else{x=400}}}if(x==200&&b.indexOf("FormRedirect")!=-1){openAjaxStatistics(l,j);c(n,i,h,j.responseText,b,g,j)}else{if(x==200){openAjaxStatistics(l,j);if(c){c(n,i,h,j.responseText,b,g,j)}}else{if(x==302){try{A=j.getResponseHeader("Location")}catch(u){}if(!A){return}var z=A.indexOf("-inner=")!=-1;if(z){h=null;var t=A.split("?");postRequest(n,t[0],t[1],i,h,c)}else{document.location=A}}else{if(x==202){try{A=j.getResponseHeader("Location")}catch(u){}if(!A){var w=B.documentElement;A=w.getElementById("$redirect").getAttribute("href");if(!A){return}}if(A==b){return}if(A.indexOf("$createdForResource=1")!=-1){if(ListBoxesHandler.setNewOptionResource(A)==true){return}}var D;if(Browser.mobile){D=true}if(!D){try{D=j.getResponseHeader("X-Paint-In-Page")}catch(C){}}if(D&&D=="false"){document.location=A}else{var z=A.indexOf("-addItems=")!=1;if(z){h=null;var t=A.split("?");postRequest(n,t[0],t[1],i,h,c)}else{document.location=A}}}else{if(typeof openAjaxStatistics!="undefined"){openAjaxStatistics(l,j)}c(n,i,h,j.responseText,b,g,j)}}}}};if(!Browser.opera8&&!Browser.s60Browser){try{j.open("POST",b,true)}catch(d){c(n,i,h,"",b,g,j);return}try{j.setRequestHeader("X-Referer",document.location.href)}catch(r){}j.setRequestHeader("X-Ajax","y");if(Browser.android){j.setRequestHeader("X-Accept-Boost","menu-button")}j.setRequestHeader("Content-type","application/x-www-form-urlencoded; charset=UTF-8");if(xcookie){opera.postError("postRequest"+xcookie);j.setRequestHeader("X-Cookie",xcookie)}if(typeof q!="undefined"&&q==true){j.setRequestHeader("Cache-Control","no-cache")}if(g&&!Browser.webkit){j.setRequestHeader("Content-length",g.length)}if(i){if(g){g+="&X-Ajax=y"}else{g="X-Ajax=y"}}if(Browser.android){g+="&X-Accept-Boost=menu-button"}j.send(g)}else{var a;var f="X-Referer="+encodeURIComponent(document.location.href)+"&X-Ajax=y";var k=b.indexOf("?")!=-1;if(k){a=b+"&"}else{a=b+"?"}if(g&&g.length!=0){a+=g+"&"+f}else{a+=f}j.open("GET",a,true);if(i){Boost.view.setProgressIndeterminate(true)}j.send("")}}function openAjaxStatistics(d,c){if(!d){return}var k=d.target;try{if(!k||!k.tagName||k.tagName.toUpperCase()!="IMG"||k.id.indexOf("codeBehindThePage")==-1){return}}catch(l){return}var q=document.getElementById("ajax_sql");var f=c.getResponseHeader("X-Request-Tracker");var j=document.getElementById("ajax_cache");if(q&&f||j){var n=document.getElementById("ajax_title");n.style.visibility="visible";n.style.display="table-row"}else{return}var o;if(q&&f){var r=c.getResponseHeader("X-Sql-Statistics");o=q.childNodes[0];var m=o.href;var p=m.indexOf("?LOG_MARKER=");var i=m.indexOf("&",i);m=m.substring(0,p+12)+f+m.substring(i);o.href=m;var p=r.indexOf("=");var i=r.indexOf(";");var h=r.substring(p+1,i);p=r.indexOf("=",i);var g=parseInt(r.substring(p+1))/1000000;o.innerHTML=h+" SQLs/"+Math.round((g*100)/100)+"ms";var n=getTrNode(q);n.style.visibility="visible";n.style.display="table-row"}if(j){var b=c.getResponseHeader("X-Cache-Statistics");o=j.childNodes[0];var p=b.indexOf("=");var i=b.indexOf(";");var h=b.substring(p+1,i);p=b.indexOf("=",i);var g=parseInt(b.substring(p+1))/1000000;if(!g&&!h){return}o.innerHTML=h+" cache hits/"+Math.round((g*100)/100)+"ms speed-up";var n=getTrNode(j);n.style.visibility="visible";n.style.display="table-row"}}function getWindowSize1(){var b=0,a=0;a=(Browser.ie5||Browser.ie4)?document.body.clientHeight:window.innerHeight;b=(Browser.ie5||Browser.ie4)?document.body.clientWidth:window.innerWidth;return[b,a]}function getWindowSize_no_viewport(){var b=0,a=0;if(typeof(window.innerWidth)=="number"){b=window.innerWidth;a=window.innerHeight}else{if(document.documentElement&&(document.documentElement.clientWidth||document.documentElement.clientHeight)){b=document.documentElement.clientWidth;a=document.documentElement.clientHeight}else{if(document.body&&(document.body.clientWidth||document.body.clientHeight)){b=document.body.clientWidth;a=document.body.clientHeight}}}return[b,a]}function getWindowSize(){var a;var b;if(typeof window.innerWidth!="undefined"){a=window.innerWidth;b=window.innerHeight}else{if(document.documentElement&&typeof document.documentElement.offsetWidth!="undefined"&&document.documentElement.offsetWidth!=0){a=document.documentElement.offsetWidth;b=document.documentElement.offsetHeight}else{if(document.body&&typeof document.body.offsetWidth!="undefined"){a=document.body.offsetWidth;b=document.body.offsetHeight}}}return[a,b]}function getScrollXY(){var b=0,a=0;if(typeof(window.pageYOffset)=="number"){a=window.pageYOffset;b=window.pageXOffset}else{if(document.body&&(document.body.scrollLeft||document.body.scrollTop)){a=document.body.scrollTop;b=document.body.scrollLeft}else{if(document.documentElement&&(document.documentElement.scrollLeft||document.documentElement.scrollTop)){a=document.documentElement.scrollTop;b=document.documentElement.scrollLeft}}}return[b,a]}function getLeft(a){var c=a.offsetLeft;var b=a.offsetParent;while(b!=null){c=c+b.offsetLeft;b=b.offsetParent}return c}function getTop(a,d){var c=a.offsetTop;var b=a.offsetParent;while(b!=null){c=c+b.offsetTop;b=b.offsetParent}return c}function getElemInsideScreenPosition(a,g,e){var d=getScrollXY();var c=getWindowSize();var f=c[0]+d[0]-e.clientWidth-22;if(a>f-10){a=f-10}if(a<d[0]+10){a=d[0]+10}var b=c[1]+d[1]-e.clientHeight-22;if(g>b-10){g=b-10}if(g<d[1]+10){g=d[1]+10}return[a,g]}function getDocumentEvent(a){if(a){return a}if(!window){return null}if(window.event){return window.event}else{return null}}function getEventTarget(c,a){c=getDocumentEvent(c);if(!c){return null}var b=null;if(c.target){b=c.target}else{b=c.srcElement}if(b==null){return null}while(b.nodeType!=1){b=b.parentNode}if(typeof a=="undefined"){return b}if(!b.tagName||b.tagName.toLowerCase()!=a.toLowerCase()){return null}return b}function getTargetElement(c){c=getDocumentEvent(c);if(!c){return null}var b;var a=c.target;if(a){if(c.currentTarget&&(c.currentTarget!=a)){if(a.tagName&&a.tagName.toLowerCase()=="input"&&a.type.toLowerCase()=="checkbox"){b=a}else{b=c.currentTarget}}else{b=a}}else{b=c.srcElement;if(b&&b.parentNode&&b.parentNode.tagName&&b.parentNode.tagName.toLowerCase()=="a"){b=b.parentNode}}return b}function getMouseOutTarget(b){var a=getTargetElement(b);return a}function getMouseOverTarget(b){var a=getTargetElement(b);if(!a){return null}return a}function getTargetAnchor(b){var a=getEventTarget(b);return getAnchorForEventTarget(a)}function getAnchorForEventTarget(a){return getAncestorByTagName(a,"a")}function cloneEvent(b){if(!b){return}if(typeof b.cloned!="undefined"&&b.cloned==true){return b}var c=new Object();if(typeof b.latitude!="undefined"){c.latitude=b.latitude;c.longitude=b.longitude;c.cloned=true;return c}c.screenX=b.screenX;c.screenY=b.screenY;c.pageX=b.pageX;c.pageY=b.pageY;c.clientX=b.clientX;c.clientY=b.clientY;c.srcElement=getTargetElement(b);c.target=b.target;c.cloned=true;try{if(typeof b.type=="string"){c.type=b.type}else{c.type="click"}}catch(a){c.type="click"}return c}function stopEventPropagation(c,a){if(!c){return true}try{if(c.cloned){return false}c.cancelBubble=true;c.returnValue=false;if(c.preventDefault&&!a){c.preventDefault()}if(c.stopPropagation){c.stopPropagation()}if(c.setAttribute){c.setAttribute("eventProcessed","true")}c.eventProcessed=true;if(Browser.s60Browser){var b=getTargetAnchor(c);if(b&&b.href=="about:blank"){b.href="javascript: return false;"}}}catch(c){}return false}function swapNodes(d,a){if(d.swapNode){d.swapNode(a);return}var f=d.parentNode;var c=a.parentNode;var e=d.nextSibling;var b=a.nextSibling;if(f){if(e){f.insertBefore(a,e)}else{f.appendChild(a)}}else{c.removeChild(a)}if(c){if(b){c.insertBefore(d,b)}else{c.appendChild(d)}}else{f.removeChild(d)}}function getNextSibling(c,b){if(!c){return null}var a=c;do{a=a.nextSibling}while(a&&a.nodeType!=1);if(b&&a==null){return getFirstChild(c.parentNode)}return a}function getPreviousSibling(b,a){if(!b){return null}var c=b;do{c=c.previousSibling}while(c&&c.nodeType!=1);if(a&&c==null){return getLastChild(b.parentNode)}return c}function getSiblingIndex(b){if(!b){return null}var a=0;while((b=getPreviousSibling(b))!=null){a++}return a}function getFirstChild(a){if(!a){return null}var b=a.firstChild;if(!b){return null}return b.nodeType==1?b:getNextSibling(b)}function getLastChild(a){if(!a){return null}var b=a.lastChild;if(!b){return null}return b.nodeType==1?b:getPreviousSibling(b)}function insertAfter(a,c,b){a.insertBefore(c,getNextSibling(b))}function getChildById(a,b){return getChildByAttribute(a,"id",b)}function getChildByClassName(b,a){return this.getChildByAttribute(b,"className",a)}function getChildByAttribute(g,f,b){if(!g){return null}if(typeof b=="string"){b=[b]}for(var h=0;h<b.length;h++){if(g[f]==b[h]){return g}if(f=="className"&&g[f]&&g[f].indexOf(b[h]+" ")!=-1){return g}}var e=g.childNodes;var a=e.length;if(a==0){return null}for(var h=0;h<b.length;h++){for(var d=0;d<a;d++){if(e[d].childNodes.length!=0){var c=null;if((c=getChildByAttribute(e[d],f,b[h]))!=null){return c}}if(e[d].nodeType!=3&&e[d][f]==b[h]){return e[d]}if(e[d].nodeType!=3&&f=="className"&&e[d][f]&&e[d][f].indexOf(b[h]+" ")!=-1){return e[d]}}}return null}function getChildByTagName(f,e){if(!f){return null}e=e.toLowerCase();if(f.tagName.toLowerCase()==e){return f}var d=f.childNodes;var a=d.length;if(a==0){return null}for(var c=0;c<a;c++){if(d[c].childNodes.length!=0){var b=null;if((b=getChildByTagName(d[c],e))!=null){return b}}if(d[c].tagName&&d[c].tagName.toLowerCase()==e){return d[c]}}return null}function getAncestorById(b,a){return getAncestorByAttribute(b,"id",a)}function getAncestorByClassName(b,a){return getAncestorByAttribute(b,"className",a)}function getAncestorByAttribute(f,e,b){if(!f){return null}var a=(typeof b!="string");if(a){for(var c=0;c<b.length;c++){if(f[e]==b[c]){return f}if(e=="className"&&f[e]&&f[e].indexOf(b[c]+" ")!=-1){return f}}}else{if(f[e]==b){return f}if(e=="className"&&f[e]&&f[e].indexOf(b+" ")!=-1){return f}}var d;while((d=f.parentNode)!=null){if(a){for(var c=0;c<b.length;c++){if(d[e]==b[c]){return d}if(e=="className"&&d[e]&&d[e].indexOf(b[c]+" ")!=-1){return d}}}else{if(d[e]==b){return d}if(e=="className"&&d[e]&&d[e].indexOf(b+" ")!=-1){return d}}f=d}return null}function getAncestorByTagName(d,b,a){b=b.toLowerCase();if(d.tagName.toLowerCase()==b&&a!=true){return d}var c;while((c=d.parentNode)!=null){if(c.tagName&&c.tagName.toLowerCase()==b){return c}d=c}return null}function removeAllChildren(f,d){var c=f.childNodes;var a=0;var e=c.length;for(var b=0;b<e;b++){if(d&&comparePosition(c[a],d)==0){a++;continue}f.removeChild(c[a])}}var _hdnDivForDom=null;function getDomObjectFromHtml(b,c,a){if(b.indexOf(a)==-1){return null}if(_hdnDivForDom==null){_hdnDivForDom=document.createElement("div");_hdnDivForDom.style.display="none";document.body.appendChild(_hdnDivForDom)}_hdnDivForDom.innerHTML=b;var d=getChildByAttribute(_hdnDivForDom,c,a);if(!d){_hdnDivForDom.innerHTML="";return null}d=d.parentNode.removeChild(d);_hdnDivForDom.innerHTML="";return d}function arrangeTableCells(f,e){var c=new Array();for(var d=0;d<f.rows.length;d++){if(!isVisible(f.rows[d])){continue}f.rows[d].style.display="none";while(typeof f.rows[d].cells[0]!="undefined"){var b=f.rows[d].removeChild(f.rows[d].cells[0]);if(isVisible(b)){c.push(b)}}}if(typeof e=="undefined"){e=Math.floor(Math.sqrt(c.length))}if(Browser.mobile&&e>3){e=3}var a=0;for(var d=0;d<f.rows.length;d++){var g=f.rows[d];for(var h=0;h<e;h++){if(a<c.length){g.appendChild(c[a]);g.style.display="";a++}}}}function setInnerHtml(c,a){var b=getChildById(c,"content");if(b!=null){c=b}c.innerHTML="";if(typeof a=="string"){c.innerHTML=a}else{c.appendChild(a)}ExecJS.runDivCode(c)}function getTextContent(e){var d=null;if(!e){throw new Error("parameter is null")}if(typeof e.textContent!="undefined"){d=e.textContent}else{if(typeof e.innerText!="undefined"){d=e.innerText}else{if(e.childNodes&&e.childNodes.length){var b="";for(var a=e.childNodes.length;a--;){var c=e.childNodes[a];if(c.nodeType==1||c.nodeType==3){if(c.nodeValue){b=c.nodeValue+b}}else{b=getTextContent(c)+b}}d=b==""?null:b}}}return d}function getElementStyle(a){if(typeof a=="string"){a=document.getElementById(a)}if(a.nodeType==9){return null}if(a.currentStyle){return a.currentStyle}else{if(window.getComputedStyle){return document.defaultView.getComputedStyle(a,null)}}}var ExecJS={runCodeArr:new Array(),isWaitingOnReady:false,runCode:function(jsCode,refObjId,requiredJsFileName){$t=ExecJS;var toWait=false;if(requiredJsFileName&&typeof g_loadedJsFiles[requiredJsFileName]=="undefined"){toWait=true}if(toWait||typeof g_loadedJsFiles["common.js"]=="undefined"){setTimeout(function(){ExecJS.runCode(jsCode,refObjId,requiredJsFileName)},100);return}if(refObjId){$t._runRelativeCode(jsCode,refObjId)}else{$t.eval(jsCode)}},eval:function(jsCode){var pointIdx=jsCode.indexOf(".");if(pointIdx!=-1){className=jsCode.substring(0,pointIdx);if(typeof className=="undefined"){setTimeout(function(){ExecJS.eval(jsCode)},100);return}}try{window.eval(jsCode)}catch(e){setTimeout(function(){ExecJS.eval(jsCode)},100)}},_runRelativeCode:function(jsCode,refObjId,isSecondAttempt){if(document.all&&document.readyState!="complete"){if(this.isWaitingOnReady==false){addEvent(document,"readystatechange",this._runOnDocumentReady,false);this.isWaitingOnReady=true}this.runCodeArr.push({jsCode:jsCode,refObjId:refObjId})}else{if(this.isObjectTotallyVisible(refObjId)){this.eval(jsCode)}else{if(!isSecondAttempt){setTimeout(function(){ExecJS._runRelativeCode(jsCode,refObjId,true)},100)}}}},runDivCode:function(contDiv){if(!contDiv){return}var scripts=contDiv.getElementsByTagName("script");for(var i=0;i<scripts.length;i++){var src=scripts[i].src;if(src&&src.length!=0){var keyName=src.replace(/_[0-9]*\.js/,".js");if(typeof g_loadedJsFiles[keyName]){
/*this.isScriptFileLoaded(src)*/
var html_doc=document.getElementsByTagName("head")[0];var js=document.createElement("script");js.setAttribute("type","text/javascript");if(location.href.indexOf("-minify-js=n")!=-1){fileName=fileName.replace("m.js",".js")}js.setAttribute("src",src);html_doc.appendChild(js);g_loadedJsFiles[keyName]=true}}else{var parent=scripts[i].parentNode;var evalStr=scripts[i].text||scripts[i].innerHTML;var containsFocusCommand=(evalStr.indexOf("focus(")!=-1);if(containsFocusCommand==false||this.isObjectTotallyVisible(parent)){if(evalStr.indexOf("function runJSCode")!=-1){continue}window.eval(evalStr)}else{setTimeout(evalStr,1000)}}}},isObjectTotallyVisible:function(c){if(typeof c=="string"){c=document.getElementById(c)}if(c==null){return false}var b=c;while(b!=null){var a=getElementStyle(b);if(a!=null){if(a.visibility=="hidden"||a.display=="none"){return false}}b=c.parentNode;c=b}return true},_runOnDocumentReady:function(){for(var i=0;i<ExecJS.runCodeArr.length;i++){if(ExecJS.isObjectTotallyVisible(ExecJS.runCodeArr[i].refObjId)){window.eval(ExecJS.runCodeArr[i].jsCode)}}}};function createCookie(c,d,e){if(e){var b=new Date();b.setTime(b.getTime()+(e*24*60*60*1000));var a="; expires="+b.toGMTString()}else{var a=""}document.cookie=c+"="+d+a+"; path=/"}function readCookie(b){var e=b+"=";var a=document.cookie.split(";");for(var d=0;d<a.length;d++){var f=a[d];while(f.charAt(0)==" "){f=f.substring(1,f.length)}if(f.indexOf(e)==0){return f.substring(e.length,f.length)}}return null}function eraseCookie(a){createCookie(a,"",-1)}function findPosX(a){var b=0;if(a.offsetParent){while(a.offsetParent){b+=a.offsetLeft;a=a.offsetParent}}else{if(a.x){b+=a.x}}return b}function findPosY(b){var a=0;if(b.offsetParent){while(b.offsetParent){a+=b.offsetTop;b=b.offsetParent}}else{if(b.y){a+=b.y}}return a}function getCoordinates(c){var b=getObjectUpperLeft(c);var a=fitWindowWidth(b.x);var d=fitWindowHeight(b.y);return{Xoffset:a,Yoffset:d}}function getMouseEventCoordinates(c){var a=0;var f=0;var d=getScrollXY();if(c.pageX||c.pageY){a=c.pageX;f=c.pageY}else{if(c.clientX||c.clientY){a=c.clientX+d[0];f=c.clientY+d[1]}}if(c.screenX==0&&c.screenY==0){var b=getEventTarget(c);a=findPosX(b);f=findPosY(b)}return{x:a,y:f}}function fitWindowWidth(c){var b=getRightPagePos()-(box.offsetWidth+16);c=(b<c)?b:c;var a=getLeftPagePos();c=(c<a)?a:c;return c}function getRightPagePos(){var a;if(typeof window.srcollX!="undefined"){a=window.innerWidth+window.scrollX}else{if(typeof window.pageXOffset!="undefined"){a=window.innerWidth+window.pageXOffset}else{if(document.documentElement&&document.documentElement.clientWidth){a=document.documentElement.clientWidth+document.documentElement.scrollLeft}else{if(document.body&&document.body.clientWidth){a=document.body.clientWidth+document.body.scrollLeft}}}}return a}function getLeftPagePos(){var a;if(typeof window.srcollX!="undefined"){a=window.scrollX}else{if(typeof window.pageXOffset!="undefined"){a=window.pageXOffset}else{if(document.documentElement&&document.documentElement.scrolLeft){a=document.documentElement.scrollLeft}else{if(document.body&&document.body.scrollLeft){a=document.body.scrollLeft}}}}return a}function fitWindowHeight(b){var a=getBottomPagePos()-(box.offsetHeight);b=(a<b)?b-(Yoffset+box.offsetHeight):b;var c=getTopPagePos();b=(b<c)?c:b;return b}function getBottomPagePos(){var a;if(typeof window.scrollY!="undefined"){a=window.innerHeight+window.scrollY}else{if(typeof window.pageYOffset!="undefined"){a=window.innerHeight+window.pageYOffset}else{if(document.documentElement&&document.documentElement.clientHeight){a=document.documentElement.clientHeight+document.documentElement.scrollTop}else{if(document.body&&document.body.clientHeight){a=document.body.clientHeight+document.body.scrollTop}}}}return a}function getTopPagePos(){var a;if(typeof window.scrollY!="undefined"){a=window.scrollY}else{if(typeof window.pageYOffset!="undefined"){a=window.pageYOffset}else{if(document.documentElement&&document.documentElement.scrollTop){a=document.documentElement.scrollTop}else{if(document.body&&document.body.scrollTop){a=document.body.scrollTop}}}}return a}function getBaseUri(){var a=document.getElementsByTagName("base");var b="";if(a){b=a[0].href;if(b&&b.lastIndexOf("/")!=b.length-1){b+="/"}}return b}function changeOpacity(a,b){if(!a){return}if(typeof a.style.MozOpacity!="undefined"){a.style.MozOpacity=b}else{if(typeof a.style.opacity!="undefined"&&!Browser.ie){a.style.opacity=b}else{if(a.style.filter!="undefined"){if(b==1){a.style.filter=""}else{a.style.filter="progid:DXImageTransform.Microsoft.BasicImage(opacity="+b+")"}}}}}function copyAttributes(f,e){for(var c=0;c<f.attributes.length;c++){var b=f.attributes[c];if(b.value==null||b.value=="null"||b.value==""){continue}if(b.name=="style"){continue}var d;if(b.value=="false"){d=false}else{if(b.value=="true"){d=true}else{d=b.value}}if(b.name=="disabled"&&d==false){continue}e.setAttribute(b.name,b.value)}e.setAttribute("style",f.style.cssText)}function copyTableRow(c,g,e){var b=document.createElement("tr");var f=e.cells;for(var d=0;d<f.length;d++){var a=document.createElement("td");copyAttributes(f[d],a);b.appendChild(a)}if(g==c.rows.length){c.appendChild(b)}else{c.insertBefore(b,c.rows[g])}for(var d=0;d<f.length;d++){b.cells[d].innerHTML=f[d].innerHTML}copyAttributes(e,b);return b}function Dim(){this.left=0;this.top=0;this.width=0;this.height=0;var a=this;this.equals=function(b){if(a.top==b.top&&a.left==b.left&&a.width==b.width&&a.height==b.height){return true}else{return false}}}function getElementPosition(a,c){if(a&&typeof a.forcedPosition!="undefined"){var d=getScrollXY();if(a.forcedPosition==Popup.POS_LEFT_TOP){return{left:d[0]+10,top:d[1]}}}var b;if(c&&!c.type.startsWith("key")){b=getMouseEventCoordinates(c)}else{b=getObjectUpperLeft(a)}return{left:b.x,top:b.y}}function getElementCoords(b,f){var c=new Dim();var a=getElementPosition(b,f);c.left=a.left;c.top=a.top;var g=getElementDimensions(b);c.width=g.width;c.height=g.height;return c}function getElementDimensions(a){var b=new Dim();b.width=parseInt(a.offsetWidth);b.height=parseInt(a.offsetHeight);return b}function getObjectUpperLeft(b){var a=b.offsetLeft;var c=b.offsetTop;b=b.offsetParent;while(b){a+=b.offsetLeft;c+=b.offsetTop;if(typeof b.clientLeft!="undefined"&&b.tagName!="BODY"){a+=b.clientLeft;c+=b.clientTop}if(b.tagName=="HTML"){break}b=b.offsetParent}return{x:a,y:c}}function getUrlParam(b,e){e=e.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var a="[\\?&]"+e+"=([^&#]*)";var d=new RegExp(a);if(!b){b=window.location.href}var c=d.exec(b);if(c==null){if(!e.startsWith(".")){return getUrlParam(b,"."+e)}else{return null}}else{return c[1]}}function getFileName(a){return a.match(/[-_\w]+[.][\w]+$/i)[0]}function getParentDialog(a){return getAncestorByClassName(a,"panel_block")||getAncestorById(a,"pane2")}function isParentDialogOnPage(a){return a.parentNode.tagName.toLowerCase()!="body"}function isElemOfClass(c,b){if(typeof b=="string"){return c.className==b||c.className.indexOf(b+" ")==0}for(var a=0;a<b.length;a++){if(c.className==b[a]||c.className.indexOf(b[a]+" ")==0){return true}}return false}function isElemOfTag(c,b){if(!c.tagName){return false}var d=c.tagName.toLowerCase();if(typeof b=="string"){return(d==b)}for(var a=0;a<b.length;a++){if(d==b[a]){return true}}return false}function isElemInView(c){var b=getScrollXY()[1];var a=b+getWindowSize()[1];var d=findPosY(c);return(d>=b&&d<=a-c.offsetHeight)}function setCaretPosition(c,b){var c;if(c!=null){if(c.createTextRange){var a=c.createTextRange();a.move("character",b);a.select()}else{if(c.selectionStart){c.focus();c.setSelectionRange(b,b)}else{c.focus()}}}}function deselectField(b){var a=b.value;b.value="";b.value=a}function setShadow(b,a){b.style.boxShadow=a;b.style.MozBoxShadow=a;b.style.webkitBoxShadow=a}function appendClassName(b,a){if(b.className.indexOf(" "+a)!=-1){return}b.className+=(b.className.length==0)?a:(" "+a)}function removeClassName(b,a){var c=new RegExp(a,"g");b.className=b.className.replace(c,"").trim()}function isVisible(b){var a=getElementStyle(b);return a.display!="none"&&a.visibility!="hidden"}function hex2rgb(b){if(b.startsWith("#")){b=b.substring(1)}var d=parseInt(b.substring(0,2),16);var c=parseInt(b.substring(2,4),16);var a=parseInt(b.substring(4,6),16);return[d,c,a]}function setTransformProperty(c,d){var a=["transform","WebkitTransform","msTransform","MozTransform","OTransform"];for(var b=0;b<a.length;b++){if(typeof c.style[a[b]]!="undefined"){c.style[a[b]]=d;return true}}return false}g_loadedJsFiles["common.js"]=true;
