车辆搜索
This commit is contained in:
@ -22,7 +22,7 @@ public class CodeGenerator {
|
||||
//自己的名字
|
||||
static String Author = "gqb";
|
||||
|
||||
public static String tableName = "zt_bug_bound_user";
|
||||
public static String tableName = "car_driving_license";
|
||||
|
||||
/**
|
||||
* <p>
|
||||
|
@ -0,0 +1,20 @@
|
||||
package com.sa.zentao.controller;
|
||||
|
||||
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/car-driving-license")
|
||||
public class CarDrivingLicenseController {
|
||||
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.sa.zentao.controller;
|
||||
|
||||
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/car-five-type")
|
||||
public class CarFiveTypeController {
|
||||
|
||||
}
|
102
src/main/java/com/sa/zentao/controller/CarManageController.java
Normal file
102
src/main/java/com/sa/zentao/controller/CarManageController.java
Normal file
@ -0,0 +1,102 @@
|
||||
package com.sa.zentao.controller;
|
||||
|
||||
|
||||
import com.sa.zentao.dao.*;
|
||||
import com.sa.zentao.entity.CarDrivingLicense;
|
||||
import com.sa.zentao.entity.CarFiveType;
|
||||
import com.sa.zentao.entity.CarOperatingVehicleLevel;
|
||||
import com.sa.zentao.entity.ZtFile;
|
||||
import com.sa.zentao.service.impl.CarManageService;
|
||||
import com.sa.zentao.utils.BeanCopyUtil;
|
||||
import com.sa.zentao.utils.BeanCopyUtilCallBack;
|
||||
import com.sa.zentao.utils.CarConstant;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-04-16
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/car-manage")
|
||||
public class CarManageController {
|
||||
|
||||
@Autowired
|
||||
private CarManageService carManageService;
|
||||
|
||||
/**
|
||||
* 查询五项
|
||||
* @param plate
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/searchFive")
|
||||
public Result removeFile(@RequestParam(value = "plate",required = true)String plate,@RequestParam(value = "model",required = false)String model){
|
||||
CarFiveType carFiveType = carManageService.searchFive(plate, model);
|
||||
if(carFiveType!=null){
|
||||
CarFiveTypeDTO carFiveTypeDTO = new CarFiveTypeDTO();
|
||||
BeanUtils.copyProperties(carFiveType,carFiveTypeDTO);
|
||||
return Result.success(carFiveTypeDTO);
|
||||
}
|
||||
return Result.success(carFiveType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询行驶证
|
||||
* @param plate
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/drivingLicense")
|
||||
public Result drivingLicense(@RequestParam(value = "plate",required = true)String plate,@RequestParam(value = "model",required = true)String model,@RequestParam(value = "owner",required = false)String owner){
|
||||
CarDrivingLicense carDrivingLicense = carManageService.drivingLicense(plate, model, owner);
|
||||
|
||||
if(carDrivingLicense!=null){
|
||||
CarDrivingLicenseDTO carDrivingLicenseDTO = new CarDrivingLicenseDTO();
|
||||
|
||||
BeanUtils.copyProperties(carDrivingLicense, carDrivingLicenseDTO);
|
||||
|
||||
return Result.success(carDrivingLicenseDTO);
|
||||
}
|
||||
return Result.success(carDrivingLicense);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询行驶证
|
||||
* @param plate
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/operatingVehicle")
|
||||
public Result operatingVehicle(@RequestParam(value = "plate",required = true)String plate){
|
||||
List<CarOperatingVehicleLevel> carOperatingVehicleLevel = carManageService.operatingVehicle(plate);
|
||||
|
||||
if(carOperatingVehicleLevel!=null){
|
||||
|
||||
List<CarOperatingVehicleLevelDTO> carOperatingVehicleLevels = BeanCopyUtil.copyListProperties(carOperatingVehicleLevel, CarOperatingVehicleLevelDTO::new, new BeanCopyUtilCallBack<CarOperatingVehicleLevel, CarOperatingVehicleLevelDTO>() {
|
||||
@Override
|
||||
public void callBack(CarOperatingVehicleLevel t, CarOperatingVehicleLevelDTO s) {
|
||||
if (s.getName().equals("疑似营运车辆")) {
|
||||
|
||||
} else {
|
||||
Map<String, String> stringStringMap = CarConstant.OPERATINGCAR.get(s.getName());
|
||||
String s1 = stringStringMap.get(s.getValue());
|
||||
s.setDescription(s1);
|
||||
}
|
||||
}
|
||||
});
|
||||
return Result.success(carOperatingVehicleLevels);
|
||||
}
|
||||
return Result.success(carOperatingVehicleLevel);
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.sa.zentao.controller;
|
||||
|
||||
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/car-operating-vehicle-level")
|
||||
public class CarOperatingVehicleLevelController {
|
||||
|
||||
}
|
184
src/main/java/com/sa/zentao/dao/CarDrivingLicenseDTO.java
Normal file
184
src/main/java/com/sa/zentao/dao/CarDrivingLicenseDTO.java
Normal file
@ -0,0 +1,184 @@
|
||||
package com.sa.zentao.dao;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
public class CarDrivingLicenseDTO implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 号牌种类01 大型汽车 02 小型汽车 03 使馆汽车 04 领馆汽车 05 境外汽车 06 外籍汽车 07 两、三轮摩托车 08 轻便摩托车 09 使馆摩托车 10 领馆摩托车 11 境外摩托车 12 外籍摩托车 13 农用运输车 14 拖拉机 15 挂车 16 教练汽车 17 教练摩托车 18 试验汽车 19 试验摩托车 20 临时入境汽车 21 临时入境摩托车 22 临时行驶车 23 公安警用汽车 24 公安警用摩托
|
||||
*/
|
||||
private String hpzl;
|
||||
|
||||
/**
|
||||
* 号牌号码
|
||||
*/
|
||||
private String hphm;
|
||||
|
||||
/**
|
||||
* 车辆品牌
|
||||
*/
|
||||
private String clpp1;
|
||||
|
||||
/**
|
||||
* 车辆型号
|
||||
*/
|
||||
private String clxh;
|
||||
|
||||
/**
|
||||
* 车辆识别代号
|
||||
*/
|
||||
private String clsbdh;
|
||||
|
||||
/**
|
||||
* 发动机号
|
||||
*/
|
||||
private String fdjh;
|
||||
|
||||
/**
|
||||
* 车辆类型B11 重型普通半挂车 B12 重型厢式半挂车 B13 重型罐式半挂车 B14 重型平板半挂车 B15 重型集装箱半挂车 B16 重型自卸半挂车 B17 重型特殊结构半挂车 B18 重型仓栅式半挂车 B19 重型旅居半挂车 B1A 重型专项作业半挂车 B1B 重型低平板半挂车 B1C 重型车辆运输半挂车 B1D 重型罐式自卸半挂车 B1E 重型平板自卸半挂车 B1F 重型集装箱自卸半挂车 B1G 重型特殊结构自卸半挂车 B1H 重型仓栅式自卸半挂车 B1J 重型专项作业自卸半挂车 B1K 重型低平板自卸半挂车 B1U 重型中置轴旅居挂车 B1V 重型中置轴车辆运输车 B1W 重型中置轴普通挂车 B21 中型普通半挂车 B22 中型厢式半挂车 B23 中型罐式半挂车 B24 中型平板半挂车 B25 中型集装箱半挂车 B26 中型自卸半挂车 B27 中型特殊结构半挂车 B28 中型仓栅式半挂车 B29 中型旅居半挂车 B2A 中型专项作业半挂车 B2B 中型低平板半挂车 B2C 中型车辆运输半挂车 B2D 中型罐式自卸半挂车 B2E 中型平板自卸半挂车 B2F 中型集装箱自卸半挂车 B2G 中型特殊结构自卸半挂车 B2H 中型仓栅式自卸半挂车 B2J 中型专项作业自卸半挂车 B2K 中型低平板自卸半挂车 B2U 中型中置轴旅居挂车 B2V 中型中置轴车辆运输车 B2W 中型中置轴普通挂车 B31 轻型普通半挂车 B32 轻型厢式半挂车 B33 轻型罐式半挂车 B34 轻型平板半挂车 B35 轻型自卸半挂车 B36 轻型仓栅式半挂车 B37 轻型旅居半挂车 B38 轻型专项作业半挂车 B39 轻型低平板半挂车 B3C 轻型车辆运输半挂车 B3D 轻型罐式自卸半挂车 B3E 轻型平板自卸半挂车 B3F 轻型集装箱自卸半挂车 B3G 轻型特殊结构自卸半挂车 B3H 轻型仓栅式自卸半挂车 B3J 轻型专项作业自卸半挂车 B3K 轻型低平板自卸半挂车 B3U
|
||||
*/
|
||||
private String cllx;
|
||||
|
||||
/**
|
||||
* 车身颜色
|
||||
*/
|
||||
private String csys;
|
||||
|
||||
/**
|
||||
* 使用性质A 非营运 B 公路客运 C 公交客运 D 出租客运 E 旅游客运 F 货运 G 租赁 H 警用 I 消防 J 救护 K 工程救险 L 营转非 M 出租转非 N 教练 O 幼儿校车 P 小学生校车 Q 初中生校车 R 危化品运输 S 中小学生校车 Z 其他
|
||||
*/
|
||||
private String syxz;
|
||||
|
||||
/**
|
||||
* 机动车所有人
|
||||
*/
|
||||
private String syr;
|
||||
|
||||
/**
|
||||
* 初次登记日期
|
||||
*/
|
||||
private String ccdjrq;
|
||||
|
||||
/**
|
||||
* 检验有效期止
|
||||
*/
|
||||
private String yxqz;
|
||||
|
||||
/**
|
||||
* 强制报废期止
|
||||
*/
|
||||
private String qzbfqz;
|
||||
|
||||
/**
|
||||
* 车辆状态A 正常 B 转出 O 锁定 N 事故逃逸 M 强制注销 L 暂扣 I 事故未处理 J 嫌疑车 C 被盗抢 D 停驶 E 注销 G 违法未处理 H 海关监管 K 查封 P 达到报废标准公告牌证作废 Q 逾期未检验 Z 其他
|
||||
*/
|
||||
private String zt;
|
||||
|
||||
/**
|
||||
* 发动机型号
|
||||
*/
|
||||
private String fdjxh;
|
||||
|
||||
/**
|
||||
* 汽油 柴油 电驱动(电能驱动汽车) 混合油 天然气 液化石油气 甲醇 乙醇 太阳能 混合动力 无(仅限全挂车等无动力的) 其他 插电式混合动力
|
||||
*/
|
||||
private String rlzl;
|
||||
|
||||
/**
|
||||
* 排量
|
||||
*/
|
||||
private String pl;
|
||||
|
||||
/**
|
||||
* 功率
|
||||
*/
|
||||
private String gl;
|
||||
|
||||
/**
|
||||
* 轴数
|
||||
*/
|
||||
private String zs;
|
||||
|
||||
/**
|
||||
* 轴距
|
||||
*/
|
||||
private String zj;
|
||||
|
||||
/**
|
||||
* 前轮距
|
||||
*/
|
||||
private String qlj;
|
||||
|
||||
/**
|
||||
* 后轮距
|
||||
*/
|
||||
private String hlj;
|
||||
|
||||
/**
|
||||
* 总质量
|
||||
*/
|
||||
private String zzl;
|
||||
|
||||
/**
|
||||
* 整备质量
|
||||
*/
|
||||
private String zbzl;
|
||||
|
||||
/**
|
||||
* 核定载质量
|
||||
*/
|
||||
private String hdzzl;
|
||||
|
||||
/**
|
||||
* 核定载客
|
||||
*/
|
||||
private String hdzk;
|
||||
|
||||
/**
|
||||
* 出厂日期
|
||||
*/
|
||||
private String ccrq;
|
||||
|
||||
/**
|
||||
* 车主是否一致
|
||||
*/
|
||||
private String owner;
|
||||
|
||||
/**
|
||||
* 1 查询成功 3.查询失败
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 查询失败返回结果
|
||||
*/
|
||||
private String msg;
|
||||
|
||||
/**
|
||||
* 查询日期
|
||||
*/
|
||||
private Date createTime;
|
||||
/**
|
||||
* 1 是所有人 2.不是所有人 0默认没有所有人
|
||||
*/
|
||||
private Integer syrFlag;
|
||||
|
||||
}
|
83
src/main/java/com/sa/zentao/dao/CarFiveTypeDTO.java
Normal file
83
src/main/java/com/sa/zentao/dao/CarFiveTypeDTO.java
Normal file
@ -0,0 +1,83 @@
|
||||
package com.sa.zentao.dao;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
public class CarFiveTypeDTO implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 车架号
|
||||
*/
|
||||
private String vin;
|
||||
|
||||
/**
|
||||
* 发动机
|
||||
*/
|
||||
private String engine;
|
||||
|
||||
/**
|
||||
* 品牌名称
|
||||
*/
|
||||
private String carName;
|
||||
|
||||
/**
|
||||
* 初次登记日期
|
||||
*/
|
||||
private Date recordDate;
|
||||
|
||||
/**
|
||||
* 查询时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 车辆模型
|
||||
*/
|
||||
private String vehicleModel;
|
||||
|
||||
/**
|
||||
* 车牌
|
||||
*/
|
||||
private String plate;
|
||||
|
||||
/**
|
||||
* 车辆类型
|
||||
*/
|
||||
private String type;
|
||||
|
||||
/**
|
||||
* 使用性质 编号 类型 编号 类型 01 大型汽车 13 农用摩托车 02 小型汽车 14 拖拉机 03 使馆汽车 15 挂车 04 领馆汽车 16 教练汽车 05 境外汽车 17 教练摩托车 06 外籍汽车 20 临时入境汽车 07 两、三轮摩托车 21 临时入境摩托车 08 轻便摩托车 22 临时行驶车 09 使馆摩托车 23 警用汽车 10 领馆摩托车 51 新能源大车 11 境外摩托车 52 新能源小车 12 外籍摩托车
|
||||
*/
|
||||
private String usage;
|
||||
|
||||
/**
|
||||
* 车辆类型
|
||||
*/
|
||||
private String cllb;
|
||||
/**
|
||||
* 未查询到反馈的消息
|
||||
*/
|
||||
private String msg;
|
||||
/**
|
||||
* 搜索到的 1命中 3 未查询到
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
package com.sa.zentao.dao;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
public class CarOperatingVehicleLevelDTO implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
@TableId(value = "id", type = IdType.AUTO)
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 疑似营运车辆
|
||||
*/
|
||||
private String name;
|
||||
|
||||
private String value;
|
||||
private String description;
|
||||
/**
|
||||
* 创建日期
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
private String plateNo;
|
||||
@TableField("`status`")
|
||||
private Integer status;
|
||||
|
||||
private String msg;
|
||||
}
|
@ -15,7 +15,8 @@ public class PerformanceDTO implements Serializable {
|
||||
|
||||
@ExcelIgnore
|
||||
private Date date;
|
||||
|
||||
@ExcelIgnore
|
||||
private Integer userId;
|
||||
private Integer id ;
|
||||
@ExcelProperty(value = "姓名",index =0)
|
||||
private String userName;
|
||||
@ -148,7 +149,7 @@ public class PerformanceDTO implements Serializable {
|
||||
private BigDecimal totalScore=BigDecimal.ZERO;
|
||||
|
||||
//版本计划完成率
|
||||
private BigDecimal versionPlanFinishedRate=BigDecimal.ZERO;;
|
||||
private BigDecimal versionPlanFinishedRate=BigDecimal.valueOf(20);
|
||||
//任务管理和分解能力
|
||||
private BigDecimal taskManageScore=BigDecimal.ZERO;;
|
||||
//分配工时占比
|
||||
@ -158,5 +159,5 @@ public class PerformanceDTO implements Serializable {
|
||||
//专业技能提升
|
||||
private BigDecimal professionalSkillEnhancementScore=BigDecimal.ZERO;
|
||||
//问题管理得分
|
||||
private BigDecimal developFeedbackStory=BigDecimal.ZERO;
|
||||
private BigDecimal developFeedbackStory=BigDecimal.valueOf(10);
|
||||
}
|
||||
|
@ -84,7 +84,11 @@ public class ProgramCountDTO implements Serializable {
|
||||
//线上Bug得分
|
||||
@ExcelProperty(value = "线上Bug得分 ",index =15)
|
||||
private BigDecimal bugScore=BigDecimal.ZERO;
|
||||
|
||||
/**
|
||||
* 线上bug率
|
||||
*/
|
||||
@ExcelIgnore
|
||||
private BigDecimal prodBugDensity=BigDecimal.ZERO;
|
||||
|
||||
//普通bug
|
||||
private BigDecimal devSlightBug;
|
||||
|
189
src/main/java/com/sa/zentao/entity/CarDrivingLicense.java
Normal file
189
src/main/java/com/sa/zentao/entity/CarDrivingLicense.java
Normal file
@ -0,0 +1,189 @@
|
||||
package com.sa.zentao.entity;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
public class CarDrivingLicense implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
@TableId(value = "id", type = IdType.AUTO)
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 号牌种类01 大型汽车 02 小型汽车 03 使馆汽车 04 领馆汽车 05 境外汽车 06 外籍汽车 07 两、三轮摩托车 08 轻便摩托车 09 使馆摩托车 10 领馆摩托车 11 境外摩托车 12 外籍摩托车 13 农用运输车 14 拖拉机 15 挂车 16 教练汽车 17 教练摩托车 18 试验汽车 19 试验摩托车 20 临时入境汽车 21 临时入境摩托车 22 临时行驶车 23 公安警用汽车 24 公安警用摩托
|
||||
*/
|
||||
private String hpzl;
|
||||
|
||||
/**
|
||||
* 号牌号码
|
||||
*/
|
||||
private String hphm;
|
||||
|
||||
/**
|
||||
* 车辆品牌
|
||||
*/
|
||||
private String clpp1;
|
||||
|
||||
/**
|
||||
* 车辆型号
|
||||
*/
|
||||
private String clxh;
|
||||
|
||||
/**
|
||||
* 车辆识别代号
|
||||
*/
|
||||
private String clsbdh;
|
||||
|
||||
/**
|
||||
* 发动机号
|
||||
*/
|
||||
private String fdjh;
|
||||
|
||||
/**
|
||||
* 车辆类型B11 重型普通半挂车 B12 重型厢式半挂车 B13 重型罐式半挂车 B14 重型平板半挂车 B15 重型集装箱半挂车 B16 重型自卸半挂车 B17 重型特殊结构半挂车 B18 重型仓栅式半挂车 B19 重型旅居半挂车 B1A 重型专项作业半挂车 B1B 重型低平板半挂车 B1C 重型车辆运输半挂车 B1D 重型罐式自卸半挂车 B1E 重型平板自卸半挂车 B1F 重型集装箱自卸半挂车 B1G 重型特殊结构自卸半挂车 B1H 重型仓栅式自卸半挂车 B1J 重型专项作业自卸半挂车 B1K 重型低平板自卸半挂车 B1U 重型中置轴旅居挂车 B1V 重型中置轴车辆运输车 B1W 重型中置轴普通挂车 B21 中型普通半挂车 B22 中型厢式半挂车 B23 中型罐式半挂车 B24 中型平板半挂车 B25 中型集装箱半挂车 B26 中型自卸半挂车 B27 中型特殊结构半挂车 B28 中型仓栅式半挂车 B29 中型旅居半挂车 B2A 中型专项作业半挂车 B2B 中型低平板半挂车 B2C 中型车辆运输半挂车 B2D 中型罐式自卸半挂车 B2E 中型平板自卸半挂车 B2F 中型集装箱自卸半挂车 B2G 中型特殊结构自卸半挂车 B2H 中型仓栅式自卸半挂车 B2J 中型专项作业自卸半挂车 B2K 中型低平板自卸半挂车 B2U 中型中置轴旅居挂车 B2V 中型中置轴车辆运输车 B2W 中型中置轴普通挂车 B31 轻型普通半挂车 B32 轻型厢式半挂车 B33 轻型罐式半挂车 B34 轻型平板半挂车 B35 轻型自卸半挂车 B36 轻型仓栅式半挂车 B37 轻型旅居半挂车 B38 轻型专项作业半挂车 B39 轻型低平板半挂车 B3C 轻型车辆运输半挂车 B3D 轻型罐式自卸半挂车 B3E 轻型平板自卸半挂车 B3F 轻型集装箱自卸半挂车 B3G 轻型特殊结构自卸半挂车 B3H 轻型仓栅式自卸半挂车 B3J 轻型专项作业自卸半挂车 B3K 轻型低平板自卸半挂车 B3U
|
||||
*/
|
||||
private String cllx;
|
||||
|
||||
/**
|
||||
* 车身颜色
|
||||
*/
|
||||
private String csys;
|
||||
|
||||
/**
|
||||
* 使用性质A 非营运 B 公路客运 C 公交客运 D 出租客运 E 旅游客运 F 货运 G 租赁 H 警用 I 消防 J 救护 K 工程救险 L 营转非 M 出租转非 N 教练 O 幼儿校车 P 小学生校车 Q 初中生校车 R 危化品运输 S 中小学生校车 Z 其他
|
||||
*/
|
||||
private String syxz;
|
||||
|
||||
/**
|
||||
* 机动车所有人
|
||||
*/
|
||||
private String syr;
|
||||
/**
|
||||
* 1 是所有人 2.不是所有人 0默认没有所有人
|
||||
*/
|
||||
private Integer syrFlag;
|
||||
/**
|
||||
* 初次登记日期
|
||||
*/
|
||||
private String ccdjrq;
|
||||
|
||||
/**
|
||||
* 检验有效期止
|
||||
*/
|
||||
private String yxqz;
|
||||
|
||||
/**
|
||||
* 强制报废期止
|
||||
*/
|
||||
private String qzbfqz;
|
||||
|
||||
/**
|
||||
* 车辆状态A 正常 B 转出 O 锁定 N 事故逃逸 M 强制注销 L 暂扣 I 事故未处理 J 嫌疑车 C 被盗抢 D 停驶 E 注销 G 违法未处理 H 海关监管 K 查封 P 达到报废标准公告牌证作废 Q 逾期未检验 Z 其他
|
||||
*/
|
||||
private String zt;
|
||||
|
||||
/**
|
||||
* 发动机型号
|
||||
*/
|
||||
private String fdjxh;
|
||||
|
||||
/**
|
||||
* 汽油 柴油 电驱动(电能驱动汽车) 混合油 天然气 液化石油气 甲醇 乙醇 太阳能 混合动力 无(仅限全挂车等无动力的) 其他 插电式混合动力
|
||||
*/
|
||||
private String rlzl;
|
||||
|
||||
/**
|
||||
* 排量
|
||||
*/
|
||||
private String pl;
|
||||
|
||||
/**
|
||||
* 功率
|
||||
*/
|
||||
private String gl;
|
||||
|
||||
/**
|
||||
* 轴数
|
||||
*/
|
||||
private String zs;
|
||||
|
||||
/**
|
||||
* 轴距
|
||||
*/
|
||||
private String zj;
|
||||
|
||||
/**
|
||||
* 前轮距
|
||||
*/
|
||||
private String qlj;
|
||||
|
||||
/**
|
||||
* 后轮距
|
||||
*/
|
||||
private String hlj;
|
||||
|
||||
/**
|
||||
* 总质量
|
||||
*/
|
||||
private String zzl;
|
||||
|
||||
/**
|
||||
* 整备质量
|
||||
*/
|
||||
private String zbzl;
|
||||
|
||||
/**
|
||||
* 核定载质量
|
||||
*/
|
||||
private String hdzzl;
|
||||
|
||||
/**
|
||||
* 核定载客
|
||||
*/
|
||||
private String hdzk;
|
||||
|
||||
/**
|
||||
* 出厂日期
|
||||
*/
|
||||
private String ccrq;
|
||||
|
||||
/**
|
||||
* 车主是否一致
|
||||
*/
|
||||
private String owner;
|
||||
|
||||
/**
|
||||
* 1 查询成功 3.查询失败
|
||||
*/
|
||||
@TableField("`status`")
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 查询失败返回结果
|
||||
*/
|
||||
private String msg;
|
||||
|
||||
/**
|
||||
* 查询日期
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
|
||||
}
|
91
src/main/java/com/sa/zentao/entity/CarFiveType.java
Normal file
91
src/main/java/com/sa/zentao/entity/CarFiveType.java
Normal file
@ -0,0 +1,91 @@
|
||||
package com.sa.zentao.entity;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
public class CarFiveType implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
@TableId(value = "id", type = IdType.AUTO)
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 车架号
|
||||
*/
|
||||
private String vin;
|
||||
|
||||
/**
|
||||
* 发动机
|
||||
*/
|
||||
private String engine;
|
||||
|
||||
/**
|
||||
* 品牌名称
|
||||
*/
|
||||
private String carName;
|
||||
|
||||
/**
|
||||
* 初次登记日期
|
||||
*/
|
||||
private Date recordDate;
|
||||
|
||||
/**
|
||||
* 查询时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 车辆模型
|
||||
*/
|
||||
private String vehicleModel;
|
||||
|
||||
/**
|
||||
* 车牌
|
||||
*/
|
||||
private String plate;
|
||||
|
||||
/**
|
||||
* 车辆类型
|
||||
*/
|
||||
@TableField("`type`")
|
||||
private String type;
|
||||
|
||||
/**
|
||||
* 使用性质 编号 类型 编号 类型 01 大型汽车 13 农用摩托车 02 小型汽车 14 拖拉机 03 使馆汽车 15 挂车 04 领馆汽车 16 教练汽车 05 境外汽车 17 教练摩托车 06 外籍汽车 20 临时入境汽车 07 两、三轮摩托车 21 临时入境摩托车 08 轻便摩托车 22 临时行驶车 09 使馆摩托车 23 警用汽车 10 领馆摩托车 51 新能源大车 11 境外摩托车 52 新能源小车 12 外籍摩托车
|
||||
*/
|
||||
@TableField("`usage`")
|
||||
private String usage;
|
||||
|
||||
/**
|
||||
* 车辆类型
|
||||
*/
|
||||
private String cllb;
|
||||
/**
|
||||
* 未查询到反馈的消息
|
||||
*/
|
||||
private String msg;
|
||||
/**
|
||||
* 搜索到的 1命中 3 未查询到
|
||||
*/
|
||||
@TableField("`status`")
|
||||
private Integer status;
|
||||
|
||||
private String model;
|
||||
}
|
@ -0,0 +1,47 @@
|
||||
package com.sa.zentao.entity;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
public class CarOperatingVehicleLevel implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
@TableId(value = "id", type = IdType.AUTO)
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 疑似营运车辆
|
||||
*/
|
||||
private String name;
|
||||
|
||||
private String value;
|
||||
|
||||
|
||||
/**
|
||||
* 创建日期
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
private String plateNo;
|
||||
@TableField("`status`")
|
||||
private Integer status;
|
||||
|
||||
private String msg;
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.sa.zentao.mapper;
|
||||
|
||||
import com.sa.zentao.entity.CarDrivingLicense;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
public interface CarDrivingLicenseMapper extends BaseMapper<CarDrivingLicense> {
|
||||
|
||||
}
|
16
src/main/java/com/sa/zentao/mapper/CarFiveTypeMapper.java
Normal file
16
src/main/java/com/sa/zentao/mapper/CarFiveTypeMapper.java
Normal file
@ -0,0 +1,16 @@
|
||||
package com.sa.zentao.mapper;
|
||||
|
||||
import com.sa.zentao.entity.CarFiveType;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
public interface CarFiveTypeMapper extends BaseMapper<CarFiveType> {
|
||||
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.sa.zentao.mapper;
|
||||
|
||||
import com.sa.zentao.entity.CarOperatingVehicleLevel;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
public interface CarOperatingVehicleLevelMapper extends BaseMapper<CarOperatingVehicleLevel> {
|
||||
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.sa.zentao.service;
|
||||
|
||||
import com.sa.zentao.entity.CarDrivingLicense;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
public interface ICarDrivingLicenseService extends IService<CarDrivingLicense> {
|
||||
|
||||
}
|
16
src/main/java/com/sa/zentao/service/ICarFiveTypeService.java
Normal file
16
src/main/java/com/sa/zentao/service/ICarFiveTypeService.java
Normal file
@ -0,0 +1,16 @@
|
||||
package com.sa.zentao.service;
|
||||
|
||||
import com.sa.zentao.entity.CarFiveType;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
public interface ICarFiveTypeService extends IService<CarFiveType> {
|
||||
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.sa.zentao.service;
|
||||
|
||||
import com.sa.zentao.entity.CarOperatingVehicleLevel;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
public interface ICarOperatingVehicleLevelService extends IService<CarOperatingVehicleLevel> {
|
||||
|
||||
}
|
@ -71,10 +71,13 @@ public interface IZtProjectService extends IService<ZtProject> {
|
||||
Map<String,Map<String,Integer>> countProject(ZtProjectQo qo);
|
||||
|
||||
void executionSyncStory(ZtProjectDTO dto);
|
||||
//产品权限
|
||||
List<Integer> authProductListByAccount(String account);
|
||||
|
||||
//所有产品集
|
||||
List<Integer> allAuthList();
|
||||
|
||||
//所有产品
|
||||
List<Integer> allProductList();
|
||||
//产品权限
|
||||
List<Integer> authProductList();
|
||||
//产品集权限
|
||||
@ -82,6 +85,9 @@ public interface IZtProjectService extends IService<ZtProject> {
|
||||
//项目权限合集
|
||||
List<Integer> projectAuthList();
|
||||
|
||||
//项目权限合集
|
||||
List<Integer> getProjectAuthListByUserId(Integer userId);
|
||||
|
||||
List<Integer> execAuthList();
|
||||
|
||||
List<ZtProject> executionListByProject(ZtProjectQo qo);
|
||||
|
@ -68,6 +68,14 @@ public interface IZtTaskService extends IService<ZtTask> {
|
||||
* @return
|
||||
*/
|
||||
List<ZtTask> taskListByEIdsAndDate(Date firstDayOfMonth, Date lastDayOfMonth, List<Integer> pids);
|
||||
/**
|
||||
*
|
||||
* @param firstDayOfMonth 开始
|
||||
* @param lastDayOfMonth 结束
|
||||
* @param pids 产品
|
||||
* @return
|
||||
*/
|
||||
List<ZtTask> taskListByCondition(Date firstDayOfMonth, Date lastDayOfMonth, List<Integer> pids,List<Integer> uids);
|
||||
|
||||
|
||||
List<ZtTask> getDelayTask(List<ZtTask> t);
|
||||
|
@ -0,0 +1,20 @@
|
||||
package com.sa.zentao.service.impl;
|
||||
|
||||
import com.sa.zentao.entity.CarDrivingLicense;
|
||||
import com.sa.zentao.mapper.CarDrivingLicenseMapper;
|
||||
import com.sa.zentao.service.ICarDrivingLicenseService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Service
|
||||
public class CarDrivingLicenseServiceImpl extends ServiceImpl<CarDrivingLicenseMapper, CarDrivingLicense> implements ICarDrivingLicenseService {
|
||||
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.sa.zentao.service.impl;
|
||||
|
||||
import com.sa.zentao.entity.CarFiveType;
|
||||
import com.sa.zentao.mapper.CarFiveTypeMapper;
|
||||
import com.sa.zentao.service.ICarFiveTypeService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Service
|
||||
public class CarFiveTypeServiceImpl extends ServiceImpl<CarFiveTypeMapper, CarFiveType> implements ICarFiveTypeService {
|
||||
|
||||
}
|
236
src/main/java/com/sa/zentao/service/impl/CarManageService.java
Normal file
236
src/main/java/com/sa/zentao/service/impl/CarManageService.java
Normal file
@ -0,0 +1,236 @@
|
||||
package com.sa.zentao.service.impl;
|
||||
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.sa.zentao.entity.CarDrivingLicense;
|
||||
import com.sa.zentao.entity.CarFiveType;
|
||||
import com.sa.zentao.entity.CarOperatingVehicleLevel;
|
||||
import com.sa.zentao.service.ICarDrivingLicenseService;
|
||||
import com.sa.zentao.service.ICarFiveTypeService;
|
||||
import com.sa.zentao.service.ICarOperatingVehicleLevelService;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.http.*;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
import org.springframework.util.LinkedMultiValueMap;
|
||||
import org.springframework.util.MultiValueMap;
|
||||
import org.springframework.web.client.RestTemplate;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
@Service
|
||||
public class CarManageService {
|
||||
|
||||
//五项
|
||||
@Autowired
|
||||
private ICarFiveTypeService carFiveTypeService;
|
||||
//行驶证
|
||||
@Autowired
|
||||
private ICarDrivingLicenseService carDrivingLicenseService;
|
||||
//营运风险等级
|
||||
@Autowired
|
||||
private ICarOperatingVehicleLevelService carOperatingVehicleLevelService;
|
||||
|
||||
RestTemplate rest =new RestTemplate();
|
||||
|
||||
/**
|
||||
* 查询五项
|
||||
* @param plate
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
public CarFiveType searchFive(String plate,String model){
|
||||
LambdaQueryWrapper<CarFiveType> eq = new QueryWrapper<CarFiveType>().lambda().eq(CarFiveType::getPlate, plate);
|
||||
if(!StringUtils.isEmpty(model)){
|
||||
eq.eq(CarFiveType::getModel, model);
|
||||
}
|
||||
List<CarFiveType> list = carFiveTypeService.list(eq);
|
||||
if(!CollectionUtils.isEmpty(list)){
|
||||
return list.get(0);
|
||||
}
|
||||
|
||||
if(StringUtils.isEmpty(plate)){
|
||||
return null;
|
||||
}
|
||||
ResponseEntity<String> forEntity = rest.getForEntity("https://api.chequan.cn/?a=carBaseInfo&user=dgkjshdxm&token=eab3335e2ffe15b8410553cedc1f589a&plate=" + plate, String.class);
|
||||
if(forEntity.getStatusCode().value()==200){
|
||||
String body = forEntity.getBody();
|
||||
JSONObject jsonObject = JSONObject.parseObject(body);
|
||||
if(!jsonObject.getInteger("code").equals(0)){
|
||||
|
||||
CarFiveType carFiveType=new CarFiveType();
|
||||
carFiveType.setMsg(jsonObject.getString("msg"));
|
||||
carFiveType.setStatus(3);
|
||||
carFiveType.setPlate(plate);
|
||||
carFiveType.setCreateTime(new Date());
|
||||
carFiveType.setModel(model);
|
||||
this.carFiveTypeService.save(carFiveType);
|
||||
return carFiveType;
|
||||
}else{
|
||||
String data = jsonObject.getString("data");
|
||||
CarFiveType carFiveType = JSON.parseObject(data, CarFiveType.class);
|
||||
carFiveType.setStatus(1);
|
||||
carFiveType.setCreateTime(new Date());
|
||||
carFiveType.setPlate(plate);
|
||||
carFiveType.setModel(model);
|
||||
this.carFiveTypeService.save(carFiveType);
|
||||
return carFiveType;
|
||||
}
|
||||
|
||||
}else{
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询行驶证 driving_license
|
||||
* @param plate
|
||||
* @param model 车辆类型
|
||||
* @param owner 车主姓名
|
||||
* @return
|
||||
*/
|
||||
public CarDrivingLicense drivingLicense(String plate,String model,String owner){
|
||||
LambdaQueryWrapper<CarDrivingLicense> eq = new QueryWrapper<CarDrivingLicense>().lambda().eq(CarDrivingLicense::getHphm, plate);
|
||||
|
||||
if(!StringUtils.isEmpty(model)){
|
||||
eq.eq(CarDrivingLicense::getCllx,model);
|
||||
}
|
||||
if(!StringUtils.isEmpty(owner)){
|
||||
eq.and(f->f.eq(CarDrivingLicense::getSyr,owner).or().eq(CarDrivingLicense::getSyrFlag,1));
|
||||
}
|
||||
|
||||
List<CarDrivingLicense> list = carDrivingLicenseService.list(eq);
|
||||
if(!CollectionUtils.isEmpty(list)){
|
||||
CarDrivingLicense carDrivingLicense = list.get(0);
|
||||
if(!StringUtils.isEmpty(owner)&&carDrivingLicense.getSyr().equals(owner)){
|
||||
return carDrivingLicense;
|
||||
}else if(!StringUtils.isEmpty(owner)){
|
||||
carDrivingLicense.setOwner("不一致");
|
||||
carDrivingLicense.setSyr("不一致");
|
||||
carDrivingLicense.setSyrFlag(2);
|
||||
return carDrivingLicense;
|
||||
}else{
|
||||
carDrivingLicense.setOwner("");
|
||||
carDrivingLicense.setSyr("");
|
||||
carDrivingLicense.setSyrFlag(0);
|
||||
return carDrivingLicense;
|
||||
}
|
||||
}
|
||||
String url ="http://api.chequan.cn/?a=vehicleLicenseInfo&user=dgkjshdxm&token=eab3335e2ffe15b8410553cedc1f589a&plate=" + plate +"&model=" + model;
|
||||
if(!StringUtils.isEmpty(owner)){
|
||||
url+="&owner=" + owner;
|
||||
}
|
||||
ResponseEntity<String> forEntity = rest.getForEntity(url, String.class);
|
||||
if(forEntity.getStatusCode().value()==200){
|
||||
String body = forEntity.getBody();
|
||||
JSONObject jsonObject = JSONObject.parseObject(body);
|
||||
if(!jsonObject.getInteger("code").equals(0)){
|
||||
|
||||
CarDrivingLicense carFiveType=new CarDrivingLicense();
|
||||
carFiveType.setMsg(jsonObject.getString("msg"));
|
||||
carFiveType.setStatus(3);
|
||||
carFiveType.setHphm(plate);
|
||||
carFiveType.setCreateTime(new Date());
|
||||
carFiveType.setCllx(model);
|
||||
carFiveType.setSyr(owner);
|
||||
carFiveType.setOwner(owner);
|
||||
carFiveType.setSyrFlag(0);
|
||||
this.carDrivingLicenseService.save(carFiveType);
|
||||
return carFiveType;
|
||||
}else{
|
||||
String data = jsonObject.getString("data");
|
||||
CarDrivingLicense carDrivingLicense = JSON.parseObject(data, CarDrivingLicense.class);
|
||||
carDrivingLicense.setStatus(1);
|
||||
carDrivingLicense.setHphm(plate);
|
||||
carDrivingLicense.setCreateTime(new Date());
|
||||
carDrivingLicense.setCllx(model);
|
||||
|
||||
if(!StringUtils.isEmpty(owner)&&carDrivingLicense.getOwner().equals("一致")){
|
||||
carDrivingLicense.setSyrFlag(1);
|
||||
}else if(!StringUtils.isEmpty(owner)&&carDrivingLicense.getOwner().equals("不一致")){
|
||||
carDrivingLicense.setSyrFlag(2);
|
||||
}else{
|
||||
carDrivingLicense.setSyrFlag(0);
|
||||
}
|
||||
carDrivingLicense.setSyr(owner);
|
||||
carDrivingLicense.setOwner(owner);
|
||||
this.carDrivingLicenseService.save(carDrivingLicense);
|
||||
return carDrivingLicense;
|
||||
}
|
||||
|
||||
}else{
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 营运车辆等级 Operating vehicle level
|
||||
*/
|
||||
public List<CarOperatingVehicleLevel> operatingVehicle(String plate){
|
||||
LambdaQueryWrapper<CarOperatingVehicleLevel> eq = new QueryWrapper<CarOperatingVehicleLevel>().lambda().eq(CarOperatingVehicleLevel::getPlateNo, plate);
|
||||
|
||||
List<CarOperatingVehicleLevel> list = carOperatingVehicleLevelService.list(eq);
|
||||
if(!CollectionUtils.isEmpty(list)){
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
HttpHeaders headers = new HttpHeaders();
|
||||
MultiValueMap<String, Object> body = new LinkedMultiValueMap<>();
|
||||
body.add("plateNo", plate);
|
||||
headers.setContentType(MediaType.MULTIPART_FORM_DATA);
|
||||
HttpEntity<MultiValueMap<String, Object>> entity = new HttpEntity<>(body, headers);
|
||||
ResponseEntity<String> response = rest.postForEntity("https://api.chequan.cn/?a=queryOnlineVehicleInfo&user=dgkjshdxm&token=eab3335e2ffe15b8410553cedc1f589a&plateNo=" + plate, entity, String.class);
|
||||
|
||||
|
||||
|
||||
|
||||
if(response.getStatusCode().value()==200){
|
||||
String result = response.getBody();
|
||||
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||
if(!jsonObject.getInteger("code").equals(0)){
|
||||
|
||||
CarOperatingVehicleLevel carFiveType=new CarOperatingVehicleLevel();
|
||||
carFiveType.setMsg(jsonObject.getString("msg"));
|
||||
carFiveType.setStatus(3);
|
||||
carFiveType.setPlateNo(plate);
|
||||
carFiveType.setCreateTime(new Date());
|
||||
this.carOperatingVehicleLevelService.save(carFiveType);
|
||||
return Arrays.asList(carFiveType);
|
||||
}else{
|
||||
String data = jsonObject.getString("data");
|
||||
List<CarOperatingVehicleLevel> carOperatingVehicleLevels = JSON.parseArray(data, CarOperatingVehicleLevel.class);
|
||||
if(!CollectionUtils.isEmpty(carOperatingVehicleLevels)){
|
||||
for (CarOperatingVehicleLevel carFiveType : carOperatingVehicleLevels) {
|
||||
carFiveType.setStatus(1);
|
||||
carFiveType.setCreateTime(new Date());
|
||||
carFiveType.setPlateNo(plate);
|
||||
this.carOperatingVehicleLevelService.save(carFiveType);
|
||||
}
|
||||
return carOperatingVehicleLevels;
|
||||
}else{
|
||||
CarOperatingVehicleLevel carOperatingVehicleLevel=new CarOperatingVehicleLevel();
|
||||
carOperatingVehicleLevel.setStatus(3);
|
||||
carOperatingVehicleLevel.setCreateTime(new Date());
|
||||
carOperatingVehicleLevel.setPlateNo(plate);
|
||||
this.carOperatingVehicleLevelService.save(carOperatingVehicleLevel);
|
||||
return Arrays.asList(carOperatingVehicleLevel);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}else{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.sa.zentao.service.impl;
|
||||
|
||||
import com.sa.zentao.entity.CarOperatingVehicleLevel;
|
||||
import com.sa.zentao.mapper.CarOperatingVehicleLevelMapper;
|
||||
import com.sa.zentao.service.ICarOperatingVehicleLevelService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author gqb
|
||||
* @since 2025-06-16
|
||||
*/
|
||||
@Service
|
||||
public class CarOperatingVehicleLevelServiceImpl extends ServiceImpl<CarOperatingVehicleLevelMapper, CarOperatingVehicleLevel> implements ICarOperatingVehicleLevelService {
|
||||
|
||||
}
|
@ -27,6 +27,7 @@ import com.sa.zentao.service.*;
|
||||
import com.sa.zentao.utils.BigDecimalUtils;
|
||||
import com.sa.zentao.utils.DateUtils;
|
||||
import com.sa.zentao.utils.ExcelUtil;
|
||||
import com.sa.zentao.utils.SFunctionColums;
|
||||
import com.tencentcloudapi.ses.v20201002.models.EmailSender;
|
||||
import jakarta.servlet.ServletOutputStream;
|
||||
import jakarta.servlet.ServletRequest;
|
||||
@ -805,6 +806,77 @@ public class IZtCountService {
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 产品集统计
|
||||
* pids 产品集
|
||||
* @param qo
|
||||
* @return
|
||||
*/
|
||||
private List<PerformanceDTO> programCount(ZtCountQo qo,List<Integer> programIds) {
|
||||
|
||||
Date d = qo.getDate();
|
||||
if (d == null) {
|
||||
d = new Date();
|
||||
}
|
||||
Date firstDayOfMonth = DateUtils.getFirstDayOfMonth(d);
|
||||
Date lastDayOfMonth = DateUtils.getLastDayOfMonth(d);
|
||||
List<ZtProduct> productList = this.productService.list(new QueryWrapper<ZtProduct>().lambda().in(ZtProduct::getProgram, programIds));
|
||||
|
||||
if (CollectionUtils.isEmpty(productList)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<ZtProjectproduct> projectproducts = this.projectproductService.list(new QueryWrapper<ZtProjectproduct>().lambda()
|
||||
.in(ZtProjectproduct::getProduct, productList.stream().map(o -> o.getId()).collect(Collectors.toList())));
|
||||
if (CollectionUtils.isEmpty(projectproducts)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<Integer> pids = productList.stream().map(o -> o.getId()).collect(Collectors.toList());
|
||||
|
||||
List<ZtTask> taskList = this.taskService.taskListByEIdsAndDate(firstDayOfMonth, lastDayOfMonth,pids);
|
||||
|
||||
List<ZtProject> ztProjects = this.projectService.getExecutionsListByProjectAndDate(projectproducts.stream().map(o->o.getProject()).collect(Collectors.toList()), firstDayOfMonth, lastDayOfMonth);
|
||||
|
||||
if (CollectionUtils.isEmpty(ztProjects)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
|
||||
List<ZtTeam> teams = this.teamService.list(new QueryWrapper<ZtTeam>().lambda().eq(ZtTeam::getType, "execution")
|
||||
.in(ZtTeam::getRoot, ztProjects.stream().map(o -> o.getId()).collect(Collectors.toList())));
|
||||
|
||||
List<String> accountIds = teams.stream().map(o -> o.getAccount()).distinct().collect(Collectors.toList());
|
||||
if (CollectionUtils.isEmpty(accountIds)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
Map<String, ZtUser> userMap = this.userService.userMapByIds(accountIds);
|
||||
//accountIds 成员
|
||||
|
||||
List<ZtUser> ztUsers = this.userService.list(new QueryWrapper<ZtUser>().lambda()
|
||||
.in(ZtUser::getAccount, accountIds));
|
||||
|
||||
|
||||
List<PerformanceDTO> result = new ArrayList<>();
|
||||
|
||||
for (ZtUser u : ztUsers) {
|
||||
|
||||
List<ItApproval> approvalList = this.taskService.itApprovalByUserName(u.getNickname(), firstDayOfMonth, lastDayOfMonth);
|
||||
if (u.getAccount().equals("liyuyan")) {
|
||||
result.add(buildXMZLScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d));
|
||||
} else if ("liushengqing".equals(u.getAccount())) {
|
||||
result.add(buildUiScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d));
|
||||
} else if (u.getUserType() == UserType.KFZ) {
|
||||
result.add(buildKFZScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d));
|
||||
} else if (u.getUserType() == UserType.CS) {
|
||||
result.add(buildCScore(userMap,pids,u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d));
|
||||
} else if (u.getUserType() == UserType.UI) {
|
||||
result.add(buildUiScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d));
|
||||
} else if (u.getUserType() == UserType.XMJL || u.getUserType() == UserType.XMGLY || u.getUserType() == UserType.GSGC) {
|
||||
result.add(buildXMJLScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d));
|
||||
} else if (u.getUserType() == UserType.XMZL) {
|
||||
result.add(buildXMZLScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d));
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
//新的
|
||||
PerformanceDTO buildKFZScore(ZtUser u, List<ItApproval> approvalList, Date firstDayOfMonth, Date lastDayOfMonth, List<ZtTask> taskList, Date d) {
|
||||
|
||||
@ -971,7 +1043,7 @@ public class IZtCountService {
|
||||
List<ZtBug> allBugList = this.bugService.list(new QueryWrapper<ZtBug>().lambda()
|
||||
.eq(ZtBug::getOpenedby, u.getAccount())
|
||||
.ge(ZtBug::getOpeneddate, firstDayOfMonth).le(ZtBug::getOpeneddate, lastDayOfMonth));
|
||||
allBugList = allBugList.stream().filter(o -> ("closed".equals(o.getStatus()) ?
|
||||
allBugList = allBugList.stream().filter(o -> ("closed".equals(o.getStatus())||"cancel".equals(o.getStatus()) ?
|
||||
((!StringUtils.isEmpty(o.getResolvedby())) ? true : false) : true)).collect(Collectors.toList());
|
||||
//严重
|
||||
long seriousBug = allBugList.stream().filter(o -> Integer.valueOf(1).equals(o.getSeverity())).count();
|
||||
@ -1041,8 +1113,10 @@ public class IZtCountService {
|
||||
}
|
||||
|
||||
List<ZtTask> taskList = this.taskService.list(new QueryWrapper<ZtTask>().lambda()
|
||||
.select(SFunctionColums.taskColumes())
|
||||
.eq(ZtTask::getType,"devel")
|
||||
.in(ZtTask::getAssignedTo,accountIds)
|
||||
.notIn(ZtTask::getStatus,"cancel","closed")
|
||||
.in(ZtTask::getStory, list.stream().map(o -> o.getId()).collect(Collectors.toList())));
|
||||
if(CollectionUtils.isEmpty(taskList)){
|
||||
return dto;
|
||||
@ -1103,6 +1177,7 @@ public class IZtCountService {
|
||||
dto.setAccount(u.getAccount());
|
||||
|
||||
dto = getMeetScore(u, firstDayOfMonth, lastDayOfMonth, dto);
|
||||
dto.setDocumentQualityScore(BigDecimal.valueOf(10));
|
||||
// //拆分任务工时
|
||||
// dto.setSplitTimeScore(s);
|
||||
|
||||
@ -1117,8 +1192,7 @@ public class IZtCountService {
|
||||
//本月天数
|
||||
dto.setDays(BigDecimal.valueOf(workDaysInCurrentMonth));
|
||||
//本月天数 请假天数
|
||||
dto.setApprovalDays(applyTime
|
||||
);
|
||||
dto.setApprovalDays(applyTime);
|
||||
|
||||
|
||||
dto.setMeetScore(getSearchMeetScore(u, firstDayOfMonth, lastDayOfMonth));
|
||||
@ -1659,6 +1733,16 @@ public class IZtCountService {
|
||||
}else{
|
||||
examineTime = examineTime.add(performanceDTO.getExamineTime());
|
||||
}
|
||||
// if(multipleUserList.contains(u.getAccount())){
|
||||
// examineTime =
|
||||
// examineTime.add(
|
||||
// (BigDecimalUtils.isZero(performanceDTO.getAllocationTime())||BigDecimalUtils.isZero(totalTime))?BigDecimal.ZERO:
|
||||
// (performanceDTO.getAllocationTime().divide(totalTime,2,BigDecimal.ROUND_HALF_UP))
|
||||
// .multiply(performanceDTO.getExamineTime())
|
||||
// );
|
||||
// }else{
|
||||
// examineTime = examineTime.add(performanceDTO.getExamineTime());
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
@ -2297,7 +2381,10 @@ public class IZtCountService {
|
||||
|
||||
//项目管理员 线上BUG得分 满分20分
|
||||
private PerformanceDTO buildBugManage(PerformanceDTO result, ZtCountQo qo, List<PerformanceDTO> perList, Map<String, ZtUser> userMap) {
|
||||
List<Integer> projectIds = this.projectService.projectAuthList();
|
||||
List<ZtProject> list = projectService.list(new QueryWrapper<ZtProject>().lambda().eq(ZtProject::getType,"project").eq(ZtProject::getPm, result.getAccount()));
|
||||
|
||||
List<Integer> projectIds = list.stream().map(o -> o.getId()).collect(Collectors.toList());
|
||||
|
||||
if (CollectionUtils.isEmpty(projectIds)) {
|
||||
return result;
|
||||
}
|
||||
@ -2392,21 +2479,40 @@ public class IZtCountService {
|
||||
|
||||
}
|
||||
|
||||
private PerformanceDTO buildTaskManage(PerformanceDTO result, List<PerformanceDTO> perList, Map<String, ZtUser> userMap) {
|
||||
private PerformanceDTO buildTaskManage(PerformanceDTO result, List<PerformanceDTO> perList, Map<String, ZtUser> userMap,Date startDate,Date endDate,List<Integer> pids) {
|
||||
|
||||
BigDecimal totalTime = BigDecimal.ZERO;
|
||||
|
||||
|
||||
|
||||
//多个项目组人员
|
||||
List multipUser = this.getmultipleDepartProjectTeam(startDate, endDate);
|
||||
//分配总工时
|
||||
List<ZtTask> taskList = this.taskService.taskListByEIdsAndDate(startDate, endDate, this.projectService.allProductList());
|
||||
BigDecimal examineTime= BigDecimal.ZERO;
|
||||
BigDecimal allocationTime = BigDecimal.ZERO;
|
||||
for (PerformanceDTO d : perList) {
|
||||
ZtUser ztUser = userMap.get(d.getAccount());
|
||||
if (ztUser != null && ztUser.getUserType() == UserType.KFZ) {
|
||||
//可用工时
|
||||
totalTime = totalTime.add(d.getExamineTime());
|
||||
allocationTime = allocationTime.add(d.getAllocationTime());
|
||||
BigDecimal totalTime = floatBatchAdd(this.taskService.getNormalTaskList(taskList.stream().filter(o->o.getAssignedTo().equals(ztUser.getAccount())).collect(Collectors.toList())).stream().map(o -> o.getConsumed()).collect(Collectors.toList()));
|
||||
|
||||
if(multipUser.contains(ztUser.getAccount())){
|
||||
examineTime =
|
||||
examineTime.add(
|
||||
(BigDecimalUtils.isZero(d.getAllocationTime())||BigDecimalUtils.isZero(examineTime))?BigDecimal.ZERO:
|
||||
(d.getAllocationTime().divide(totalTime,2,BigDecimal.ROUND_HALF_UP))
|
||||
.multiply(d.getExamineTime())
|
||||
);
|
||||
}else{
|
||||
examineTime = examineTime.add(d.getExamineTime());
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
BigDecimal taskManageRate = BigDecimalUtils.isZero(allocationTime) ? BigDecimal.ZERO : totalTime.divide(allocationTime, 2, BigDecimal.ROUND_HALF_UP);
|
||||
BigDecimal taskManageRate = BigDecimalUtils.isZero(allocationTime) ? BigDecimal.ZERO :allocationTime .divide(examineTime, 2, BigDecimal.ROUND_HALF_UP);
|
||||
result.setAllocationTime(allocationTime);
|
||||
result.setExamineTime(totalTime);
|
||||
result.setExamineTime(examineTime);
|
||||
|
||||
BigDecimal taskManageScore = BigDecimal.ZERO;
|
||||
if (BigDecimalUtils.isZero(taskManageRate)) {
|
||||
@ -2419,6 +2525,9 @@ public class IZtCountService {
|
||||
taskManageScore = BigDecimal.valueOf((20 - ((96 - i) * 5)));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
result.setTaskManageScore(taskManageScore);
|
||||
result.setAllocationTimeManageRate(taskManageRate);
|
||||
return result;
|
||||
@ -2504,17 +2613,18 @@ public class IZtCountService {
|
||||
dataMap.put("任务总量", performanceDTO.getTotalTask().toString());
|
||||
dataMap.put("延期数量", performanceDTO.getDelayTask().toString());
|
||||
dataMap.put("及时完成率", performanceDTO.getFinishPunctuality().multiply(BigDecimal.valueOf(100)).toString());
|
||||
|
||||
dataMap.put("创新贡献", performanceDTO.getExcellentShare().toString());
|
||||
|
||||
dataMap.put("测试普通bug", performanceDTO.getDevSlightBug().toString());
|
||||
dataMap.put("测试重大bug", performanceDTO.getDevSeriousBug().toString());
|
||||
dataMap.put("缺陷检出率", performanceDTO.getBugFindRate().multiply(BigDecimal.valueOf(100)).toString());
|
||||
dataMap.put("缺陷检出分数", performanceDTO.getBugFindScore().multiply(BigDecimal.valueOf(100)).toString());
|
||||
dataMap.put("线上普通bug", performanceDTO.getSlightBug().toString());
|
||||
dataMap.put("线上重大bug", performanceDTO.getSeriousBug().toString());
|
||||
|
||||
dataMap.put("总分", devlopTotal(dataMap.get("准时率得分")
|
||||
, dataMap.get("缺陷检出率"), dataMap.get("测试文档"), dataMap.get("工作态度"), dataMap.get("质量贡献"), dataMap.get("线上Bug"))
|
||||
, dataMap.get("缺陷检出率"), dataMap.get("测试文档"), dataMap.get("工作态度"), dataMap.get("质量贡献"), dataMap.get("线上Bug"), dataMap.get("创新贡献"))
|
||||
);
|
||||
|
||||
writeXlsx(name, "templates/scope/测试工程师.xlsx", name + "测试.xlsx", dataMap);
|
||||
|
||||
|
||||
@ -2534,7 +2644,8 @@ public class IZtCountService {
|
||||
throw new BusinessException("请检查");
|
||||
}
|
||||
ZtUser u = this.userService.getByAccount(name);
|
||||
|
||||
result.setUserId(u.getId());
|
||||
result.setAccount(u.getAccount());
|
||||
String month = DateUtils.formatDate(d, "yyyy-MM");
|
||||
ZtMonthScore monthScore = this.monthScoreService.getOne(new QueryWrapper<ZtMonthScore>().lambda().eq(ZtMonthScore::getAccount, name)
|
||||
.eq(ZtMonthScore::getDateStr, month));
|
||||
@ -2548,7 +2659,9 @@ public class IZtCountService {
|
||||
Date firstDayOfMonth = DateUtils.getFirstDayOfMonth(d);
|
||||
Date lastDayOfMonth = DateUtils.getLastDayOfMonth(d);
|
||||
|
||||
List<Integer> pids = this.projectService.authProductList();
|
||||
List<Integer> pids = this.projectService.authProductListByAccount(name);
|
||||
|
||||
|
||||
if (CollectionUtils.isEmpty(pids)) {
|
||||
return result;
|
||||
}
|
||||
@ -2608,18 +2721,20 @@ public class IZtCountService {
|
||||
} else if (u.getUserType() == UserType.UI) {
|
||||
result = buildUiScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d);
|
||||
} else if (u.getUserType() == UserType.XMJL || u.getUserType() == UserType.XMGLY || u.getUserType() == UserType.GSGC) {
|
||||
List<ZtProject> list = projectService.list(new QueryWrapper<ZtProject>().lambda().eq(ZtProject::getPm, result.getAccount()));
|
||||
result = buildXMJLScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d);
|
||||
ZtCountQo ztCountQo = new ZtCountQo();
|
||||
BeanUtils.copyProperties(qo, ztCountQo);
|
||||
List<PerformanceDTO> perList = this.newPerformanceCount(ztCountQo);
|
||||
List<ZtProduct> ztProducts = this.productService.listByIds(pids);
|
||||
List<PerformanceDTO> perList = this.programCount(ztCountQo,ztProducts.stream().map(o->o.getProgram()).collect(Collectors.toList()));
|
||||
|
||||
result = buildTaskManage(result, perList, userMap);
|
||||
result = buildTaskManage(result, perList, userMap,firstDayOfMonth,lastDayOfMonth,pids);
|
||||
result = buildBugManage(result, ztCountQo, perList, userMap);
|
||||
|
||||
String versionPlanScore = versionPlanScore(ztCountQo, perList, userMap);
|
||||
result.setVersionPlanFinishedRate(new BigDecimal(versionPlanScore));
|
||||
result.setSystemStabilityScore(BigDecimal.valueOf(10));
|
||||
result.setProfessionalSkillEnhancementScore(BigDecimal.valueOf(5));
|
||||
result.setProfessionalSkillEnhancementScore(BigDecimal.valueOf(0));
|
||||
} else if (u.getUserType() == UserType.XMZL) {
|
||||
result = buildXMZLScore(u, approvalList, firstDayOfMonth, lastDayOfMonth, taskList, d);
|
||||
}
|
||||
@ -2683,15 +2798,31 @@ public class IZtCountService {
|
||||
BigDecimal examineTime = BigDecimal.ZERO;
|
||||
BigDecimal allocationTime = BigDecimal.ZERO;
|
||||
Map<String, ZtUser> userMap = this.userService.userMapByIds(null);
|
||||
List multipleUserList = getmultipleDepartProjectTeam(firstDayOfMonth, lastDayOfMonth);
|
||||
//分配总工时
|
||||
List<ZtTask> taskList = this.taskService.taskListByCondition(firstDayOfMonth, lastDayOfMonth, this.projectService.allProductList(),multipleUserList);
|
||||
|
||||
|
||||
|
||||
for (PerformanceDTO performanceDTO : performanceDTOS) {
|
||||
ZtUser ztUser = userMap.get(performanceDTO.getAccount());
|
||||
if (ztUser != null && ztUser.getUserType() == UserType.KFZ) {
|
||||
examineTime = examineTime.add(performanceDTO.getExamineTime());
|
||||
BigDecimal totalTime = floatBatchAdd(this.taskService.getNormalTaskList(taskList.stream().filter(o->o.getAssignedTo().equals(ztUser.getAccount())).collect(Collectors.toList())).stream().map(o -> o.getConsumed()).collect(Collectors.toList()));
|
||||
|
||||
if(multipleUserList.contains(ztUser.getAccount())){
|
||||
examineTime =
|
||||
examineTime.add(
|
||||
(BigDecimalUtils.isZero(performanceDTO.getAllocationTime())||BigDecimalUtils.isZero(totalTime))?BigDecimal.ZERO:
|
||||
(performanceDTO.getAllocationTime().divide(totalTime,2,BigDecimal.ROUND_HALF_UP))
|
||||
.multiply(performanceDTO.getExamineTime())
|
||||
);
|
||||
}else{
|
||||
examineTime = examineTime.add(performanceDTO.getExamineTime());
|
||||
}
|
||||
allocationTime = allocationTime.add(performanceDTO.getAllocationTime());
|
||||
}
|
||||
}
|
||||
obj.put("storyTime", BigDecimalUtils.isZero(examineTime) ? 0 : allocationTime.divide(examineTime, 2, BigDecimal.ROUND_HALF_UP));
|
||||
obj.put("storyTime", BigDecimalUtils.isZero(examineTime) ? 0 : allocationTime.divide(examineTime, 2, BigDecimal.ROUND_UP));
|
||||
map.put(DateUtils.formatDate(d, "yyyy-MM"), obj);
|
||||
|
||||
}
|
||||
@ -2726,6 +2857,8 @@ public class IZtCountService {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
for (int i = 0; i < 6; i++) {
|
||||
Date d = DateUtils.dateSubMonth(date, i);
|
||||
|
||||
@ -2752,14 +2885,16 @@ public class IZtCountService {
|
||||
countQo.setProject(id);
|
||||
countQo.setDate(firstDayOfMonth);
|
||||
List<PerformanceDTO> performanceDTOS = this.newPerformanceCount(countQo);
|
||||
BigDecimal examineTime = BigDecimal.ZERO;
|
||||
BigDecimal allocationTime = BigDecimal.ZERO;
|
||||
Map<String, ZtUser> userMap = this.userService.userMapByIds(null);
|
||||
//分配总工时
|
||||
|
||||
|
||||
|
||||
for (PerformanceDTO performanceDTO : performanceDTOS) {
|
||||
ZtUser ztUser = userMap.get(performanceDTO.getAccount());
|
||||
if (ztUser != null && ztUser.getUserType() == UserType.KFZ) {
|
||||
examineTime = examineTime.add(performanceDTO.getExamineTime());
|
||||
|
||||
allocationTime = allocationTime.add(performanceDTO.getAllocationTime());
|
||||
}
|
||||
}
|
||||
@ -2825,13 +2960,14 @@ public class IZtCountService {
|
||||
int kfzCount=0;
|
||||
List multipleUserList= getmultipleDepartProjectTeam(firstDayOfMonth,lastDayOfMonth);
|
||||
//分配总工时
|
||||
List<ZtTask> taskList = this.taskService.taskListByEIdsAndDate(firstDayOfMonth, lastDayOfMonth, pIds);
|
||||
BigDecimal totalTime = floatBatchAdd(this.taskService.getNormalTaskList(taskList).stream().map(o -> o.getConsumed()).collect(Collectors.toList()));
|
||||
List<ZtTask> taskList = this.taskService.taskListByEIdsAndDate(firstDayOfMonth, lastDayOfMonth, this.projectService.allProductList());
|
||||
|
||||
for (PerformanceDTO performanceDTO : performanceDTOS) {
|
||||
ZtUser ztUser = userMap.get(performanceDTO.getAccount());
|
||||
if (ztUser != null && ztUser.getUserType() == UserType.KFZ) {
|
||||
//如果多项目组 那么 分配任务工时占 总工时的% TODO
|
||||
BigDecimal totalTime = floatBatchAdd(this.taskService.getNormalTaskList(taskList.stream().filter(o->o.getAssignedTo().equals(ztUser.getAccount())).collect(Collectors.toList())).stream().map(o -> o.getConsumed()).collect(Collectors.toList()));
|
||||
|
||||
if(multipleUserList.contains(ztUser.getAccount())){
|
||||
examineTime =
|
||||
examineTime.add(
|
||||
@ -2890,7 +3026,7 @@ public class IZtCountService {
|
||||
// //线上bug率
|
||||
List<ZtBug> prodBugList = bugList.stream().filter(o -> o.getBugType().equals("prod")).collect(Collectors.toList());
|
||||
|
||||
dto.setProdBugRate((CollectionUtils.isEmpty(bugList) || BigDecimalUtils.isZero(dto.getAllocationTime())) ? BigDecimal.ZERO : BigDecimal.valueOf(prodBugList.size()).divide(dto.getAllocationTime(), 2, BigDecimal.ROUND_HALF_UP));
|
||||
dto.setProdBugRate((CollectionUtils.isEmpty(bugList) || BigDecimalUtils.isZero(dto.getAllocationTime())) ? BigDecimal.ZERO : BigDecimal.valueOf(prodBugList.size()).divide(dto.getAllocationTime(), 4, BigDecimal.ROUND_HALF_UP));
|
||||
|
||||
return dto;
|
||||
}
|
||||
|
@ -14,6 +14,7 @@ import com.sa.zentao.entity.*;
|
||||
import com.sa.zentao.enums.ActionStatus;
|
||||
import com.sa.zentao.enums.ActionType;
|
||||
import com.sa.zentao.enums.ProductStoryStatus;
|
||||
import com.sa.zentao.enums.ProjectTypeEnums;
|
||||
import com.sa.zentao.mapper.ZtProductMapper;
|
||||
import com.sa.zentao.mapper.ZtProjectMapper;
|
||||
import com.sa.zentao.qo.ZtProjectQo;
|
||||
@ -414,6 +415,8 @@ public class ZtProductServiceImpl extends ServiceImpl<ZtProductMapper, ZtProduct
|
||||
|
||||
@Autowired
|
||||
private IZtTaskService taskService;
|
||||
@Autowired
|
||||
private IZtProjectstoryService projectstoryService;
|
||||
|
||||
@Override
|
||||
public Map<String, Object> getAllBusinessSelect(ZtAllBusinessDTO dto) {
|
||||
@ -550,10 +553,19 @@ public class ZtProductServiceImpl extends ServiceImpl<ZtProductMapper, ZtProduct
|
||||
List<ZtProjectproduct> projectproductlist = this.projectproductService.list(new QueryWrapper<ZtProjectproduct>().lambda()
|
||||
.eq(ZtProjectproduct::getProduct, product.getId()));
|
||||
if(!CollectionUtils.isEmpty(projectproductlist)){
|
||||
List<ZtProject> ztProjects = this.projectService.listByIds(projectproductlist.stream().map(o -> o.getProject()).collect(Collectors.toList()));
|
||||
//产品集的项目
|
||||
List<Integer> projectIds = projectproductlist.stream().map(o -> o.getProject()).collect(Collectors.toList());
|
||||
//需求已经绑定了项目 需求只能绑定一次项目
|
||||
List<ZtProjectstory> projectStory = this.projectstoryService.projectListByStory(Arrays.asList(storyId), ProjectTypeEnums.project);
|
||||
if(!CollectionUtils.isEmpty(projectStory)){
|
||||
projectIds=Arrays.asList(projectStory.get(0).getProject());
|
||||
}
|
||||
List<ZtProject> ztProjects = this.projectService.listByIds(projectIds);
|
||||
|
||||
|
||||
result.put("project",ztProjects);
|
||||
List<ZtExecutionproject> list = this.executionprojectService.list(new QueryWrapper<ZtExecutionproject>().lambda()
|
||||
.in(ZtExecutionproject::getProject, ztProjects.stream().map(o -> o.getId()).collect(Collectors.toList())));
|
||||
.in(ZtExecutionproject::getProject, projectIds));
|
||||
List<ZtProject> execList=new ArrayList<>();
|
||||
if(!CollectionUtils.isEmpty(list)){
|
||||
execList = this.projectService
|
||||
|
@ -881,6 +881,31 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
||||
this.kanbanlaneService.addStory(excludeId, storyService.listByIds(storyIds));
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Integer> authProductListByAccount(String account) {
|
||||
|
||||
ZtUser user = userService.selectByName(account);
|
||||
String productIds = user.getProductIds();
|
||||
if (StringUtils.isEmpty(productIds)) {
|
||||
return new ArrayList<>();
|
||||
} else {
|
||||
String[] split = productIds.split(",");
|
||||
List<Integer> result = new ArrayList();
|
||||
for (String s : split) {
|
||||
result.add(Integer.valueOf(s));
|
||||
}
|
||||
if (CollectionUtils.isEmpty(result)) {
|
||||
return result;
|
||||
}
|
||||
List<ZtProduct> list = this.productService.list(new QueryWrapper<ZtProduct>().lambda().in(ZtProduct::getProgram, result));
|
||||
if (CollectionUtils.isEmpty(list)) {
|
||||
return result;
|
||||
} else {
|
||||
return list.stream().map(o -> o.getId()).collect(Collectors.toList());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
@ -901,6 +926,18 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
||||
return this.baseMapper.selectList(new QueryWrapper<ZtProject>()
|
||||
.lambda().eq(ZtProject::getType, "program")).stream().map(o -> o.getId()).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Integer> allProductList() {
|
||||
List<Integer> authList = this.allAuthList();
|
||||
List<ZtProduct> list = this.productService.list(new QueryWrapper<ZtProduct>().lambda().in(ZtProduct::getProgram, authList));
|
||||
if (CollectionUtils.isEmpty(list)) {
|
||||
return authList;
|
||||
} else {
|
||||
return list.stream().map(o -> o.getId()).collect(Collectors.toList());
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Integer> authList() {
|
||||
LoginRiskUser loginRiskUser = RiskUserThreadLocal.get();
|
||||
@ -927,7 +964,33 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
||||
|
||||
}
|
||||
|
||||
|
||||
public List<Integer> getProjectAuthListByUserId(Integer userId){
|
||||
ZtUser user = userService.getById(userId);
|
||||
// if (user.getAccount().equals("admin")) {
|
||||
// return this.baseMapper.selectList(new QueryWrapper<ZtProject>()
|
||||
// .lambda().eq(ZtProject::getType, "project")).stream().map(o -> o.getId()).collect(Collectors.toList());
|
||||
// }
|
||||
String productIds = user.getProductIds();
|
||||
if (StringUtils.isEmpty(productIds)) {
|
||||
return new ArrayList<>();
|
||||
} else {
|
||||
String[] split = productIds.split(",");
|
||||
List<Integer> result = new ArrayList();
|
||||
for (String s : split) {
|
||||
result.add(Integer.valueOf(s));
|
||||
}
|
||||
List<ZtProduct> list = this.productService.list(new QueryWrapper<ZtProduct>().lambda().in(ZtProduct::getProgram, result));
|
||||
if (CollectionUtils.isEmpty(list)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<ZtProjectproduct> projectList = this.projectproductService.list(new QueryWrapper<ZtProjectproduct>().lambda()
|
||||
.in(ZtProjectproduct::getProduct, list.stream().map(o -> o.getId()).collect(Collectors.toList())));
|
||||
if (CollectionUtils.isEmpty(projectList)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
return projectList.stream().map(o -> o.getProject()).collect(Collectors.toList());
|
||||
}
|
||||
}
|
||||
//项目list
|
||||
@Override
|
||||
public List<Integer> projectAuthList() {
|
||||
@ -1261,18 +1324,12 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
||||
return new HashMap<>();
|
||||
}
|
||||
|
||||
List<ZtTask> list = this.taskService.list(new QueryWrapper<ZtTask>().lambda()
|
||||
List<ZtTask> list = this.taskService.list(new QueryWrapper<ZtTask>().lambda().select(SFunctionColums.taskColumes())
|
||||
.notIn(ZtTask::getStatus,"cancel","closed","reviewing","draft")
|
||||
.in(ZtTask::getExecution, execList.stream().map(o -> o.getExecution()).collect(Collectors.toList())));
|
||||
if (CollectionUtils.isEmpty(list)) {
|
||||
return new HashMap<>();
|
||||
}
|
||||
//工时
|
||||
List<ZtEffort> efforts = this.effortService.list(new QueryWrapper<ZtEffort>().lambda()
|
||||
.eq(ZtEffort::getObjecttype, "task")
|
||||
.in(ZtEffort::getObjectid, list.stream().map(o -> o.getId()).collect(Collectors.toList()))
|
||||
.gt(ZtEffort::getDate, new Date(firstDayOfMonth.getTime() - 2000)).lt(ZtEffort::getDate, lastDayOfMonth)
|
||||
);
|
||||
|
||||
|
||||
if (CollectionUtils.isEmpty(execList)) {
|
||||
@ -1358,12 +1415,6 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
||||
|
||||
m.put("task", "");
|
||||
}
|
||||
//使用
|
||||
// double sum = fList.stream().mapToDouble(o -> o.getConsumed()).sum();
|
||||
//任务id
|
||||
// List<Integer> taskIds = fList.stream().map(o -> o.getObjectid()).collect(Collectors.toList());
|
||||
|
||||
// m.put("use",sum+"");
|
||||
|
||||
l.add(m);
|
||||
|
||||
|
@ -651,10 +651,20 @@ public class ZtStoryServiceImpl extends ServiceImpl<ZtStoryMapper, ZtStory> impl
|
||||
.filter(o -> o.getExecution().intValue() == execId.intValue()).collect(Collectors.toList());
|
||||
Integer project = fProjectList.get(0).getProject();
|
||||
|
||||
//当前迭代绑定的项目
|
||||
List<ZtProjectstory> list = this.projectstoryService.list(new QueryWrapper<ZtProjectstory>().lambda()
|
||||
.eq(ZtProjectstory::getProject, project)
|
||||
.eq(ZtProjectstory::getStory, storyId)
|
||||
);
|
||||
List<ZtProjectstory> bindProject = this.projectstoryService.list(new QueryWrapper<ZtProjectstory>().lambda()
|
||||
.ne(ZtProjectstory::getProject, project)
|
||||
.eq(ZtProjectstory::getStory, storyId)
|
||||
);
|
||||
if(!CollectionUtils.isEmpty(bindProject)){
|
||||
Integer oldProject = bindProject.get(0).getProject();
|
||||
//切换的迭代不是当前需求已经绑定的迭代
|
||||
this.projectstoryService.remove(new QueryWrapper<ZtProjectstory>().lambda().eq(ZtProjectstory::getProject, oldProject).eq(ZtProjectstory::getStory, storyId));
|
||||
}
|
||||
|
||||
if (CollectionUtils.isEmpty(list)) {
|
||||
ZtProjectDTO d = new ZtProjectDTO();
|
||||
|
@ -342,6 +342,26 @@ public class ZtTaskServiceImpl extends ServiceImpl<ZtTaskMapper, ZtTask> impleme
|
||||
return taskList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ZtTask> taskListByCondition(Date firstDayOfMonth, Date lastDayOfMonth, List<Integer> pids, List<Integer> uids) {
|
||||
if (CollectionUtils.isEmpty(pids)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
if (CollectionUtils.isEmpty(uids)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
if (firstDayOfMonth == null || lastDayOfMonth == null) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<ZtTask> taskList = this.list(new QueryWrapper<ZtTask>().lambda()
|
||||
.select(SFunctionColums.taskColumes())
|
||||
.in(ZtTask::getProduct,pids)
|
||||
.in(ZtTask::getAssignedTo,uids)
|
||||
.ge(ZtTask::getFinishedDate, firstDayOfMonth).le(ZtTask::getFinishedDate, lastDayOfMonth));
|
||||
|
||||
return taskList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ZtTask> getDelayTask(List<ZtTask> t) {
|
||||
if (CollectionUtils.isEmpty(t)) {
|
||||
|
342
src/main/java/com/sa/zentao/utils/CarConstant.java
Normal file
342
src/main/java/com/sa/zentao/utils/CarConstant.java
Normal file
@ -0,0 +1,342 @@
|
||||
package com.sa.zentao.utils;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
public class CarConstant {
|
||||
/**
|
||||
* 车辆类型
|
||||
*/
|
||||
public static final Map<String,String> MODELTYPE=new HashMap<>(){
|
||||
{
|
||||
// 添加所有车辆类型数据
|
||||
// B系列 - 半挂车
|
||||
put("B11", "重型普通半挂车");
|
||||
put("B12", "重型厢式半挂车");
|
||||
put("B13", "重型罐式半挂车");
|
||||
put("B14", "重型平板半挂车");
|
||||
put("B15", "重型集装箱半挂车");
|
||||
put("B16", "重型自卸半挂车");
|
||||
put("B17", "重型特殊结构半挂车");
|
||||
put("B18", "重型仓栅式半挂车");
|
||||
put("B19", "重型旅居半挂车");
|
||||
put("B1A", "重型专项作业半挂车");
|
||||
put("B1B", "重型低平板半挂车");
|
||||
put("B1C", "重型车辆运输半挂车");
|
||||
put("B1D", "重型罐式自卸半挂车");
|
||||
put("B1E", "重型平板自卸半挂车");
|
||||
put("B1F", "重型集装箱自卸半挂车");
|
||||
put("B1G", "重型特殊结构自卸半挂车");
|
||||
put("B1H", "重型仓栅式自卸半挂车");
|
||||
put("B1J", "重型专项作业自卸半挂车");
|
||||
put("B1K", "重型低平板自卸半挂车");
|
||||
put("B1U", "重型中置轴旅居挂车");
|
||||
put("B1V", "重型中置轴车辆运输车");
|
||||
put("B1W", "重型中置轴普通挂车");
|
||||
put("B21", "中型普通半挂车");
|
||||
put("B22", "中型厢式半挂车");
|
||||
put("B23", "中型罐式半挂车");
|
||||
put("B24", "中型平板半挂车");
|
||||
put("B25", "中型集装箱半挂车");
|
||||
put("B26", "中型自卸半挂车");
|
||||
put("B27", "中型特殊结构半挂车");
|
||||
put("B28", "中型仓栅式半挂车");
|
||||
put("B29", "中型旅居半挂车");
|
||||
put("B2A", "中型专项作业半挂车");
|
||||
put("B2B", "中型低平板半挂车");
|
||||
put("B2C", "中型车辆运输半挂车");
|
||||
put("B2D", "中型罐式自卸半挂车");
|
||||
put("B2E", "中型平板自卸半挂车");
|
||||
put("B2F", "中型集装箱自卸半挂车");
|
||||
put("B2G", "中型特殊结构自卸半挂车");
|
||||
put("B2H", "中型仓栅式自卸半挂车");
|
||||
put("B2J", "中型专项作业自卸半挂车");
|
||||
put("B2K", "中型低平板自卸半挂车");
|
||||
put("B2U", "中型中置轴旅居挂车");
|
||||
put("B2V", "中型中置轴车辆运输车");
|
||||
put("B2W", "中型中置轴普通挂车");
|
||||
put("B31", "轻型普通半挂车");
|
||||
put("B32", "轻型厢式半挂车");
|
||||
put("B33", "轻型罐式半挂车");
|
||||
put("B34", "轻型平板半挂车");
|
||||
put("B35", "轻型自卸半挂车");
|
||||
put("B36", "轻型仓栅式半挂车");
|
||||
put("B37", "轻型旅居半挂车");
|
||||
put("B38", "轻型专项作业半挂车");
|
||||
put("B39", "轻型低平板半挂车");
|
||||
put("B3C", "轻型车辆运输半挂车");
|
||||
put("B3D", "轻型罐式自卸半挂车");
|
||||
put("B3E", "轻型平板自卸半挂车");
|
||||
put("B3F", "轻型集装箱自卸半挂车");
|
||||
put("B3G", "轻型特殊结构自卸半挂车");
|
||||
put("B3H", "轻型仓栅式自卸半挂车");
|
||||
put("B3J", "轻型专项作业自卸半挂车");
|
||||
put("B3K", "轻型低平板自卸半挂车");
|
||||
put("B3U", "轻型中置轴旅居挂车");
|
||||
put("B3V", "轻型中置轴车辆运输车");
|
||||
put("B3W", "轻型中置轴普通挂车");
|
||||
|
||||
// D系列 - 电车
|
||||
put("D11", "无轨电车");
|
||||
put("D12", "有轨电车");
|
||||
|
||||
// G系列 - 全挂车
|
||||
put("G11", "重型普通全挂车");
|
||||
put("G12", "重型厢式全挂车");
|
||||
put("G13", "重型罐式全挂车");
|
||||
put("G14", "重型平板全挂车");
|
||||
put("G15", "重型集装箱全挂车");
|
||||
put("G16", "重型自卸全挂车");
|
||||
put("G17", "重型仓栅式全挂车");
|
||||
put("G18", "重型旅居全挂车");
|
||||
put("G19", "重型专项作业全挂车");
|
||||
put("G1A", "重型厢式自卸全挂车");
|
||||
put("G1B", "重型罐式自卸全挂车");
|
||||
put("G1C", "重型平板自卸全挂车");
|
||||
put("G1D", "重型集装箱自卸全挂极");
|
||||
put("G1E", "重型仓栅式自卸全挂车");
|
||||
put("G1F", "重型专项作业自卸全挂车");
|
||||
put("G21", "中型普通全挂车");
|
||||
put("G22", "中型厢式全挂车");
|
||||
put("G23", "中型罐式全挂车");
|
||||
put("G24", "中型平板全挂车");
|
||||
put("G25", "中型集装箱全挂车");
|
||||
put("极26", "中型自卸全挂车");
|
||||
put("G27", "中型仓栅式全挂车");
|
||||
put("G28", "中型旅居全挂车");
|
||||
put("G29", "中型专项作业全挂车");
|
||||
put("G2A", "中型厢式自卸全挂车");
|
||||
put("G2B", "中型罐式自卸全挂车");
|
||||
put("G2C", "中型平板自卸全挂车");
|
||||
put("G2D", "中型集装箱自卸全挂车");
|
||||
put("G2E", "中型仓栅式自卸全挂车");
|
||||
put("G2F", "中型专项作业自卸全挂车");
|
||||
put("G31", "轻型普通全挂车");
|
||||
put("G32", "轻型厢式全挂车");
|
||||
put("G33", "轻型罐式全挂车");
|
||||
put("G34", "轻型平板全挂车");
|
||||
put("G35", "轻型自卸全挂车");
|
||||
put("G36", "轻型仓栅式全挂车");
|
||||
put("G37", "轻型旅居全挂车");
|
||||
put("G38", "轻型专项作业全挂车");
|
||||
put("G3A", "轻型厢式自卸全挂车");
|
||||
put("G3B", "轻型罐式自卸全挂车");
|
||||
put("G3C", "轻型平板自卸全挂车");
|
||||
put("G3D", "轻型集装箱自卸全挂车");
|
||||
put("G3E", "轻型仓栅式自卸全挂车");
|
||||
put("G3F", "轻型专项作业自卸全挂车");
|
||||
|
||||
// H系列 - 货车
|
||||
put("H11", "重型普通货车");
|
||||
put("H12", "重型厢式货车");
|
||||
put("H13", "重型封闭货车");
|
||||
put("H14", "重型罐式货车");
|
||||
put("H15", "重型平板货车");
|
||||
put("H16", "重型集装厢车");
|
||||
put("H17", "重型自卸货车");
|
||||
put("H18", "重型特殊结构货车");
|
||||
put("H19", "重型仓栅式货车");
|
||||
put("H1A", "重型车辆运输车");
|
||||
put("H1B", "重型厢式自卸货车");
|
||||
put("H1C", "重型罐式自卸货车");
|
||||
put("H1D", "重型平板自卸货车");
|
||||
put("H1E", "重型集装厢自卸货车");
|
||||
put("H1F", "重型特殊结构自卸货车");
|
||||
put("H1G", "重型仓栅式自卸货车");
|
||||
put("H21", "中型普通货车");
|
||||
put("H22", "中型厢式货车");
|
||||
put("H23", "中型封闭货车");
|
||||
put("H24", "中型罐式货车");
|
||||
put("H25", "中型平板货车");
|
||||
put("H26", "中型集装厢车");
|
||||
put("H27", "中型自卸货车");
|
||||
put("H28", "中型特殊结构货车");
|
||||
put("H29", "中型仓栅式货车");
|
||||
put("H2A", "中型车辆运输车");
|
||||
put("H2B", "中型厢式自卸货车");
|
||||
put("H2C", "中型罐式自卸货车");
|
||||
put("H2D", "中型平板自卸货车");
|
||||
put("H2E", "中型集装厢自卸货车");
|
||||
put("H2F", "中型特殊结构自卸货车");
|
||||
put("H2G", "中型仓栅式自卸货车");
|
||||
put("H31", "轻型普通货车");
|
||||
put("H32", "轻型厢式货车");
|
||||
put("H33", "轻型封闭货车");
|
||||
put("H34", "轻型罐式货车");
|
||||
put("H35", "轻型平板货车");
|
||||
put("H37", "轻型自卸货车");
|
||||
put("H38", "轻型特殊结构货车");
|
||||
put("H39", "轻型仓栅式货车");
|
||||
put("H3A", "轻型车辆运输车");
|
||||
put("H3B", "轻型厢式自卸货车");
|
||||
put("H3C", "轻型罐式自卸货车");
|
||||
put("H3D", "轻型平板自卸货车");
|
||||
put("H3F", "轻型特殊结构自卸货车");
|
||||
put("H3G", "轻型仓栅式自卸货车");
|
||||
put("H41", "微型普通货车");
|
||||
put("H42", "微型厢式货车");
|
||||
put("H43", "微型封闭货车");
|
||||
put("H44", "微型罐式货车");
|
||||
put("H45", "微型自卸货车");
|
||||
put("H46", "微型特殊结构货车");
|
||||
put("H47", "微型仓栅式货车");
|
||||
put("H4A", "微型车辆运输车");
|
||||
put("H4B", "微型厢式自卸货车");
|
||||
put("H4C", "微型罐式自卸货车");
|
||||
put("H4F", "微型特殊结构自卸货车");
|
||||
put("H4G", "微型仓栅式自卸货车");
|
||||
put("H51", "普通低速货车");
|
||||
put("H52", "厢式低速货车");
|
||||
put("H53", "罐式低速货车");
|
||||
put("H54", "自卸低速货车");
|
||||
put("H55", "仓栅式低速货车");
|
||||
put("H5B", "厢式自卸低速货车");
|
||||
put("H5C", "罐式自卸低速货车");
|
||||
|
||||
// 其他类型
|
||||
put("J11", "轮式装载机械");
|
||||
put("J12", "轮式挖掘机械");
|
||||
put("J13", "轮式平地机械");
|
||||
put("K11", "大型普通客车");
|
||||
put("K12", "大型双层客车");
|
||||
put("K13", "大型卧铺客车");
|
||||
put("K14", "大型铰接客车");
|
||||
put("K15", "大型越野客车");
|
||||
put("K16", "大型轿车");
|
||||
put("K17", "大型专用客车");
|
||||
put("K18", "大型专用校车");
|
||||
put("K21", "中型普通客车");
|
||||
put("K22", "中型双层客车");
|
||||
put("K23", "中型卧铺客车");
|
||||
put("K24", "中型铰接客车");
|
||||
put("K25", "中型越野客车");
|
||||
put("K26", "中型轿车");
|
||||
put("K27", "中型专用客车");
|
||||
put("K28", "中型专用校车");
|
||||
put("K31", "小型普通客车");
|
||||
put("K32", "小型越野客车");
|
||||
put("K33", "小型轿车");
|
||||
put("K34", "小型专用客车");
|
||||
put("K38", "小型专用校车");
|
||||
put("K39", "小型面包车");
|
||||
put("K41", "微型普通客车");
|
||||
put("K42", "微型越野客车");
|
||||
put("K43", "微型轿车");
|
||||
put("K49", "微型面包车");
|
||||
put("M11", "普通正三轮摩托车");
|
||||
put("M12", "轻便正三轮摩托车");
|
||||
put("M13", "正三轮载客摩托车");
|
||||
put("M14", "正三轮载货摩托车");
|
||||
put("M15", "侧三轮摩托车");
|
||||
put("M21", "普通二轮摩托车");
|
||||
put("M22", "轻便二轮摩托车");
|
||||
put("N11", "三轮汽车");
|
||||
put("Q11", "重型半挂牵引车");
|
||||
put("Q12", "重型全挂牵引车");
|
||||
put("Q21", "中型半挂牵引车");
|
||||
put("Q22", "中型全挂牵引车");
|
||||
put("Q31", "轻型半挂牵引车");
|
||||
put("Q32", "轻型全挂牵引车");
|
||||
put("T11", "大型轮式拖拉机");
|
||||
put("T21", "小型轮式拖拉机");
|
||||
put("T22", "手扶拖拉机");
|
||||
put("T23", "手扶变形运输机");
|
||||
put("X99", "其它");
|
||||
put("Z11", "大型非载货专项作业车");
|
||||
put("Z12", "大型载货专项作业车");
|
||||
put("Z21", "中型非载货专项作业车");
|
||||
put("Z22", "中型载货专项作业车");
|
||||
put("Z31", "小型非载货专项作业车");
|
||||
put("Z32", "小型载货专项作业车");
|
||||
put("Z41", "微型非载货专项作业车");
|
||||
put("Z42", "微型载货专项作业车");
|
||||
put("Z51", "重型非载货专项作业车");
|
||||
put("Z52", "重型载货专项作业车");
|
||||
put("Z71", "轻型非载货专项作业车");
|
||||
put("Z72", "轻型载货专项作业车");
|
||||
}
|
||||
};
|
||||
/**
|
||||
* 使用性质
|
||||
*/
|
||||
public static final Map<String,String> USEDTYPE=new HashMap<>(){{
|
||||
put("A", "非营运");
|
||||
put("B", "公路客运");
|
||||
put("C", "公交客运");
|
||||
put("D", "出租客运");
|
||||
put("E", "旅游客运");
|
||||
put("F", "货运");
|
||||
put("G", "租赁");
|
||||
put("H", "警用");
|
||||
put("I", "消防");
|
||||
put("J", "救护");
|
||||
put("K", "工程救险");
|
||||
put("L", "营转非");
|
||||
put("M", "出租转非");
|
||||
put("N", "教练");
|
||||
put("O", "幼儿校车");
|
||||
put("P", "小学生校车");
|
||||
put("Q", "初中生校车");
|
||||
put("R", "危化品运输");
|
||||
put("S", "中小学生校车");
|
||||
put("Z", "其他");
|
||||
}};
|
||||
|
||||
/**
|
||||
* 车辆状态
|
||||
*/
|
||||
public static final Map<String,String> CARSTATUS=new HashMap<>(){{
|
||||
put("A", "正常");
|
||||
put("B", "转出");
|
||||
put("O", "锁定");
|
||||
put("N", "事故逃逸");
|
||||
put("M", "强制注销");
|
||||
put("L", "暂扣");
|
||||
put("I", "事故未处理");
|
||||
put("J", "嫌疑车");
|
||||
put("C", "被盗抢");
|
||||
put("D", "停驶");
|
||||
put("E", "注销");
|
||||
put("G", "违法未处理");
|
||||
put("H", "海关监管");
|
||||
put("K", "查封");
|
||||
put("P", "达到报废标准公告牌证作废");
|
||||
put("Q", "逾期未检验");
|
||||
put("Z", "其他");
|
||||
}};
|
||||
|
||||
/**
|
||||
* 车辆状态
|
||||
*/
|
||||
public static final Map<String,Map<String,String>> OPERATINGCAR=new HashMap<String,Map<String,String>>(){{
|
||||
put("月度里程疑似度等级", new HashMap<>(){{
|
||||
put("10%","1-800");
|
||||
put("20%","800-1600");
|
||||
put("30%","1600-3000");
|
||||
put("40%","3000-5000");
|
||||
put("50%","5000以上");
|
||||
}});
|
||||
put("季度里程疑似度等级", new HashMap<>(){{
|
||||
put("10%","1-1200");
|
||||
put("20%","1200-2500");
|
||||
put("30%","2500-5000");
|
||||
put("40%","5000-10000");
|
||||
put("50%","10000以上");
|
||||
}});
|
||||
put("半年度里程疑似度等级", new HashMap<>(){{
|
||||
put("10%","1-2000");
|
||||
put("20%","2000-4000");
|
||||
put("30%","4000-8000");
|
||||
put("40%","8000-16000");
|
||||
put("50%","16000以上");
|
||||
}});
|
||||
put("年度里程疑似度等级", new HashMap<>(){{
|
||||
put("10%","1-6300");
|
||||
put("20%","6300-9700");
|
||||
put("30%","9700-14000");
|
||||
put("40%","14000-18000");
|
||||
put("50%","18000以上");
|
||||
}});
|
||||
}};
|
||||
|
||||
}
|
39
src/main/resources/mapper/CarDrivingLicenseMapper.xml
Normal file
39
src/main/resources/mapper/CarDrivingLicenseMapper.xml
Normal file
@ -0,0 +1,39 @@
|
||||
<?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.sa.zentao.mapper.CarDrivingLicenseMapper">
|
||||
<resultMap id="BaseResultMap" type="com.sa.zentao.entity.CarDrivingLicense">
|
||||
<result column="id" property="id" />
|
||||
<result column="hpzl" property="hpzl" />
|
||||
<result column="hphm" property="hphm" />
|
||||
<result column="clpp1" property="clpp1" />
|
||||
<result column="clxh" property="clxh" />
|
||||
<result column="clsbdh" property="clsbdh" />
|
||||
<result column="fdjh" property="fdjh" />
|
||||
<result column="cllx" property="cllx" />
|
||||
<result column="csys" property="csys" />
|
||||
<result column="syxz" property="syxz" />
|
||||
<result column="syr" property="syr" />
|
||||
<result column="ccdjrq" property="ccdjrq" />
|
||||
<result column="yxqz" property="yxqz" />
|
||||
<result column="qzbfqz" property="qzbfqz" />
|
||||
<result column="zt" property="zt" />
|
||||
<result column="fdjxh" property="fdjxh" />
|
||||
<result column="rlzl" property="rlzl" />
|
||||
<result column="pl" property="pl" />
|
||||
<result column="gl" property="gl" />
|
||||
<result column="zs" property="zs" />
|
||||
<result column="zj" property="zj" />
|
||||
<result column="qlj" property="qlj" />
|
||||
<result column="hlj" property="hlj" />
|
||||
<result column="zzl" property="zzl" />
|
||||
<result column="zbzl" property="zbzl" />
|
||||
<result column="hdzzl" property="hdzzl" />
|
||||
<result column="hdzk" property="hdzk" />
|
||||
<result column="ccrq" property="ccrq" />
|
||||
<result column="owner" property="owner" />
|
||||
<result column="status" property="status" />
|
||||
<result column="msg" property="msg" />
|
||||
<result column="create_time" property="createTime" />
|
||||
</resultMap>
|
||||
|
||||
</mapper>
|
18
src/main/resources/mapper/CarFiveTypeMapper.xml
Normal file
18
src/main/resources/mapper/CarFiveTypeMapper.xml
Normal file
@ -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.sa.zentao.mapper.CarFiveTypeMapper">
|
||||
<resultMap id="BaseResultMap" type="com.sa.zentao.entity.CarFiveType">
|
||||
<result column="id" property="id" />
|
||||
<result column="vin" property="vin" />
|
||||
<result column="engine" property="engine" />
|
||||
<result column="car_name" property="carName" />
|
||||
<result column="record_date" property="recordDate" />
|
||||
<result column="create_time" property="createTime" />
|
||||
<result column="vehicle_model" property="vehicleModel" />
|
||||
<result column="plate" property="plate" />
|
||||
<result column="type" property="type" />
|
||||
<result column="usage" property="usage" />
|
||||
<result column="cllb" property="cllb" />
|
||||
</resultMap>
|
||||
|
||||
</mapper>
|
11
src/main/resources/mapper/CarOperatingVehicleLevelMapper.xml
Normal file
11
src/main/resources/mapper/CarOperatingVehicleLevelMapper.xml
Normal file
@ -0,0 +1,11 @@
|
||||
<?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.sa.zentao.mapper.CarOperatingVehicleLevelMapper">
|
||||
<resultMap id="BaseResultMap" type="com.sa.zentao.entity.CarOperatingVehicleLevel">
|
||||
<result column="id" property="id" />
|
||||
<result column="name" property="name" />
|
||||
<result column="value" property="value" />
|
||||
<result column="create_time" property="createTime" />
|
||||
</resultMap>
|
||||
|
||||
</mapper>
|
Reference in New Issue
Block a user