zoukankan      html  css  js  c++  java
  • 多对一的增删改查-list页面,add页面,update页面,tongji页面

    <%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>列表展示</title>、
    <link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/css/index2.css">
    <script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery-1.8.3.min.js"></script>
    </head>
    <body>
    ---销售总额(企业自报):${pz.sales1zong}万元<br>
    ---销售总额(评审核准):${pz.sales2zong}万元<br>
    ---财政奖励总额:${pz.rewardszong}万元<br>
    <button type="button" onclick="tj()">添加</button>
    <button type="button" onclick="tongji()">企业奖励统计</button>
    <table>
    <tr>
    <td>序号</td>
    <td>单位</td>
    <td>专利号</td>
    <td>专利名称</td>
    <td>技术领域</td>
    <td>企业自报销售额</td>
    <td>评审核准销售额</td>
    <td>误差比</td>
    <td>财政奖励金额</td>
    <td>操作</td>
    </tr>
    <c:forEach items="${info.list }" var="p">
    <tr>
    <td>${p.id }</td>
    <td>${p.name }</td>
    <td>${p.pantentno }</td>
    <td>${p.pantentname }</td>
    <td>${p.category }</td>
    <td>${p.sales1 }</td>
    <td>${p.sales2 }</td>
    <td>${p.wucha }%</td>
    <td>${p.rewards }</td>
    <td>
    <button type="button" onclick="toUpdate(${p.id})">修改</button>
    </td>
    </tr>
    </c:forEach>
    </table>
    <a href="list?pageNum=1">首页</a>
    <a href="list?pageNum=${info.pageNum-1 }">上一页</a>
    <a href="list?pageNum=${info.pageNum+1 }">下一页</a>
    <a href="list?pageNum=${info.pages }">尾页</a>
    </body>
    <script type="text/javascript">

    function tj(){
    location.href = "toadd";
    }
    function tongji(){
    location.href = "tongji";
    }
    function toUpdate(id){
    location.href = "toupdate?id="+id;
    }


    </script>
    </html>

    ----------------------------------------------------------------------

    <%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>添加页面</title>
    <link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/css/index2.css">
    <script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery-1.8.3.min.js"></script>
    </head>
    <body>
    <form action="add" method="post">

    单位:<select name="company_id">
    <c:forEach items="${coms }" var="company">
    <option value="${company.id }">${company.name }</option>
    </c:forEach>
    </select><br>
    专利号:<input type="text" name="pantentno"><br>
    专利名称:<input type="text" name="pantentname"><br>
    技术领域:<input type="text" name="category"><br>
    企业自报销售额:<input type="text" name="sales1"><br>
    评审核准销售额:<input type="text" name="sales2"><br>
    财政奖励金额:<input type="text" name="rewards"><br>
    <button>保存</button>
    </form>
    </body>
    </html>

    ---------------------------------------------------------------------------------

    <%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>修改</title>
    </head>
    <body>
    <form action="update" method="post">
    <input type="hidden" name="id" value="${pantent.id }">
    单位:<select name="company_id">
    <c:forEach items="${coms }" var="company">
    <option value="${company.id }">${company.name }</option>
    </c:forEach>
    </select><br>
    专利号:<input type="text" name="pantentno" value="${pantent.pantentno}"><br>
    专利名称:<input type="text" name="pantentname" value="${pantent.pantentname}"><br>
    技术领域:<input type="text" name="category" value="${pantent.category}"><br>
    企业自报销售额:<input type="text" name="sales1" value="${pantent.sales1}"><br>
    评审核准销售额:<input type="text" name="sales2" value="${pantent.sales2}"><br>
    财政奖励金额:<input type="text" name="rewards" value="${pantent.rewards}"><br>
    <button>保存</button>
    </form>
    </body>
    </html>

    -------------------------------------------------------------------------------------------------------

    <%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>奖励报表</title>
    <link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/css/index2.css">
    <script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery-1.8.3.min.js"></script>
    </head>
    <body>
    <table>
    <tr>
    <td>编号</td>
    <td>单位</td>
    <td>奖励总额(万元)</td>
    </tr>
    <c:forEach items="${list }" var="pantent">
    <tr>
    <td>${pantent.id }</td>
    <td>${pantent.name }</td>
    <td>${pantent.rewardszong }</td>
    </tr>
    </c:forEach>
    </table>

    </body>
    </html>

  • 相关阅读:
    Visual Studio 常用快捷键 (二)
    Visual Studio 常用快捷键
    页游体验
    JSFL 工具
    GhostCat工具
    如何制作一个塔防游戏
    水墨
    给 想转2dx 却无从下手的aser
    两岸三地在线编程学习网站大全
    as3反射应用及简要代码
  • 原文地址:https://www.cnblogs.com/liuzhaolong/p/12921368.html
Copyright © 2011-2022 走看看