开发OTA备案工具-车辆升级
This commit is contained in:
+20
@@ -7,6 +7,7 @@ import javax.servlet.http.HttpServletResponse;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.ota.entity.OtaBaSjGgnrfs;
|
||||
import com.jero.modules.ota.entity.OtaBaSjSjyxpg;
|
||||
import com.jero.modules.ota.service.IOtaBaSjGgnrfsService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
@@ -144,6 +145,25 @@ public class OtaBaSjGgnrfsController extends JeroController<OtaBaSjGgnrfs, IOtaB
|
||||
return Result.OK(otaBaSjGgnrfs);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 通过otaId查询
|
||||
*
|
||||
* @param otaId
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-用户告知内容及方式-通过otaId查询")
|
||||
@ApiOperation(value = "升级备案-用户告知内容及方式-通过otaId查询", notes = "升级备案-用户告知内容及方式-通过otaId查询")
|
||||
@GetMapping(value = "/queryByOtaId")
|
||||
public Result<?> queryByOtaId(@RequestParam(name = "otaId", required = true) String otaId,
|
||||
@RequestParam(name = "otaIdT", required = true) String otaIdT) {
|
||||
OtaBaSjGgnrfs otaBaSjGgnrfs = otaBaSjGgnrfsService.queryByOtaId(otaId, otaIdT);
|
||||
if (otaBaSjGgnrfs == null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(otaBaSjGgnrfs);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
|
||||
+170
@@ -0,0 +1,170 @@
|
||||
package com.jero.modules.ota.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.ota.entity.OtaBaSjGnxtwh;
|
||||
import com.jero.modules.ota.service.IOtaBaSjGnxtwhService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import com.jero.common.system.base.controller.JeroController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import com.jero.common.aspect.annotation.AutoLog;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 车型备案-功能系统维护
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="车型备案-功能系统维护")
|
||||
@RestController
|
||||
@RequestMapping("/ota/otaBaSjGnxtwh")
|
||||
@Slf4j
|
||||
public class OtaBaSjGnxtwhController extends JeroController<OtaBaSjGnxtwh, IOtaBaSjGnxtwhService> {
|
||||
@Autowired
|
||||
private IOtaBaSjGnxtwhService otaBaSjGnxtwhService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-分页列表查询")
|
||||
@ApiOperation(value="车型备案-功能系统维护-分页列表查询", notes="车型备案-功能系统维护-分页列表查询")
|
||||
@GetMapping(value = "/page")
|
||||
public Result<?> queryPageList(OtaBaSjGnxtwh otaBaSjGnxtwh,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<OtaBaSjGnxtwh> queryWrapper = QueryGenerator.initQueryWrapper(otaBaSjGnxtwh, req.getParameterMap());
|
||||
Page<OtaBaSjGnxtwh> page = new Page<OtaBaSjGnxtwh>(pageNo, pageSize);
|
||||
IPage<OtaBaSjGnxtwh> pageList = otaBaSjGnxtwhService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-列表查询")
|
||||
@ApiOperation(value="车型备案-功能系统维护-列表查询", notes="车型备案-功能系统维护-列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<List<OtaBaSjGnxtwh>> queryList() {
|
||||
List<OtaBaSjGnxtwh> list = otaBaSjGnxtwhService.queryList();
|
||||
return Result.OK(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-添加")
|
||||
@ApiOperation(value="车型备案-功能系统维护-添加", notes="车型备案-功能系统维护-添加")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<?> add(@Validated @RequestBody OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
otaBaSjGnxtwhService.add(otaBaSjGnxtwh);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-编辑")
|
||||
@ApiOperation(value="车型备案-功能系统维护-编辑", notes="车型备案-功能系统维护-编辑")
|
||||
@PutMapping(value = "/edit")
|
||||
public Result<?> edit(@Validated @RequestBody OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
otaBaSjGnxtwhService.editById(otaBaSjGnxtwh);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-通过id删除")
|
||||
@ApiOperation(value="车型备案-功能系统维护-通过id删除", notes="车型备案-功能系统维护-通过id删除")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
|
||||
otaBaSjGnxtwhService.deleteById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-批量删除")
|
||||
@ApiOperation(value="车型备案-功能系统维护-批量删除", notes="车型备案-功能系统维护-批量删除")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.otaBaSjGnxtwhService.deleteByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "车型备案-功能系统维护-通过id查询")
|
||||
@ApiOperation(value="车型备案-功能系统维护-通过id查询", notes="车型备案-功能系统维护-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
OtaBaSjGnxtwh otaBaSjGnxtwh = otaBaSjGnxtwhService.queryById(id);
|
||||
if(otaBaSjGnxtwh==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(otaBaSjGnxtwh);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param otaBaSjGnxtwh
|
||||
*/
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
return super.exportXls(request, otaBaSjGnxtwh, OtaBaSjGnxtwh.class, "车型备案-功能系统维护");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, OtaBaSjGnxtwh.class);
|
||||
}
|
||||
|
||||
}
|
||||
+170
@@ -0,0 +1,170 @@
|
||||
package com.jero.modules.ota.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssj;
|
||||
import com.jero.modules.ota.service.IOtaBaSjJssjService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import com.jero.common.system.base.controller.JeroController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import com.jero.common.aspect.annotation.AutoLog;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="升级备案-结束升级")
|
||||
@RestController
|
||||
@RequestMapping("/ota/otaBaSjJssj")
|
||||
@Slf4j
|
||||
public class OtaBaSjJssjController extends JeroController<OtaBaSjJssj, IOtaBaSjJssjService> {
|
||||
@Autowired
|
||||
private IOtaBaSjJssjService otaBaSjJssjService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param otaBaSjJssj
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级-分页列表查询")
|
||||
@ApiOperation(value="升级备案-结束升级-分页列表查询", notes="升级备案-结束升级-分页列表查询")
|
||||
@GetMapping(value = "/page")
|
||||
public Result<?> queryPageList(OtaBaSjJssj otaBaSjJssj,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<OtaBaSjJssj> queryWrapper = QueryGenerator.initQueryWrapper(otaBaSjJssj, req.getParameterMap());
|
||||
Page<OtaBaSjJssj> page = new Page<OtaBaSjJssj>(pageNo, pageSize);
|
||||
IPage<OtaBaSjJssj> pageList = otaBaSjJssjService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级-列表查询")
|
||||
@ApiOperation(value="升级备案-结束升级-列表查询", notes="升级备案-结束升级-列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<List<OtaBaSjJssj>> queryList() {
|
||||
List<OtaBaSjJssj> list = otaBaSjJssjService.queryList();
|
||||
return Result.OK(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param otaBaSjJssj
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级-添加")
|
||||
@ApiOperation(value="升级备案-结束升级-添加", notes="升级备案-结束升级-添加")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<?> add(@Validated @RequestBody OtaBaSjJssj otaBaSjJssj) {
|
||||
otaBaSjJssjService.add(otaBaSjJssj);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param otaBaSjJssj
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级-编辑")
|
||||
@ApiOperation(value="升级备案-结束升级-编辑", notes="升级备案-结束升级-编辑")
|
||||
@PutMapping(value = "/edit")
|
||||
public Result<?> edit(@Validated @RequestBody OtaBaSjJssj otaBaSjJssj) {
|
||||
otaBaSjJssjService.editById(otaBaSjJssj);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级-通过id删除")
|
||||
@ApiOperation(value="升级备案-结束升级-通过id删除", notes="升级备案-结束升级-通过id删除")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
|
||||
otaBaSjJssjService.deleteById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级-批量删除")
|
||||
@ApiOperation(value="升级备案-结束升级-批量删除", notes="升级备案-结束升级-批量删除")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.otaBaSjJssjService.deleteByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级-通过id查询")
|
||||
@ApiOperation(value="升级备案-结束升级-通过id查询", notes="升级备案-结束升级-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
OtaBaSjJssj otaBaSjJssj = otaBaSjJssjService.queryById(id);
|
||||
if(otaBaSjJssj==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(otaBaSjJssj);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param otaBaSjJssj
|
||||
*/
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, OtaBaSjJssj otaBaSjJssj) {
|
||||
return super.exportXls(request, otaBaSjJssj, OtaBaSjJssj.class, "升级备案-结束升级");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, OtaBaSjJssj.class);
|
||||
}
|
||||
|
||||
}
|
||||
+170
@@ -0,0 +1,170 @@
|
||||
package com.jero.modules.ota.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssjyy;
|
||||
import com.jero.modules.ota.service.IOtaBaSjJssjyyService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import com.jero.common.system.base.controller.JeroController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import com.jero.common.aspect.annotation.AutoLog;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级原因
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="升级备案-结束升级原因")
|
||||
@RestController
|
||||
@RequestMapping("/ota/otaBaSjJssjyy")
|
||||
@Slf4j
|
||||
public class OtaBaSjJssjyyController extends JeroController<OtaBaSjJssjyy, IOtaBaSjJssjyyService> {
|
||||
@Autowired
|
||||
private IOtaBaSjJssjyyService otaBaSjJssjyyService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param otaBaSjJssjyy
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级原因-分页列表查询")
|
||||
@ApiOperation(value="升级备案-结束升级原因-分页列表查询", notes="升级备案-结束升级原因-分页列表查询")
|
||||
@GetMapping(value = "/page")
|
||||
public Result<?> queryPageList(OtaBaSjJssjyy otaBaSjJssjyy,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<OtaBaSjJssjyy> queryWrapper = QueryGenerator.initQueryWrapper(otaBaSjJssjyy, req.getParameterMap());
|
||||
Page<OtaBaSjJssjyy> page = new Page<OtaBaSjJssjyy>(pageNo, pageSize);
|
||||
IPage<OtaBaSjJssjyy> pageList = otaBaSjJssjyyService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级原因-列表查询")
|
||||
@ApiOperation(value="升级备案-结束升级原因-列表查询", notes="升级备案-结束升级原因-列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<List<OtaBaSjJssjyy>> queryList() {
|
||||
List<OtaBaSjJssjyy> list = otaBaSjJssjyyService.queryList();
|
||||
return Result.OK(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param otaBaSjJssjyy
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级原因-添加")
|
||||
@ApiOperation(value="升级备案-结束升级原因-添加", notes="升级备案-结束升级原因-添加")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<?> add(@Validated @RequestBody OtaBaSjJssjyy otaBaSjJssjyy) {
|
||||
otaBaSjJssjyyService.add(otaBaSjJssjyy);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param otaBaSjJssjyy
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级原因-编辑")
|
||||
@ApiOperation(value="升级备案-结束升级原因-编辑", notes="升级备案-结束升级原因-编辑")
|
||||
@PutMapping(value = "/edit")
|
||||
public Result<?> edit(@Validated @RequestBody OtaBaSjJssjyy otaBaSjJssjyy) {
|
||||
otaBaSjJssjyyService.editById(otaBaSjJssjyy);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级原因-通过id删除")
|
||||
@ApiOperation(value="升级备案-结束升级原因-通过id删除", notes="升级备案-结束升级原因-通过id删除")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
|
||||
otaBaSjJssjyyService.deleteById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级原因-批量删除")
|
||||
@ApiOperation(value="升级备案-结束升级原因-批量删除", notes="升级备案-结束升级原因-批量删除")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.otaBaSjJssjyyService.deleteByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "升级备案-结束升级原因-通过id查询")
|
||||
@ApiOperation(value="升级备案-结束升级原因-通过id查询", notes="升级备案-结束升级原因-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
OtaBaSjJssjyy otaBaSjJssjyy = otaBaSjJssjyyService.queryById(id);
|
||||
if(otaBaSjJssjyy==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(otaBaSjJssjyy);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param otaBaSjJssjyy
|
||||
*/
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, OtaBaSjJssjyy otaBaSjJssjyy) {
|
||||
return super.exportXls(request, otaBaSjJssjyy, OtaBaSjJssjyy.class, "升级备案-结束升级原因");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, OtaBaSjJssjyy.class);
|
||||
}
|
||||
|
||||
}
|
||||
+16
@@ -6,6 +6,7 @@ import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.ota.entity.OtaBaCxQt;
|
||||
import com.jero.modules.ota.entity.OtaBaSjQtsjxx;
|
||||
import com.jero.modules.ota.service.IOtaBaSjQtsjxxService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
@@ -144,6 +145,21 @@ public class OtaBaSjQtsjxxController extends JeroController<OtaBaSjQtsjxx, IOtaB
|
||||
return Result.OK(otaBaSjQtsjxx);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过otaId查询
|
||||
*/
|
||||
@AutoLog(value = "车型备案-其他升级信息-通过otaId查询")
|
||||
@ApiOperation(value = "车型备案-其他升级信息-通过otaId查询", notes = "车型备案-其他升级信息-通过otaId查询")
|
||||
@GetMapping(value = "/queryByOtaId")
|
||||
public Result<?> queryByOtaId(@RequestParam(name = "otaId", required = true) String otaId,
|
||||
@RequestParam(name = "otaIdT", required = true) String otaIdT) {
|
||||
OtaBaSjQtsjxx otaBaSjQtsjxx = otaBaSjQtsjxxService.queryByOtaId(otaId, otaIdT);
|
||||
if (otaBaSjQtsjxx == null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(otaBaSjQtsjxx);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
|
||||
+74
@@ -0,0 +1,74 @@
|
||||
package com.jero.modules.ota.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.math.BigDecimal;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||
import com.jero.common.aspect.annotation.Dict;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 车型备案-功能系统维护
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("ota_ba_sj_gnxtwh")
|
||||
@Accessors(chain = true)
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@ApiModel(value="ota_ba_sj_gnxtwh对象", description="车型备案-功能系统维护")
|
||||
public class OtaBaSjGnxtwh implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**主键*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private String id;
|
||||
|
||||
/**创建人*/
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String createBy;
|
||||
|
||||
/**创建日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
private java.util.Date createTime;
|
||||
|
||||
/**更新人*/
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private String updateBy;
|
||||
|
||||
/**更新日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "更新日期")
|
||||
private java.util.Date updateTime;
|
||||
|
||||
/**所属部门*/
|
||||
@ApiModelProperty(value = "所属部门")
|
||||
private String sysOrgCode;
|
||||
|
||||
/**功能系统*/
|
||||
@Excel(name = "功能系统", width = 15)
|
||||
@ApiModelProperty(value = "功能系统")
|
||||
private String gnxt;
|
||||
|
||||
/**对应控制器*/
|
||||
@Excel(name = "对应控制器", width = 15)
|
||||
@ApiModelProperty(value = "对应控制器")
|
||||
private String dykzq;
|
||||
|
||||
}
|
||||
+94
@@ -0,0 +1,94 @@
|
||||
package com.jero.modules.ota.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.math.BigDecimal;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||
import com.jero.common.aspect.annotation.Dict;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("ota_ba_sj_jssj")
|
||||
@Accessors(chain = true)
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@ApiModel(value="ota_ba_sj_jssj对象", description="升级备案-结束升级")
|
||||
public class OtaBaSjJssj implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**主键*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private String id;
|
||||
|
||||
/**创建人*/
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String createBy;
|
||||
|
||||
/**创建日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
private java.util.Date createTime;
|
||||
|
||||
/**更新人*/
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private String updateBy;
|
||||
|
||||
/**更新日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "更新日期")
|
||||
private java.util.Date updateTime;
|
||||
|
||||
/**所属部门*/
|
||||
@ApiModelProperty(value = "所属部门")
|
||||
private String sysOrgCode;
|
||||
|
||||
/**otaId*/
|
||||
@Excel(name = "otaId", width = 15)
|
||||
@ApiModelProperty(value = "otaId")
|
||||
private String otaid;
|
||||
|
||||
/**实施的升级是否和备案一致*/
|
||||
@Excel(name = "实施的升级是否和备案一致", width = 15)
|
||||
@ApiModelProperty(value = "实施的升级是否和备案一致")
|
||||
private Integer sfyz;
|
||||
|
||||
/**完成升级的车辆数*/
|
||||
@Excel(name = "完成升级的车辆数", width = 15)
|
||||
@ApiModelProperty(value = "完成升级的车辆数")
|
||||
private String wccls;
|
||||
|
||||
/**VIN码清单*/
|
||||
@Excel(name = "VIN码清单", width = 15)
|
||||
@ApiModelProperty(value = "VIN码清单")
|
||||
private String csv;
|
||||
|
||||
/**故障处置措施和应急响应实施记录*/
|
||||
@Excel(name = "故障处置措施和应急响应实施记录", width = 15)
|
||||
@ApiModelProperty(value = "故障处置措施和应急响应实施记录")
|
||||
private String ssjl;
|
||||
|
||||
/**故障处置措施和应急响应实施记录附件*/
|
||||
@Excel(name = "故障处置措施和应急响应实施记录附件", width = 15)
|
||||
@ApiModelProperty(value = "故障处置措施和应急响应实施记录附件")
|
||||
private String ssjlfj;
|
||||
|
||||
}
|
||||
+84
@@ -0,0 +1,84 @@
|
||||
package com.jero.modules.ota.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.math.BigDecimal;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||
import com.jero.common.aspect.annotation.Dict;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级原因
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("ota_ba_sj_jssjyy")
|
||||
@Accessors(chain = true)
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@ApiModel(value="ota_ba_sj_jssjyy对象", description="升级备案-结束升级原因")
|
||||
public class OtaBaSjJssjyy implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**主键*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private String id;
|
||||
|
||||
/**创建人*/
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String createBy;
|
||||
|
||||
/**创建日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
private java.util.Date createTime;
|
||||
|
||||
/**更新人*/
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private String updateBy;
|
||||
|
||||
/**更新日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "更新日期")
|
||||
private java.util.Date updateTime;
|
||||
|
||||
/**所属部门*/
|
||||
@ApiModelProperty(value = "所属部门")
|
||||
private String sysOrgCode;
|
||||
|
||||
/**otaId*/
|
||||
@Excel(name = "otaId", width = 15)
|
||||
@ApiModelProperty(value = "otaId")
|
||||
private String otaid;
|
||||
|
||||
/**未完成原因*/
|
||||
@Excel(name = "未完成原因", width = 15)
|
||||
@ApiModelProperty(value = "未完成原因")
|
||||
private String wwcyy;
|
||||
|
||||
/**未完成数量*/
|
||||
@Excel(name = "未完成数量", width = 15)
|
||||
@ApiModelProperty(value = "未完成数量")
|
||||
private String wwcsl;
|
||||
|
||||
/**未完成附件*/
|
||||
@Excel(name = "未完成附件", width = 15)
|
||||
@ApiModelProperty(value = "未完成附件")
|
||||
private String wwcfj;
|
||||
|
||||
}
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
package com.jero.modules.ota.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.jero.modules.ota.entity.OtaBaSjGnxtwh;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: 车型备案-功能系统维护
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface OtaBaSjGnxtwhMapper extends BaseMapper<OtaBaSjGnxtwh> {
|
||||
|
||||
}
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
package com.jero.modules.ota.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssj;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface OtaBaSjJssjMapper extends BaseMapper<OtaBaSjJssj> {
|
||||
|
||||
}
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
package com.jero.modules.ota.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssjyy;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级原因
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface OtaBaSjJssjyyMapper extends BaseMapper<OtaBaSjJssjyy> {
|
||||
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.jero.modules.ota.mapper.OtaBaSjGnxtwhMapper">
|
||||
<resultMap id="OtaBaSjGnxtwhResultMap" type="com.jero.modules.ota.entity.OtaBaSjGnxtwh">
|
||||
<id column="id" property="id" />
|
||||
<result column="create_by" property="createBy" />
|
||||
<result column="create_time" property="createTime" />
|
||||
<result column="update_by" property="updateBy" />
|
||||
<result column="update_time" property="updateTime" />
|
||||
<result column="sys_org_code" property="sysOrgCode" />
|
||||
<result column="gnxt" property="gnxt" />
|
||||
<result column="dykzq" property="dykzq" />
|
||||
</resultMap>
|
||||
</mapper>
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.jero.modules.ota.mapper.OtaBaSjJssjMapper">
|
||||
<resultMap id="OtaBaSjJssjResultMap" type="com.jero.modules.ota.entity.OtaBaSjJssj">
|
||||
<id column="id" property="id" />
|
||||
<result column="create_by" property="createBy" />
|
||||
<result column="create_time" property="createTime" />
|
||||
<result column="update_by" property="updateBy" />
|
||||
<result column="update_time" property="updateTime" />
|
||||
<result column="sys_org_code" property="sysOrgCode" />
|
||||
<result column="otaid" property="otaid" />
|
||||
<result column="sfyz" property="sfyz" />
|
||||
<result column="wccls" property="wccls" />
|
||||
<result column="csv" property="csv" />
|
||||
<result column="ssjl" property="ssjl" />
|
||||
<result column="ssjlfj" property="ssjlfj" />
|
||||
</resultMap>
|
||||
</mapper>
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.jero.modules.ota.mapper.OtaBaSjJssjyyMapper">
|
||||
<resultMap id="OtaBaSjJssjyyResultMap" type="com.jero.modules.ota.entity.OtaBaSjJssjyy">
|
||||
<id column="id" property="id" />
|
||||
<result column="create_by" property="createBy" />
|
||||
<result column="create_time" property="createTime" />
|
||||
<result column="update_by" property="updateBy" />
|
||||
<result column="update_time" property="updateTime" />
|
||||
<result column="sys_org_code" property="sysOrgCode" />
|
||||
<result column="otaid" property="otaid" />
|
||||
<result column="wwcyy" property="wwcyy" />
|
||||
<result column="wwcsl" property="wwcsl" />
|
||||
<result column="wwcfj" property="wwcfj" />
|
||||
</resultMap>
|
||||
</mapper>
|
||||
+2
@@ -58,4 +58,6 @@ public interface IOtaBaSjGgnrfsService extends IService<OtaBaSjGgnrfs> {
|
||||
* @return
|
||||
*/
|
||||
List<OtaBaSjGgnrfs> queryList();
|
||||
|
||||
OtaBaSjGgnrfs queryByOtaId(String otaId, String otaIdT);
|
||||
}
|
||||
|
||||
+61
@@ -0,0 +1,61 @@
|
||||
package com.jero.modules.ota.service;
|
||||
|
||||
import com.jero.modules.ota.entity.OtaBaSjGnxtwh;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 车型备案-功能系统维护
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface IOtaBaSjGnxtwhService extends IService<OtaBaSjGnxtwh> {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
void add(OtaBaSjGnxtwh otaBaSjGnxtwh);
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
void editById(OtaBaSjGnxtwh otaBaSjGnxtwh);
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
void deleteById(String id);
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
void deleteByIds(List<String> ids);
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
OtaBaSjGnxtwh queryById(String id);
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
List<OtaBaSjGnxtwh> queryList();
|
||||
}
|
||||
+61
@@ -0,0 +1,61 @@
|
||||
package com.jero.modules.ota.service;
|
||||
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssj;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface IOtaBaSjJssjService extends IService<OtaBaSjJssj> {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjJssj
|
||||
* @return
|
||||
*/
|
||||
void add(OtaBaSjJssj otaBaSjJssj);
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjJssj
|
||||
* @return
|
||||
*/
|
||||
void editById(OtaBaSjJssj otaBaSjJssj);
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
void deleteById(String id);
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
void deleteByIds(List<String> ids);
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
OtaBaSjJssj queryById(String id);
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
List<OtaBaSjJssj> queryList();
|
||||
}
|
||||
+61
@@ -0,0 +1,61 @@
|
||||
package com.jero.modules.ota.service;
|
||||
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssjyy;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级原因
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface IOtaBaSjJssjyyService extends IService<OtaBaSjJssjyy> {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjJssjyy
|
||||
* @return
|
||||
*/
|
||||
void add(OtaBaSjJssjyy otaBaSjJssjyy);
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjJssjyy
|
||||
* @return
|
||||
*/
|
||||
void editById(OtaBaSjJssjyy otaBaSjJssjyy);
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
void deleteById(String id);
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
void deleteByIds(List<String> ids);
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
OtaBaSjJssjyy queryById(String id);
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
List<OtaBaSjJssjyy> queryList();
|
||||
}
|
||||
+3
@@ -1,5 +1,6 @@
|
||||
package com.jero.modules.ota.service;
|
||||
|
||||
import com.jero.modules.ota.entity.OtaBaCxQt;
|
||||
import com.jero.modules.ota.entity.OtaBaSjQtsjxx;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.List;
|
||||
@@ -58,4 +59,6 @@ public interface IOtaBaSjQtsjxxService extends IService<OtaBaSjQtsjxx> {
|
||||
* @return
|
||||
*/
|
||||
List<OtaBaSjQtsjxx> queryList();
|
||||
|
||||
OtaBaSjQtsjxx queryByOtaId(String otaId, String otaIdT);
|
||||
}
|
||||
|
||||
+97
-46
@@ -1,89 +1,140 @@
|
||||
package com.jero.modules.ota.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.jero.modules.ota.entity.AttachmentEO;
|
||||
import com.jero.modules.ota.entity.OtaBaCxAqcs;
|
||||
import com.jero.modules.ota.entity.OtaBaCxTxjl;
|
||||
import com.jero.modules.ota.entity.OtaBaSjGgnrfs;
|
||||
import com.jero.modules.ota.enums.OtaModuleEnum;
|
||||
import com.jero.modules.ota.mapper.OtaBaSjGgnrfsMapper;
|
||||
import com.jero.modules.ota.service.IOtaBaCxTxjlService;
|
||||
import com.jero.modules.ota.service.IOtaBaSjGgnrfsService;
|
||||
import com.jero.modules.ota.utils.ComparisonUtil;
|
||||
import com.jero.modules.system.service.ISysDictService;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-用户告知内容及方式
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-17
|
||||
* @Date: 2023-03-17
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class OtaBaSjGgnrfsServiceImpl extends ServiceImpl<OtaBaSjGgnrfsMapper, OtaBaSjGgnrfs> implements IOtaBaSjGgnrfsService {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjGgnrfs
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
|
||||
@Autowired
|
||||
private IOtaBaCxTxjlService otaBaCxTxjlService;
|
||||
|
||||
@Autowired
|
||||
private ISysDictService sysDictService;
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjGgnrfs
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void add(OtaBaSjGgnrfs otaBaSjGgnrfs) {
|
||||
Date now = new Date();
|
||||
otaBaSjGgnrfs.setCreateTime(now);
|
||||
otaBaSjGgnrfs.setUpdateTime(now);
|
||||
save(otaBaSjGgnrfs);
|
||||
if (null != otaBaSjGgnrfs) {
|
||||
OtaBaSjGgnrfs otaBaSjGgnrfsOld = this.getByOtaId(otaBaSjGgnrfs.getOtaId());
|
||||
if (null != otaBaSjGgnrfsOld) {
|
||||
otaBaSjGgnrfs.setId(otaBaSjGgnrfsOld.getId());
|
||||
} else {
|
||||
otaBaSjGgnrfs.setCreateTime(now);
|
||||
}
|
||||
otaBaSjGgnrfs.setUpdateTime(now);
|
||||
saveOrUpdate(otaBaSjGgnrfs);
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
if (ObjectUtils.isEmpty(otaBaSjGgnrfsOld)) {
|
||||
otaBaSjGgnrfsOld = new OtaBaSjGgnrfs();
|
||||
}
|
||||
List<OtaBaCxTxjl> reList = cu.comparisonRecord(otaBaSjGgnrfs.getOtaId(), OtaModuleEnum.SJ_YHGZNRFS, otaBaSjGgnrfsOld, otaBaSjGgnrfs, sysDictService);
|
||||
otaBaCxTxjlService.saveBatch(reList);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjGgnrfs
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjGgnrfs
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void editById(OtaBaSjGgnrfs otaBaSjGgnrfs) {
|
||||
Date now = new Date();
|
||||
Date now = new Date();
|
||||
otaBaSjGgnrfs.setUpdateTime(now);
|
||||
saveOrUpdate(otaBaSjGgnrfs);
|
||||
saveOrUpdate(otaBaSjGgnrfs);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteByIds(List<String> ids) {
|
||||
removeByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public OtaBaSjGgnrfs queryById(String id) {
|
||||
return getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<OtaBaSjGgnrfs> queryList() {
|
||||
return list();
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaSjGgnrfs queryByOtaId(String otaId, String otaIdT) {
|
||||
OtaBaSjGgnrfs res = getByOtaId(otaId);
|
||||
if (ObjectUtils.isEmpty(res)) {
|
||||
res = getByOtaId(otaIdT);
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
private OtaBaSjGgnrfs getByOtaId(String otaId) {
|
||||
if (org.apache.commons.lang3.StringUtils.isEmpty(otaId)) {
|
||||
return null;
|
||||
}
|
||||
LambdaQueryWrapper<OtaBaSjGgnrfs> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.eq(OtaBaSjGgnrfs::getOtaId, otaId);
|
||||
return this.getOne(queryWrapper, false);
|
||||
}
|
||||
}
|
||||
|
||||
+89
@@ -0,0 +1,89 @@
|
||||
package com.jero.modules.ota.service.impl;
|
||||
|
||||
import com.jero.modules.ota.entity.OtaBaSjGnxtwh;
|
||||
import com.jero.modules.ota.mapper.OtaBaSjGnxtwhMapper;
|
||||
import com.jero.modules.ota.service.IOtaBaSjGnxtwhService;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.List;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: 车型备案-功能系统维护
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class OtaBaSjGnxtwhServiceImpl extends ServiceImpl<OtaBaSjGnxtwhMapper, OtaBaSjGnxtwh> implements IOtaBaSjGnxtwhService {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void add(OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
Date now = new Date();
|
||||
otaBaSjGnxtwh.setCreateTime(now);
|
||||
otaBaSjGnxtwh.setUpdateTime(now);
|
||||
save(otaBaSjGnxtwh);
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjGnxtwh
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void editById(OtaBaSjGnxtwh otaBaSjGnxtwh) {
|
||||
Date now = new Date();
|
||||
otaBaSjGnxtwh.setUpdateTime(now);
|
||||
saveOrUpdate(otaBaSjGnxtwh);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteByIds(List<String> ids) {
|
||||
removeByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public OtaBaSjGnxtwh queryById(String id) {
|
||||
return getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<OtaBaSjGnxtwh> queryList() {
|
||||
return list();
|
||||
}
|
||||
}
|
||||
+89
@@ -0,0 +1,89 @@
|
||||
package com.jero.modules.ota.service.impl;
|
||||
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssj;
|
||||
import com.jero.modules.ota.mapper.OtaBaSjJssjMapper;
|
||||
import com.jero.modules.ota.service.IOtaBaSjJssjService;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.List;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class OtaBaSjJssjServiceImpl extends ServiceImpl<OtaBaSjJssjMapper, OtaBaSjJssj> implements IOtaBaSjJssjService {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjJssj
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void add(OtaBaSjJssj otaBaSjJssj) {
|
||||
Date now = new Date();
|
||||
otaBaSjJssj.setCreateTime(now);
|
||||
otaBaSjJssj.setUpdateTime(now);
|
||||
save(otaBaSjJssj);
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjJssj
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void editById(OtaBaSjJssj otaBaSjJssj) {
|
||||
Date now = new Date();
|
||||
otaBaSjJssj.setUpdateTime(now);
|
||||
saveOrUpdate(otaBaSjJssj);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteByIds(List<String> ids) {
|
||||
removeByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public OtaBaSjJssj queryById(String id) {
|
||||
return getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<OtaBaSjJssj> queryList() {
|
||||
return list();
|
||||
}
|
||||
}
|
||||
+89
@@ -0,0 +1,89 @@
|
||||
package com.jero.modules.ota.service.impl;
|
||||
|
||||
import com.jero.modules.ota.entity.OtaBaSjJssjyy;
|
||||
import com.jero.modules.ota.mapper.OtaBaSjJssjyyMapper;
|
||||
import com.jero.modules.ota.service.IOtaBaSjJssjyyService;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.List;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-结束升级原因
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-28
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class OtaBaSjJssjyyServiceImpl extends ServiceImpl<OtaBaSjJssjyyMapper, OtaBaSjJssjyy> implements IOtaBaSjJssjyyService {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjJssjyy
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void add(OtaBaSjJssjyy otaBaSjJssjyy) {
|
||||
Date now = new Date();
|
||||
otaBaSjJssjyy.setCreateTime(now);
|
||||
otaBaSjJssjyy.setUpdateTime(now);
|
||||
save(otaBaSjJssjyy);
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjJssjyy
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void editById(OtaBaSjJssjyy otaBaSjJssjyy) {
|
||||
Date now = new Date();
|
||||
otaBaSjJssjyy.setUpdateTime(now);
|
||||
saveOrUpdate(otaBaSjJssjyy);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteByIds(List<String> ids) {
|
||||
removeByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public OtaBaSjJssjyy queryById(String id) {
|
||||
return getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<OtaBaSjJssjyy> queryList() {
|
||||
return list();
|
||||
}
|
||||
}
|
||||
+94
-46
@@ -1,89 +1,137 @@
|
||||
package com.jero.modules.ota.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.jero.modules.ota.entity.OtaBaCxQt;
|
||||
import com.jero.modules.ota.entity.OtaBaCxTxjl;
|
||||
import com.jero.modules.ota.entity.OtaBaSjQtsjxx;
|
||||
import com.jero.modules.ota.enums.OtaModuleEnum;
|
||||
import com.jero.modules.ota.mapper.OtaBaSjQtsjxxMapper;
|
||||
import com.jero.modules.ota.service.IOtaBaCxTxjlService;
|
||||
import com.jero.modules.ota.service.IOtaBaSjQtsjxxService;
|
||||
import com.jero.modules.ota.utils.ComparisonUtil;
|
||||
import com.jero.modules.system.service.ISysDictService;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: 升级备案-其他升级信息
|
||||
* @Author: jero-boot
|
||||
* @Date: 2023-03-17
|
||||
* @Date: 2023-03-17
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class OtaBaSjQtsjxxServiceImpl extends ServiceImpl<OtaBaSjQtsjxxMapper, OtaBaSjQtsjxx> implements IOtaBaSjQtsjxxService {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjQtsjxx
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
@Autowired
|
||||
private IOtaBaCxTxjlService otaBaCxTxjlService;
|
||||
|
||||
@Autowired
|
||||
private ISysDictService sysDictService;
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param otaBaSjQtsjxx
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void add(OtaBaSjQtsjxx otaBaSjQtsjxx) {
|
||||
Date now = new Date();
|
||||
otaBaSjQtsjxx.setCreateTime(now);
|
||||
otaBaSjQtsjxx.setUpdateTime(now);
|
||||
save(otaBaSjQtsjxx);
|
||||
if (null != otaBaSjQtsjxx) {
|
||||
OtaBaSjQtsjxx otaBaSjQtsjxxOld = this.getByOtaId(otaBaSjQtsjxx.getOtaId());
|
||||
if (null != otaBaSjQtsjxxOld) {
|
||||
otaBaSjQtsjxx.setId(otaBaSjQtsjxxOld.getId());
|
||||
} else {
|
||||
otaBaSjQtsjxx.setCreateTime(now);
|
||||
}
|
||||
otaBaSjQtsjxx.setUpdateTime(now);
|
||||
saveOrUpdate(otaBaSjQtsjxx);
|
||||
ComparisonUtil cu = new ComparisonUtil();
|
||||
if (ObjectUtils.isEmpty(otaBaSjQtsjxxOld)) {
|
||||
otaBaSjQtsjxxOld = new OtaBaSjQtsjxx();
|
||||
}
|
||||
List<OtaBaCxTxjl> reList = cu.comparisonRecord(otaBaSjQtsjxx.getOtaId(), OtaModuleEnum.CX_QT, otaBaSjQtsjxxOld, otaBaSjQtsjxx, sysDictService);
|
||||
otaBaCxTxjlService.saveBatch(reList);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjQtsjxx
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param otaBaSjQtsjxx
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void editById(OtaBaSjQtsjxx otaBaSjQtsjxx) {
|
||||
Date now = new Date();
|
||||
Date now = new Date();
|
||||
otaBaSjQtsjxx.setUpdateTime(now);
|
||||
saveOrUpdate(otaBaSjQtsjxx);
|
||||
saveOrUpdate(otaBaSjQtsjxx);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteByIds(List<String> ids) {
|
||||
removeByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public OtaBaSjQtsjxx queryById(String id) {
|
||||
return getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<OtaBaSjQtsjxx> queryList() {
|
||||
return list();
|
||||
}
|
||||
|
||||
@Override
|
||||
public OtaBaSjQtsjxx queryByOtaId(String otaId, String otaIdT) {
|
||||
OtaBaSjQtsjxx res = getByOtaId(otaId);
|
||||
if (ObjectUtils.isEmpty(res)) {
|
||||
res = getByOtaId(otaIdT);
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
public OtaBaSjQtsjxx getByOtaId(String otaId) {
|
||||
if (org.apache.commons.lang3.StringUtils.isEmpty(otaId)) {
|
||||
return null;
|
||||
}
|
||||
LambdaQueryWrapper<OtaBaSjQtsjxx> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.eq(OtaBaSjQtsjxx::getOtaId, otaId);
|
||||
return this.getOne(queryWrapper, false);
|
||||
}
|
||||
}
|
||||
|
||||
+21
-20
@@ -47,7 +47,6 @@ public class OtaBaSjSjfzbhServiceImpl extends ServiceImpl<OtaBaSjSjfzbhMapper, O
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
*/
|
||||
@Override
|
||||
public void add(JSONObject json) {
|
||||
@@ -59,28 +58,30 @@ public class OtaBaSjSjfzbhServiceImpl extends ServiceImpl<OtaBaSjSjfzbhMapper, O
|
||||
oldList = getByOtaId(otaId);
|
||||
deleteByOtaId(otaId);
|
||||
JSONArray list = json.getJSONArray("list");
|
||||
for (Object obj : list) {
|
||||
Map<String, Object> objMap = (HashMap) obj;
|
||||
OtaBaSjSjfzbh otaBaSjSjfzbh = new OtaBaSjSjfzbh();
|
||||
Field[] fields = OtaBaSjSjfzbh.class.getDeclaredFields();
|
||||
for (Field field : fields) {
|
||||
if (field.getName().equals("createTime") || field.getName().equals("updateTime")) {
|
||||
continue;
|
||||
}
|
||||
Object bjObj = objMap.get(field.getName());
|
||||
if (null != bjObj) {
|
||||
try {
|
||||
field.setAccessible(true);
|
||||
field.set(otaBaSjSjfzbh, bjObj.toString());
|
||||
} catch (IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
if (null != list) {
|
||||
for (Object obj : list) {
|
||||
Map<String, Object> objMap = (HashMap) obj;
|
||||
OtaBaSjSjfzbh otaBaSjSjfzbh = new OtaBaSjSjfzbh();
|
||||
Field[] fields = OtaBaSjSjfzbh.class.getDeclaredFields();
|
||||
for (Field field : fields) {
|
||||
if (field.getName().equals("createTime") || field.getName().equals("updateTime")) {
|
||||
continue;
|
||||
}
|
||||
Object bjObj = objMap.get(field.getName());
|
||||
if (null != bjObj) {
|
||||
try {
|
||||
field.setAccessible(true);
|
||||
field.set(otaBaSjSjfzbh, bjObj.toString());
|
||||
} catch (IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
otaBaSjSjfzbh.setOtaId(otaId);
|
||||
otaBaSjSjfzbh.setCreateTime(now);
|
||||
otaBaSjSjfzbh.setUpdateTime(now);
|
||||
newList.add(otaBaSjSjfzbh);
|
||||
}
|
||||
otaBaSjSjfzbh.setOtaId(otaId);
|
||||
otaBaSjSjfzbh.setCreateTime(now);
|
||||
otaBaSjSjfzbh.setUpdateTime(now);
|
||||
newList.add(otaBaSjSjfzbh);
|
||||
}
|
||||
if (ObjectUtils.isEmpty(oldList)) {
|
||||
oldList = new ArrayList<>();
|
||||
|
||||
+21
-19
@@ -53,28 +53,30 @@ public class OtaBaSjSjxtbhServiceImpl extends ServiceImpl<OtaBaSjSjxtbhMapper, O
|
||||
oldList = getByOtaId(otaId);
|
||||
deleteByOtaId(otaId);
|
||||
JSONArray list = json.getJSONArray("list");
|
||||
for (Object obj : list) {
|
||||
Map<String, Object> objMap = (HashMap) obj;
|
||||
OtaBaSjSjxtbh otaBaSjSjxtbh = new OtaBaSjSjxtbh();
|
||||
Field[] fields = OtaBaSjSjxtbh.class.getDeclaredFields();
|
||||
for (Field field : fields) {
|
||||
if (field.getName().equals("createTime") || field.getName().equals("updateTime")) {
|
||||
continue;
|
||||
}
|
||||
Object bjObj = objMap.get(field.getName());
|
||||
if (null != bjObj) {
|
||||
try {
|
||||
field.setAccessible(true);
|
||||
field.set(otaBaSjSjxtbh, bjObj.toString());
|
||||
} catch (IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
if (null != list) {
|
||||
for (Object obj : list) {
|
||||
Map<String, Object> objMap = (HashMap) obj;
|
||||
OtaBaSjSjxtbh otaBaSjSjxtbh = new OtaBaSjSjxtbh();
|
||||
Field[] fields = OtaBaSjSjxtbh.class.getDeclaredFields();
|
||||
for (Field field : fields) {
|
||||
if (field.getName().equals("createTime") || field.getName().equals("updateTime")) {
|
||||
continue;
|
||||
}
|
||||
Object bjObj = objMap.get(field.getName());
|
||||
if (null != bjObj) {
|
||||
try {
|
||||
field.setAccessible(true);
|
||||
field.set(otaBaSjSjxtbh, bjObj.toString());
|
||||
} catch (IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
otaBaSjSjxtbh.setOtaId(otaId);
|
||||
otaBaSjSjxtbh.setCreateTime(now);
|
||||
otaBaSjSjxtbh.setUpdateTime(now);
|
||||
newList.add(otaBaSjSjxtbh);
|
||||
}
|
||||
otaBaSjSjxtbh.setOtaId(otaId);
|
||||
otaBaSjSjxtbh.setCreateTime(now);
|
||||
otaBaSjSjxtbh.setUpdateTime(now);
|
||||
newList.add(otaBaSjSjxtbh);
|
||||
}
|
||||
if (ObjectUtils.isEmpty(oldList)) {
|
||||
oldList = new ArrayList<>();
|
||||
|
||||
+7
-1
@@ -5,6 +5,7 @@ import com.jero.modules.ota.enums.OtaModuleEnum;
|
||||
import com.jero.modules.ota.enums.OtaTitleEnum;
|
||||
import com.jero.modules.system.service.ISysDictService;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.util.ArrayList;
|
||||
@@ -56,7 +57,12 @@ public class ComparisonUtil<T> {
|
||||
if (ObjectUtils.isEmpty(id)) {
|
||||
Field tableField = newObj.getClass().getDeclaredField(tableTitle);
|
||||
tableField.setAccessible(true);
|
||||
String content = "新增了一条'" + tableField.get(newObj).toString() + "'";
|
||||
String tableFieldStr = "空";
|
||||
Object tableFieldObj = tableField.get(newObj);
|
||||
if (ObjectUtils.isNotEmpty(tableFieldStr)) {
|
||||
tableFieldStr = tableFieldObj.toString();
|
||||
}
|
||||
String content = "新增了一条'" + tableFieldStr + "'";
|
||||
resList.add(new OtaBaCxTxjl(otaId, otaModuleEnum.getName(), content));
|
||||
Field[] fields = newObj.getClass().getDeclaredFields();
|
||||
for (Field field : fields) {
|
||||
|
||||
Reference in New Issue
Block a user