2024/02/26

<%@ page import="bean.School" %>
<%@ page import="java.util.List" %><%--
  Created by IntelliJ IDEA.
  User: 龚涵彬
  Date: 2024/2/27
  Time: 15:11
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
<h1>调剂操作</h1>
<br>
<table>
    <th>
        院校编号
    </th>
    <th>
        院校名称
    </th>
    <th>
        调剂计划
    </th>
    <th>
        操作
    </th>
<%
    List<School> list = (List<School>) session.getAttribute("schoollist");
    System.out.println(list.get(1).getId());
    if (list != null) {
        for (School item : list) {
            request.setAttribute("item",item);
            %>
    <tr>
        <td>
            ${item.getId()}
        </td>
        <td>
            ${item.getName()}
        </td>
        <td>
            ${item.getRt()}
        </td>
        <td>
            <form action="shenqingtiaoji.jsp">
                <input type="hidden" name="schoolid" value="${item.getId()}">
                <input type="submit" value="申请调剂">
            </form>
        </td>
    </tr>
<%
        }
    }

%>
</table>
</body>
</html>

 

<%--
  Created by IntelliJ IDEA.
  User: 龚涵彬
  Date: 2024/2/27
  Time: 16:23
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
<% String schoolid=request.getParameter("schoolid");
    System.out.println(schoolid);%>
<form action="tijiao-servlet">
    学院编号:<input type="text" name="schoolid" value="<%=schoolid%>"><br>
    学生编号:<input type="text" name="stuid" value="${sessionScope.User.id}"><br>
    学生姓名:<input type="text" name="name" value="${sessionScope.User.name}"><br>
    调剂申请专业:<select name="zhuanye" id="cars">
        <option value="计算机专业">计算机专业</option>
        <option value="软件工程专业" selected>软件工程专业</option>
        <option value="电子信息工程专业">电子信息工程专业</option>
    </select><br>
    总分:<input type="text" name="zongfen"><br>
    数学:<input type="text" name="math" value="${sessionScope.User.math}"><br>
    政治:<input type="text" name="zhengzhi" value="${sessionScope.User.zhengzhi}"><br>
    英语:<input type="text" name="yingyu" value="${sessionScope.User.english}"><br>
    专业:<input type="text" name="zy" value="${sessionScope.User.zy}"><br>
    <input type="submit"value="确认提交">
</form>

</body>
</html>

 

posted @ 2024-02-28 19:38  伐木工熊大  阅读(3)  评论(0编辑  收藏  举报