基于SpringBoot+Vue的校园闲置物品租售管理系统设计与实现毕设(文档+源码)

        

目录

一、项目介绍

二、开发环境

三、功能介绍

四、核心代码

五、效果图

六、源码获取:


        大家好呀,我是一个混迹在java圈的码农。今天要和大家分享的是 一款基于SpringBoot+Vue的校园闲置物品租售管理系统,项目源码请点击文章末尾联系我哦~目前有各类成品 毕设 JavaWeb  SSM SpringBoot等等项目框架,源码丰富,欢迎咨询。 

一、项目介绍

        系统采用了Java技术,将所有业务模块采用以浏览器交互的模式,选择MySQL作为系统的数据库,开发工具选择My eclipse来进行系统的设计。基本实现了校园闲置物品租售系统应有的主要功能模块,本系统有管理员、卖家用户,管理员;首页、个人中心、用户管理、卖家管理、商品种类管理、商品信息管理商品租借管理商品购买管理闲置鱼塘、系统管理,用户;首页、个人中心、商品租借管理商品购买管理、我的收藏管理,卖家;首页、个人中心、商品种类管理、商品信息管理商品租借管理商品购买管理、我的收藏管理,前台首页;首页、商品信息、闲置鱼塘、校园资讯、个人中心、后台管理等操作。

        对系统进行测试后,改善了程序逻辑和代码。同时确保系统中所有的程序都能正常运行,所有的功能都能操作,并且该系统有很好的操作体验,实现了对于校园闲置物品租售系统校园商家双赢。

关键词:校园闲置物品租售系统Java语言; Mysql数据库;springboot框架 

二、开发环境

开发系统:Windows
JDK版本:Java JDK1.8(推荐)
开发工具:IDEA/MyEclipse(推荐IDEA)
数据库版本: mysql8.0(推荐)
数据库可视化工具: navicat
服务器:SpringBoot自带 apache tomcat
框架:springboot,vue

三、功能介绍

        校园闲置物品租售系统,在校园闲置物品租售系统可以查看首页、商品信息、闲置鱼塘、校园资讯、个人中心、后台管理等内容。管理员对卖家管理、商品种类、商品信息、商品租赁进行详情、删除、修改操作。用户进入系统可以对首页、个人中心、商品租借管理、商品购买管理、我的收藏管理进行相对应操作。卖家进入系统可以对首页、个人中心、商品种类管理、商品信息管理、商品租借管理、商品购买管理、我的收藏管理进行相对应操作。

四、核心代码


/**
 * 商品租借
 * 后端接口
 * @author 
 * @email 
 */
@RestController
@RequestMapping("/shangpinzujie")
public class ShangpinzujieController {
    @Autowired
    private ShangpinzujieService shangpinzujieService;
    


    /**
     * 后端列表
     */
    @RequestMapping("/page")
    public R page(@RequestParam Map<String, Object> params,ShangpinzujieEntity shangpinzujie, HttpServletRequest request){
		String tableName = request.getSession().getAttribute("tableName").toString();
		if(tableName.equals("maijia")) {
			shangpinzujie.setMaijiahao((String)request.getSession().getAttribute("username"));
		}
		if(tableName.equals("yonghu")) {
			shangpinzujie.setZhanghao((String)request.getSession().getAttribute("username"));
		}
        EntityWrapper<ShangpinzujieEntity> ew = new EntityWrapper<ShangpinzujieEntity>();
		PageUtils page = shangpinzujieService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, shangpinzujie), params), params));

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

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

	 /**
     * 查询
     */
    @RequestMapping("/query")
    public R query(ShangpinzujieEntity shangpinzujie){
        EntityWrapper< ShangpinzujieEntity> ew = new EntityWrapper< ShangpinzujieEntity>();
 		ew.allEq(MPUtil.allEQMapPre( shangpinzujie, "shangpinzujie")); 
		ShangpinzujieView shangpinzujieView =  shangpinzujieService.selectView(ew);
		return R.ok("查询商品租借成功").put("data", shangpinzujieView);
    }
	
    /**
     * 后端详情
     */
    @RequestMapping("/info/{id}")
    public R info(@PathVariable("id") Long id){
        ShangpinzujieEntity shangpinzujie = shangpinzujieService.selectById(id);
        return R.ok().put("data", shangpinzujie);
    }

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



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

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

    /**
     * 删除
     */
    @RequestMapping("/delete")
    public R delete(@RequestBody Long[] ids){
        shangpinzujieService.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<ShangpinzujieEntity> wrapper = new EntityWrapper<ShangpinzujieEntity>();
		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("maijia")) {
			wrapper.eq("maijiahao", (String)request.getSession().getAttribute("username"));
		}
		if(tableName.equals("yonghu")) {
			wrapper.eq("zhanghao", (String)request.getSession().getAttribute("username"));
		}

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


}

五、效果图

六、源码获取:

👇🏻获取联系方式在文章末尾👇🏻
有需要的伙伴可以点击下方名片,与我联系哦~

  • 8
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值