ssm社区医院儿童预防接种管理系统源码

news2024/11/18 9:26:34

ssm社区医院儿童预防接种管理系统源码709

开发技术:后端 ssm 后台管理 vue 用户端 vue.js+html

一、课题研究目的和意义

为了方便家长用户更全面的掌握孩子的疫苗接种情况,系统提供便利的疫苗接种服务,同时也旨在推广疫苗接种知识,提高人们对疫苗的认知和接种意愿。具体来说,少儿疫苗接种平台的意义体现在几个方面:提供便捷的服务。少儿疫苗接种小程序可以帮助家长轻松查询和预约疫苗接种服务,避免了传统方式中需要排队等待的繁琐流程,节省了时间和精力。提高接种率。少儿疫苗接种小程序不仅能够提供接种服务,还能为用户提供详细的疫苗接种知识和建议,让家长了解疫苗的作用和重要性,从而更加愿意让孩子接种疫苗,提高接种率。促进疫苗接种管理。少儿疫苗接种小程序可以记录孩子的接种记录和接种计划,让家长随时了解孩子的接种情况,保障孩子的健康安全。增强疾病防控能力。可以及时发布疫苗知识信息和防控措施,让用户了解最新疾病动态,做好少儿防控措施,从而增强少儿免疫能力。综上所述,少儿疫苗接种平台的目的和意义在于为家长提供便捷的疫苗接种服务,促进疫苗接种管理,增强少儿疾病防控能力,提高人们对少儿疫苗的认知和接种意愿,从而保障孩子的健康和社区的健康安全。

演示视频:

ssm社区医院儿童预防接种管理系统源码

二、主要参考文献资料

[1]苏强,晏任斯,孙淑慧.政府激励措施下民众疫苗接种的演化博弈分析[J/OL].工业工程与管理:1-24[2023-03-06].

[2]吕雪灵,徐筱倩,孙良,丁振涛,李欣.3~17岁未成年人家长对子女新冠疫苗接种意愿及影响因素的调查[J].中国国境卫生检疫杂志,2023,46(01):67-73.

[3]魏孔鹏, 谷洪彬, 李啸龙. 基于Android的儿童疫苗接种系统的设计与实现[J]. 数字技术与应用, 2019, 37(6):5.

[4]顾济海. 一种疫苗安全智能管理系统:, CN213040860U[P]. 2021..

[5]吴小芳. 浅谈健康教育在儿童预防接种中的作用[J]. 母婴世界 2021年10期, 264页, 2021.

[6]任乐文, 谢玲, 丁月,等. 微信小程序应用于5岁儿童龋病预防的临床研究[J]. 中国学校卫生, 2022, 43(11):4.

[7]王培花, 王芳, 宣靓. 互联网+线上预约平台在HPV疫苗预防接种服务中的作用[J]. 中文科技期刊数据库(引文版)医药卫生, 2022(5):4.

package com.controller;

import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Calendar;
import java.util.Map;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Date;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import java.io.IOException;

import com.utils.ValidatorUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.annotation.IgnoreAuth;

import com.entity.JiezhongyichangEntity;
import com.entity.view.JiezhongyichangView;

import com.service.JiezhongyichangService;
import com.service.TokenService;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.MD5Util;
import com.utils.MPUtil;
import com.utils.CommonUtil;

/**
 * 接种异常
 * 后端接口
 * @author 
 * @email 
 * @date 2022-04-25 18:34:15
 */
@RestController
@RequestMapping("/jiezhongyichang")
public class JiezhongyichangController {
    @Autowired
    private JiezhongyichangService jiezhongyichangService;



    


    /**
     * 后端列表
     */
    @RequestMapping("/page")
    public R page(@RequestParam Map<String, Object> params,JiezhongyichangEntity jiezhongyichang, 
		HttpServletRequest request){

		String tableName = request.getSession().getAttribute("tableName").toString();
		if(tableName.equals("jiazhang")) {
			jiezhongyichang.setJiazhangzhanghao((String)request.getSession().getAttribute("username"));
		}
		if(tableName.equals("hushi")) {
			jiezhongyichang.setHushizhanghao((String)request.getSession().getAttribute("username"));
		}
        EntityWrapper<JiezhongyichangEntity> ew = new EntityWrapper<JiezhongyichangEntity>();
		PageUtils page = jiezhongyichangService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, jiezhongyichang), params), params));
        return R.ok().put("data", page);
    }
    
    /**
     * 前端列表
     */
	@IgnoreAuth
    @RequestMapping("/list")
    public R list(@RequestParam Map<String, Object> params,JiezhongyichangEntity jiezhongyichang, 
		HttpServletRequest request){
        EntityWrapper<JiezhongyichangEntity> ew = new EntityWrapper<JiezhongyichangEntity>();
		PageUtils page = jiezhongyichangService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, jiezhongyichang), params), params));
        return R.ok().put("data", page);
    }

	/**
     * 列表
     */
    @RequestMapping("/lists")
    public R list( JiezhongyichangEntity jiezhongyichang){
       	EntityWrapper<JiezhongyichangEntity> ew = new EntityWrapper<JiezhongyichangEntity>();
      	ew.allEq(MPUtil.allEQMapPre( jiezhongyichang, "jiezhongyichang")); 
        return R.ok().put("data", jiezhongyichangService.selectListView(ew));
    }

	 /**
     * 查询
     */
    @RequestMapping("/query")
    public R query(JiezhongyichangEntity jiezhongyichang){
        EntityWrapper< JiezhongyichangEntity> ew = new EntityWrapper< JiezhongyichangEntity>();
 		ew.allEq(MPUtil.allEQMapPre( jiezhongyichang, "jiezhongyichang")); 
		JiezhongyichangView jiezhongyichangView =  jiezhongyichangService.selectView(ew);
		return R.ok("查询接种异常成功").put("data", jiezhongyichangView);
    }
	
    /**
     * 后端详情
     */
    @RequestMapping("/info/{id}")
    public R info(@PathVariable("id") Long id){
        JiezhongyichangEntity jiezhongyichang = jiezhongyichangService.selectById(id);
        return R.ok().put("data", jiezhongyichang);
    }

    /**
     * 前端详情
     */
	@IgnoreAuth
    @RequestMapping("/detail/{id}")
    public R detail(@PathVariable("id") Long id){
        JiezhongyichangEntity jiezhongyichang = jiezhongyichangService.selectById(id);
        return R.ok().put("data", jiezhongyichang);
    }
    



    /**
     * 后端保存
     */
    @RequestMapping("/save")
    public R save(@RequestBody JiezhongyichangEntity jiezhongyichang, HttpServletRequest request){
    	jiezhongyichang.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
    	//ValidatorUtils.validateEntity(jiezhongyichang);

        jiezhongyichangService.insert(jiezhongyichang);
        return R.ok();
    }
    
    /**
     * 前端保存
     */
    @RequestMapping("/add")
    public R add(@RequestBody JiezhongyichangEntity jiezhongyichang, HttpServletRequest request){
    	jiezhongyichang.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
    	//ValidatorUtils.validateEntity(jiezhongyichang);

        jiezhongyichangService.insert(jiezhongyichang);
        return R.ok();
    }

    /**
     * 修改
     */
    @RequestMapping("/update")
    @Transactional
    public R update(@RequestBody JiezhongyichangEntity jiezhongyichang, HttpServletRequest request){
        //ValidatorUtils.validateEntity(jiezhongyichang);
        jiezhongyichangService.updateById(jiezhongyichang);//全部更新
        return R.ok();
    }
    

    /**
     * 删除
     */
    @RequestMapping("/delete")
    public R delete(@RequestBody Long[] ids){
        jiezhongyichangService.deleteBatchIds(Arrays.asList(ids));
        return R.ok();
    }
    
    /**
     * 提醒接口
     */
	@RequestMapping("/remind/{columnName}/{type}")
	public R remindCount(@PathVariable("columnName") String columnName, HttpServletRequest request, 
						 @PathVariable("type") String type,@RequestParam Map<String, Object> map) {
		map.put("column", columnName);
		map.put("type", type);
		
		if(type.equals("2")) {
			SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
			Calendar c = Calendar.getInstance();
			Date remindStartDate = null;
			Date remindEndDate = null;
			if(map.get("remindstart")!=null) {
				Integer remindStart = Integer.parseInt(map.get("remindstart").toString());
				c.setTime(new Date()); 
				c.add(Calendar.DAY_OF_MONTH,remindStart);
				remindStartDate = c.getTime();
				map.put("remindstart", sdf.format(remindStartDate));
			}
			if(map.get("remindend")!=null) {
				Integer remindEnd = Integer.parseInt(map.get("remindend").toString());
				c.setTime(new Date());
				c.add(Calendar.DAY_OF_MONTH,remindEnd);
				remindEndDate = c.getTime();
				map.put("remindend", sdf.format(remindEndDate));
			}
		}
		
		Wrapper<JiezhongyichangEntity> wrapper = new EntityWrapper<JiezhongyichangEntity>();
		if(map.get("remindstart")!=null) {
			wrapper.ge(columnName, map.get("remindstart"));
		}
		if(map.get("remindend")!=null) {
			wrapper.le(columnName, map.get("remindend"));
		}

		String tableName = request.getSession().getAttribute("tableName").toString();
		if(tableName.equals("jiazhang")) {
			wrapper.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
		}
		if(tableName.equals("hushi")) {
			wrapper.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
		}

		int count = jiezhongyichangService.selectCount(wrapper);
		return R.ok().put("count", count);
	}
	







    /**
     * (按值统计)
     */
    @RequestMapping("/value/{xColumnName}/{yColumnName}")
    public R value(@PathVariable("yColumnName") String yColumnName, @PathVariable("xColumnName") String xColumnName,HttpServletRequest request) {
        Map<String, Object> params = new HashMap<String, Object>();
        params.put("xColumn", xColumnName);
        params.put("yColumn", yColumnName);
        EntityWrapper<JiezhongyichangEntity> ew = new EntityWrapper<JiezhongyichangEntity>();
        String tableName = request.getSession().getAttribute("tableName").toString();
        if(tableName.equals("jiazhang")) {
            ew.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
        }
        if(tableName.equals("hushi")) {
            ew.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
        }
        List<Map<String, Object>> result = jiezhongyichangService.selectValue(params, ew);
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        for(Map<String, Object> m : result) {
            for(String k : m.keySet()) {
                if(m.get(k) instanceof Date) {
                    m.put(k, sdf.format((Date)m.get(k)));
                }
            }
        }
        return R.ok().put("data", result);
    }

    /**
     * (按值统计)时间统计类型
     */
    @RequestMapping("/value/{xColumnName}/{yColumnName}/{timeStatType}")
    public R valueDay(@PathVariable("yColumnName") String yColumnName, @PathVariable("xColumnName") String xColumnName, @PathVariable("timeStatType") String timeStatType,HttpServletRequest request) {
        Map<String, Object> params = new HashMap<String, Object>();
        params.put("xColumn", xColumnName);
        params.put("yColumn", yColumnName);
        params.put("timeStatType", timeStatType);
        EntityWrapper<JiezhongyichangEntity> ew = new EntityWrapper<JiezhongyichangEntity>();
        String tableName = request.getSession().getAttribute("tableName").toString();
        if(tableName.equals("jiazhang")) {
            ew.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
        }
        if(tableName.equals("hushi")) {
            ew.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
        }
        List<Map<String, Object>> result = jiezhongyichangService.selectTimeStatValue(params, ew);
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        for(Map<String, Object> m : result) {
            for(String k : m.keySet()) {
                if(m.get(k) instanceof Date) {
                    m.put(k, sdf.format((Date)m.get(k)));
                }
            }
        }
        return R.ok().put("data", result);
    }

    /**
     * 分组统计
     */
    @RequestMapping("/group/{columnName}")
    public R group(@PathVariable("columnName") String columnName,HttpServletRequest request) {
        Map<String, Object> params = new HashMap<String, Object>();
        params.put("column", columnName);
        EntityWrapper<JiezhongyichangEntity> ew = new EntityWrapper<JiezhongyichangEntity>();
        String tableName = request.getSession().getAttribute("tableName").toString();
        if(tableName.equals("jiazhang")) {
            ew.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
        }
        if(tableName.equals("hushi")) {
            ew.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
        }
        List<Map<String, Object>> result = jiezhongyichangService.selectGroup(params, ew);
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        for(Map<String, Object> m : result) {
            for(String k : m.keySet()) {
                if(m.get(k) instanceof Date) {
                    m.put(k, sdf.format((Date)m.get(k)));
                }
            }
        }
        return R.ok().put("data", result);
    }
}

package com.controller;

import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Calendar;
import java.util.Map;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Date;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import java.io.IOException;

import com.utils.ValidatorUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.annotation.IgnoreAuth;

import com.entity.JiezhongxinxiEntity;
import com.entity.view.JiezhongxinxiView;

import com.service.JiezhongxinxiService;
import com.service.TokenService;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.MD5Util;
import com.utils.MPUtil;
import com.utils.CommonUtil;

/**
 * 接种信息
 * 后端接口
 * @author 
 * @email 
 * @date 2022-04-25 18:34:14
 */
@RestController
@RequestMapping("/jiezhongxinxi")
public class JiezhongxinxiController {
    @Autowired
    private JiezhongxinxiService jiezhongxinxiService;



    


    /**
     * 后端列表
     */
    @RequestMapping("/page")
    public R page(@RequestParam Map<String, Object> params,JiezhongxinxiEntity jiezhongxinxi, 
		HttpServletRequest request){

		String tableName = request.getSession().getAttribute("tableName").toString();
		if(tableName.equals("jiazhang")) {
			jiezhongxinxi.setJiazhangzhanghao((String)request.getSession().getAttribute("username"));
		}
		if(tableName.equals("hushi")) {
			jiezhongxinxi.setHushizhanghao((String)request.getSession().getAttribute("username"));
		}
        EntityWrapper<JiezhongxinxiEntity> ew = new EntityWrapper<JiezhongxinxiEntity>();
		PageUtils page = jiezhongxinxiService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, jiezhongxinxi), params), params));
        return R.ok().put("data", page);
    }
    
    /**
     * 前端列表
     */
	@IgnoreAuth
    @RequestMapping("/list")
    public R list(@RequestParam Map<String, Object> params,JiezhongxinxiEntity jiezhongxinxi, 
		HttpServletRequest request){
        EntityWrapper<JiezhongxinxiEntity> ew = new EntityWrapper<JiezhongxinxiEntity>();
		PageUtils page = jiezhongxinxiService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, jiezhongxinxi), params), params));
        return R.ok().put("data", page);
    }

	/**
     * 列表
     */
    @RequestMapping("/lists")
    public R list( JiezhongxinxiEntity jiezhongxinxi){
       	EntityWrapper<JiezhongxinxiEntity> ew = new EntityWrapper<JiezhongxinxiEntity>();
      	ew.allEq(MPUtil.allEQMapPre( jiezhongxinxi, "jiezhongxinxi")); 
        return R.ok().put("data", jiezhongxinxiService.selectListView(ew));
    }

	 /**
     * 查询
     */
    @RequestMapping("/query")
    public R query(JiezhongxinxiEntity jiezhongxinxi){
        EntityWrapper< JiezhongxinxiEntity> ew = new EntityWrapper< JiezhongxinxiEntity>();
 		ew.allEq(MPUtil.allEQMapPre( jiezhongxinxi, "jiezhongxinxi")); 
		JiezhongxinxiView jiezhongxinxiView =  jiezhongxinxiService.selectView(ew);
		return R.ok("查询接种信息成功").put("data", jiezhongxinxiView);
    }
	
    /**
     * 后端详情
     */
    @RequestMapping("/info/{id}")
    public R info(@PathVariable("id") Long id){
        JiezhongxinxiEntity jiezhongxinxi = jiezhongxinxiService.selectById(id);
        return R.ok().put("data", jiezhongxinxi);
    }

    /**
     * 前端详情
     */
	@IgnoreAuth
    @RequestMapping("/detail/{id}")
    public R detail(@PathVariable("id") Long id){
        JiezhongxinxiEntity jiezhongxinxi = jiezhongxinxiService.selectById(id);
        return R.ok().put("data", jiezhongxinxi);
    }
    



    /**
     * 后端保存
     */
    @RequestMapping("/save")
    public R save(@RequestBody JiezhongxinxiEntity jiezhongxinxi, HttpServletRequest request){
    	jiezhongxinxi.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
    	//ValidatorUtils.validateEntity(jiezhongxinxi);

        jiezhongxinxiService.insert(jiezhongxinxi);
        return R.ok();
    }
    
    /**
     * 前端保存
     */
    @RequestMapping("/add")
    public R add(@RequestBody JiezhongxinxiEntity jiezhongxinxi, HttpServletRequest request){
    	jiezhongxinxi.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
    	//ValidatorUtils.validateEntity(jiezhongxinxi);

        jiezhongxinxiService.insert(jiezhongxinxi);
        return R.ok();
    }

    /**
     * 修改
     */
    @RequestMapping("/update")
    @Transactional
    public R update(@RequestBody JiezhongxinxiEntity jiezhongxinxi, HttpServletRequest request){
        //ValidatorUtils.validateEntity(jiezhongxinxi);
        jiezhongxinxiService.updateById(jiezhongxinxi);//全部更新
        return R.ok();
    }
    

    /**
     * 删除
     */
    @RequestMapping("/delete")
    public R delete(@RequestBody Long[] ids){
        jiezhongxinxiService.deleteBatchIds(Arrays.asList(ids));
        return R.ok();
    }
    
    /**
     * 提醒接口
     */
	@RequestMapping("/remind/{columnName}/{type}")
	public R remindCount(@PathVariable("columnName") String columnName, HttpServletRequest request, 
						 @PathVariable("type") String type,@RequestParam Map<String, Object> map) {
		map.put("column", columnName);
		map.put("type", type);
		
		if(type.equals("2")) {
			SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
			Calendar c = Calendar.getInstance();
			Date remindStartDate = null;
			Date remindEndDate = null;
			if(map.get("remindstart")!=null) {
				Integer remindStart = Integer.parseInt(map.get("remindstart").toString());
				c.setTime(new Date()); 
				c.add(Calendar.DAY_OF_MONTH,remindStart);
				remindStartDate = c.getTime();
				map.put("remindstart", sdf.format(remindStartDate));
			}
			if(map.get("remindend")!=null) {
				Integer remindEnd = Integer.parseInt(map.get("remindend").toString());
				c.setTime(new Date());
				c.add(Calendar.DAY_OF_MONTH,remindEnd);
				remindEndDate = c.getTime();
				map.put("remindend", sdf.format(remindEndDate));
			}
		}
		
		Wrapper<JiezhongxinxiEntity> wrapper = new EntityWrapper<JiezhongxinxiEntity>();
		if(map.get("remindstart")!=null) {
			wrapper.ge(columnName, map.get("remindstart"));
		}
		if(map.get("remindend")!=null) {
			wrapper.le(columnName, map.get("remindend"));
		}

		String tableName = request.getSession().getAttribute("tableName").toString();
		if(tableName.equals("jiazhang")) {
			wrapper.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
		}
		if(tableName.equals("hushi")) {
			wrapper.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
		}

		int count = jiezhongxinxiService.selectCount(wrapper);
		return R.ok().put("count", count);
	}
	







    /**
     * (按值统计)
     */
    @RequestMapping("/value/{xColumnName}/{yColumnName}")
    public R value(@PathVariable("yColumnName") String yColumnName, @PathVariable("xColumnName") String xColumnName,HttpServletRequest request) {
        Map<String, Object> params = new HashMap<String, Object>();
        params.put("xColumn", xColumnName);
        params.put("yColumn", yColumnName);
        EntityWrapper<JiezhongxinxiEntity> ew = new EntityWrapper<JiezhongxinxiEntity>();
        String tableName = request.getSession().getAttribute("tableName").toString();
        if(tableName.equals("jiazhang")) {
            ew.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
        }
        if(tableName.equals("hushi")) {
            ew.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
        }
        List<Map<String, Object>> result = jiezhongxinxiService.selectValue(params, ew);
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        for(Map<String, Object> m : result) {
            for(String k : m.keySet()) {
                if(m.get(k) instanceof Date) {
                    m.put(k, sdf.format((Date)m.get(k)));
                }
            }
        }
        return R.ok().put("data", result);
    }

    /**
     * (按值统计)时间统计类型
     */
    @RequestMapping("/value/{xColumnName}/{yColumnName}/{timeStatType}")
    public R valueDay(@PathVariable("yColumnName") String yColumnName, @PathVariable("xColumnName") String xColumnName, @PathVariable("timeStatType") String timeStatType,HttpServletRequest request) {
        Map<String, Object> params = new HashMap<String, Object>();
        params.put("xColumn", xColumnName);
        params.put("yColumn", yColumnName);
        params.put("timeStatType", timeStatType);
        EntityWrapper<JiezhongxinxiEntity> ew = new EntityWrapper<JiezhongxinxiEntity>();
        String tableName = request.getSession().getAttribute("tableName").toString();
        if(tableName.equals("jiazhang")) {
            ew.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
        }
        if(tableName.equals("hushi")) {
            ew.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
        }
        List<Map<String, Object>> result = jiezhongxinxiService.selectTimeStatValue(params, ew);
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        for(Map<String, Object> m : result) {
            for(String k : m.keySet()) {
                if(m.get(k) instanceof Date) {
                    m.put(k, sdf.format((Date)m.get(k)));
                }
            }
        }
        return R.ok().put("data", result);
    }

    /**
     * 分组统计
     */
    @RequestMapping("/group/{columnName}")
    public R group(@PathVariable("columnName") String columnName,HttpServletRequest request) {
        Map<String, Object> params = new HashMap<String, Object>();
        params.put("column", columnName);
        EntityWrapper<JiezhongxinxiEntity> ew = new EntityWrapper<JiezhongxinxiEntity>();
        String tableName = request.getSession().getAttribute("tableName").toString();
        if(tableName.equals("jiazhang")) {
            ew.eq("jiazhangzhanghao", (String)request.getSession().getAttribute("username"));
        }
        if(tableName.equals("hushi")) {
            ew.eq("hushizhanghao", (String)request.getSession().getAttribute("username"));
        }
        List<Map<String, Object>> result = jiezhongxinxiService.selectGroup(params, ew);
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        for(Map<String, Object> m : result) {
            for(String k : m.keySet()) {
                if(m.get(k) instanceof Date) {
                    m.put(k, sdf.format((Date)m.get(k)));
                }
            }
        }
        return R.ok().put("data", result);
    }
}

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/1283401.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

数据库更换版本

目录 0.前言 1.官网下载MySQL 2.配置初始化文件my.ini 3.初始化MySQL 4.安装mysql服务并启动修改密码 5.配置环境变量​编辑 0.前言 心累&#xff0c;为了完成实验&#xff0c;必须使用8.0版本导致我更新版本的时候&#xff0c;把sqlyog干崩溃了&#xff0c;什么版本不兼…

全球与中国仿制药市场:增长趋势、竞争格局与前景展望

仿制药是指在剂型、功效、给药方法、品质、性能特征、用途等方面与原厂药相似并已获得原厂药上市许可的药品。仿制药的价格低于品牌药。糖尿病、癌症和心血管疾病等慢性疾病的快速成长推动了仿制药市场的成长。此外&#xff0c;仿制药的实惠价格以及最新产品的批准和推出也有助…

面试必会-JAVA基础篇-02

文章目录 11. ArrayList 和 LinkedList 的区别是什么&#xff1f;12. 说一下HashMap的实现原理&#xff1f;13. HashMap的put方法的具体流程&#xff1f;14. 讲一讲HashMap的扩容机制15. ConcurrentHashMap 底层具体实现知道吗&#xff1f;16. 创建线程的四种方式17. runnable …

Educational Codeforces Round 159 (Rated for Div. 2)(A~F)(LCA + 线性基)

A - Binary Imbalance 题意&#xff1a;给定一个01串&#xff0c;你能够在相邻相同字符中插入‘1’,在相邻不同字符中插入‘0’&#xff0c;求最终能否使得0的数量严格大于1的数量。 思路&#xff1a;可以发现&#xff0c;当出现了‘01’或者‘10’子序列时&#xff0c;能够无…

shopee主营店铺链接怎么填,shopee店铺url在哪里找——站斧浏览器

要设置Shopee主营店铺链接&#xff0c;在设置页面中填写自己想要推广的其他店铺的链接地址&#xff0c;并进行测试和提交审核。通过设置主营店铺链接&#xff0c;卖家可以增加销售量和曝光率。 shopee主营店铺链接怎么填&#xff1f; Shopee主营店铺链接是指卖家在Shopee平台…

[ISCTF 2023]——Web、Misc较全详细Writeup、Re、Crypto部分Writeup

前言 由于懒我直接把上交的wp稍加修改拉上来了&#xff0c;凑活看 文章目录 前言Pwntest_ncnc_shell ReverseCreakmeEasyRebabyReeasy_z3mix_reeasy_flower_tea Webwhere_is_the_flag圣杯战争!!!绕进你的心里easy_websitewafrez_ini1z_Ssqldouble_picklewebincludefuzz!恐怖G…

拼多多股价为什么可以创下两年新高并一举超越阿里巴巴?

来源&#xff1a;猛兽财经 作者&#xff1a;猛兽财经 拼多多再次证明了它是全球电商领域中不可忽视的力量 过去两年&#xff0c;由于某些众所周知的原因&#xff0c;很多中概股的股价都很疲软&#xff0c;甚至半死不活的&#xff0c;很多投资中概股的朋友也一直承受着很大的…

交通强国添力量 无人机巡航为何备受期待?

在高速建设交通强国的过程中&#xff0c;交通运输部海事局计划完善“陆海空天”一体化水上交通运输安全保障体系。无人机巡航系统将在提升海事船舶监管和水上搜救能力方面发挥关键作用&#xff0c;以构建更为全面的监管体系。尽管已初步建立了海事监管体系&#xff0c;但仍存在…

APP逆向工具环境安装

环境安装及配置&#xff1a; 1.JDK安装及配置链接&#xff1a;https://pan.baidu.com/s/146I4vDJdz8YeR0OEqLS8xw 提取码&#xff1a;7h00 2.SDK环境配置链接&#xff1a;https://pan.baidu.com/s/1A8rwqyw8Nn7p93Axqpll3A 提取码&#xff1a;cwv43.NDK环境配置链接&#xff1…

深度学习在工业自动化领域的简析

原创 | 文 BFT机器人 在机器视觉和工业自动化领域&#xff0c;很少有比“深度学习”更引人注目的词汇。大约七年前左右&#xff0c;这个词随着一波庞大的营销炒作而出现&#xff0c;附带着“革命性”和“颠覆性”等形容词。几年后&#xff0c;尘埃落定&#xff0c;深度学习在自…

销售人员一定要知道的6种获取电话号码的方法

对于销售来说&#xff0c;电话销售是必须要知道的销售方法&#xff0c;也是销售生涯中的必经之路。最开始我们并不清楚这么电话是从哪里来的&#xff0c;也不清楚是通过哪些方法渠道获取。那么今天就来分享给各位销售人员获取客户电话号码的方法。 1.打印自己的名片&#xff0…

[ 蓝桥杯Web真题 ]-视频弹幕

目录 介绍 准备 目标 效果 规定 思路 解答参考 扩展功能 介绍 弹幕指直接显现在视频上的评论&#xff0c;可以以滚动、停留甚至更多动作特效方式出现在视频上&#xff0c;是观看视频的人发送的简短评论。通过发送弹幕可以给观众一种“实时互动”的错觉&#xff0c;弹幕…

大数据 - MapReduce:从原理到实战的全面指南

本文深入探讨了MapReduce的各个方面&#xff0c;从基础概念和工作原理到编程模型和实际应用场景&#xff0c;最后专注于性能优化的最佳实践。 一、引言 1.1 数据的价值与挑战 在信息爆炸的时代&#xff0c;数据被视为新的石油。每天都有数以百万计的数据被生成、存储和处理&…

GUI库pyqt5的中线程通信问题

背景 在使用pyqt5编写GUI程序时&#xff0c;我们可能有时会需要使用多线程来处理问题&#xff0c;这就可能会涉及到线程之间相互通信的问题。比如接下来要解决的进度条问题。 解决思路 我们可以通过pyqt5的信号与槽机制来完成线程之间的通信。 代码编写 # Copyright (C) 2…

如何写好亚马逊listing页面?助你提高转化率!(下)

一、产品长描述 产品长描述位于listing页面的中部&#xff0c;是产品信息的重要组成部分。卖家可以描述产品的特点、功能和使用方法&#xff0c;有助于解决买家可能存在的疑虑&#xff0c;从而增加销售、提高转化率和品牌形象。 在亚马逊上&#xff0c;有两种长描述方式——有…

Canvas鼠标画线

鼠标按下开始画线,鼠标移动根据鼠标的轨迹去画,鼠标抬起停止画线 <!DOCTYPE html> <html lang"en"><head><meta charset"UTF-8"><meta name"viewport" content"widthdevice-width, initial-scale1.0">…

[SHCTF 2023]——week1-week3 Web方向详细Writeup

Week1 babyRCE 源码如下 <?php$rce $_GET[rce]; if (isset($rce)) {if (!preg_match("/cat|more|less|head|tac|tail|nl|od|vi|vim|sort|flag| |\;|[0-9]|\*|\|\%|\>|\<|\|\"/i", $rce)) {system($rce);}else {echo "hhhhhhacker!!!".&…

antv x6填坑指南: 部分节点拖拽和操作撤销重做不生效问题、使用Stencil过滤时过滤后分组的显示高度无法根据过滤节点自适应问题

问题1. 部分分组中节点拖拽添加或操作后撤销重做操作不生效。 前提&#xff1a;使用Stencil插件&#xff0c;创建画布侧边栏的 UI 组件&#xff0c;同时使用其分组、折叠能力。分组包含固定分组、后台接口获取的动态分组和组件。 //固定分组初始化 initStencil (graph, stenc…

C语言——深入理解指针(5)

目录 1. sizeof和strlen的对比 1.1 sizeof 1.2 strlen 1.3 sizeof和strlen 的对比 2. 数据和指针题解析 2.1 一维数组 2.2 字符数组 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.2,6 2.3 二维数组 3. 指针运算题解析 3.1 例1 3.2 例2 3.3 例3 3.4 例4 3.5 例5 3.6 例…