EditDocTempletFields.jsp
上传用户:mingda
上传日期:2017-06-20
资源大小:27691k
文件大小:11k
源码类别:

OA系统

开发平台:

Java

  1. <%@ page contentType="text/html; charset=gb2312"%>
  2. <%@ page import="com.gforce.gfoa.*,com.gforce.currency.*,java.util.*" %>
  3. <jsp:include page="/CheckLogin.jsp" flush="true"/> <% Session m_session = new Session(session); %>
  4. <html>
  5. <head>
  6. <meta http-equiv="Content-Type" content="text/html; charset=gb2312"><meta http-equiv="pragma" content="no-cache">
  7. <title>文档模板字段管理-- GForce OA 2.0</title>
  8. <link href="../css/txt.jsp" rel="stylesheet" type="text/css">
  9. <script language="JavaScript" src="/js/changestyle.js"></script>
  10. <script language="JavaScript" type="text/javascript">
  11. function checkEditFields()
  12. {
  13.   if(document.EditDocTempletFields.FieldName.value=="")
  14.   {
  15.     alert("请输入字段名称!");
  16.     document.EditDocTempletFields.FieldName.focus();
  17.     return false;
  18.   }
  19.   if(document.EditDocTempletFields.EnglishAb.value=="")
  20.   {
  21.     alert("请输入字段的英文缩写!");
  22.     document.EditDocTempletFields.EnglishAb.focus();
  23.     return false;
  24.   }
  25. }
  26. </script>
  27. <%
  28. Request m_request = new Request(request);
  29. int intDocTempletFieldsID = m_request.GetInt("ID");
  30. String strTFID;
  31. int intDocTempletID = m_request.GetInt("TempletID");
  32. int iSysDirID = m_request.GetInt("SysDirID");
  33. if(intDocTempletFieldsID <1)
  34. {
  35. %>
  36. <script language="JavaScript" type="text/JavaScript">
  37. alert("请选择正确的字段,修改失败!");
  38. history.back();
  39. </script>
  40. <%
  41. }
  42. else
  43. {
  44. strTFID = intDocTempletFieldsID+"";
  45. Vector vt = DocTempletFieldsManager.getRecordBySearch(strTFID);
  46. if(vt.size()==1)
  47. {
  48. %>
  49. </head>
  50. <body bgcolor="<%=m_session.GetString("BackColor")%>" leftmargin="0" topmargin="0">
  51. <table width="100%" height="100%" border="0" align="center" cellspacing="0">
  52. <tr>
  53.   <td  align="center" valign="top"><p>&nbsp;</p>
  54.           <table width="90%" border="0" align="center" cellspacing="0">
  55.             <tr>
  56.               <td align="center">
  57.                 <font color="#000000"><strong>公文模版管理--字段信息修改</strong></font>
  58.               </td>
  59.             </tr>
  60.             <tr>
  61.               <td>
  62.                 &nbsp;
  63.               </td>
  64.             </tr>
  65.           </table>
  66.   <form name="EditDocTempletFields" action="EditDocTempletFieldsAction.jsp?SysDirID=<%=iSysDirID%>&TempletID=<%=intDocTempletID%>" method="post" onSubmit="javascript:return checkEditFields();">
  67.       <table  border="1" cellpadding="0" cellspacing="1" width="90%">
  68.       <tr>
  69.         <td width="14%" align="center" valign="middle"><font color="#0A0A0A">字段名称:</font></td>
  70.         <td width="35%" align="left" valign="middle" nowrap>&nbsp;<input name="FieldName" type="text" maxlength="300" size="35" Value="<%=((Vector)vt.get(0)).get(1).toString()%>"></td>
  71.         <td width="14%" align="center" valign="middle"><font color="#0A0A0A">英文缩写:</font></td>
  72.         <td width="35%" align="left" valign="middle" nowrap>&nbsp;<input name="EnglishAb" type="text" maxlength="300" size="35" value="<%=((Vector)vt.get(0)).get(3).toString()%>"></td>
  73.       </tr>
  74.       <tr>
  75.        <td width="14%" align="center" valign="middle"><font color="#0A0A0A">字段类型:</font></td>
  76.        <td colspan="3" align="left" valign="middle" nowrap>
  77.            <p>
  78.           &nbsp;<input name="FieldType" type="radio" value="String" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("String"))?" checked":""%>>文本类型
  79.           <input type="radio" name="FieldType" value="Date" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Date"))?" checked":""%>>日期类型
  80.           <input type="radio" name="FieldType" value="Numeric" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Numeric"))?" checked":""%>>数值类型
  81.           <input type="radio" name="FieldType" value="Text" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Text"))?" checked":""%>>大文本类型
  82.           <input type="radio" name="FieldType" value="Radio"<%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Radio"))?" checked":""%>>单选类型
  83.           <input type="radio" name="FieldType" value="Checkbox" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Checkbox"))?" checked":""%>>多选类型
  84.           <br>
  85.           &nbsp;<input type="radio" name="FieldType" value="Select" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Select"))?" checked":""%>>下拉单选型
  86.           <input type="radio" name="FieldType" value="List" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("List"))?" checked":""%>>下拉多选型
  87.           <input type="radio" name="FieldType" value="Read" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Read"))?" checked":""%>>只读文本型
  88.           <input type="radio" name="FieldType" value="ACC" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("ACC"))?" checked":""%>>附件类型
  89.           <input type="radio" name="FieldType" value="Name" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Name"))?" checked":""%>>操作用户姓名
  90.           <input type="radio" name="FieldType" value="Optime" <%=(((Vector)vt.get(0)).get(2).toString().equalsIgnoreCase("Optime"))?" checked":""%>>用户操作时间
  91.         </p>
  92.       </td>
  93.   </tr>
  94. <tr>
  95.   <td width="14%" align="center" valign="middle"><font color="#0A0A0A">选项内容:</font></td>
  96.   <td align="left" valign="middle" nowrap colspan="2">&nbsp;<textarea name="Options" cols="40" rows="4"><%=((Vector)vt.get(0)).get(6).toString()%></textarea> </td>
  97.   <td>
  98.   <font color="#0A0A0A">&nbsp;&nbsp;&nbsp;选项表述与选项值之间使用<a href="" onclick="document.EditDocTempletFields.Options.insertAdjacentText('beforeEnd','《¥》');return false;"><font color="#FF0000">《¥》</font></a>间隔<br>
  99.   &nbsp;不同选项之间使用<a href="" onclick="document.EditDocTempletFields.Options.insertAdjacentText('beforeEnd','《,》');return false;"><font color="#FF0000">《,》</font></a>间隔<br>&nbsp;例如:<br><font color="red">&nbsp;&nbsp;&nbsp;优秀
  100.   《¥》90《,》良好《¥》80《,》<br>&nbsp;差《¥》40</font></font></td>
  101.   </tr>
  102.   <tr>
  103.   <td width="14%" align="center" valign="middle"><font color="#0A0A0A">默认值:</font></td>
  104.   <td colspan="1" align="left" valign="middle" nowrap>
  105.   &nbsp;<textarea cols="30" rows="4" name="DefaultValue"><%=((Vector)vt.get(0)).get(16).toString()%></textarea>
  106.   <input name="TempletID" type="hidden" Value="<%=intDocTempletID%>">
  107.   <input name="ID" type="hidden" Value="<%=intDocTempletFieldsID%>">
  108.   </td>
  109.   <td width="14%" align="center" valign="middle"><font color="#0A0A0A">填写说明:</font></td>
  110.   <td align="left" valign="middle" nowrap width="35%" colspan="1">
  111.   &nbsp;<textarea name="FieldContent" cols="30" rows="4"><%=((Vector)vt.get(0)).get(7).toString()%></textarea></td>
  112.   </tr>
  113.   <tr>
  114.  <td width="14%" align="center" valign="middle"><font color="#0A0A0A">排序编号:</font></td>
  115.  <td width="35%" colspan="1" align="left" valign="middle" nowrap>&nbsp;<input name="OrderNumber" type="text" maxlength="10" size="7" Value="<%=((Vector)vt.get(0)).get(4)%>">
  116.  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0A0A0A">字段长度:</font><input name="MaxLength" type="text" maxlength="10" size="7" Value="<%=((Vector)vt.get(0)).get(15)%>"></td>
  117.  <td width="14%" align="center" valign="middle"><font color="#0A0A0A">填写要求:</font></td>
  118.  <td colspan="1" align="left" valign="middle" nowrap>
  119.  &nbsp;<input name="IsMustFill" type="radio" value=1 <%=((Vector)vt.get(0)).get(8).toString().equalsIgnoreCase("true")?"checked":""%>>必须填写
  120.  &nbsp;&nbsp;<input type="radio" name="IsMustFill" value=0 <%=((Vector)vt.get(0)).get(8).toString().equalsIgnoreCase("false")?"checked":""%>>由用户选择是否填写
  121.  </td>
  122.  </tr>
  123.  <tr>
  124.   <td width="14%" align="center" valign="middle"><font color="#0A0A0A">只读用户<br>姓名:</font></td>
  125.   <td colspan="1" align="left" valign="middle" nowrap>
  126.   &nbsp;<textarea name="ReadableUserNames" cols="30" rows="3" readonly="true" onDblClick="GetUserIDAndNames(document.EditDocTempletFields.ReadableUserIDs,this);"><%=UserManager.getPersonnelNamesByUserIDs(((Vector)vt.get(0)).get(10).toString())%></textarea>
  127.   <input name="ReadableUserIDs" type="hidden" Value="<%=((Vector)vt.get(0)).get(10).toString()%>"><a href="" onclick="GetUserIDAndNames(document.EditDocTempletFields.ReadableUserIDs, document.EditDocTempletFields.ReadableUserNames);return false;" title="选择员工名称"><img src="/images/couple.gif" border="0"></a>
  128.   </td>
  129.   <td width="14%" align="center" valign="middle"><font color="#0A0A0A">可写用户<br>姓名:</font></td>
  130.   <td colspan="1" align="left" valign="middle" nowrap>
  131.   &nbsp;<textarea name="WritableUserNames" cols="30" rows="3" readonly="true" onDblClick="GetUserIDAndNames(document.EditDocTempletFields.WritableUserIDs,this);"><%=UserManager.getPersonnelNamesByUserIDs(((Vector)vt.get(0)).get(9).toString())%></textarea>
  132.   <input name="WritableUserIDs" type="hidden" Value="<%=((Vector)vt.get(0)).get(9).toString()%>"><a href="" onclick="GetUserIDAndNames(document.EditDocTempletFields.WritableUserIDs, document.EditDocTempletFields.WritableUserNames);return false;" title="选择员工名称"><img src="/images/couple.gif" border="0"></a>
  133.   </td>
  134.  </tr>
  135. <tr>
  136.   <td width="14%" align="center" valign="middle"><font color="#0A0A0A">激活事件:</font></td>
  137.   <td colspan="4" align="left" valign="middle" nowrap>&nbsp;<textarea name="Event" cols="80" rows="4"><%=((Vector)vt.get(0)).get(5).toString()%></textarea></td>
  138. </tr>
  139. <tr>
  140.  <td width="14%" align="center" valign="middle"><font color="#0A0A0A">字段状态:</font></td>
  141.  <td colspan="3" align="left" valign="middle" nowrap>
  142.  &nbsp;<input name="IsUseful" type="radio" value="1" <%=((Vector)vt.get(0)).get(11).toString().equalsIgnoreCase("true")?"checked":""%>>可用
  143.  &nbsp;&nbsp;&nbsp;&nbsp;<input type="radio" name="IsUseful" value="0" <%=((Vector)vt.get(0)).get(11).toString().equalsIgnoreCase("false")?"checked":""%>>不可用
  144.  </td>
  145. </tr>
  146.   <tr>
  147.  <td width="14%" align="center" valign="middle"><font color="#0A0A0A"> 搜索条件<br>类型:</font></td>
  148.  <td colspan="4" align="left" valign="middle" nowrap>
  149.  &nbsp;<select name="SearchType">
  150.     <option value=">" <%=((Vector)vt.get(0)).get(12).toString().equalsIgnoreCase(">")?"selected":""%>>></option>
  151.     <option value="<" <%=((Vector)vt.get(0)).get(12).toString().equalsIgnoreCase("<")?"selected":""%>><</option>
  152.     <option value="包含" <%=((Vector)vt.get(0)).get(12).toString().equalsIgnoreCase("包含")?"selected":""%>>包含</option>
  153.   </select>
  154.   </td>
  155.   </tr>
  156.   <tr>
  157.   <td width="14%" align="center" valign="middle">搜索字段:</td>
  158.   <td colspan="4" align="left" valign="middle" nowrap>&nbsp;<input name="SearchFieldsInForm" type="text" maxlength="10" size="37" Value="<%=((Vector)vt.get(0)).get(13).toString()%>"></td>
  159.   </tr>
  160.              <table width="90%" border="0">
  161.                 <tr>
  162.                  <td width="40%">&nbsp;</td><td width="60%">&nbsp;</td>
  163.                </tr>
  164.                <tr>
  165.                  <td width="40%">&nbsp;</td>
  166.                  <td align="left" valign="middle" nowrap>
  167.   <input type="submit" value="确定">
  168.   &nbsp;&nbsp;&nbsp; <input type="reset" value="重填"> &nbsp;&nbsp;&nbsp;
  169.   <input type="button" value="返回" onclick="window.location='DocTempletFieldsManage.jsp?SysDirID=<%=iSysDirID%>&ID=<%=intDocTempletID%>';">
  170.   </td>
  171.         </tr>
  172.         </table>
  173.         </table>
  174.   </form>
  175.   </td>
  176. </tr>
  177. </table>
  178. </body>
  179. </html>
  180. <%
  181. }
  182. else
  183. {
  184. %>
  185. <script language="JavaScript" type="text/JavaScript">
  186. alert("该记录已经被删除,修改失败!");
  187. history.back();
  188. </script>
  189. <%
  190. }
  191. }
  192. %>