基于javaweb+jsp的敬老院养老院管理系统(带报告文档)

基于javaweb+jsp的敬老院养老院管理系统(带报告文档)

JavaWeb JavaBean JSP MVC MySQL Tomcat JavaScript Bootstrap.

基础JSP+Servlet或JSP+SSM(Spring、SpringMVC、MyBatis)框架或JSP+SSM+Maven(pom.xml)框架或SpringBoot…均可修改

开发工具:eclipse/idea/myeclipse/sts等均可配置运行

适用

课程设计,大作业,毕业设计,项目练习,学习演示等

    <select id="findAllSplit" parameterType="java.util.Map" resultMap="BaseResultMap">
        SELECT <include refid="Base_Column_List" /> FROM `t_fangjian`
        <where>
            <if test="searchColumn != null and searchColumn != '' and keyword != null and keyword != ''">
                ${searchColumn} LIKE CONCAT('%',#{keyword},'%')  AND
            </if>
            1=1
        </where>
        ORDER BY id ASC
        <if test="startIndex != null and pageSize != null">
            LIMIT #{startIndex},#{pageSize};
        </if>
    </select>
    <!--数量-->
    <select id="getAllCount" parameterType="java.util.Map" resultType="Integer">
        SELECT COUNT(*) FROM `t_fangjian`
        <where>
            <if test="searchColumn != null and searchColumn != '' and keyword != null and keyword != ''">
                ${searchColumn} LIKE CONCAT('%',#{keyword},'%')  AND
            </if>
            1=1
        </where>
    </select>
</mapper>
     * 删除公告
     *
     * @param response
     * @param request
     * @throws IOException
     */
    @RequestMapping("noticeDelete")
    public void delete(HttpServletResponse response, HttpServletRequest request) throws IOException {
        Serializable id = Util.decode(request, "id");
        noticeService.delete(Arrays.asList(id));
        this.redirectList(request, response);
    }

    /**
     * 编辑公告
     *
     * @param response
     * @param request
     * @throws IOException
     */
    @RequestMapping("noticeEdit")
        vo.setXinxiTel(Util.decode(request, "xinxiTel"));
        vo.setXinxiBir(Util.decode(request, "xinxiBir"));
        vo.setXinxiZhuzhi(Util.decode(request, "xinxiZhuzhi"));
        vo.setXinxiText(Util.decode(request, "xinxiText"));
        xinxiService.update(vo);
        this.redirectList(request, response);
    }

    /**
     * 获取信息的详细信息(详情页面与编辑页面要显示该信息的详情)并跳转回页面
     *
     * @param response
     * @param request
     * @throws IOException
     */
    @RequestMapping({"xinxiGet", "xinxiEditPre"})
    public void get(HttpServletResponse response, HttpServletRequest request) throws IOException {
        Serializable id = Util.decode(request, "id");//取出主键id
        Xinxi vo = xinxiService.get(id);
        request.getSession().setAttribute("vo", vo);
        String to = request.getRequestURI().toLowerCase().contains("get") ? "info" : "edit";//判断是去详情显示页面还是编辑页面
        response.sendRedirect("xinxi_" + to + ".jsp");
    }
        return pageNum;
    }

    public void setPageNum(int pageNum) {
        this.pageNum = pageNum;
    }

    public int getPageSize() {
        return pageSize;
    }

    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
    }


    public int getTotalPage() {
        return totalPage;
    }

    // 返回一个随机颜色(Color对象)
    private Color getRandomColor(int minColor, int maxColor) {
        Random random = new Random();
        // 保存minColor最大不会超过255
        if (minColor > 255)
            minColor = 255;
        //  保存minColor最大不会超过255
        if (maxColor > 255)
            maxColor = 255;
        //  获得红色的随机颜色值
        int red = minColor + random.nextInt(maxColor - minColor);
        //  获得绿色的随机颜色值
        int green = minColor + random.nextInt(maxColor - minColor);
        //  获得蓝色的随机颜色值
        int blue = minColor + random.nextInt(maxColor - minColor);
        return new Color(red, green, blue);
    }
}
package com.demo.controller;

import com.demo.util.Util;
import com.demo.service.FangjianService;
import com.demo.vo.Fangjian;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
     * @return
     */
    public static String getTime() {
        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(System.currentTimeMillis());
    }
    /**
     * 判断字符串是不是中文
     *
     * @param c
     * @return
     */
    private static boolean isChinese(char c) {
        Character.UnicodeBlock ub = Character.UnicodeBlock.of(c);
        return (ub == Character.UnicodeBlock.CJK_UNIFIED_IDEOGRAPHS
                || ub == Character.UnicodeBlock.CJK_COMPATIBILITY_IDEOGRAPHS
                || ub == Character.UnicodeBlock.CJK_UNIFIED_IDEOGRAPHS_EXTENSION_A
     * @param request
     * @throws IOException
     */
    @RequestMapping("xinxiDelete")
    public void delete(HttpServletResponse response, HttpServletRequest request) throws IOException {
        Serializable id = Util.decode(request, "id");
        xinxiService.delete(Arrays.asList(id));
        this.redirectList(request, response);
    }

    /**
     * 编辑信息
     *
     * @param response
     * @param request
     * @throws IOException
     */
    @RequestMapping("churuyuanDelete")
    public void delete(HttpServletResponse response, HttpServletRequest request) throws IOException {
        Serializable id = Util.decode(request, "id");
        churuyuanService.delete(Arrays.asList(id));
        this.redirectList(request, response);
    }

    /**
     * 编辑出入院
     *
    }

    public void setId(Long id) {
        this.id = id;
    }
    public String getFangjianLouhao() {
        return fangjianLouhao;
    }

    public void setFangjianLouhao(String fangjianLouhao) {
        this.fangjianLouhao = fangjianLouhao;
    }
    public String getFangjianFangjianhao() {
        return fangjianFangjianhao;
    }
</html>
<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8"/>
    <title>修改信息</title>
    <link rel="stylesheet" type="text/css" href="css/index.css"/>
</head>
<body>
<jsp:include page="menu.jsp"/>
<div class="index-content">
    <div class="index-content-operation">
        <a class="info-detail">修改信息</a>
     * @param request
     * @throws IOException
     */
    @RequestMapping("noticeList")
    public void list(HttpServletResponse response, HttpServletRequest request) throws IOException {
        this.redirectList(request, response);
    }

    /**
     * 跳转到列表页面
     *
     * @param request
     * @param response
     */
    private void redirectList(HttpServletRequest request, HttpServletResponse response) throws IOException {
        //查询列和关键字
        String searchColumn = Util.decode(request, "searchColumn");
        String keyword = Util.decode(request, "keyword");
        Map<String, Object> params = new HashMap();//用来保存控制层传进来的参数(查询条件)
        params.put("searchColumn", searchColumn);//要查询的列
        params.put("keyword", keyword);//查询的关键字
        Map<String, Object> map = noticeService.list(params);

运行环境

Java≥6、Tomcat≥7.0、MySQL≥5.5

开发工具

eclipse/idea/myeclipse/sts等均可配置运行

技术框架

JavaWeb JavaBean JSP MVC MySQL Tomcat JavaScript Bootstrap.

基础JSP+Servlet或JSP+SSM(Spring、SpringMVC、MyBatis)框架或JSP+SSM+Maven(pom.xml)框架或SpringBoot…均可修改

适用

课程设计,大作业,毕业设计,项目练习,学习演示等

功能说明

登录、注册、退出、用户模块、公告模块、出入院模块、房间模块、信息模块的增删改查管理

20220319000856

20220319000857

20220319000858

20220319000859

20220319000900

20220319000901

20220319000902

20220319000903

20220319000904

20220319000905

20220319000906

document

  • 2
    点赞
  • 10
    收藏
    觉得还不错? 一键收藏
  • 2
    评论
Javaweb JSP的新闻中心管理系统是一个用于管理新闻中心的网络应用程序。该系统使用JSP作为前端技术,Java作为后端技术,能够实现对新闻中心的全面管理。 首先,该系统具有用户管理功能。管理员可以创建和管理不同的用户账户,并设置不同的权限。这样可以确保只有授权的用户能够进入系统并进行相关操作。 其次,该系统还具有新闻管理功能。管理员可以通过系统添加、编辑和删除新闻。新闻可以包含标题、内容、发布时间等信息。在添加和编辑新闻时,系统提供了丰富的编辑器和格式化工具,使管理员能够轻松地创建和编辑新闻内容。 此外,该系统还支持新闻分类管理。管理员可以创建不同的新闻分类,并将新闻分配到相应的分类中。这样可以使新闻更加有条理,方便用户进行浏览和搜索。 除了基本的管理功能外,该系统还提供了用户评论功能和新闻搜索功能。用户可以在浏览新闻时发表自己的评论和意见,管理员则可以对评论进行审核和回复。另外,用户还可以使用搜索功能查找感兴趣的新闻。 最后,系统还包含一些辅助功能,如用户登录、数据备份与恢复等。登录功能可以保护系统的安全性,避免未经授权的访问,而数据备份与恢复功能可以在系统出现故障时,快速还原系统数据。 总之,Javaweb JSP的新闻中心管理系统是一个功能全面、易于使用的系统,能够帮助管理员高效地管理新闻中心,为用户提供优质的新闻浏览和互动体验。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值