<%@ page contentType="text/html; charset=GBK" %>
<%@ page import = "zr.zrpower.common.util.SysPreperty" %>
<%@ page import = "zr.zrpower.entity.sys.SessionUser" %>
<%@ page import = "zr.zrpower.ejb.sys.UIService" %>

<%@ page import = "java.lang.Object"%>
<HTML>
<%
SessionUser user = (SessionUser)session.getAttribute("userinfo");
UIService userUI =new UIService();

String strPARENTNO = request.getParameter("Menu_No");
if (strPARENTNO==null)
{strPARENTNO = "";}
%>
<HTML>
<HEAD>
<TITLE></TITLE>
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META http-equiv="Content-Type" content="text/html; charset=GBK">
<link REL="stylesheet" type="text/css" href="../../zrsysmanage/css/<%=user.getUserCSS()%>">
<SCRIPT LANGUAGE="JavaScript" src="../../zrsysmanage/script/Public.js"></SCRIPT>
<%if("6".equals(user.getUserWINDOWTYPE())){ %>
<LINK type="text/css" rel="stylesheet" href="../../zrsysmanage/html5/css/style_tables.css">
<SCRIPT LANGUAGE="JavaScript" src="../../zrsysmanage/html5/script/jquery-2.0.3.min.js"></SCRIPT>
<SCRIPT LANGUAGE="JavaScript" src="../../zrsysmanage/html5/layer/layer.js"></SCRIPT>
<%}%>
<SCRIPT LANGUAGE="javascript">
function Check(theForm)
{
  if ((trim(theForm.MENUNAME.value)=="")){

    <%if("6".equals(user.getUserWINDOWTYPE())){ %>
       layer.alert('菜单名称不能为空！', {icon: 7});
      <%}else{%>
       alert("菜单名称不能为空！");
       <%}%>
    theForm.MENUNAME.focus();
    return false;
  }
  var strMenuNo=theForm.PARENTNO.value;
  if (strMenuNo.length==9)
  {

    <%if("6".equals(user.getUserWINDOWTYPE())){ %>
       layer.alert('只能设置三级菜单！', {icon: 7});
      <%}else{%>
       alert("只能设置三级菜单！");
       <%}%>
    return false;
  }
  return true;
}
</SCRIPT>
</HEAD>
<BODY class="BodyMain">
<FORM name="RegForm" method="post" action="../../actionmenu.do">
<input type="hidden" name="PARENTNO" value="<%=strPARENTNO%>">
<input type="hidden" name="ISPOWER" value="0">
<input type="hidden" name="FLAG" value="1">
<input type="hidden" name="ISOPEN" value="0">
<input type="hidden" name="SUBCOUNT" value="0">
<input type="hidden" name="Act" value="add">



           <DIV id="divMessage" style='padding-left:0;padding-top:0;width:100%;height:100%;overflow:auto'>
           <br>&nbsp;
           <fieldset style="width: 98%">
           <legend>增加菜单信息</legend>
           <table border="0" class="inputTable" cellspacing="0" cellpadding="0" align="center">
             <tr>
               <td class="inputTdtitle">菜单名称：</td>
               <td class="inputTd"><input class="text" type="text" name="MENUNAME" size="60" maxlength="25"><Font class="WriteSign">*</Font></td>
             </tr>
             <tr>
                 <td class="inputTdtitle">菜单类别：</td>
                 <td class="inputTd">
                 <input type="radio" name="ISPOWERx" value=0 onclick="document.RegForm.ISPOWER.value='0'" checked>类别　　
		 <input type="radio" name="ISPOWERx" value=1 onclick="document.RegForm.ISPOWER.value='1'">任务
               </td>
             </tr>
             <tr>
               <td class="inputTdtitle">链接路径：</td>
               <td class="inputTd" ><input class="text" type="text" name="URL" size="60" maxlength="300"></td>
            </tr>


             <tr>
               <td class="inputTdtitle">新窗口打开：</td>
               <td class="inputTd" >
                 <input type="radio" name="ISOPENx" value=0 onclick="document.RegForm.ISOPEN.value='0'" checked> 否&nbsp;&nbsp;&nbsp;　
		 <input type="radio" name="ISOPENx" value=1 onclick="document.RegForm.ISOPEN.value='1'"> 是
               </td>
            </tr>

             <tr>
               <td class="inputTdtitle">菜单属性：</td>
               <td class="inputTd" >
                  <input type="radio" name="Flagx" value=1 onclick="document.RegForm.FLAG.value='1'" checked>启用　　
		  <input type="radio" name="Flagx" value=0 onclick="document.RegForm.FLAG.value='0'">禁止
               </td>

             </tr>
             <tr>
               <td class="inputTdtitle">排序号：</td>
               <td class="inputTd" ><input class="text" type="text" name="MNCODE" size="60" maxlength="9">
               <br>说明：请按菜单编号的规范编排序号，如：系统管理001 字典管理001001 数据字典管理 001001001。
               </td>
            </tr>

          </table>
          <br>
          </fieldset>
                 <center><br>
                 <table cellspacing="0" cellpadding="0" border='0'><tr>
                 <%=userUI.ClickButton("保存","JavaScript:if(Check(document.RegForm)){document.RegForm.submit();}","buttonSave.gif",user.getUserImage())%>
                 <%=userUI.ClickButton("返回","JavaScript:history.back();","buttonReturn.gif",user.getUserImage())%>
                 </tr></table>
                 </center>
          </DIV>


</FORM>
</BODY>
</HTML>
<%
//清空相关对象
user = null;
userUI = null;
%>
