package com.controller;
import java.math.BigDecimal;
import java.text.SimpleDateFormat;
import java.text.ParseException;
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.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.ChezilichangEntity;
import com.entity.view.ChezilichangView;
import com.service.ChezilichangService;
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-05-17 16:29:22
*/
@RestController
@RequestMapping("/chezilichang")
public class ChezilichangController {
@Autowired
private ChezilichangService chezilichangService;
/**
* 后端列表
*/
@RequestMapping("/page")
public R page(@RequestParam Map<String, Object> params,ChezilichangEntity chezilichang,
HttpServletRequest request){
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("yonghu")) {
chezilichang.setYonghuzhanghao((String)request.getSession().getAttribute("username"));
}
EntityWrapper<ChezilichangEntity> ew = new EntityWrapper<ChezilichangEntity>();
PageUtils page = chezilichangService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, chezilichang), params), params));
return R.ok().put("data", page);
}
/**
* 前端列表
*/
@IgnoreAuth
@RequestMapping("/list")
public R list(@RequestParam Map<String, Object> params,ChezilichangEntity chezilichang,
HttpServletRequest request){
EntityWrapper<ChezilichangEntity> ew = new EntityWrapper<ChezilichangEntity>();
PageUtils page = chezilichangService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, chezilichang), params), params));
return R.ok().put("data", page);
}
/**
* 列表
*/
@RequestMapping("/lists")
public R list( ChezilichangEntity chezilichang){
EntityWrapper<ChezilichangEntity> ew = new EntityWrapper<ChezilichangEntity>();
ew.allEq(MPUtil.allEQMapPre( chezilichang, "chezilichang"));
return R.ok().put("data", chezilichangService.selectListView(ew));
}
/**
* 查询
*/
@RequestMapping("/query")
public R query(ChezilichangEntity chezilichang){
EntityWrapper< ChezilichangEntity> ew = new EntityWrapper< ChezilichangEntity>();
ew.allEq(MPUtil.allEQMapPre( chezilichang, "chezilichang"));
ChezilichangView chezilichangView = chezilichangService.selectView(ew);
return R.ok("查询车子离场成功").put("data", chezilichangView);
}
/**
* 后端详情
*/
@RequestMapping("/info/{id}")
public R info(@PathVariable("id") Long id){
ChezilichangEntity chezilichang = chezilichangService.selectById(id);
return R.ok().put("data", chezilichang);
}
/**
* 前端详情
*/
@IgnoreAuth
@RequestMapping("/detail/{id}")
public R detail(@PathVariable("id") Long id){
ChezilichangEntity chezilichang = chezilichangService.selectById(id);
return R.ok().put("data", chezilichang);
}
/**
* 后端保存
*/
@RequestMapping("/save")
public R save(@RequestBody ChezilichangEntity chezilichang, HttpServletRequest request){
chezilichang.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(chezilichang);
chezilichangService.insert(chezilichang);
return R.ok();
}
/**
* 前端保存
*/
@RequestMapping("/add")
public R add(@RequestBody ChezilichangEntity chezilichang, HttpServletRequest request){
chezilichang.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(chezilichang);
chezilichangService.insert(chezilichang);
return R.ok();
}
/**
* 修改
*/
@RequestMapping("/update")
@Transactional
public R update(@RequestBody ChezilichangEntity chezilichang, HttpServletRequest request){
//ValidatorUtils.validateEntity(chezilichang);
chezilichangService.updateById(chezilichang);//全部更新
return R.ok();
}
/**
* 审核
*/
@RequestMapping("/shBatch")
@Transactional
public R update(@RequestBody Long[] ids, @RequestParam String sfsh, @RequestParam String shhf){
List<ChezilichangEntity> list = new ArrayList<ChezilichangEntity>();
for(Long id : ids) {
ChezilichangEntity chezilichang = chezilichangService.selectById(id);
chezilichang.setSfsh(sfsh);
chezilichang.setShhf(shhf);
list.add(chezilichang);
}
chezilichangService.updateBatchById(list);
return R.ok();
}
/**
* 删除
*/
@RequestMapping("/delete")
public R delete(@RequestBody Long[] ids){
chezilichangService.deleteBatchIds(Arrays.asList(ids));
return R.ok();
}
/**
* (按值统计)
*/
@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<ChezilichangEntity> ew = new EntityWrapper<ChezilichangEntity>();
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("yonghu")) {
ew.eq("yonghuzhanghao", (String)request.getSession().getAttribute("username"));
}
List<Map<String, Object>> result = chezilichangService.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("/valueMul/{xColumnName}")
public R valueMul(@PathVariable("xColumnName") String xColumnName,@RequestParam String yColumnNameMul, HttpServletRequest request) {
String[] yColumnNames = yColumnNameMul.split(",");
Map<String, Object> params = new HashMap<String, Object>();
params.put("xColumn", xColumnName);
List<List<Map<String, Object>>> result2 = new ArrayList<List<Map<String,Object>>>();
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
EntityWrapper<ChezilichangEntity> ew = ne
没有合适的资源?快使用搜索试试~ 我知道了~
智能停车计费-智能停车计费系统-智能停车计费系统源码-智能停车计费管理系统-基于Web的智能停车计费系统设计与实现-java代码
共601个文件
svg:161个
java:123个
vue:91个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 33 浏览量
2024-03-20
17:26:04
上传
评论
收藏 18.91MB ZIP 举报
温馨提示
智能停车计费-智能停车计费系统-智能停车计费系统源码-智能停车计费管理系统-智能停车计费管理系统java代码-智能停车计费系统设计与实现-基于springboot的智能停车计费系统-基于Web的智能停车计费系统设计与实现-智能停车计费网站-智能停车计费网站代码-智能停车计费平台-智能停车计费平台代码-智能停车计费项目-智能停车计费项目代码-智能停车计费代码 1、技术栈:java,springboot,vue,ajax,maven,mysql,MyBatisPlus等 开发语言:Java 框架:SpringBoot JDK版本:JDK1.8 数据库:mysql 5.7 数据库工具:SQLyog/Navicat 开发软件:eclipse/myeclipse/idea Maven包:Maven 浏览器:谷歌浏览器 2、系统的实现 用户信息 图片素材 视频素材 摘 要 I 目 录 III 第1章 绪论 1 1.1选题动因 1 1.2背景与意义 1 第2章 相关技术介绍 3 2.1 MySQL数据库 3 2.2 Vue前端技术 3 2.3 B/S架构模式 4 2.4 ElementUI介
资源推荐
资源详情
资源评论
收起资源包目录
智能停车计费-智能停车计费系统-智能停车计费系统源码-智能停车计费管理系统-基于Web的智能停车计费系统设计与实现-java代码 (601个子文件)
update-password.vue.bak 3KB
main.js.bak 2KB
IndexMain.vue.bak 2KB
IndexAsideStatic.vue.bak 2KB
BreadCrumbs.vue.bak 2KB
IndexHeader.vue.bak 2KB
3-build.bat 15B
2-run.bat 14B
build.bat 14B
run.bat 14B
1-install.bat 12B
install.bat 12B
.classpath 2KB
mvnw.cmd 7KB
app.0e0eb7df.css 326KB
chunk-vendors.1a58561a.css 242KB
app.66b79742.css 124KB
chunk-vendors.0fdd4e14.css 37KB
swiper.min.css 13KB
swiper.min.css 13KB
iconfont.css 622B
canvas-bg-1.css 391B
canvas-bg-1.css 391B
canvas-bg-2.css 83B
canvas-bg-2.css 83B
canvas-bg-4.css 61B
canvas-bg-5.css 61B
canvas-bg-3.css 61B
canvas-bg-3.css 61B
必读推荐.docx 15KB
.factorypath 15KB
.gitignore 364B
index.html 1KB
index.html 989B
index.html 815B
index.html 623B
favicon.ico 4KB
favicon.ico 4KB
favicon.ico 4KB
favicon.ico 4KB
maven-wrapper.jar 50KB
ChezilichangController.java 13KB
WeiguichufaController.java 13KB
BaiduUtil.java 8KB
CommonController.java 7KB
YonghuController.java 7KB
ChezilichangEntity.java 7KB
ChatController.java 6KB
ForumController.java 6KB
ChezilichangModel.java 6KB
ChezilichangVO.java 6KB
ChezijinchangEntity.java 6KB
ChezijinchangController.java 6KB
CheweifenleiController.java 5KB
CheweixinxiController.java 5KB
MessagesController.java 5KB
UsersController.java 5KB
MPUtil.java 5KB
MavenWrapperDownloader.java 5KB
NewsController.java 5KB
CheweixinxiEntity.java 5KB
ChezijinchangModel.java 4KB
WeiguichufaEntity.java 4KB
FileController.java 4KB
ChezijinchangVO.java 4KB
CommonUtil.java 4KB
ForumEntity.java 4KB
MessagesEntity.java 4KB
CheweixinxiModel.java 4KB
CheweixinxiVO.java 3KB
AuthorizationInterceptor.java 3KB
YonghuEntity.java 3KB
ConfigController.java 3KB
WeiguichufaModel.java 3KB
WeiguichufaVO.java 3KB
ChatEntity.java 3KB
NewsEntity.java 3KB
Query.java 3KB
ChezilichangServiceImpl.java 3KB
WeiguichufaServiceImpl.java 3KB
TokenServiceImpl.java 2KB
MessagesModel.java 2KB
ForumModel.java 2KB
MessagesVO.java 2KB
ForumVO.java 2KB
TokenEntity.java 2KB
CheweifenleiEntity.java 2KB
ChezijinchangServiceImpl.java 2KB
YonghuModel.java 2KB
CheweifenleiServiceImpl.java 2KB
PageUtils.java 2KB
CheweixinxiServiceImpl.java 2KB
YonghuVO.java 2KB
MessagesServiceImpl.java 2KB
YonghuServiceImpl.java 2KB
ForumServiceImpl.java 2KB
NewsServiceImpl.java 2KB
ChatServiceImpl.java 2KB
ChatModel.java 2KB
ChatVO.java 2KB
共 601 条
- 1
- 2
- 3
- 4
- 5
- 6
- 7
资源评论
十五喵
- 粉丝: 2728
- 资源: 2530
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功