⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 trainingplan_feedbacklist.jsp

📁 java jsp教程
💻 JSP
字号:
<%--
描述:显示当前登录人已经填写过的培训反馈记录

接收:TrainingFeedbackInfoList

调用一:添加培训反馈
调用TrainingPlan_AddNewFeedbackServlet1
传入参数:无

调用二:修改培训反馈
调用TrainingPlan_ModifyFeedbackServlet1
传入参数:TrainingFeedbackNo


调用三:删除培训反馈
调用TrainingPlan_DelFeedbackServlet
传入参数TrainingFeedbackNo

显示控制:
以反馈日期倒序排列

校验:
已关闭的培训计划的反馈记录不允许删除和修改

对应Demo页面:plan_train_qingkuangbiao.html
--%>
<!--/jsp/plan/TrainingPlan_FeedbackList.jsp-->
<%@ page contentType="text/html; charset=GBK" %>
<%@ page import = "java.util.List"%>
<%@ page import = "java.util.HashMap"%>
<%@ page import = "java.util.Iterator"%>
<%@ page import = "com.icss.cnpc.plan.vo.TrainingFeedbackInfo"%>
<%@ page import = "com.icss.cnpc.plan.vo.TrainingPlanInfo"%>
<%
	List trainingFeedbackInfoList = (List)request.getAttribute("trainingFeedbackInfoList");
	HashMap map = (HashMap)request.getAttribute("map");
%>
<html>
<head>
<title>我 的 培 训 情 况 表</title>
<link rel = "stylesheet" href = "<%=request.getContextPath()%>/css/style.css">
</head>
<body background = "<%=request.getContextPath()%>/images/grid.gif" topMargin = "30">
<form name = "form1">
<input type="hidden" name="trainingbackno">
<input type="hidden" name="trainingno">
<table border = "0" width = "95%" align = "center" cellspacing = "1" cellpadding = "1" bgColor=#b3c4db>
	<tr bgcolor="#a6d0f2" height = "30">
		<th colspan = "7">我 的 培 训 情 况 表</th>
	</tr>
	<tr height = "30" align = "center" bgColor=#eef4ff>
		<td width = "5%"></td>
		<td width="15%">培训班编号</td>
		<td width = "20%">培训班名称</td>
		<td width = "20%">主办单位</td>
		<td widht = "15">培训类型</td>
		<td widht = "15">培训方式</td>
		<td widht = "10">反馈时间</td>
	</tr>
	<%
		for(Iterator trainingFeedbackInfoIter = trainingFeedbackInfoList.iterator();trainingFeedbackInfoIter.hasNext();){
			TrainingFeedbackInfo trainingFeedbackInfoVo = (TrainingFeedbackInfo)trainingFeedbackInfoIter.next();
	%>
	<tr height = "25" align = "center" bgColor=#eef4ff>
		<td><input type = "radio" name="aa" onClick="selectFeedback('<%=trainingFeedbackInfoVo.getTrainingbackno()%>','<%=trainingFeedbackInfoVo.getTrainingno()%>')" ></td>
		<td><%=trainingFeedbackInfoVo.getTrainingno()%></td>
		<%
			String tPlanName = trainingFeedbackInfoVo.getTrainingname();
			String tempName = tPlanName;
			if (tPlanName != null && tPlanName.length() >11) {
				tempName = tPlanName.substring(0, 10) + "..";
			}
			String trainingorgname=((TrainingPlanInfo)map.get(trainingFeedbackInfoVo.getTrainingno())).getTrainingorg();
			String temporgname=trainingorgname;
			if (trainingorgname != null && trainingorgname.length() >11)
			{
				temporgname = trainingorgname.substring(0, 10) + "..";
			}	
		%>
		<td><a href = "javascript:openPlanBasicInfo('<%=trainingFeedbackInfoVo.getTrainingno()%>')" title="<%=tPlanName%>"><%=tempName%></a></td>
		<td ><font title="<%=trainingorgname%>"><%=temporgname%></font></td>
		<td><%=((TrainingPlanInfo)map.get(trainingFeedbackInfoVo.getTrainingno())).getTrainingmode()%></td>
		<td><%=trainingFeedbackInfoVo.getTrainingtype()%></td>
		<td><%=trainingFeedbackInfoVo.getFeedbackdate()%></td>
	</tr>
	<%
		}
	%>

</table>
<br>
<center>
	 <%@ include file="../.././include/defaultPageScrollBar.jsp" %>
</center>
</form>
<center>
	<img src = "<%=request.getContextPath()%>/images/add.gif" style = "cursor:hand" onClick = "javascript:addTrainingPlanBackInfo()">
	<img src = "<%=request.getContextPath()%>/images/modify.gif" style = "cursor:hand" onClick = "javascript:modifyTrainingPlanFeedBackInfo()">
	<img src = "<%=request.getContextPath()%>/images/delete.gif" style = "cursor:hand" onClick = "javascript:deleteTrainingPlanFeedBackInfo()">
</center>
</body>
<script language = "javascript">
function selectFeedback(feedbackno,planno)
{
	document.form1.trainingbackno.value=feedbackno;
	document.form1.trainingno.value=planno;
}
function deleteTrainingPlanFeedBackInfo(){
	if(!check_radioSelected()){
		return false;}
	if(!window.confirm("确认删除")){
		return false;
	}
	//alert(document.form1.trainingbackno.value);
	//alert(document.form1.trainingno.value);
	document.form1.action = "<%=request.getContextPath()%>/servlet/TrainingPlan_DelFeedbackServlet";
	document.form1.submit();

}

function modifyTrainingPlanFeedBackInfo(){
	if(!check_radioSelected()){
		return false;}
	document.form1.action = "<%=request.getContextPath()%>/servlet/TrainingPlan_ModifyFeedbackServlet1";
	document.form1.submit();

}

function addTrainingPlanBackInfo(){
	document.form1.action = "<%=request.getContextPath()%>/servlet/TrainingPlan_AddNewFeedbackServlet1";
	document.form1.submit();

}

function openPlanBasicInfo(trainingno){
	wx=600;
	wy=400;
	urlstr= "<%=request.getContextPath()%>/servlet/TrainingPlan_ViewPlanInfoServlet?trainingno=" + trainingno;
	x=(window.screen.width-wx)/2;
	y=(window.screen.height-wy)/2;
	wposition=",left="+x+",top="+y;
	window.open(urlstr,"查看计划信息","width="+wx+",height="+wy+",scrollbars=yes,status=no"+wposition);
}

function check_radioSelected(){
	feedbackno=document.form1.trainingbackno.value;
	if(feedbackno=="")
	{
		alert("请选择反馈记录");
		return false;
	}
	return true;
}
</script>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -