add_peccancy.jsp
资源名称:NetOffice.rar [点击查看]
上传用户:guhaomin
上传日期:2007-06-10
资源大小:23203k
文件大小:9k
源码类别:
电子政务应用
开发平台:
Java
- <%@ taglib uri="/vnex.tld" prefix="vnex" %>
- <%@ taglib uri="/vnex_vehicle_automobile.tld" prefix="vnex_auto" %>
- <%@ page errorPage="/vnex/ErrorPage.jsp" %>
- <%@ page import="com.vnex.intranet.util.*" %>
- <%@ page import="java.sql.Timestamp" %>
- <%
- // get the currentTime
- Timestamp tCurrent = new Timestamp(System.currentTimeMillis());
- Calendar calCurrent = TimeStamp.convertTimestampToCalendar(tCurrent);
- String currentDate = "" + TimeStamp.formatCalendar( TimeStamp.YMD, calCurrent );
- %>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
- <HTML>
- <jsp:include page="/vnex/page/FORM_HEAD.jsp" />
- <BODY text=#000000 vLink=#000000 aLink=#000000 link=#000000 bgColor=#ffffff topMargin=20 leftmargin="0" marginwidth="0" marginheight="0">
- <script language="JavaScript1.2" src="/vnex/menu/dockmenu_office.js"></script>
- <script language="JavaScript1.2" src="/vnex/menu/dockmenu.js"></script>
- <script Language="JavaScript" src="/vnex/intranet/calendar/Popup.js"></script>
- <script language="JavaScript" src="/vnex/util/strUtil.js"></script>
- <script language="JavaScript" src="/vnex/util/validate.js"></script>
- <script language="JavaScript">
- var currentDate ="<%=currentDate%>";
- function addPeccancySuccess(form)
- {
- if(checkIt(form))
- {
- form.action="/mainctrl/driver/addPeccancySuccess";
- form.submit();
- }
- }
- function listPeccancy(form)
- {
- form.action="/mainctrl/driver/listPeccancy";
- form.submit();
- }
- function checkIt(form)
- {
- if(isEmpty(form.timeS.value) || isEmptyStr(form.timeS.value))
- {
- alert("请输入违章日期");
- form.timeS.focus();
- return false;
- }
- if(!isVNEXDate(form.timeS.value) )
- {
- alert("违章日期非法");
- form.timeS.focus();
- return false;
- }
- if( currentDate < form.timeS.value )
- {
- alert("违章日期必须是本日或之前");
- form.timeS.focus();
- return false;
- }
- if(isEmpty(form.site.value) || isEmptyStr(form.site.value))
- {
- alert("请输入违章地点");
- form.site.focus();
- return false;
- }
- if(isInvalidateLen(form.site.value,100))
- {
- alert("违章地点不能超过25个汉字或100个英文字符");
- form.site.focus();
- return false;
- }
- if(isEmpty(form.severityLevel.value) || isEmptyStr(form.severityLevel.value))
- {
- alert("请输入违章严重程度");
- form.severityLevel.focus();
- return false;
- }
- if(isInvalidateLen(form.severityLevel.value,100))
- {
- alert("违章严重程度不能超过25个汉字或100个英文字符");
- form.severityLevel.focus();
- return false;
- }
- if(isEmpty(form.punishment.value) || isEmptyStr(form.punishment.value))
- {
- alert("请输入处罚措施");
- form.punishment.focus();
- return false;
- }
- if(isInvalidateLen(form.punishment.value,100))
- {
- alert("处罚措施不能超过25个汉字或100个英文字符");
- form.punishment.focus();
- return false;
- }
- if(isInvalidateLen(form.note.value, 800))
- {
- alert("你的说明过长了,它只能容纳200个汉字或800个英文字符");
- return false;
- }
- return true;
- }
- </script>
- <DIV align=center>
- <form name="myform" method="post" action="">
- <input type="hidden" name="empId" value="<%=request.getParameter("empId")%>">
- <input type="hidden" name="empName" value="<%= request.getParameter("empName") %>">
- <TABLE class=outter cellSpacing=0 cellPadding=0 width=600 border=0>
- <jsp:include page="/vnex/page/TTOA_TABLE_TOP.jsp" />
- <TR>
- <TD colSpan=3 align="center"><br>
- <!--个人信息开始 -->
- <table width="600" border="1" cellspacing="1" bordercolor="#666666">
- <tr bgcolor="#fafafa">
- <td>
- <table class=title width="600" border="0" cellspacing="1" cellpadding="2">
- <tr bgcolor="#666666">
- <td colspan="2" height="15" bgcolor="#666666"><font class="strongw"> <a href="/mainctrl/home/index"><font color="#FFFFFF">首页</font></a>>><a href="/mainctrl/office/main"><font color="#FFFFFF">办公室管理</font></a>>><a href="/mainctrl/driver/listDriver"><font color="#FFFFFF">司机管理</font></a>>><a href="/mainctrl/driver/detailDriver?empId=<%= request.getParameter("empId") %>"><font color="#FFFFFF">司机详细信息</font></a>>>添加违章记录
- </font></td>
- </tr>
- <tr bgcolor="#fafafa">
- <td width="100"><font class="strong"> 姓名:</font></td>
- <td colspan="2" width="487" bgcolor="#fafafa"><%= FieldUtil.filterScriptTag(request.getParameter("empName")) %> </td>
- </tr>
- <tr bgcolor="#e0e0e0">
- <td width="100"> <font class="strong"> 违章日期:</font>
- </td>
- <td align="left" width="487">
- <input type="text" name="timeS" readonly size="24" class="text" value="">
- <img src="/vnex/intranet/calendar/datetime.gif" style="cursor:hand;" align="absmiddle" alt="弹出日历下拉菜单" onClick="fPopUpCalendarDlg(timeS);return false;" width="16" height="16">
- *( 注:带 * 的为必填内容) </td>
- </tr>
- <tr bgcolor="#fafafa">
- <td width="100"><font class="strong"> 违章地点:</font></td>
- <td colspan="2" width="487">
- <input type="site" name="site" class="file" size="24">
- * </td>
- </tr>
- <tr bgcolor="#e0e0e0">
- <td width="100"><font class="strong"> 使用车辆:</font></td>
- <td width="487">
- <select name="automobileId">
- <vnex_auto:autoList>
- <vnex:items select='<%= request.getParameter("automobileId") %>' >
- <option value="<vnex_auto:autoAttribute attribute="automobileId" />" <vnex_auto:autoAttribute attribute="isSelected" /> >
- <vnex_auto:autoAttribute attribute="carCertNo" />
- </option>
- </vnex:items>
- </vnex_auto:autoList>
- </select>
- * </td>
- </tr>
- <tr bgcolor="#fafafa">
- <td width="100"><font class="strong"> 严重程度:</font></td>
- <td colspan="2" width="487">
- <input type="text" name="severityLevel" class="file" size="6">
- * </td>
- </tr>
- <tr bgcolor="#e0e0e0">
- <td width="100"><font class="strong"> 违章原因:</font>
- </td>
- <td colspan="2" width="487">
- <input type="text" name="reason" class="file" size="72">
- </td>
- </tr>
- <tr bgcolor="#fafafa">
- <td width="100"> <font class="strong"> 处罚措施:</font>
- </td>
- <td colspan="2" width="487">
- <input type="text" name="punishment" class="file" size="24">
- * </td>
- </tr>
- <tr bgcolor="#e0e0e0">
- <td width="100"> <font class="strong"> 其他说明:
- </font> </td>
- <td colspan="2" width="487">
- <textarea name="note" cols="59" rows="5"></textarea>
- </td>
- </tr>
- <tr bgcolor="#fafafa" align="center">
- <td colspan="3" height="30">
- <input type="button" name="Submit" value="保存" class="file" onclick="addPeccancySuccess(this.form)">
- <input type="reset" name="Submit22" class="file" value="重置">
- <input type="button" name="Submit2" class="file" value="放弃" onclick="listPeccancy(this.form)">
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- <jsp:include page="/vnex/page/TTOA_HELP.jsp" />
- </TD>
- </TR>
- <TR>
- <jsp:include page="/vnex/page/TTOA_TABLE_BOTTOM.jsp" />
- </TR>
- </TABLE>
- <BR>
- <jsp:include page="/vnex/page/TTOA_PRODUCER_LOGO.jsp" />
- </form></DIV>
- </BODY></HTML>