springboot/ssm校园菜鸟驿站管理系统Java校园快递取件管理系统

这篇具有很好参考价值的文章主要介绍了springboot/ssm校园菜鸟驿站管理系统Java校园快递取件管理系统。希望对大家有所帮助。如果存在错误或未考虑完全的地方,请大家不吝赐教,您也可以点击"举报违法"按钮提交疑问。

springboot/ssm校园菜鸟驿站管理系统Java校园快递取件管理系统

开发语言:Java

框架:springboot(可改ssm) + vue

JDK版本:JDK1.8(或11)

服务器:tomcat

数据库:mysql 5.7(或8.0)

数据库工具:Navicat

开发软件:eclipse//idea

依赖管理包:Maven

如需了解更多代码细节或修改代码功能界面,本人都能提供技术支持。(声音嘎嘎好听喔!)

祝你早日找到合适的代码哦~

注:主页千套源码&文档,文章最下方获取源码哦文章来源地址https://www.toymoban.com/news/detail-828267.html

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 com.utils.ValidatorUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
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.NewsEntity;
import com.entity.view.NewsView;

import com.service.NewsService;
import com.service.TokenService;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.MD5Util;
import com.utils.MPUtil;
import com.utils.CommonUtil;
import java.io.IOException;

/**
 * 后端接口
 * @author 
 * @email 
 * @date 2023-03-25 14:13:13
 */
@RestController
@RequestMapping("/news")
public class NewsController {
    @Autowired
    private NewsService newsService;


    


    /**
     * 后端列表
     */
    @RequestMapping("/page")
    public R page(@RequestParam Map<String, Object> params,NewsEntity news,
		HttpServletRequest request){
        EntityWrapper<NewsEntity> ew = new EntityWrapper<NewsEntity>();
		PageUtils page = newsService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, news), params), params));

        return R.ok().put("data", page);
    }
    
    /**
     * 前端列表
     */
	@IgnoreAuth
    @RequestMapping("/list")
    public R list(@RequestParam Map<String, Object> params,NewsEntity news, 
		HttpServletRequest request){
        EntityWrapper<NewsEntity> ew = new EntityWrapper<NewsEntity>();
		PageUtils page = newsService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, news), params), params));
        return R.ok().put("data", page);
    }

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

	 /**
     * 查询
     */
    @RequestMapping("/query")
    public R query(NewsEntity news){
        EntityWrapper< NewsEntity> ew = new EntityWrapper< NewsEntity>();
 		ew.allEq(MPUtil.allEQMapPre( news, "news")); 
		NewsView newsView =  newsService.selectView(ew);
		return R.ok("查询食堂资讯成功").put("data", newsView);
    }
	
    /**
     * 后端详情
     */
    @RequestMapping("/info/{id}")
    public R info(@PathVariable("id") Long id){
        NewsEntity news = newsService.selectById(id);
        return R.ok().put("data", news);
    }

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



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

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

    /**
     * 删除
     */
    @RequestMapping("/delete")
    public R delete(@RequestBody Long[] ids){
        newsService.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<NewsEntity> wrapper = new EntityWrapper<NewsEntity>();
		if(map.get("remindstart")!=null) {
			wrapper.ge(columnName, map.get("remindstart"));
		}
		if(map.get("remindend")!=null) {
			wrapper.le(columnName, map.get("remindend"));
		}


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

}

到了这里,关于springboot/ssm校园菜鸟驿站管理系统Java校园快递取件管理系统的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处: 如若内容造成侵权/违法违规/事实不符,请点击违法举报进行投诉反馈,一经查实,立即删除!

领支付宝红包 赞助服务器费用

相关文章

  • (附源码)基于SSM框架的校园宿舍管理系统 毕业设计241738

    SSM校园宿舍管理系统的设计与实现 摘 要 科技进步的飞速发展引起人们日常生活的巨大变化,电子信息技术的飞速发展使得电子信息技术的各个领域的应用水平得到普及和应用。信息时代的到来已成为不可阻挡的时尚潮流,人类发展的历史正进入一个新时代。在现实运用中,

    2024年02月02日
    浏览(29)
  • 基于JavaWeb+SSM+Vue校园水电费管理小程序系统的设计和实现

    摘 要 III Abstract 1 1 系统概述 2 1.1 概述 2 1.2课题意义 3 1.3 主要内容 3 2 系统开发环境 4 2.1微信开发者工具 4 2.2小程序框架以及目录结构介绍 5 2.3 JAVA简介 5 2.4 MySQL数据库 6 2.5 SSM框架 6 3 需求分析 6 3.1 系统设计目标 7 3.2需求分析概述 7 3.3 系统可行性分析 8 3.4经济可行性 8 3.5操作

    2024年02月04日
    浏览(30)
  • 基于springboot校园缴费管理系统

    博主主页 :猫头鹰源码 博主简介 :Java领域优质创作者、CSDN博客专家、公司架构师、全网粉丝5万+、专注Java技术领域和毕业设计项目实战 主要内容 :毕业设计(Javaweb项目|小程序等)、简历模板、学习资料、面试题库、技术咨询 文末联系获取 随着社会的不断发展和教育事业的

    2024年02月12日
    浏览(25)
  • springboot+vue校园宿舍管理系统

    《004.SpringBoot+vue之校园宿舍管理系统》 [1]本系统涉及到的技术主要如下: 推荐环境配置:DEA jdk1.8 Maven MySQL 前后端分离; 后台:SpringBoot+Mybatis+Redis; 前台:vue+ElementUI; [2]功能模块展示: 超级管理员 1.系统管理:用户管理、角色管理、菜单管理 2.学生宿舍管理 2.1.宿舍楼管理

    2024年02月03日
    浏览(73)
  • springboot(ssm仓库管理系统 wms智能仓储管理系统Java系统

    springboot(ssm仓库管理系统 wms智能仓储管理系统Java系统 开发语言:Java 框架:ssm/springboot + vue JDK版本:JDK1.8(或11) 服务器:tomcat 数据库:mysql 5.7(或8.0) 数据库工具:Navicat 开发软件:eclipse//idea 依赖管理包:Maven 如需了解更多代码细节或修改代码功能界面,本人都能提供技

    2024年01月18日
    浏览(31)
  • java+springboot+mysql校园跑腿管理系统

    项目介绍: 使用java+springboot+mysql开发的校园跑腿管理系统,系统包含超级管理员,系统管理员、用户角色,功能如下: 超级管理员:管理员管理;用户管理(充值);任务类型;任务管理;订单管理;充值管理;留言反馈;公告管理;修改个人信息;修改密码; 管理员:和

    2024年02月10日
    浏览(25)
  • springboot(ssm旅游信息管理系统 在线旅游系统 Java系统

    springboot(ssm旅游信息管理系统 在线旅游系统 Java系统 开发语言:Java 框架:ssm/springboot + vue JDK版本:JDK1.8(或11) 服务器:tomcat 数据库:mysql 5.7(或8.0) 数据库工具:Navicat 开发软件:eclipse//idea 依赖管理包:Maven 如需了解更多代码细节或修改代码功能界面,本人都能提供技

    2024年01月19日
    浏览(47)
  • springboot(ssm甘肃旅游管理系统 在线旅游景点管理系统 Java系统

    springboot(ssm甘肃旅游管理系统 在线旅游景点管理系统 Java系统 开发语言:Java 框架:ssm/springboot + vue JDK版本:JDK1.8(或11) 服务器:tomcat 数据库:mysql 5.7(或8.0) 数据库工具:Navicat 开发软件:eclipse//idea 依赖管理包:Maven 如需了解更多代码细节或修改代码功能界面,本人都

    2024年01月18日
    浏览(46)
  • N-130基于springboot,vue校园社团管理系统

    开发工具:IDEA 服务器:Tomcat9.0, jdk1.8 项目构建:maven 数据库:mysql5.7 系统分前后台,项目采用前后端分离 前端技术:vue+elementUI 服务端技术:springboot+mybatis-plus 本系统分学生、社长、管理员三个角色,功能如下: 一、学生(用户)功能包括:  1.登录、注册、首页、修改密码

    2024年02月08日
    浏览(30)
  • java+springboot+mysql校园通讯录管理系统

    项目介绍: 使用java+springboot+mysql开发的校园通讯录管理系统,系统包含超级管理员、管理员、用户角色,功能如下: 超级管理员:管理员管理;部门管理;用户管理;留言管理;公告管理;个人信息修改;密码修改。 管理员:比超级管理员少了一个管理员管理模块;其他的

    2024年02月13日
    浏览(25)

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

博客赞助

微信扫一扫打赏

请作者喝杯咖啡吧~博客赞助

支付宝扫一扫领取红包,优惠每天领

二维码1

领取红包

二维码2

领红包