﻿
/*combine position*/
/*  
 * (c) 2007-2008 UssCorp  
 * compressed version
 */function yF(){};yF.IG="template1";yF.BasePath="/dat/";function by(prefix){if(window["alldlg"]==null)window["alldlg"]=[];var dm=null;var lJ=null;var rW=null;var jg=null;var nt=null;var jf=null;var lu=null;var Prefix=prefix;var qd=window["alldlg"];var nC="";var V=this;var rR=0;var xp=function(){return navigator.userAgent.toLowerCase().indexOf("firefox")!= -1;};var FX=function(){this.className="close close_img close_over";};var Gn=function(){this.className="close close_img";};var bh=function(dg){var cy=dg.attributes,i,l,n;if(cy){l=cy.length;for(i=0;i<l;i+=1){n=cy[i].name;if(typeof dg[n]==='function'){dg[n]=null;}}}cy=dg.childNodes;if(cy){l=cy.length;for(i=0;i<l;i+=1){bh(dg.childNodes[i]);}}};var cD=function(dh){var cy,i,l,n;if(dh!=null&&dh.hasChildNodes()){while(dh.childNodes.length>=1){dh.removeChild(dh.firstChild);}}};this.Hide=function(){try{xDisplay(jf,"none");if(xp())dm.style.overflow="hidden";dm.style.display="none";vP(jg);Eq();}catch(e){alert(e);}};var pj=function(eJ,ig,w,h,jl){xWidth(dm,w);rW.innerHTML=ig;nt.onclick=(typeof jl=="function")?jl:V.Hide;var lM=(typeof eJ=='object'?eJ.id:eJ);var zN=xGetElementById(lM+"_close");if(zN!=null)zN.onclick=(typeof jl=="function")?jl:V.Hide;var AH=xGetElementById(lM+"_ok");if(AH!=null&&typeof V.rp=='function')AH.onclick=function(){V.Hide();V.rp.apply(null);V.rp=window.undefined};EC(eJ);};var EH=function(aw){var el=null;if(document.all)el=window.event.srcElement;else el=aw.target;if(el==lu)CK(aw,dm.id);};var EC=function(eJ){var iO=null;var lM=(typeof eJ=='object'?eJ.id:eJ);if(nC==lM&&typeof eJ!='object')return;if(typeof eJ=='undefined')return;if(typeof eJ=='object'){if(eJ.tagName==undefined||(eJ.tagName!=null&&eJ.tagName.toLowerCase()!="div")){var oDiv=document.createElement("div");oDiv.appendChild(eJ);oDiv.id=eJ.id;eJ=oDiv;}iO=eJ;}else{iO=qd[lM];if(iO==null)iO=document.getElementById(lM);}if(iO.getAttribute){var bX=iO.getAttribute("style");if(bX!=null&&bX!=""){if(typeof bX=='object')bX=bX.cssText.toLowerCase();bX=bX.replace(/display:[ ]*?none[;]?/,"");if(document.all)iO.style.cssText=bX;else iO.setAttribute("style",bX);}}if(nC!="")qd[nC]=lJ.firstChild;cD(lJ);lJ.appendChild(iO);nC=lM;jg=iO;};var yS=function(){if(xp())dm.style.overflow="auto";vW(dm);xDisplay(dm,"");lb(jg);xDisplay(jg,"");var w=cJ(dm,"width",1)-2*cJ(jg,"margin-left",1)-2*cJ(jg,"padding-left",1);if(w>0)xWidth(jg,w);};var yT=function(){if(xp())dm.style.overflow="auto";var df=qM();xMoveTo(jf,0,0);kc(jf,df.w,df.h);xDisplay(dm,"");lb(jg);xDisplay(jg,"");var w=cJ(dm,"width",1)-2*cJ(jg,"margin-left",1)-2*cJ(jg,"padding-left",1);if(w>0)jg.style.width=w+"px";var lH=aT("uss_scrollable","div");if(lH!=null){lH=lH[0];if(lH!=null){var Ax=parseInt(lH.getAttribute("max_height"),10);if(xHeight(lH)>Ax)xHeight(lH,Ax);}}vW(dm);};this.Gz=function(jt,ig,w,h,jl){pj(jt,ig,w,h,jl);yS();};this.Show=function(jt,ig,w,h){if(arguments.length>0)pj(jt,ig,w,0,window.undefined);yS();};this.rr=function(jt,ig,w,h,jl){if(arguments.length>0)pj(jt,ig,w,h,jl);yT();};this.bf=function(jt,ig,w,h){if(arguments.length>0)pj(jt,ig,w,h,window.undefined);yT();};this.SetHtml=function(html){var AC=qd[nC];if(AC!=null)xInnerHtml(AC,html);};this.Iy=function(id){if(qd[id]!=null){cD(lJ);lJ.appendChild(qd[id]);nC=id;}};this.xJ=function(jt,ig,w,h,jl){pj(jt,ig,w,h);};this.Ht=function(Ay){if(!dm)return;var ve=cJ(dm,"z-index",1);xB(dm,ve+Ay);rR=Ay;};var Eq=function(){if(rR!=0){var ve=cJ(dm,"z-index",1);xB(dm,ve-rR);rR=0;}};this.IZ=function(ax,bv){var aG=qd[ax];if(aG!=null){cD(aG);aG.innerHTML=bv;}else{aG=document.createElement("div");aG.id=ax;aG.innerHTML=bv;qd[ax]=aG;}};dm=document.getElementById(Prefix+"dlg_frame");if(dm==null){dm=document.createElement("div");dm.className="dialog";dm.id=Prefix+"dlg_frame";dm.style.display="none";lJ=document.createElement("div");document.body.appendChild(dm);lu=document.createElement("div");lu.className="header";lu.onmousedown=EH;dm.appendChild(lu);dm.appendChild(lJ);nt=document.createElement("div");nt.className="close close_img";nt.onmouseover=FX;nt.onmouseout=Gn;lu.appendChild(nt);rW=document.createElement("span");rW.className="header_text";lu.appendChild(rW);}jf=document.getElementById(Prefix+"dlg_cover");if(jf==null){jf=document.createElement("div");jf.className="dlg_cover";jf.id=Prefix+"dlg_cover";jf.style.display="none";document.body.appendChild(jf);}}
/*combine position*/
/*  
 * (c) 2007-2008 UssCorp  
 * compressed version
 */;function aK(){var T=new Object();T.eK=null;T.ci=null;var xg="/dat/dialog/images/";T.EG=function(w,h){T.eK=document.createElement("div");T.eK.id="status_dlg";T.eK.className="status_dlg";xWidth(T.eK,w);document.body.appendChild(T.eK);T.ci=document.createElement("div");T.ci.id="status_dlg_cover";T.ci.className="status_dlg_cover";document.body.appendChild(T.ci);var sa=document.createElement("div");if(typeof h!='undefined')xHeight(sa,h);sa.className="top";T.eK.appendChild(sa);sa.innerHTML="<table cellpadding='0' cellspacing='0' border='0'><tbody> <tr><td valign='middle' ><img vspace=4px hspace=4px /></td><td valign='middle' align='left' class='msg'><span></span></td></tr></tbody></table>";var up=document.createElement("div");up.className="bottom";T.eK.appendChild(up);var a=document.createElement("a");a.innerHTML="Đóng cửa sổ";a.href="javascript:void(0)";a.onclick=T.xV;up.appendChild(a);};T.FC=function(status,message,tX,w,h){message="<p>"+message+"</p>";T.eK=xGetElementById("status_dlg");T.ci=xGetElementById("status_dlg_cover");if(T.eK==null)T.EG(w,h);else{xWidth(T.eK,w);if(typeof h!='undefined'){var zD=T.eK.firstChild;if(zD!=null)xHeight(zD,h);}}var Cells=T.eK.firstChild.firstChild.getElementsByTagName("tbody")[0].getElementsByTagName("tr")[0].getElementsByTagName("td");var oImg=Cells[0].childNodes[0];var uv=Cells[1].childNodes[0];;if(status=="ok"){oImg.src=xg+"success.gif";uv.innerHTML=message;}else if(status=="error"){oImg.src=xg+"error.gif";uv.innerHTML=message;}else if(status=="loading"){oImg.src=xg+"loading.gif";uv.innerHTML=message;}if(tX==true)xDisplay(T.eK.lastChild,"");else xDisplay(T.eK.lastChild,"none");xDisplay(T.ci,"");Gi(T.ci);xDisplay(T.eK,"");vW(T.eK);};T.xV=function(){T.eK=xGetElementById("status_dlg");T.ci=xGetElementById("status_dlg_cover");xDisplay(T.eK,"none");xDisplay(T.ci,"none");};return T;};aK.Show=function(status,message,tX,w,h){var iQ=new aK();iQ.FC(status,message,tX,w,h);iQ=null;};aK.Hide=function(){var iQ=new aK();iQ.xV();iQ=null;};function IY(){this.oDiv=null;var JK=0;var xg="/dat/dialog/images/";var V=this;var Init=function(){if(JK==1)return;V.oDiv=document.createElement("div");V.oDiv.className="uss_status";document.body.appendChild(V.oDiv);var html="<table cellpadding='0' cellspacing='0'><tr><td id='tl'></td><td id='tc' colspan='2'></td><td id='tr'></td></tr>";html+="<tr><td id='cl'></td><td id='cc1'><img id='status_div_icon' /></td><td id='cc'><div id='status_div_content'></td><td id='cr'></td></tr>";html+="<tr><td id='bl'></td><td id='bc' colspan='2'></td><td id='br'></td></tr></table><div>";V.oDiv.innerHTML=html;JK=1;};var IP=function(status){var src=xg+"blank.gif";if(status=="ok")src=xg+"success.gif";else if(status=="error")src=xg+"error.gif";else if(status=="loading")src=xg+"loading_s.gif";return src;};var ov=function(status,message){Init();xGetElementById("status_div_icon").src=IP(status);xGetElementById("status_div_content").innerHTML=message;};var jZ=function(status,message,top,left,bw){ov(status,message);xDisplay(V.oDiv,"");if(typeof top=='undefined')top=0;if(typeof left=='undefined')left=0;xMoveTo(V.oDiv,left,top);if(typeof bw!='undefined')setTimeout(V.Hide,bw);};var mG=function(status,message,top,bw){ov(status,message);xDisplay(V.oDiv,"");if(typeof top=='undefined')top=0;var left=(xClientWidth()-xWidth(V.oDiv))/2;xMoveTo(V.oDiv,left,top);if(typeof bw!='undefined')setTimeout(V.Hide,bw);};var mK=function(status,message,top,right,bw){ov(status,message);xDisplay(V.oDiv,"block");if(typeof top=='undefined')top=0;if(typeof right=='undefined')right=0;var left=xClientWidth()-xWidth(V.oDiv)-right;xMoveTo(V.oDiv,left,top);if(typeof bw!='undefined'){setTimeout(V.Hide,bw);}};this.Hide=function(){xDisplay(V.oDiv,'none');};this.Jf=function(top,left){jZ("loading","loading ...",top,left);};this.Je=function(top){mG("loading","loading ...",top);};this.Jc=function(top,right){mK("loading","loading ...",top,right);};this.IX=function(msg,top,left,bw){if(msg=='')msg="execution not success";jZ("error",msg,top,left,bw);};this.IW=function(msg,top,bw){if(msg=='')msg="execution not success";mG("error",msg,top,bw);};this.Jb=function(msg,top,right,bw){if(msg=='')msg="execution not success";mK("error",msg,top,right,bw);};this.IV=function(msg,top,left,bw){if(msg=='')msg="execution success";jZ("ok",msg,top,left,bw);};this.IS=function(msg,top,bw){if(msg=='')msg="execution success";mG("ok",msg,top,bw);};this.IU=function(msg,top,right,bw){if(msg=='')msg="execution success";mK("ok",msg,top,right,bw);};this.IR=function(msg,top,left,bw){jZ("none",msg,top,left,bw);};this.Jd=function(top,bw){mG("none",msg,top,bw);};this.IQ=function(top,right,bw){mK("none",msg,top,right,bw);}};var JL=new IY();
/*combine position*/

/*
 * drag 1.0 
 * (c) 2007-2008 UssGroup  
 * compressed version
  */
var cN=new Object();cN.zIndex=0;function AY(){var ny,s,i;this.isIE=false;this.lp=false;this.version=null;ny=navigator.userAgent;s="MSIE";if((i=ny.indexOf(s))>=0){this.isIE=true;this.version=parseFloat(ny.substr(i+s.length));return;}s="Netscape6/";if((i=ny.indexOf(s))>=0){this.lp=true;this.version=parseFloat(ny.substr(i+s.length));return;}s="Gecko";if((i=ny.indexOf(s))>=0){this.lp=true;this.version=6.1;return;}};var gH=new AY();var cN=new Object();cN.zIndex=0;function CK(event,rN){var el;var x,y;if(typeof rN!='undefined'){if(typeof rN=='string')cN.hm=document.getElementById(rN);else cN.hm=rN;}else{if(gH.isIE)cN.hm=window.event.srcElement;if(gH.lp)cN.hm=event.target;if(cN.hm.nodeType==3)cN.hm=cN.hm.parentNode;}if(cN.hm==null)return;if(gH.isIE){x=window.event.clientX+document.documentElement.scrollLeft+document.body.scrollLeft;y=window.event.clientY+document.documentElement.scrollTop+document.body.scrollTop;}if(gH.lp){x=event.clientX+window.scrollX;y=event.clientY+window.scrollY;}cN.DW=x;cN.DU=y;cN.vX=parseInt(cN.hm.style.left,10);cN.vZ=parseInt(cN.hm.style.top,10);if(isNaN(cN.vX))cN.vX=0;if(isNaN(cN.vZ))cN.vZ=0;if(gH.isIE){document.attachEvent("onmousemove",rH);document.attachEvent("onmouseup",rm);window.event.cancelBubble=true;window.event.returnValue=false;}if(gH.lp){document.addEventListener("mousemove",rH,false);document.addEventListener("mouseup",rm,false);event.preventDefault();}};function rH(event){var x,y,left,top;if(gH.isIE){x=window.event.clientX+document.documentElement.scrollLeft+document.body.scrollLeft;y=window.event.clientY+document.documentElement.scrollTop+document.body.scrollTop;}if(gH.lp){x=event.clientX+window.scrollX;y=event.clientY+window.scrollY;}left=(cN.vX+x-cN.DW);top=(cN.vZ+y-cN.DU);cN.hm.style.left=left+"px";cN.hm.style.top=top+"px";if(gH.isIE){window.event.cancelBubble=true;window.event.returnValue=false;}if(gH.lp)event.preventDefault();};function rm(event){cN.hm=null;if(gH.isIE){document.detachEvent("onmousemove",rH);document.detachEvent("onmouseup",rm);}if(gH.lp){document.removeEventListener("mousemove",rH,false);document.removeEventListener("mouseup",rm,false);}}