<%@ page contentType="text/html;charset=UTF-8" %>
<%@ page import="java.util.Iterator" %>
<%@ page import="java.util.Collection" %>
<%@ page import="net.sz600.basicdata.*" %>
<%@ page import="net.sz600.tool.SzConvert" %>
<%@ page import="net.sz600.tool.SzDateHelp" %>
<%@ page import="net.sz600.system.*" %>
<%@ page import="net.sz600.flow.*" %>
<%@ include file="/sessionInfo.jsp"%>
<%
  String strLevel = "../../";
%>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link href="<%=strSkin_SESSION%>/css2007.css" rel="stylesheet" type="text/css">
</head>
<%
    //获取提交的参数
    String sType = SzConvert.toZeroStr(request.getParameter("type"));
    String sPage = SzConvert.toZeroStr(request.getParameter("page"));
    String sSearch = SzConvert.strWriteData(request.getParameter("txtSearch"));
    String sPKEY = SzConvert.toZeroStr(request.getParameter("PKEY"));
    String sTable_type = "SZKC_CPFL";
%>
<%
    SzData szData = null;
    SzDataInfo szDataInfo = null;

    String sOPERATOR = request.getParameter("OPERATOR");
    String sKEY =  SzConvert.toZeroStr(request.getParameter("KEY"));
    String sReadonly = "";
    boolean bReadonly = false;
    if (sOPERATOR.equals("detail")) {
        sReadonly = "readonly";
        bReadonly = true;
    }
    //读取数据
    LcPersonInfo lcPersonInfo = null;
    LcPerson lcPerson = new LcPerson();
    if (!sKEY.equals("0")) {
        lcPersonInfo = (LcPersonInfo)lcPerson.getInfoByKey(Integer.parseInt(sKEY));
    }
    if (lcPersonInfo == null) {
        lcPersonInfo = new LcPersonInfo();
    } else {
    }

%>

<body>
<!-----上面的工具栏------>
<form name="formUpdate" method="post">
  <input type="hidden" name="PKEY" value="<%=sPKEY%>">
  <input type="hidden" name="page" value="<%=sPage%>">
  <input type="hidden" name="txtSearch" value="<%=sSearch%>">
  <input type="hidden" name="OPERATOR" value="<%=sOPERATOR%>">
  <input type="hidden" name="KEY" value="<%=sKEY%>">
  <input type="hidden" name="type" value="<%=sType%>">
  <input type="hidden" name="detailCount" value="0">
<%@ include file="title.jsp"%>
<table width="100%">
  <tr>
    <td>
    <% if (!bReadonly) { %>
      <%=SzPageHelp.saveButton()%>
    <% } %>
      <%=SzPageHelp.backButton()%>
    </td>
  </tr>
</table>

<!-----信息维护------>
<TABLE id=SZFORMtable1 style="CURSOR: hand" cellSpacing=0 borderColorDark=#ffffff cellPadding=3 width=650 borderColorLight=#c0c0c0 border=1>
<DIV id=divSZFORMtable1 style="BACKGROUND: #c0c0c0; CURSOR: hand; HEIGHT: 20px"><INPUT id=XX1 size=10 name=XX1><INPUT id=XX12 size=10 name=XX12></DIV>
<TBODY>
<TR id=SZFORMtr1>
<TD class=trMouseOut id=SZFORMtd1 style="CURSOR: hand">所属流程步骤</TD>
<TD class=trMouseOut id=SZFORMtd2 style="CURSOR: hand"><INPUT class=txtClass1 id=XX2 size=10 name=XX2></TD>
<TD class=trMouseOut id=SZFORMtd3 style="CURSOR: hand">&nbsp;</TD>
<TD class=trMouseOut id=SZFORMtd4 style="CURSOR: hand">&nbsp;</TD></TR>
<TR id=SZFORMtr2>
<TD class=trMouseOut id=SZFORMtd5 style="CURSOR: hand">人员ID</TD>
<TD class=trMouseOut id=SZFORMtd6 style="CURSOR: hand"><INPUT class=txtClass1 id=XX4 size=10 name=XX4></TD>
<TD class=trMouseOut id=SZFORMtd7 style="CURSOR: hand">人员姓名</TD>
<TD class=trMouseOut id=SZFORMtd8 style="CURSOR: hand"><INPUT class=txtClass1 id=XX5 size=10 name=XX5></TD></TR>
<TR id=SZFORMtr3>
<TD class=trMouseOut id=SZFORMtd9 style="CURSOR: hand">办理时间</TD>
<TD class=trMouseOut id=SZFORMtd10 style="CURSOR: hand"><INPUT class=txtClass1 id=XX6 size=10 name=XX6></TD>
<TD class=trMouseOut id=SZFORMtd11 style="CURSOR: hand">办理状态</TD>
<TD class=trMouseOut id=SZFORMtd12 style="CURSOR: hand"><INPUT class=txtClass1 id=XX7 size=10 name=XX7></TD></TR>
<TR id=SZFORMtr4>
<TD class=trMouseOut id=SZFORMtd13 style="CURSOR: hand">办理意见</TD>
<TD class=trMouseOut id=SZFORMtd14 style="CURSOR: hand" colSpan=3><TEXTAREA class=areaClass2 id=XX8 name=XX8></TEXTAREA></TD></TR>
<TR id=SZFORMtr8>
<TD id=SZFORMtd29 style="CURSOR: hand">人员类型</TD>
<TD class=trMouseOut id=SZFORMtd30 style="CURSOR: hand" colSpan=3><INPUT id=XX11 type=checkbox value=3 name=XX11>申请人<INPUT id=XX11 type=checkbox value=4 name=XX11>申请人直系上级<INPUT id=XX11 type=checkbox value=5 name=XX11>办理人直系上级<INPUT id=XX11 type=checkbox value=6 name=XX11>办理人直系下属</TD></TR>
<TR id=SZFORMtr7>
<TD class=trMouseOut id=SZFORMtd25 style="CURSOR: hand">约束条件</TD>
<TD class=trMouseOut id=SZFORMtd26 style="CURSOR: hand" colSpan=3><INPUT id=XX9 type=radio CHECKED value=0 name=XX9>无约束<INPUT id=XX9 type=radio value=1 name=XX9>同一部门<INPUT id=XX9 type=radio value=2 name=XX9>直系上级部门<INPUT id=XX9 type=radio value=3 name=XX9>直系下级部门</TD></TR>
</TBODY></TABLE>

</form>

<!-----这里包含要提交的内容--->
<form name="formHidden" method="post">
  <input type="hidden" name="page" value="<%=sPage%>">
  <input type="hidden" name="txtSearch" value="<%=sSearch%>">
  <input type="hidden" name="type" value="<%=sType%>">
</form>
<script language="javascript" src="../../share/js/commonTool.js"></script>
<script language="javascript">
  //动态的隐藏
  var oDivSZFORMtable1 = document.getElementById("divSZFORMtable1");
  if (oDivSZFORMtable1 != null) {
    oDivSZFORMtable1.style.display="none";
  }
  //动态的加入XX2的值
  var oXX1 = document.getElementById("XX1");
  if (oXX1 != null) {
    oXX1.value = "<%=lcPersonInfo.getRYID()%>";
  }
  var oXX2 = document.getElementById("XX2");
  if (oXX2 != null) {
    oXX2.value = "<%=lcPersonInfo.getRYBZID()%>";
  }
  var oXX4 = document.getElementById("XX4");
  if (oXX4 != null) {
    oXX4.value = "<%=lcPersonInfo.getRYDLID()%>";
  }
  var oXX5 = document.getElementById("XX5");
  if (oXX5 != null) {
    oXX5.value = "<%=lcPersonInfo.getRYDLXM()%>";
  }
  var oXX6 = document.getElementById("XX6");
  if (oXX6 != null) {
    oXX6.value = "<%=lcPersonInfo.getRYJSSJ()%>";
  }
  var oXX7 = document.getElementById("XX7");
  if (oXX7 != null) {
    oXX7.value = "<%=lcPersonInfo.getRYZT()%>";
  }
  var oXX8 = document.getElementById("XX8");
  if (oXX8 != null) {
    oXX8.value = "<%=lcPersonInfo.getRYBLYJ()%>";
  }
  var oXX9 = document.getElementById("XX9");
  if (oXX9 != null) {
    CheckRadio(formUpdate.XX9, "<%=lcPersonInfo.getRYYSTJ()%>");  }
  var oXX11 = document.getElementById("XX11");
  if (oXX11 != null) {
    CheckCheckBox(formUpdate.XX11, "<%=lcPersonInfo.getRYLX()%>");  }
  var oXX12 = document.getElementById("XX12");
  if (oXX12 != null) {
    oXX12.value = "<%=lcPersonInfo.getRYLCID()%>";
  }
  //判断是否有明细，如果有就动态增加
</script>
<script language="javascript">

  function FormSave(formName, url) {
    //检查是否可以保存
    if (!notNum(formName.XX2, "所属流程步骤")) {
      return false;
    }
    if (!notNum(formName.XX4, "人员ID")) {
      return false;
    }
    if (!notNum(formName.XX7, "办理状态")) {
      return false;
    }
    if (!notNum(formName.XX12, "所属流程ID")) {
      return false;
    }

    formName.action = url;
    formName.submit();
  }
</script>
</body>
