2018-06-03 22:26:41 +08:00

62 lines
2.0 KiB
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<%@ page contentType="text/html; charset=GBK"%><%@
include file="/IncludeBegin.jsp"%><%
/*
页面说明:代码生成树图
*/
String PG_TITLE = "代码生成树图"; // 浏览器窗口标题 <title> PG_TITLE </title>
String PG_CONTENT_TITLE = "&nbsp;&nbsp;代码生成树图&nbsp;&nbsp;"; //默认的内容区标题
String PG_CONTNET_TEXT = "请点击左侧列表";//默认的内容区文字
String PG_LEFT_WIDTH = "200";//默认的treeview宽度
//获得页面参数
String sExampleId = CurPage.getParameter("ObjectNo");
String sViewId = CurPage.getParameter("ViewId");
//定义Treeview
OHTMLTreeView tviTemp = new OHTMLTreeView(CurPage, "代码生成树图","right");
//代码生成树图
//参数为:代码编号
tviTemp.init("ExampleTree");
%><%@include file="/Resources/CodeParts/View04.jsp"%>
<script type="text/javascript">
function openChildComp(sURL,sParameterString){
sParaStringTmp = "";
sLastChar=sParameterString.substring(sParameterString.length-1);
if(sLastChar=="&") sParaStringTmp=sParameterString;
else sParaStringTmp=sParameterString+"&";
/*
* 附加两个参数
* ToInheritObj:是否将对象的权限状态相关变量复制至子组件
* OpenerFunctionName:用于自动注册组件关联REG_FUNCTION_DEF.TargetComp
*/
sParaStringTmp += "ToInheritObj=y&OpenerFunctionName="+getCurTVItem().name;
AsControl.OpenView(sURL,sParaStringTmp,"right");
}
<%/*treeview单击选中事件*/%>
function TreeViewOnClick(){
var sCurItemID = getCurTVItem().id;
if(sCurItemID=="010"){
openChildComp("/FrameCase/widget/dw/ExampleList.jsp","");
}else if(sCurItemID=="020"){
return false;//openChildComp("/FrameCase/widget/dw/ExampleList.jsp","");
}else if(sCurItemID=="020010"){
openChildComp("/FrameCase/widget/dw/ExampleList.jsp","");
}else if(sCurItemID=="020020"){
openChildComp("/FrameCase/widget/dw/ExampleList.jsp","");
}else if(sCurItemID=="030"){
openChildComp("/FrameCase/widget/dw/ExampleList.jsp","");
}
setTitle(getCurTVItem().name);
}
function initTreeView(){
<%=tviTemp.generateHTMLTreeView()%>
expandNode('root');
selectItem("010");
}
initTreeView();
</script>
<%@ include file="/IncludeEnd.jsp"%>