function aegismenusubmit(formname){ var fn = formname; var doc = document ; if(document.all[formname] == null ) { doc = window.parent.topFrame.document ; } var noLinkRegExp = new RegExp("athena.pegasus.location=$"); if( noLinkRegExp.test(url) ) { return true; } var url = eval("doc." + formname + ".url.value"); var target2 = eval("doc." + formname + ".targetvalue.value"); var position = eval("doc." + formname + ".AgsSelPos.value"); var contentRoot = eval("doc." + formname + ".AgsSelCont.value"); var selectedDepth = eval("doc." + formname + ".AgsSelDepth.value"); var selectedPositionRoot = eval("doc." + formname + ".AgsSelPosRoot.value"); var dynamic = eval("doc." + formname + ".dynamic.value"); var status = eval("doc." + formname + ".status.value"); var menuname = eval("doc." + formname + ".menutitle.value"); var statusTrust = eval("doc." + formname + ".PaneUrl.value"); //alert('statusTrust'+statusTrust); //alert('statusTrust length'+statusTrust.length); var trustCode = statusTrust.split('.'); //alert('trustCode.length'+trustCode.length); if ( statusTrust.length > 0 ){ var trustCode = statusTrust.split('.'); // trustCode[1] 검증로직 필요 : trustCode[1] 없으면 if(trustCode[1] == "xrw" ) { setRoot(contentRoot); setFlag("/TrustF"); //alert('33'); var _tmp = trustCode[0]+"."+trustCode[1]; submit('TrustForm', _tmp, 'M', fn, target2, menuname); //alert('33-11'); return; } }else { resizeContent(); } //alert('status : '+status); //cookie를 지운다. if(status != null && status == "N"){ //alert('delete cookie : status : '+status); //alert("before"); //alert(getCookie("menusToExpand")); //alert(getCookie("itemToHighlight")); //alert(getCookie("tabbedMenuSelected")); deleteCookie("menusToExpand"); deleteCookie("itemToHighlight"); deleteCookie("tabbedMenuSelected"); //alert("after"); //alert(getCookie("menusToExpand")); //alert(getCookie("itemToHighlight")); //alert(getCookie("tabbedMenuSelected")); } if(target2 =="_parent"){ parent.init(posValue,contValue,false,url,status); } else if(target2=="_self"){ //alert('position : '+position); if ( position == "left" ) { window.parent.document.all("body").src= url+"&AgsSelPos=" + position + "&AgsSelCont=" + contentRoot + "&AgsSelDepth=" + selectedDepth + "&AgsSelPosRoot=" + selectedPositionRoot + "&dynamic=" + dynamic + "&menutitle=" + menuname + "&userid=" + document.all["titleMenuName"].userid.value; } else { //alert('else!'); // if ( document.all["titleMenuName"].menuName == null ) if ( document.all["titleMenuName"] == undefined ) { // ******************* 1220 added by hykim if(document.all["titleManuID"] == undefined){ //alert('document.all[titleManuID] is undefind'); window.parent.document.all("body").src= url+"&AgsSelPos=" + position + "&AgsSelCont=" + contentRoot + "&AgsSelDepth=" + selectedDepth + "&AgsSelPosRoot=" + selectedPositionRoot + "&dynamic=" + dynamic; }else{ //alert('document.all[titleManuID].value : '+document.all["titleManuID"].value); var titleMenuID = document.all["titleManuID"].value; var titleMenuName = document.all["titleManuName"].value; //alert('titleMenuID : '+titleMenuID); //alert('titleMenuName : '+titleMenuName); window.parent.document.all("body").src= url+"&AgsSelPos=" + position + "&AgsSelCont=" + titleMenuID + "&AgsSelDepth=" + selectedDepth + "&AgsSelPosRoot=" + selectedPositionRoot + "&dynamic=" + dynamic; } // ******************* 1220 added by hykim } else { var mn = ""; var ui = ""; // ... if ( document.all["titleMenuName"].menuName != null ) { mn = document.all["titleMenuName"].menuName.value; } if ( document.all["titleMenuName"].userid != null ) { ui = document.all["titleMenuName"].userid.value; } window.parent.document.all("body").src= url+"&AgsSelPos=" + position + "&AgsSelCont=" + contentRoot + "&AgsSelDepth=" + selectedDepth + "&AgsSelPosRoot=" + selectedPositionRoot + "&dynamic=" + dynamic + "&menutitle=" + mn + "&userid=" + ui; } } } else if(target2=="top"){ //target이 top일때 // ******************* 1231 added by ykkang top.location.reload(); } //target이 parent도 아니고 self, top 도 아닐때 else { //alert('000-111'); eval("doc."+formname+".submit()"); top.body.location.reload(); } } /* This function is used to set framesize */ function resizeContent() { parent.document.all( "master" ).rows = "90,*,0%" } function resizeHidden() { parent.document.all( "master" ).rows = "90,0%,*" } function submit(param, url, menu, fn, target2, menuname){ var mdiId = "mdi"; var title = ""; var formname = fn; var target = target2.split(','); var code = url; if (param == "TrustForm"){ mdiId = menuname + "0"; resizeHidden(); //Frame reSize parent.biz.RWViewer.window.javascript.callSubmission(menu, "submission1",formname); parent.biz.RWViewer.window.javascript.changeNodeColor(); //parent.biz.RWViewer.window.javascript.setMenuName(code, menuname); } } // ========================================================================= // Cookie functions // ========================================================================= /* This function is used to set cookies */ function setCookie(name,value,expires,path,domain,secure) { document.cookie = name + "=" + escape (value) + ((expires) ? "; expires=" + expires.toGMTString() : "") + ((path) ? "; path=" + path : "") + ((domain) ? "; domain=" + domain : "") + ((secure) ? "; secure" : ""); } /* This function is used to get cookies */ function getCookie(name) { var prefix = name + "=" var start = document.cookie.indexOf(prefix) if (start==-1) { return null; } var end = document.cookie.indexOf(";", start+prefix.length) if (end==-1) { end=document.cookie.length; } var value=document.cookie.substring(start+prefix.length, end) return unescape(value); } /* This function is used to delete cookies */ function deleteCookie(name,path,domain) { if (getCookie(name)) { document.cookie = name + "=" + ((path) ? "; path=" + path : "") + ((domain) ? "; domain=" + domain : "") + "; expires=Thu, 01-Jan-70 00:00:01 GMT"; } } var root = ""; var flag = ""; // 메뉴 리스트를 보여주기 위한 root id. function setRoot(name){ root = name; //parent.biz.RWViewer.window.javascript.setFavoritesRoot(root); } // trustform과 systemier메뉴와의 구분. function setFlag(name) { flag = name; }