📄 content.jsp
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<META name="GENERATOR" content="IBM Software Development Platform">
<META http-equiv="Content-Style-Type" content="text/css">
<LINK href="../theme/Master.css" rel="stylesheet" type="text/css">
<TITLE>Employee List</TITLE>
</HEAD>
<BODY>
<TABLE>
<TR style="background-color: #145378;">
<TH width="5%">Emp No</TH>
<TH width="15%">Employee Name</TH>
<TH width="10%">BirthDate</TH>
<TH width="30%">Address</TH>
<TH width="10%">Phone</TH>
<TH width="10%">E-mail</TH>
<TH width="10%">Job</TH>
<TH width="5%">Salary</TH>
<TH width="5%">Edit</TH>
<TH width="5%">Delete</TH>
</TR>
<%
int count = 0;
String strcolor = "";
String emp_no = "";
for (int i = 0; i < model.EmpModel.getEmployeeList().size(); i++) {
Emp.Employee emp = (Emp.Employee) model.EmpModel
.getEmployeeList().get(i);
//emp_no = rs.getString("EmpNo");
count = count % 2;
if (count == 0) {
strcolor = "#D9D9D9";
} else {
strcolor = "#EFEFEF";
}
count++;
// empList.setEmpNo(rs.getString("EmpNo"));
%>
<script type="text/javascript">
function confirmDelete(){
if(confirm("Are you sure?")){
window.location.href = "delete_employee.jsp?act=delete&emp_no=<%=emp.getEmpNo()%>";
}
}
</script>
<TR style="background-color:<%=strcolor%>;">
<TD><%=emp.getEmpNo()%></TD>
<TD><%=emp.getEmpName()%></TD>
<TD><%=emp.getBirthDate()%></TD>
<TD><%=emp.getAddress()%></TD>
<TD><%=emp.getPhone()%></TD>
<TD><%=emp.getEmail()%></TD>
<TD><%=emp.getJob()%></TD>
<TD><%=emp.getSalary()%></TD>
<TD><A
href="edit_employee.jsp?act=edit&emp_no=<%=emp.getEmpNo()%>">Edit</A></TD>
<TD><A href="javascript:confirmDelete()">Delete</A></TD>
</TR>
<%
}
%>
</TABLE>
</BODY>
</HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -