You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

227 lines
8.0 KiB

<%@page import="com.zky.para.Para"%>
<%@include file="/auth.jsp"%>
<%@page import="java.util.Date"%>
<%@ page import="com.zky.bjca.SM4" %>
<%@ page import="cn.org.bjca.utils.Base64" %>
<%@page language="java" pageEncoding="utf-8" %>
<jsp:useBean id="getPara" scope="application" class="com.zky.para.SyncPara"/>
<%
String qj =Common.convertNull(request.getParameter("qj"));
String school=Common.convertNull(request.getParameter("school"));
String sj = Common.convertNull(request.getParameter("sj"));
HashFmlBuf buf = (HashFmlBuf)request.getAttribute("by_trainId");
sj =buf.fget("frameworkid",0);
school=buf.fget("depart_id",0);
qj=buf.fget("areaid",0);
String trainType=buf.fget("train_type ",0);
String trainSubject=buf.fget("train_subject ",0);
Login loginObj = (Login)session.getAttribute("login");
String optrid = loginObj.optrid;
String optrname = getPara.getDesc("TAB_EMPLOYEE","EMPID","EMPNAME",optrid);
%>
<html>
<head>
<title>培训修改管理</title>
<link href="../../css/font.css" rel="stylesheet" type="text/css">
<script src="../../js/date.js"></script>
<script src="../../js/check.js"></script>
<script>
function textToUpperCase(){
if(event.keyCode>=65 && event.keyCode<=99 || event.type=="change"){
event.srcElement.value = event.srcElement.value.toUpperCase();
}
}
function check(operate) {
form1.operate.value = operate;
if(operate=='modifyTrain'){
if (form1.trainId.value == "") {
alert("请输入培训编号!");
form1.trainId.focus();
return false;
}
if (form1.trainType.value == "") {
alert("请输入培训类型!");
form1.trainType.focus();
return false;
}
if (form1.trainSubject.value == "") {
alert("请输入培训课程!");
form1.trainSubject.focus();
return false;
}
}
form1.submit();
}
function selectChange(i)
{
form1.action = "/zhyw/smry/rypx/TrainUpdate.jsp";
form1.submit();
}
//在填写时间的时候完成时在调用此方法与 让 出生年月与age同步
function agesync(){
//首先获取到出生年月 (正则规定的格式是 0年-0月-0日
var birthday= document.getElementById("birthday").value;
//得到年份
var year=birthday.substring(0,birthday.indexOf("-"));
//获取今年的年份
var myDate=new Date();
// 得到年龄 今年的年份-出生年份
var agevalue=(parseInt(myDate.getFullYear())-parseInt(year));
//想age输入框写值
document.getElementById("empage").value=agevalue;
}
function textToUpperCase(){
if(event.keyCode>=65 && event.keyCode<=99 || event.type=="change"){
event.srcElement.value = event.srcElement.value.toUpperCase();
}
}
</script>
<style type="text/css">
.aselect{
width: 155px;
}
</style>
</head>
<body onload="setValue();">
<form name="form1" method="post" action="/servlet/TrainManage">
<input type="hidden" name="operate" value=""/>
<input type="hidden" name="trainId" value="<%=buf.fget("train_id",0)%>" />
<table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" class="box">
<tr>
<td valign="top"><table width="100%" height="23" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="25%" background="/images/tab_search_01.jpg"><table width="80%" height="23" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="3%"><img src="/images/little_red.jpg" width="12" height="12"></td>
<td width="97%" class="font12b">&nbsp;培训修改管理</td>
</tr>
</table></td>
<td width="82%" background="/images/tab_search_03.jpg"><img src="/images/tab_search_02.jpg" width="12" height="23"></td>
</tr>
</table>
<table width="99%" border="0" align="center" cellpadding="2" cellspacing="1" bgcolor="d8e9fe" class="table02">
<tr bgcolor="#FFFFFF">
<td class="cell1" height="30">所属地市</td>
<td class="cell2">
<input type="text" class='aselect' disabled="disabled" value="<%=buf.fget("FRAMEWORKNAME", 0) %>">
</td>
<td class="cell1" style="line-height: 35px;">所属区县</td>
<td class="cell2">
<input type="text" class='aselect' disabled="disabled" value="<%=buf.fget("AREADEF", 0) %>">
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td class="cell1" style="line-height: 35px;">所属单位</td>
<td class="cell2">
<input type="text" class='aselect' disabled="disabled" value="<%=buf.fget("DEPARTNAME", 0) %>">
</td>
<td class="cell1">下属部门</td>
<td class="cell2" >
<input type="text" class='aselect' name="pary" value="<%=buf.fget("part",0) %>" >&nbsp;<font color="#ff0000">* (如果无下属部门,请填写"无部门")</font>
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td class="cell1" style="line-height: 35px;">培训人姓名</td>
<td class="cell2">
<input style="color:red;" type="text" name="trainName" value="<%=buf.fget("train_name",0)%>" />
</td>
<td class="cell1">培训编号</td>
<td class="cell2" >
<%=buf.fget("train_id",0)%>
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td class="cell1" style="line-height: 35px;">培训类型</td>
<td class="cell2">
<select class='aselect' name="trainType" value="<%=trainType%>">
<%
if(trainType.equals("0")){ %>
<option value="0" selected="selected">资料学习</option>
<option value="1" >视频学习</option>
<option value="2">音频学习</option>
<%
}else if(trainType.equals("1")){ %>
<option value="0" >资料学习</option>
<option value="1" selected="selected">视频学习</option>
<option value="2">音频学习</option>
<%
}else{ %>
<option value="0" >资料学习</option>
<option value="1" >视频学习</option>
<option value="2" selected="selected">音频学习</option>
<%
}
%>
</select>
</td>
<td class="cell1">培训对象</td>
<td class="cell2">
<select class='aselect' name="trainSubject" value="<%=trainSubject%>">
<%
if(trainSubject.equals("0")){ %>
<option value="0" selected="selected">涉密文件</option>
<option value="1">涉密设备</option>
<option value="2">涉密资产</option>
<option value="3">涉密人员</option>
<%
}else if(trainSubject.equals("1")){ %>
<option value="0">涉密文件</option>
<option value="1" selected="selected">涉密设备</option>
<option value="2">涉密资产</option>
<option value="3">涉密人员</option>
<%
}else if(trainSubject.equals("2")){ %>
<option value="0">涉密文件</option>
<option value="1">涉密设备</option>
<option value="2" selected="selected">涉密资产</option>
<option value="3">涉密人员</option>
<%
}else{ %>
<option value="0">涉密文件</option>
<option value="1">涉密设备</option>
<option value="2">涉密资产</option>
<option value="3" selected="selected">涉密人员</option>
<%
}
%>
</select>
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td class="cell1" style="line-height: 35px;">培训日期</td>
<td class="cell2">
<input name='empidenddate' type='text' readonly=true value='<%=buf.fget("train_time",0) %>' onclick="fPopCalendar(empidenddate,empidenddate); return true;" onblur="agesync()" >
</td>
<td class="cell1"></td>
<td class="cell2">
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td class="cell1" style="line-height: 50px;">培训地点</td>
<td class="cell2" colspan="3">
<textarea rows="2" cols="43" name="trainAddress"><%=SM4.SM4Decrypt(Base64.decode(buf.fget("train_address",0))) %></textarea>
</td>
</tr>
</table>
</td>
</tr>
</table>
<table width="99%" align="center">
<tr align="center">
<td>
<input border="0" type="image" src="../../images1/bc1.png" alt="保存" onclick="check('modifyTrain')"/>&nbsp;&nbsp;
<a href="javascript:history.go(-1)"><img src="../../images1/fh.png" alt="返回" border="0" /></a>
</td>
</tr>
</table>
<%@include file="/foot.jsp"%>
</form>
</body>
</html>