feat(): 创建不同的页面,修改登录携带的值
parent
6775891272
commit
859b06ecad
|
@ -0,0 +1,65 @@
|
|||
package com.muyu.common.core.utils;
|
||||
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @author DongZl
|
||||
* @description: 对象工具类
|
||||
* @Date 2023-10-9 下午 04:56
|
||||
*/
|
||||
public class ObjUtils {
|
||||
|
||||
/**
|
||||
* 兼容
|
||||
* CharSequence: 如果长度为零,则认为为空。
|
||||
* Array: 如果长度为零,则认为为空。
|
||||
* Collection: 如果元素为零,则认为为空。
|
||||
* Map: 如果键值映射为零,则认为为空。
|
||||
* @param o 对象
|
||||
* @return 如果对象具有受支持的类型并且为空或null,则为true,否则为false
|
||||
*/
|
||||
public static boolean notNull(Object o){
|
||||
return ObjectUtils.isNotEmpty(o);
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断long类型不为0
|
||||
* @param val 值
|
||||
* @return 返回值不为0
|
||||
*/
|
||||
public static boolean notNull(Long val){
|
||||
return ObjectUtils.isNotEmpty(val) && val != 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断Integer类型不为0
|
||||
* @param val 值
|
||||
* @return 返回值不为0
|
||||
*/
|
||||
public static boolean notNull(Integer val){
|
||||
return ObjectUtils.isNotEmpty(val) && val != 0;
|
||||
}
|
||||
/**
|
||||
* 判断BigDecimal类型不为0
|
||||
* @param val 值
|
||||
* @return 返回值不为0
|
||||
*/
|
||||
public static boolean notNull(BigDecimal val){
|
||||
return ObjectUtils.isNotEmpty(val) && val.doubleValue() == 0.00;
|
||||
}
|
||||
/**
|
||||
* 判断BigDecimal类型不为0
|
||||
* @param val 值
|
||||
* @return 返回值不为0
|
||||
*/
|
||||
public static boolean notChildNull(Object[] val){
|
||||
for (Object o : val) {
|
||||
if (!notNull(o)){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
|
@ -137,6 +137,16 @@ public class SysUser extends BaseEntity {
|
|||
*/
|
||||
private Long roleId;
|
||||
|
||||
/**
|
||||
* 登录类型
|
||||
*/
|
||||
private String type;
|
||||
|
||||
/**
|
||||
* 企业ID
|
||||
*/
|
||||
private Integer enterpriseId;
|
||||
|
||||
public SysUser (Long userId) {
|
||||
this.userId = userId;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-customer-business</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-customer-business-client</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,30 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-customer-business</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-customer-business-common</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-core</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-security</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
|
@ -0,0 +1,197 @@
|
|||
package com.muyu.customer.business.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.muyu.common.security.utils.SecurityUtils;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.annotation.Excel;
|
||||
import com.muyu.customer.business.domain.req.VehicleQueryReq;
|
||||
import com.muyu.customer.business.domain.req.VehicleSaveReq;
|
||||
import com.muyu.customer.business.domain.req.VehicleEditReq;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 车辆录入对象 vehicle
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@TableName("vehicle")
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ApiModel(value = "Vehicle", description = "车辆录入")
|
||||
public class Vehicle extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 车辆id */
|
||||
@TableId(value = "id",type = IdType.AUTO)
|
||||
@ApiModelProperty(name = "车辆id", value = "车辆id")
|
||||
private Long id;
|
||||
|
||||
/** 车辆vin */
|
||||
@Excel(name = "车辆vin")
|
||||
@ApiModelProperty(name = "车辆vin", value = "车辆vin")
|
||||
private String vin;
|
||||
|
||||
/** 品牌 */
|
||||
@Excel(name = "品牌")
|
||||
@ApiModelProperty(name = "品牌", value = "品牌")
|
||||
private String brand;
|
||||
|
||||
/** 型号 */
|
||||
@Excel(name = "型号")
|
||||
@ApiModelProperty(name = "型号", value = "型号")
|
||||
private String model;
|
||||
|
||||
/** 生产日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "生产日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "生产日期", value = "生产日期")
|
||||
private Date productionDate;
|
||||
|
||||
/** 车身类型 */
|
||||
@Excel(name = "车身类型")
|
||||
@ApiModelProperty(name = "车身类型", value = "车身类型")
|
||||
private String bodyType;
|
||||
|
||||
/** 车身颜色 */
|
||||
@Excel(name = "车身颜色")
|
||||
@ApiModelProperty(name = "车身颜色", value = "车身颜色")
|
||||
private String color;
|
||||
|
||||
/** 发动机排量 */
|
||||
@Excel(name = "发动机排量")
|
||||
@ApiModelProperty(name = "发动机排量", value = "发动机排量")
|
||||
private BigDecimal engineCapacity;
|
||||
|
||||
/** 燃油类型 */
|
||||
@Excel(name = "燃油类型")
|
||||
@ApiModelProperty(name = "燃油类型", value = "燃油类型")
|
||||
private String fuelType;
|
||||
|
||||
/** 变速器类型 */
|
||||
@Excel(name = "变速器类型")
|
||||
@ApiModelProperty(name = "变速器类型", value = "变速器类型")
|
||||
private String transmission;
|
||||
|
||||
/** 驱动方式 */
|
||||
@Excel(name = "驱动方式")
|
||||
@ApiModelProperty(name = "驱动方式", value = "驱动方式")
|
||||
private String driveType;
|
||||
|
||||
/** 行驶里程 */
|
||||
@Excel(name = "行驶里程")
|
||||
@ApiModelProperty(name = "行驶里程", value = "行驶里程")
|
||||
private BigDecimal mileage;
|
||||
|
||||
/** 注册日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "注册日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "注册日期", value = "注册日期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 车牌号码 */
|
||||
@Excel(name = "车牌号码")
|
||||
@ApiModelProperty(name = "车牌号码", value = "车牌号码")
|
||||
private String licenseNumber;
|
||||
|
||||
/** 持有者 */
|
||||
@Excel(name = "持有者")
|
||||
@ApiModelProperty(name = "持有者", value = "持有者")
|
||||
private String holder;
|
||||
|
||||
/** 车辆类型 */
|
||||
@Excel(name = "车辆类型")
|
||||
@ApiModelProperty(name = "车辆类型", value = "车辆类型")
|
||||
private String vehicleType;
|
||||
|
||||
/**
|
||||
* 查询构造器
|
||||
*/
|
||||
public static Vehicle queryBuild( VehicleQueryReq vehicleQueryReq){
|
||||
return Vehicle.builder()
|
||||
.vin(vehicleQueryReq.getVin())
|
||||
.brand(vehicleQueryReq.getBrand())
|
||||
.model(vehicleQueryReq.getModel())
|
||||
.productionDate(vehicleQueryReq.getProductionDate())
|
||||
.bodyType(vehicleQueryReq.getBodyType())
|
||||
.color(vehicleQueryReq.getColor())
|
||||
.engineCapacity(vehicleQueryReq.getEngineCapacity())
|
||||
.fuelType(vehicleQueryReq.getFuelType())
|
||||
.transmission(vehicleQueryReq.getTransmission())
|
||||
.driveType(vehicleQueryReq.getDriveType())
|
||||
.mileage(vehicleQueryReq.getMileage())
|
||||
.registrationDate(vehicleQueryReq.getRegistrationDate())
|
||||
.licenseNumber(vehicleQueryReq.getLicenseNumber())
|
||||
.holder(vehicleQueryReq.getHolder())
|
||||
.vehicleType(vehicleQueryReq.getVehicleType())
|
||||
.build();
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加构造器
|
||||
*/
|
||||
public static Vehicle saveBuild(VehicleSaveReq vehicleSaveReq){
|
||||
return Vehicle.builder()
|
||||
.vin(vehicleSaveReq.getVin())
|
||||
.brand(vehicleSaveReq.getBrand())
|
||||
.model(vehicleSaveReq.getModel())
|
||||
.productionDate(vehicleSaveReq.getProductionDate())
|
||||
.bodyType(vehicleSaveReq.getBodyType())
|
||||
.color(vehicleSaveReq.getColor())
|
||||
.engineCapacity(vehicleSaveReq.getEngineCapacity())
|
||||
.fuelType(vehicleSaveReq.getFuelType())
|
||||
.transmission(vehicleSaveReq.getTransmission())
|
||||
.driveType(vehicleSaveReq.getDriveType())
|
||||
.mileage(vehicleSaveReq.getMileage())
|
||||
.registrationDate(vehicleSaveReq.getRegistrationDate())
|
||||
.licenseNumber(vehicleSaveReq.getLicenseNumber())
|
||||
.holder(vehicleSaveReq.getHolder())
|
||||
.vehicleType(vehicleSaveReq.getVehicleType())
|
||||
.createTime(new Date())
|
||||
.createBy(SecurityUtils.getUsername())
|
||||
.remark(vehicleSaveReq.getRemark())
|
||||
.build();
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改构造器
|
||||
*/
|
||||
public static Vehicle editBuild(Long id, VehicleEditReq vehicleEditReq){
|
||||
return Vehicle.builder()
|
||||
.id(id)
|
||||
.vin(vehicleEditReq.getVin())
|
||||
.brand(vehicleEditReq.getBrand())
|
||||
.model(vehicleEditReq.getModel())
|
||||
.productionDate(vehicleEditReq.getProductionDate())
|
||||
.bodyType(vehicleEditReq.getBodyType())
|
||||
.color(vehicleEditReq.getColor())
|
||||
.engineCapacity(vehicleEditReq.getEngineCapacity())
|
||||
.fuelType(vehicleEditReq.getFuelType())
|
||||
.transmission(vehicleEditReq.getTransmission())
|
||||
.driveType(vehicleEditReq.getDriveType())
|
||||
.mileage(vehicleEditReq.getMileage())
|
||||
.registrationDate(vehicleEditReq.getRegistrationDate())
|
||||
.licenseNumber(vehicleEditReq.getLicenseNumber())
|
||||
.holder(vehicleEditReq.getHolder())
|
||||
.vehicleType(vehicleEditReq.getVehicleType())
|
||||
.updateTime(new Date())
|
||||
.updateBy(SecurityUtils.getUsername())
|
||||
.remark(vehicleEditReq.getRemark())
|
||||
.build();
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,91 @@
|
|||
package com.muyu.customer.business.domain.req;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 车辆录入对象 vehicle
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@ApiModel(value = "VehicleEditReq", description = "车辆录入")
|
||||
public class VehicleEditReq extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 车辆vin */
|
||||
@ApiModelProperty(name = "车辆vin", value = "车辆vin")
|
||||
private String vin;
|
||||
|
||||
/** 品牌 */
|
||||
@ApiModelProperty(name = "品牌", value = "品牌")
|
||||
private String brand;
|
||||
|
||||
/** 型号 */
|
||||
@ApiModelProperty(name = "型号", value = "型号")
|
||||
private String model;
|
||||
|
||||
/** 生产日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "生产日期", value = "生产日期")
|
||||
private Date productionDate;
|
||||
|
||||
/** 车身类型 */
|
||||
@ApiModelProperty(name = "车身类型", value = "车身类型")
|
||||
private String bodyType;
|
||||
|
||||
/** 车身颜色 */
|
||||
@ApiModelProperty(name = "车身颜色", value = "车身颜色")
|
||||
private String color;
|
||||
|
||||
/** 发动机排量 */
|
||||
@ApiModelProperty(name = "发动机排量", value = "发动机排量")
|
||||
private BigDecimal engineCapacity;
|
||||
|
||||
/** 燃油类型 */
|
||||
@ApiModelProperty(name = "燃油类型", value = "燃油类型")
|
||||
private String fuelType;
|
||||
|
||||
/** 变速器类型 */
|
||||
@ApiModelProperty(name = "变速器类型", value = "变速器类型")
|
||||
private String transmission;
|
||||
|
||||
/** 驱动方式 */
|
||||
@ApiModelProperty(name = "驱动方式", value = "驱动方式")
|
||||
private String driveType;
|
||||
|
||||
/** 行驶里程 */
|
||||
@ApiModelProperty(name = "行驶里程", value = "行驶里程")
|
||||
private BigDecimal mileage;
|
||||
|
||||
/** 注册日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "注册日期", value = "注册日期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 车牌号码 */
|
||||
@ApiModelProperty(name = "车牌号码", value = "车牌号码")
|
||||
private String licenseNumber;
|
||||
|
||||
/** 持有者 */
|
||||
@ApiModelProperty(name = "持有者", value = "持有者")
|
||||
private String holder;
|
||||
|
||||
/** 车辆类型 */
|
||||
@ApiModelProperty(name = "车辆类型", value = "车辆类型")
|
||||
private String vehicleType;
|
||||
|
||||
}
|
|
@ -0,0 +1,91 @@
|
|||
package com.muyu.customer.business.domain.req;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 车辆录入对象 vehicle
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@ApiModel(value = "VehicleQueryReq", description = "车辆录入")
|
||||
public class VehicleQueryReq extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 车辆vin */
|
||||
@ApiModelProperty(name = "车辆vin", value = "车辆vin")
|
||||
private String vin;
|
||||
|
||||
/** 品牌 */
|
||||
@ApiModelProperty(name = "品牌", value = "品牌")
|
||||
private String brand;
|
||||
|
||||
/** 型号 */
|
||||
@ApiModelProperty(name = "型号", value = "型号")
|
||||
private String model;
|
||||
|
||||
/** 生产日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "生产日期", value = "生产日期")
|
||||
private Date productionDate;
|
||||
|
||||
/** 车身类型 */
|
||||
@ApiModelProperty(name = "车身类型", value = "车身类型")
|
||||
private String bodyType;
|
||||
|
||||
/** 车身颜色 */
|
||||
@ApiModelProperty(name = "车身颜色", value = "车身颜色")
|
||||
private String color;
|
||||
|
||||
/** 发动机排量 */
|
||||
@ApiModelProperty(name = "发动机排量", value = "发动机排量")
|
||||
private BigDecimal engineCapacity;
|
||||
|
||||
/** 燃油类型 */
|
||||
@ApiModelProperty(name = "燃油类型", value = "燃油类型")
|
||||
private String fuelType;
|
||||
|
||||
/** 变速器类型 */
|
||||
@ApiModelProperty(name = "变速器类型", value = "变速器类型")
|
||||
private String transmission;
|
||||
|
||||
/** 驱动方式 */
|
||||
@ApiModelProperty(name = "驱动方式", value = "驱动方式")
|
||||
private String driveType;
|
||||
|
||||
/** 行驶里程 */
|
||||
@ApiModelProperty(name = "行驶里程", value = "行驶里程")
|
||||
private BigDecimal mileage;
|
||||
|
||||
/** 注册日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "注册日期", value = "注册日期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 车牌号码 */
|
||||
@ApiModelProperty(name = "车牌号码", value = "车牌号码")
|
||||
private String licenseNumber;
|
||||
|
||||
/** 持有者 */
|
||||
@ApiModelProperty(name = "持有者", value = "持有者")
|
||||
private String holder;
|
||||
|
||||
/** 车辆类型 */
|
||||
@ApiModelProperty(name = "车辆类型", value = "车辆类型")
|
||||
private String vehicleType;
|
||||
|
||||
}
|
|
@ -0,0 +1,111 @@
|
|||
package com.muyu.customer.business.domain.req;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 车辆录入对象 vehicle
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@ApiModel(value = "VehicleSaveReq", description = "车辆录入")
|
||||
public class VehicleSaveReq extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 车辆id */
|
||||
|
||||
@ApiModelProperty(name = "车辆id", value = "车辆id")
|
||||
private Long id;
|
||||
|
||||
/** 车辆vin */
|
||||
|
||||
@ApiModelProperty(name = "车辆vin", value = "车辆vin")
|
||||
private String vin;
|
||||
|
||||
/** 品牌 */
|
||||
|
||||
@ApiModelProperty(name = "品牌", value = "品牌")
|
||||
private String brand;
|
||||
|
||||
/** 型号 */
|
||||
|
||||
@ApiModelProperty(name = "型号", value = "型号")
|
||||
private String model;
|
||||
|
||||
/** 生产日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
|
||||
@ApiModelProperty(name = "生产日期", value = "生产日期")
|
||||
private Date productionDate;
|
||||
|
||||
/** 车身类型 */
|
||||
|
||||
@ApiModelProperty(name = "车身类型", value = "车身类型")
|
||||
private String bodyType;
|
||||
|
||||
/** 车身颜色 */
|
||||
|
||||
@ApiModelProperty(name = "车身颜色", value = "车身颜色")
|
||||
private String color;
|
||||
|
||||
/** 发动机排量 */
|
||||
|
||||
@ApiModelProperty(name = "发动机排量", value = "发动机排量")
|
||||
private BigDecimal engineCapacity;
|
||||
|
||||
/** 燃油类型 */
|
||||
|
||||
@ApiModelProperty(name = "燃油类型", value = "燃油类型")
|
||||
private String fuelType;
|
||||
|
||||
/** 变速器类型 */
|
||||
|
||||
@ApiModelProperty(name = "变速器类型", value = "变速器类型")
|
||||
private String transmission;
|
||||
|
||||
/** 驱动方式 */
|
||||
|
||||
@ApiModelProperty(name = "驱动方式", value = "驱动方式")
|
||||
private String driveType;
|
||||
|
||||
/** 行驶里程 */
|
||||
|
||||
@ApiModelProperty(name = "行驶里程", value = "行驶里程")
|
||||
private BigDecimal mileage;
|
||||
|
||||
/** 注册日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
|
||||
@ApiModelProperty(name = "注册日期", value = "注册日期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 车牌号码 */
|
||||
|
||||
@ApiModelProperty(name = "车牌号码", value = "车牌号码")
|
||||
private String licenseNumber;
|
||||
|
||||
/** 持有者 */
|
||||
|
||||
@ApiModelProperty(name = "持有者", value = "持有者")
|
||||
private String holder;
|
||||
|
||||
/** 车辆类型 */
|
||||
|
||||
@ApiModelProperty(name = "车辆类型", value = "车辆类型")
|
||||
private String vehicleType;
|
||||
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-customer-business</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-customer-business-remote</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,115 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-customer-business</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-customer-business-server</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-customer-business-common</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</dependency>
|
||||
<!-- SpringCloud Alibaba Nacos -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringCloud Alibaba Nacos Config -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringCloud Alibaba Sentinel -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-sentinel</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringBoot Actuator -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-actuator</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- Swagger UI -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger-ui</artifactId>
|
||||
<version>${swagger.fox.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Mysql Connector -->
|
||||
<dependency>
|
||||
<groupId>com.mysql</groupId>
|
||||
<artifactId>mysql-connector-j</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common DataSource -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-datasource</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common DataScope -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-datascope</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common Log -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-log</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common Swagger -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-swagger</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<finalName>${project.artifactId}</finalName>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>repackage</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<!-- 加入maven deploy插件,当在deploy时,忽略些model-->
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,23 @@
|
|||
package com.muyu.customer.business;
|
||||
|
||||
import com.muyu.common.security.annotation.EnableCustomConfig;
|
||||
import com.muyu.common.security.annotation.EnableMyFeignClients;
|
||||
import com.muyu.common.swagger.annotation.EnableCustomSwagger2;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
|
||||
/**
|
||||
* 车联网客户业务系统启动类 MuYuCustomerBusinessApplication
|
||||
*
|
||||
* @author DeKangLiu
|
||||
* Date 2024/5/27 16:51
|
||||
*/
|
||||
@EnableCustomConfig
|
||||
@EnableCustomSwagger2
|
||||
@EnableMyFeignClients
|
||||
@SpringBootApplication
|
||||
public class MuYuCustomerBusinessApplication {
|
||||
public static void main (String[] args) {
|
||||
SpringApplication.run(MuYuCustomerBusinessApplication.class, args);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,111 @@
|
|||
package com.muyu.customer.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import io.swagger.annotations.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.muyu.common.core.domain.Result;
|
||||
import com.muyu.common.core.utils.poi.ExcelUtil;
|
||||
import com.muyu.common.core.web.controller.BaseController;
|
||||
import com.muyu.common.log.annotation.Log;
|
||||
import com.muyu.common.log.enums.BusinessType;
|
||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||
import com.muyu.customer.business.domain.Vehicle;
|
||||
import com.muyu.customer.business.domain.req.VehicleQueryReq;
|
||||
import com.muyu.customer.business.domain.req.VehicleSaveReq;
|
||||
import com.muyu.customer.business.domain.req.VehicleEditReq;
|
||||
import com.muyu.customer.business.service.VehicleService;
|
||||
import com.muyu.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 车辆录入Controller
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Api(tags = "车辆录入")
|
||||
@RestController
|
||||
@RequestMapping("/vehicle")
|
||||
public class VehicleController extends BaseController {
|
||||
@Autowired
|
||||
private VehicleService vehicleService;
|
||||
|
||||
/**
|
||||
* 查询车辆录入列表
|
||||
*/
|
||||
@ApiOperation("获取车辆录入列表")
|
||||
@RequiresPermissions("customerBusiness:vehicle:list")
|
||||
@GetMapping("/list")
|
||||
public Result<TableDataInfo<Vehicle>> list(VehicleQueryReq vehicleQueryReq) {
|
||||
startPage();
|
||||
List<Vehicle> list = vehicleService.list(Vehicle.queryBuild(vehicleQueryReq));
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出车辆录入列表
|
||||
*/
|
||||
@ApiOperation("导出车辆录入列表")
|
||||
@RequiresPermissions("customerBusiness:vehicle:export")
|
||||
@Log(title = "车辆录入", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, Vehicle vehicle) {
|
||||
List<Vehicle> list = vehicleService.list(vehicle);
|
||||
ExcelUtil<Vehicle> util = new ExcelUtil<Vehicle>(Vehicle.class);
|
||||
util.exportExcel(response, list, "车辆录入数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取车辆录入详细信息
|
||||
*/
|
||||
@ApiOperation("获取车辆录入详细信息")
|
||||
@RequiresPermissions("customerBusiness:vehicle:query")
|
||||
@GetMapping(value = "/{id}")
|
||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = Long.class)
|
||||
public Result<Vehicle> getInfo(@PathVariable("id") Long id) {
|
||||
return Result.success(vehicleService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增车辆录入
|
||||
*/
|
||||
@RequiresPermissions("customerBusiness:vehicle:add")
|
||||
@Log(title = "车辆录入", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
@ApiOperation("新增车辆录入")
|
||||
public Result<String> add(@RequestBody VehicleSaveReq vehicleSaveReq) {
|
||||
return toAjax(vehicleService.save(Vehicle.saveBuild(vehicleSaveReq)));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改车辆录入
|
||||
*/
|
||||
@RequiresPermissions("customerBusiness:vehicle:edit")
|
||||
@Log(title = "车辆录入", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/{id}")
|
||||
@ApiOperation("修改车辆录入")
|
||||
public Result<String> edit(@PathVariable Long id, @RequestBody VehicleEditReq vehicleEditReq) {
|
||||
return toAjax(vehicleService.updateById(Vehicle.editBuild(id,vehicleEditReq)));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除车辆录入
|
||||
*/
|
||||
@RequiresPermissions("customerBusiness:vehicle:remove")
|
||||
@Log(title = "车辆录入", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
@ApiOperation("删除车辆录入")
|
||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = String.class, example = "1,2,3,4")
|
||||
public Result<String> remove(@PathVariable List<Long> ids) {
|
||||
return toAjax(vehicleService.removeBatchByIds(ids));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.muyu.customer.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.muyu.customer.business.domain.Vehicle;
|
||||
|
||||
/**
|
||||
* 车辆录入Mapper接口
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
public interface VehicleMapper extends BaseMapper<Vehicle> {
|
||||
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
package com.muyu.customer.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.muyu.customer.business.domain.Vehicle;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* 车辆录入Service接口
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
public interface VehicleService extends IService<Vehicle> {
|
||||
/**
|
||||
* 查询车辆录入列表
|
||||
*
|
||||
* @param vehicle 车辆录入
|
||||
* @return 车辆录入集合
|
||||
*/
|
||||
public List<Vehicle> list(Vehicle vehicle);
|
||||
|
||||
}
|
|
@ -0,0 +1,101 @@
|
|||
package com.muyu.customer.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.muyu.common.core.utils.ObjUtils;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.muyu.customer.business.mapper.VehicleMapper;
|
||||
import com.muyu.customer.business.domain.Vehicle;
|
||||
import com.muyu.customer.business.service.VehicleService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
|
||||
/**
|
||||
* 车辆录入Service业务层处理
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class VehicleServiceImpl extends ServiceImpl<VehicleMapper, Vehicle> implements VehicleService {
|
||||
|
||||
/**
|
||||
* 查询车辆录入列表
|
||||
*
|
||||
* @param vehicle 车辆录入
|
||||
* @return 车辆录入
|
||||
*/
|
||||
@Override
|
||||
public List<Vehicle> list(Vehicle vehicle) {
|
||||
LambdaQueryWrapper<Vehicle> queryWrapper = new LambdaQueryWrapper<>();
|
||||
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getVin())){
|
||||
queryWrapper.eq(Vehicle::getVin, vehicle.getVin());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getBrand())){
|
||||
queryWrapper.eq(Vehicle::getBrand, vehicle.getBrand());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getModel())){
|
||||
queryWrapper.eq(Vehicle::getModel, vehicle.getModel());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getProductionDate())){
|
||||
queryWrapper.eq(Vehicle::getProductionDate, vehicle.getProductionDate());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getBodyType())){
|
||||
queryWrapper.eq(Vehicle::getBodyType, vehicle.getBodyType());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getColor())){
|
||||
queryWrapper.eq(Vehicle::getColor, vehicle.getColor());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getEngineCapacity())){
|
||||
queryWrapper.eq(Vehicle::getEngineCapacity, vehicle.getEngineCapacity());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getFuelType())){
|
||||
queryWrapper.eq(Vehicle::getFuelType, vehicle.getFuelType());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getTransmission())){
|
||||
queryWrapper.eq(Vehicle::getTransmission, vehicle.getTransmission());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getDriveType())){
|
||||
queryWrapper.eq(Vehicle::getDriveType, vehicle.getDriveType());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getMileage())){
|
||||
queryWrapper.eq(Vehicle::getMileage, vehicle.getMileage());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getRegistrationDate())){
|
||||
queryWrapper.eq(Vehicle::getRegistrationDate, vehicle.getRegistrationDate());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getLicenseNumber())){
|
||||
queryWrapper.eq(Vehicle::getLicenseNumber, vehicle.getLicenseNumber());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getHolder())){
|
||||
queryWrapper.eq(Vehicle::getHolder, vehicle.getHolder());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(vehicle.getVehicleType())){
|
||||
queryWrapper.eq(Vehicle::getVehicleType, vehicle.getVehicleType());
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
return list(queryWrapper);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,2 @@
|
|||
Spring Boot Version: ${spring-boot.version}
|
||||
Spring Application Name: ${spring.application.name}
|
|
@ -0,0 +1,30 @@
|
|||
# Tomcat
|
||||
server:
|
||||
port: 9207
|
||||
|
||||
# Spring
|
||||
spring:
|
||||
application:
|
||||
# 应用名称
|
||||
name: muyu-customer-business
|
||||
profiles:
|
||||
# 环境配置
|
||||
active: dev
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
# 服务注册地址
|
||||
server-addr: 127.0.0.1:8848
|
||||
namespace: jinmo
|
||||
config:
|
||||
# 配置中心地址
|
||||
server-addr: 127.0.0.1:8848
|
||||
namespace: jinmo
|
||||
# 配置文件格式
|
||||
file-extension: yml
|
||||
# 共享配置
|
||||
shared-configs:
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
logging:
|
||||
level:
|
||||
com.muyu.customer.business.mapper: DEBUG
|
|
@ -0,0 +1,74 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration scan="true" scanPeriod="60 seconds" debug="false">
|
||||
<!-- 日志存放路径 -->
|
||||
<property name="log.path" value="logs/muyu-customer-business"/>
|
||||
<!-- 日志输出格式 -->
|
||||
<property name="log.pattern" value="%d{HH:mm:ss.SSS} [%thread] %-5level %logger{20} - [%method,%line] - %msg%n"/>
|
||||
|
||||
<!-- 控制台输出 -->
|
||||
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<encoder>
|
||||
<pattern>${log.pattern}</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<!-- 系统日志输出 -->
|
||||
<appender name="file_info" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>${log.path}/info.log</file>
|
||||
<!-- 循环政策:基于时间创建日志文件 -->
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<!-- 日志文件名格式 -->
|
||||
<fileNamePattern>${log.path}/info.%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<!-- 日志最大的历史 60天 -->
|
||||
<maxHistory>60</maxHistory>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>${log.pattern}</pattern>
|
||||
</encoder>
|
||||
<filter class="ch.qos.logback.classic.filter.LevelFilter">
|
||||
<!-- 过滤的级别 -->
|
||||
<level>INFO</level>
|
||||
<!-- 匹配时的操作:接收(记录) -->
|
||||
<onMatch>ACCEPT</onMatch>
|
||||
<!-- 不匹配时的操作:拒绝(不记录) -->
|
||||
<onMismatch>DENY</onMismatch>
|
||||
</filter>
|
||||
</appender>
|
||||
|
||||
<appender name="file_error" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>${log.path}/error.log</file>
|
||||
<!-- 循环政策:基于时间创建日志文件 -->
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<!-- 日志文件名格式 -->
|
||||
<fileNamePattern>${log.path}/error.%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<!-- 日志最大的历史 60天 -->
|
||||
<maxHistory>60</maxHistory>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>${log.pattern}</pattern>
|
||||
</encoder>
|
||||
<filter class="ch.qos.logback.classic.filter.LevelFilter">
|
||||
<!-- 过滤的级别 -->
|
||||
<level>ERROR</level>
|
||||
<!-- 匹配时的操作:接收(记录) -->
|
||||
<onMatch>ACCEPT</onMatch>
|
||||
<!-- 不匹配时的操作:拒绝(不记录) -->
|
||||
<onMismatch>DENY</onMismatch>
|
||||
</filter>
|
||||
</appender>
|
||||
|
||||
<!-- 系统模块日志级别控制 -->
|
||||
<logger name="com.muyu" level="info"/>
|
||||
<!-- Spring日志级别控制 -->
|
||||
<logger name="org.springframework" level="warn"/>
|
||||
|
||||
<root level="info">
|
||||
<appender-ref ref="console"/>
|
||||
</root>
|
||||
|
||||
<!--系统操作日志-->
|
||||
<root level="info">
|
||||
<appender-ref ref="file_info"/>
|
||||
<appender-ref ref="file_error"/>
|
||||
</root>
|
||||
</configuration>
|
|
@ -0,0 +1,34 @@
|
|||
<?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.muyu.customer.business.mapper.VehicleMapper">
|
||||
|
||||
<resultMap type="com.muyu.customer.business.domain.Vehicle" id="VehicleResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="vin" column="vin" />
|
||||
<result property="brand" column="brand" />
|
||||
<result property="model" column="model" />
|
||||
<result property="productionDate" column="production_date" />
|
||||
<result property="bodyType" column="body_type" />
|
||||
<result property="color" column="color" />
|
||||
<result property="engineCapacity" column="engine_capacity" />
|
||||
<result property="fuelType" column="fuel_type" />
|
||||
<result property="transmission" column="transmission" />
|
||||
<result property="driveType" column="drive_type" />
|
||||
<result property="mileage" column="mileage" />
|
||||
<result property="registrationDate" column="registration_date" />
|
||||
<result property="licenseNumber" column="license_number" />
|
||||
<result property="holder" column="holder" />
|
||||
<result property="vehicleType" column="vehicle_type" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectVehicleVo">
|
||||
select id, vin, brand, model, production_date, body_type, color, engine_capacity, fuel_type, transmission, drive_type, mileage, registration_date, license_number, holder, vehicle_type, create_by, create_time, update_by, update_time, remark from vehicle
|
||||
</sql>
|
||||
</mapper>
|
|
@ -0,0 +1,29 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-modules</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
<packaging>pom</packaging>
|
||||
<description>
|
||||
muyu-customer-business车联网客户业务系统模块
|
||||
</description>
|
||||
<modules>
|
||||
<module>muyu-customer-business-common</module>
|
||||
<module>muyu-customer-business-client</module>
|
||||
<module>muyu-customer-business-remote</module>
|
||||
<module>muyu-customer-business-server</module>
|
||||
</modules>
|
||||
<artifactId>muyu-customer-business</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-net-working</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-net-working-client</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,26 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-net-working</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-net-working-common</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-core</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,196 @@
|
|||
package com.muyu.net.working.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.annotation.Excel;
|
||||
import com.muyu.net.working.domain.req.EnterpriseQueryReq;
|
||||
import com.muyu.net.working.domain.req.EnterpriseSaveReq;
|
||||
import com.muyu.net.working.domain.req.EnterpriseEditReq;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 企业信息对象 enterprise
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@TableName("enterprise")
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ApiModel(value = "Enterprise", description = "企业信息")
|
||||
public class Enterprise extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
@TableId(value = "id",type = IdType.AUTO)
|
||||
@ApiModelProperty(name = "主键", value = "主键")
|
||||
private String id;
|
||||
|
||||
/** 企业名称 */
|
||||
@Excel(name = "企业名称")
|
||||
@ApiModelProperty(name = "企业名称", value = "企业名称")
|
||||
private String ebterpriseName;
|
||||
|
||||
/** 法定代表人 */
|
||||
@Excel(name = "法定代表人")
|
||||
@ApiModelProperty(name = "法定代表人", value = "法定代表人")
|
||||
private String legalPerson;
|
||||
|
||||
/** 经营执照凭证号码 */
|
||||
@Excel(name = "经营执照凭证号码")
|
||||
@ApiModelProperty(name = "经营执照凭证号码", value = "经营执照凭证号码")
|
||||
private String businessLincenseNumber;
|
||||
|
||||
/** 企业成立时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "企业成立时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "企业成立时间", value = "企业成立时间")
|
||||
private Date estabinessDate;
|
||||
|
||||
/** 经营范围 */
|
||||
@Excel(name = "经营范围")
|
||||
@ApiModelProperty(name = "经营范围", value = "经营范围")
|
||||
private String businessScope;
|
||||
|
||||
/** 注册地址 */
|
||||
@Excel(name = "注册地址")
|
||||
@ApiModelProperty(name = "注册地址", value = "注册地址")
|
||||
private String address;
|
||||
|
||||
/** 企业联系方式 */
|
||||
@Excel(name = "企业联系方式")
|
||||
@ApiModelProperty(name = "企业联系方式", value = "企业联系方式")
|
||||
private String contactPhone;
|
||||
|
||||
/** 公司邮箱 */
|
||||
@Excel(name = "公司邮箱")
|
||||
@ApiModelProperty(name = "公司邮箱", value = "公司邮箱")
|
||||
private String email;
|
||||
|
||||
/** 企业当前状态 */
|
||||
@Excel(name = "企业当前状态")
|
||||
@ApiModelProperty(name = "企业当前状态", value = "企业当前状态")
|
||||
private String status;
|
||||
|
||||
/** 企业入驻平台时期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "企业入驻平台时期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "企业入驻平台时期", value = "企业入驻平台时期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 企业认证id */
|
||||
@Excel(name = "企业认证id")
|
||||
@ApiModelProperty(name = "企业认证id", value = "企业认证id")
|
||||
private Long certificationId;
|
||||
|
||||
/** 认证时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "认证时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "认证时间", value = "认证时间")
|
||||
private Date authenticationDate;
|
||||
|
||||
/** 服务级别 */
|
||||
@Excel(name = "服务级别")
|
||||
@ApiModelProperty(name = "服务级别", value = "服务级别")
|
||||
private Long serviceLevel;
|
||||
|
||||
/** 开通服务id */
|
||||
@Excel(name = "开通服务id")
|
||||
@ApiModelProperty(name = "开通服务id", value = "开通服务id")
|
||||
private Long openServerId;
|
||||
|
||||
/** 增值服务id */
|
||||
@Excel(name = "增值服务id")
|
||||
@ApiModelProperty(name = "增值服务id", value = "增值服务id")
|
||||
private Long addServerId;
|
||||
|
||||
/**
|
||||
* 查询构造器
|
||||
*/
|
||||
public static Enterprise queryBuild( EnterpriseQueryReq enterpriseQueryReq){
|
||||
return Enterprise.builder()
|
||||
.ebterpriseName(enterpriseQueryReq.getEbterpriseName())
|
||||
.legalPerson(enterpriseQueryReq.getLegalPerson())
|
||||
.businessLincenseNumber(enterpriseQueryReq.getBusinessLincenseNumber())
|
||||
.estabinessDate(enterpriseQueryReq.getEstabinessDate())
|
||||
.businessScope(enterpriseQueryReq.getBusinessScope())
|
||||
.address(enterpriseQueryReq.getAddress())
|
||||
.contactPhone(enterpriseQueryReq.getContactPhone())
|
||||
.email(enterpriseQueryReq.getEmail())
|
||||
.status(enterpriseQueryReq.getStatus())
|
||||
.registrationDate(enterpriseQueryReq.getRegistrationDate())
|
||||
.certificationId(enterpriseQueryReq.getCertificationId())
|
||||
.authenticationDate(enterpriseQueryReq.getAuthenticationDate())
|
||||
.serviceLevel(enterpriseQueryReq.getServiceLevel())
|
||||
.openServerId(enterpriseQueryReq.getOpenServerId())
|
||||
.addServerId(enterpriseQueryReq.getAddServerId())
|
||||
.build();
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加构造器
|
||||
*/
|
||||
public static Enterprise saveBuild(EnterpriseSaveReq enterpriseSaveReq){
|
||||
return Enterprise.builder()
|
||||
.ebterpriseName(enterpriseSaveReq.getEbterpriseName())
|
||||
.legalPerson(enterpriseSaveReq.getLegalPerson())
|
||||
.businessLincenseNumber(enterpriseSaveReq.getBusinessLincenseNumber())
|
||||
.estabinessDate(enterpriseSaveReq.getEstabinessDate())
|
||||
.businessScope(enterpriseSaveReq.getBusinessScope())
|
||||
.address(enterpriseSaveReq.getAddress())
|
||||
.contactPhone(enterpriseSaveReq.getContactPhone())
|
||||
.email(enterpriseSaveReq.getEmail())
|
||||
.status(enterpriseSaveReq.getStatus())
|
||||
.registrationDate(enterpriseSaveReq.getRegistrationDate())
|
||||
.certificationId(enterpriseSaveReq.getCertificationId())
|
||||
.authenticationDate(enterpriseSaveReq.getAuthenticationDate())
|
||||
.serviceLevel(enterpriseSaveReq.getServiceLevel())
|
||||
.openServerId(enterpriseSaveReq.getOpenServerId())
|
||||
.addServerId(enterpriseSaveReq.getAddServerId())
|
||||
.createBy(enterpriseSaveReq.getCreateBy())
|
||||
.createTime(new Date())
|
||||
.remark(enterpriseSaveReq.getRemark())
|
||||
.build();
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改构造器
|
||||
*/
|
||||
public static Enterprise editBuild(String id, EnterpriseEditReq enterpriseEditReq){
|
||||
return Enterprise.builder()
|
||||
.id(id)
|
||||
.ebterpriseName(enterpriseEditReq.getEbterpriseName())
|
||||
.legalPerson(enterpriseEditReq.getLegalPerson())
|
||||
.businessLincenseNumber(enterpriseEditReq.getBusinessLincenseNumber())
|
||||
.estabinessDate(enterpriseEditReq.getEstabinessDate())
|
||||
.businessScope(enterpriseEditReq.getBusinessScope())
|
||||
.address(enterpriseEditReq.getAddress())
|
||||
.contactPhone(enterpriseEditReq.getContactPhone())
|
||||
.email(enterpriseEditReq.getEmail())
|
||||
.status(enterpriseEditReq.getStatus())
|
||||
.registrationDate(enterpriseEditReq.getRegistrationDate())
|
||||
.certificationId(enterpriseEditReq.getCertificationId())
|
||||
.authenticationDate(enterpriseEditReq.getAuthenticationDate())
|
||||
.serviceLevel(enterpriseEditReq.getServiceLevel())
|
||||
.openServerId(enterpriseEditReq.getOpenServerId())
|
||||
.addServerId(enterpriseEditReq.getAddServerId())
|
||||
.updateBy(enterpriseEditReq.getUpdateBy())
|
||||
.updateTime(new Date())
|
||||
.remark(enterpriseEditReq.getRemark())
|
||||
.build();
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,91 @@
|
|||
package com.muyu.net.working.domain.req;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 企业信息对象 enterprise
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@ApiModel(value = "EnterpriseEditReq", description = "企业信息")
|
||||
public class EnterpriseEditReq extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 企业名称 */
|
||||
@ApiModelProperty(name = "企业名称", value = "企业名称")
|
||||
private String ebterpriseName;
|
||||
|
||||
/** 法定代表人 */
|
||||
@ApiModelProperty(name = "法定代表人", value = "法定代表人")
|
||||
private String legalPerson;
|
||||
|
||||
/** 经营执照凭证号码 */
|
||||
@ApiModelProperty(name = "经营执照凭证号码", value = "经营执照凭证号码")
|
||||
private String businessLincenseNumber;
|
||||
|
||||
/** 企业成立时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "企业成立时间", value = "企业成立时间")
|
||||
private Date estabinessDate;
|
||||
|
||||
/** 经营范围 */
|
||||
@ApiModelProperty(name = "经营范围", value = "经营范围")
|
||||
private String businessScope;
|
||||
|
||||
/** 注册地址 */
|
||||
@ApiModelProperty(name = "注册地址", value = "注册地址")
|
||||
private String address;
|
||||
|
||||
/** 企业联系方式 */
|
||||
@ApiModelProperty(name = "企业联系方式", value = "企业联系方式")
|
||||
private String contactPhone;
|
||||
|
||||
/** 公司邮箱 */
|
||||
@ApiModelProperty(name = "公司邮箱", value = "公司邮箱")
|
||||
private String email;
|
||||
|
||||
/** 企业当前状态 */
|
||||
@ApiModelProperty(name = "企业当前状态", value = "企业当前状态")
|
||||
private String status;
|
||||
|
||||
/** 企业入驻平台时期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "企业入驻平台时期", value = "企业入驻平台时期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 企业认证id */
|
||||
@ApiModelProperty(name = "企业认证id", value = "企业认证id")
|
||||
private Long certificationId;
|
||||
|
||||
/** 认证时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "认证时间", value = "认证时间")
|
||||
private Date authenticationDate;
|
||||
|
||||
/** 服务级别 */
|
||||
@ApiModelProperty(name = "服务级别", value = "服务级别")
|
||||
private Long serviceLevel;
|
||||
|
||||
/** 开通服务id */
|
||||
@ApiModelProperty(name = "开通服务id", value = "开通服务id")
|
||||
private Long openServerId;
|
||||
|
||||
/** 增值服务id */
|
||||
@ApiModelProperty(name = "增值服务id", value = "增值服务id")
|
||||
private Long addServerId;
|
||||
|
||||
}
|
|
@ -0,0 +1,91 @@
|
|||
package com.muyu.net.working.domain.req;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 企业信息对象 enterprise
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@ApiModel(value = "EnterpriseQueryReq", description = "企业信息")
|
||||
public class EnterpriseQueryReq extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 企业名称 */
|
||||
@ApiModelProperty(name = "企业名称", value = "企业名称")
|
||||
private String ebterpriseName;
|
||||
|
||||
/** 法定代表人 */
|
||||
@ApiModelProperty(name = "法定代表人", value = "法定代表人")
|
||||
private String legalPerson;
|
||||
|
||||
/** 经营执照凭证号码 */
|
||||
@ApiModelProperty(name = "经营执照凭证号码", value = "经营执照凭证号码")
|
||||
private String businessLincenseNumber;
|
||||
|
||||
/** 企业成立时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "企业成立时间", value = "企业成立时间")
|
||||
private Date estabinessDate;
|
||||
|
||||
/** 经营范围 */
|
||||
@ApiModelProperty(name = "经营范围", value = "经营范围")
|
||||
private String businessScope;
|
||||
|
||||
/** 注册地址 */
|
||||
@ApiModelProperty(name = "注册地址", value = "注册地址")
|
||||
private String address;
|
||||
|
||||
/** 企业联系方式 */
|
||||
@ApiModelProperty(name = "企业联系方式", value = "企业联系方式")
|
||||
private String contactPhone;
|
||||
|
||||
/** 公司邮箱 */
|
||||
@ApiModelProperty(name = "公司邮箱", value = "公司邮箱")
|
||||
private String email;
|
||||
|
||||
/** 企业当前状态 */
|
||||
@ApiModelProperty(name = "企业当前状态", value = "企业当前状态")
|
||||
private String status;
|
||||
|
||||
/** 企业入驻平台时期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "企业入驻平台时期", value = "企业入驻平台时期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 企业认证id */
|
||||
@ApiModelProperty(name = "企业认证id", value = "企业认证id")
|
||||
private Long certificationId;
|
||||
|
||||
/** 认证时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(name = "认证时间", value = "认证时间")
|
||||
private Date authenticationDate;
|
||||
|
||||
/** 服务级别 */
|
||||
@ApiModelProperty(name = "服务级别", value = "服务级别")
|
||||
private Long serviceLevel;
|
||||
|
||||
/** 开通服务id */
|
||||
@ApiModelProperty(name = "开通服务id", value = "开通服务id")
|
||||
private Long openServerId;
|
||||
|
||||
/** 增值服务id */
|
||||
@ApiModelProperty(name = "增值服务id", value = "增值服务id")
|
||||
private Long addServerId;
|
||||
|
||||
}
|
|
@ -0,0 +1,111 @@
|
|||
package com.muyu.net.working.domain.req;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import io.swagger.annotations.*;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 企业信息对象 enterprise
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Data
|
||||
@SuperBuilder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@ApiModel(value = "EnterpriseSaveReq", description = "企业信息")
|
||||
public class EnterpriseSaveReq extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
|
||||
@ApiModelProperty(name = "主键", value = "主键")
|
||||
private String id;
|
||||
|
||||
/** 企业名称 */
|
||||
|
||||
@ApiModelProperty(name = "企业名称", value = "企业名称")
|
||||
private String ebterpriseName;
|
||||
|
||||
/** 法定代表人 */
|
||||
|
||||
@ApiModelProperty(name = "法定代表人", value = "法定代表人")
|
||||
private String legalPerson;
|
||||
|
||||
/** 经营执照凭证号码 */
|
||||
|
||||
@ApiModelProperty(name = "经营执照凭证号码", value = "经营执照凭证号码")
|
||||
private String businessLincenseNumber;
|
||||
|
||||
/** 企业成立时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
|
||||
@ApiModelProperty(name = "企业成立时间", value = "企业成立时间")
|
||||
private Date estabinessDate;
|
||||
|
||||
/** 经营范围 */
|
||||
|
||||
@ApiModelProperty(name = "经营范围", value = "经营范围")
|
||||
private String businessScope;
|
||||
|
||||
/** 注册地址 */
|
||||
|
||||
@ApiModelProperty(name = "注册地址", value = "注册地址")
|
||||
private String address;
|
||||
|
||||
/** 企业联系方式 */
|
||||
|
||||
@ApiModelProperty(name = "企业联系方式", value = "企业联系方式")
|
||||
private String contactPhone;
|
||||
|
||||
/** 公司邮箱 */
|
||||
|
||||
@ApiModelProperty(name = "公司邮箱", value = "公司邮箱")
|
||||
private String email;
|
||||
|
||||
/** 企业当前状态 */
|
||||
|
||||
@ApiModelProperty(name = "企业当前状态", value = "企业当前状态")
|
||||
private String status;
|
||||
|
||||
/** 企业入驻平台时期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
|
||||
@ApiModelProperty(name = "企业入驻平台时期", value = "企业入驻平台时期")
|
||||
private Date registrationDate;
|
||||
|
||||
/** 企业认证id */
|
||||
|
||||
@ApiModelProperty(name = "企业认证id", value = "企业认证id")
|
||||
private Long certificationId;
|
||||
|
||||
/** 认证时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
|
||||
@ApiModelProperty(name = "认证时间", value = "认证时间")
|
||||
private Date authenticationDate;
|
||||
|
||||
/** 服务级别 */
|
||||
|
||||
@ApiModelProperty(name = "服务级别", value = "服务级别")
|
||||
private Long serviceLevel;
|
||||
|
||||
/** 开通服务id */
|
||||
|
||||
@ApiModelProperty(name = "开通服务id", value = "开通服务id")
|
||||
private Long openServerId;
|
||||
|
||||
/** 增值服务id */
|
||||
|
||||
@ApiModelProperty(name = "增值服务id", value = "增值服务id")
|
||||
private Long addServerId;
|
||||
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-net-working</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-net-working-remote</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,116 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-net-working</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>muyu-net-working-server</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
<dependencies>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-net-working-common</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</dependency>
|
||||
<!-- SpringCloud Alibaba Nacos -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringCloud Alibaba Nacos Config -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringCloud Alibaba Sentinel -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-sentinel</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringBoot Actuator -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-actuator</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- Swagger UI -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger-ui</artifactId>
|
||||
<version>${swagger.fox.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Mysql Connector -->
|
||||
<dependency>
|
||||
<groupId>com.mysql</groupId>
|
||||
<artifactId>mysql-connector-j</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common DataSource -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-datasource</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common DataScope -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-datascope</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common Log -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-log</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common Swagger -->
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-common-swagger</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<finalName>${project.artifactId}</finalName>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>repackage</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<!-- 加入maven deploy插件,当在deploy时,忽略些model-->
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
package com.muyu.net.working;
|
||||
|
||||
import com.muyu.common.security.annotation.EnableCustomConfig;
|
||||
import com.muyu.common.security.annotation.EnableMyFeignClients;
|
||||
import com.muyu.common.swagger.annotation.EnableCustomSwagger2;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
|
||||
/**
|
||||
* 车联网运营平台启动类 MuYuNetWorkingApplication
|
||||
*
|
||||
* @author DeKangLiu
|
||||
* Date 2024/5/26 21:45
|
||||
*/
|
||||
@EnableCustomConfig
|
||||
@EnableCustomSwagger2
|
||||
@EnableMyFeignClients
|
||||
@SpringBootApplication
|
||||
public class MuYuNetWorkingApplication {
|
||||
public static void main (String[] args) {
|
||||
SpringApplication.run(MuYuNetWorkingApplication.class, args);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,111 @@
|
|||
package com.muyu.net.working.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import io.swagger.annotations.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.muyu.common.core.domain.Result;
|
||||
import com.muyu.common.core.utils.poi.ExcelUtil;
|
||||
import com.muyu.common.core.web.controller.BaseController;
|
||||
import com.muyu.common.log.annotation.Log;
|
||||
import com.muyu.common.log.enums.BusinessType;
|
||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||
import com.muyu.net.working.domain.Enterprise;
|
||||
import com.muyu.net.working.domain.req.EnterpriseQueryReq;
|
||||
import com.muyu.net.working.domain.req.EnterpriseSaveReq;
|
||||
import com.muyu.net.working.domain.req.EnterpriseEditReq;
|
||||
import com.muyu.net.working.service.EnterpriseService;
|
||||
import com.muyu.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 企业信息Controller
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Api(tags = "企业信息")
|
||||
@RestController
|
||||
@RequestMapping("/car")
|
||||
public class EnterpriseController extends BaseController {
|
||||
@Autowired
|
||||
private EnterpriseService enterpriseService;
|
||||
|
||||
/**
|
||||
* 查询企业信息列表
|
||||
*/
|
||||
@ApiOperation("获取企业信息列表")
|
||||
@RequiresPermissions("netWorking:car:list")
|
||||
@GetMapping("/list")
|
||||
public Result<TableDataInfo<Enterprise>> list(EnterpriseQueryReq enterpriseQueryReq) {
|
||||
startPage();
|
||||
List<Enterprise> list = enterpriseService.list(Enterprise.queryBuild(enterpriseQueryReq));
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出企业信息列表
|
||||
*/
|
||||
@ApiOperation("导出企业信息列表")
|
||||
@RequiresPermissions("netWorking:car:export")
|
||||
@Log(title = "企业信息", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, Enterprise enterprise) {
|
||||
List<Enterprise> list = enterpriseService.list(enterprise);
|
||||
ExcelUtil<Enterprise> util = new ExcelUtil<Enterprise>(Enterprise.class);
|
||||
util.exportExcel(response, list, "企业信息数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取企业信息详细信息
|
||||
*/
|
||||
@ApiOperation("获取企业信息详细信息")
|
||||
@RequiresPermissions("netWorking:car:query")
|
||||
@GetMapping(value = "/{id}")
|
||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "String", paramType = "path", dataTypeClass = String.class)
|
||||
public Result<Enterprise> getInfo(@PathVariable("id") String id) {
|
||||
return Result.success(enterpriseService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增企业信息
|
||||
*/
|
||||
@RequiresPermissions("netWorking:car:add")
|
||||
@Log(title = "企业信息", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
@ApiOperation("新增企业信息")
|
||||
public Result<String> add(@RequestBody EnterpriseSaveReq enterpriseSaveReq) {
|
||||
return toAjax(enterpriseService.save(Enterprise.saveBuild(enterpriseSaveReq)));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改企业信息
|
||||
*/
|
||||
@RequiresPermissions("netWorking:car:edit")
|
||||
@Log(title = "企业信息", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/{id}")
|
||||
@ApiOperation("修改企业信息")
|
||||
public Result<String> edit(@PathVariable String id, @RequestBody EnterpriseEditReq enterpriseEditReq) {
|
||||
return toAjax(enterpriseService.updateById(Enterprise.editBuild(id,enterpriseEditReq)));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除企业信息
|
||||
*/
|
||||
@RequiresPermissions("netWorking:car:remove")
|
||||
@Log(title = "企业信息", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
@ApiOperation("删除企业信息")
|
||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "String", paramType = "path", dataTypeClass = String.class, example = "1,2,3,4")
|
||||
public Result<String> remove(@PathVariable List<String> ids) {
|
||||
return toAjax(enterpriseService.removeBatchByIds(ids));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.muyu.net.working.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.muyu.net.working.domain.Enterprise;
|
||||
|
||||
/**
|
||||
* 企业信息Mapper接口
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
public interface EnterpriseMapper extends BaseMapper<Enterprise> {
|
||||
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
package com.muyu.net.working.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.muyu.net.working.domain.Enterprise;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* 企业信息Service接口
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
public interface EnterpriseService extends IService<Enterprise> {
|
||||
/**
|
||||
* 查询企业信息列表
|
||||
*
|
||||
* @param enterprise 企业信息
|
||||
* @return 企业信息集合
|
||||
*/
|
||||
public List<Enterprise> list(Enterprise enterprise);
|
||||
|
||||
}
|
|
@ -0,0 +1,101 @@
|
|||
package com.muyu.net.working.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.muyu.common.core.utils.ObjUtils;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.muyu.net.working.mapper.EnterpriseMapper;
|
||||
import com.muyu.net.working.domain.Enterprise;
|
||||
import com.muyu.net.working.service.EnterpriseService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
|
||||
/**
|
||||
* 企业信息Service业务层处理
|
||||
*
|
||||
* @author muyu
|
||||
* @date 2024-05-27
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class EnterpriseServiceImpl extends ServiceImpl<EnterpriseMapper, Enterprise> implements EnterpriseService {
|
||||
|
||||
/**
|
||||
* 查询企业信息列表
|
||||
*
|
||||
* @param enterprise 企业信息
|
||||
* @return 企业信息
|
||||
*/
|
||||
@Override
|
||||
public List<Enterprise> list(Enterprise enterprise) {
|
||||
LambdaQueryWrapper<Enterprise> queryWrapper = new LambdaQueryWrapper<>();
|
||||
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getEbterpriseName())){
|
||||
queryWrapper.like(Enterprise::getEbterpriseName, enterprise.getEbterpriseName());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getLegalPerson())){
|
||||
queryWrapper.eq(Enterprise::getLegalPerson, enterprise.getLegalPerson());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getBusinessLincenseNumber())){
|
||||
queryWrapper.eq(Enterprise::getBusinessLincenseNumber, enterprise.getBusinessLincenseNumber());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getEstabinessDate())){
|
||||
queryWrapper.eq(Enterprise::getEstabinessDate, enterprise.getEstabinessDate());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getBusinessScope())){
|
||||
queryWrapper.eq(Enterprise::getBusinessScope, enterprise.getBusinessScope());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getAddress())){
|
||||
queryWrapper.eq(Enterprise::getAddress, enterprise.getAddress());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getContactPhone())){
|
||||
queryWrapper.eq(Enterprise::getContactPhone, enterprise.getContactPhone());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getEmail())){
|
||||
queryWrapper.eq(Enterprise::getEmail, enterprise.getEmail());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getStatus())){
|
||||
queryWrapper.eq(Enterprise::getStatus, enterprise.getStatus());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getRegistrationDate())){
|
||||
queryWrapper.eq(Enterprise::getRegistrationDate, enterprise.getRegistrationDate());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getCertificationId())){
|
||||
queryWrapper.eq(Enterprise::getCertificationId, enterprise.getCertificationId());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getAuthenticationDate())){
|
||||
queryWrapper.eq(Enterprise::getAuthenticationDate, enterprise.getAuthenticationDate());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getServiceLevel())){
|
||||
queryWrapper.eq(Enterprise::getServiceLevel, enterprise.getServiceLevel());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getOpenServerId())){
|
||||
queryWrapper.eq(Enterprise::getOpenServerId, enterprise.getOpenServerId());
|
||||
}
|
||||
|
||||
if (ObjUtils.notNull(enterprise.getAddServerId())){
|
||||
queryWrapper.eq(Enterprise::getAddServerId, enterprise.getAddServerId());
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
return list(queryWrapper);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,2 @@
|
|||
Spring Boot Version: ${spring-boot.version}
|
||||
Spring Application Name: ${spring.application.name}
|
|
@ -0,0 +1,30 @@
|
|||
# Tomcat
|
||||
server:
|
||||
port: 9204
|
||||
|
||||
# Spring
|
||||
spring:
|
||||
application:
|
||||
# 应用名称
|
||||
name: muyu-net-working
|
||||
profiles:
|
||||
# 环境配置
|
||||
active: dev
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
# 服务注册地址
|
||||
server-addr: 127.0.0.1:8848
|
||||
namespace: jinmo
|
||||
config:
|
||||
# 配置中心地址
|
||||
server-addr: 127.0.0.1:8848
|
||||
namespace: jinmo
|
||||
# 配置文件格式
|
||||
file-extension: yml
|
||||
# 共享配置
|
||||
shared-configs:
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
logging:
|
||||
level:
|
||||
com.muyu.net.working.mapper: DEBUG
|
|
@ -0,0 +1,74 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration scan="true" scanPeriod="60 seconds" debug="false">
|
||||
<!-- 日志存放路径 -->
|
||||
<property name="log.path" value="logs/muyu-system"/>
|
||||
<!-- 日志输出格式 -->
|
||||
<property name="log.pattern" value="%d{HH:mm:ss.SSS} [%thread] %-5level %logger{20} - [%method,%line] - %msg%n"/>
|
||||
|
||||
<!-- 控制台输出 -->
|
||||
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<encoder>
|
||||
<pattern>${log.pattern}</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<!-- 系统日志输出 -->
|
||||
<appender name="file_info" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>${log.path}/info.log</file>
|
||||
<!-- 循环政策:基于时间创建日志文件 -->
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<!-- 日志文件名格式 -->
|
||||
<fileNamePattern>${log.path}/info.%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<!-- 日志最大的历史 60天 -->
|
||||
<maxHistory>60</maxHistory>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>${log.pattern}</pattern>
|
||||
</encoder>
|
||||
<filter class="ch.qos.logback.classic.filter.LevelFilter">
|
||||
<!-- 过滤的级别 -->
|
||||
<level>INFO</level>
|
||||
<!-- 匹配时的操作:接收(记录) -->
|
||||
<onMatch>ACCEPT</onMatch>
|
||||
<!-- 不匹配时的操作:拒绝(不记录) -->
|
||||
<onMismatch>DENY</onMismatch>
|
||||
</filter>
|
||||
</appender>
|
||||
|
||||
<appender name="file_error" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>${log.path}/error.log</file>
|
||||
<!-- 循环政策:基于时间创建日志文件 -->
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<!-- 日志文件名格式 -->
|
||||
<fileNamePattern>${log.path}/error.%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<!-- 日志最大的历史 60天 -->
|
||||
<maxHistory>60</maxHistory>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>${log.pattern}</pattern>
|
||||
</encoder>
|
||||
<filter class="ch.qos.logback.classic.filter.LevelFilter">
|
||||
<!-- 过滤的级别 -->
|
||||
<level>ERROR</level>
|
||||
<!-- 匹配时的操作:接收(记录) -->
|
||||
<onMatch>ACCEPT</onMatch>
|
||||
<!-- 不匹配时的操作:拒绝(不记录) -->
|
||||
<onMismatch>DENY</onMismatch>
|
||||
</filter>
|
||||
</appender>
|
||||
|
||||
<!-- 系统模块日志级别控制 -->
|
||||
<logger name="com.muyu" level="info"/>
|
||||
<!-- Spring日志级别控制 -->
|
||||
<logger name="org.springframework" level="warn"/>
|
||||
|
||||
<root level="info">
|
||||
<appender-ref ref="console"/>
|
||||
</root>
|
||||
|
||||
<!--系统操作日志-->
|
||||
<root level="info">
|
||||
<appender-ref ref="file_info"/>
|
||||
<appender-ref ref="file_error"/>
|
||||
</root>
|
||||
</configuration>
|
|
@ -0,0 +1,34 @@
|
|||
<?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.muyu.net.working.mapper.EnterpriseMapper">
|
||||
|
||||
<resultMap type="com.muyu.net.working.domain.Enterprise" id="EnterpriseResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="ebterpriseName" column="ebterprise_name" />
|
||||
<result property="legalPerson" column="legal_person" />
|
||||
<result property="businessLincenseNumber" column="business_lincense_number" />
|
||||
<result property="estabinessDate" column="estabiness_date" />
|
||||
<result property="businessScope" column="business_scope" />
|
||||
<result property="address" column="address" />
|
||||
<result property="contactPhone" column="contact_phone" />
|
||||
<result property="email" column="email" />
|
||||
<result property="status" column="status" />
|
||||
<result property="registrationDate" column="registration_date" />
|
||||
<result property="certificationId" column="certification_id" />
|
||||
<result property="authenticationDate" column="authentication_date" />
|
||||
<result property="serviceLevel" column="service_level" />
|
||||
<result property="openServerId" column="open_server_id" />
|
||||
<result property="addServerId" column="add_server_id" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectEnterpriseVo">
|
||||
select id, ebterprise_name, legal_person, business_lincense_number, estabiness_date, business_scope, address, contact_phone, email, status, registration_date, certification_id, authentication_date, service_level, open_server_id, add_server_id, create_by, create_time, update_by, update_time, remark from enterprise
|
||||
</sql>
|
||||
</mapper>
|
|
@ -0,0 +1,30 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>muyu-modules</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
<packaging>pom</packaging>
|
||||
<description>
|
||||
muyu-net-working车联网运营平台模块
|
||||
</description>
|
||||
<modules>
|
||||
<module>muyu-net-working-common</module>
|
||||
<module>muyu-net-working-server</module>
|
||||
<module>muyu-net-working-client</module>
|
||||
<module>muyu-net-working-remote</module>
|
||||
</modules>
|
||||
|
||||
|
||||
<artifactId>muyu-net-working</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
</project>
|
|
@ -49,6 +49,7 @@
|
|||
<sql id="selectUserVo">
|
||||
select u.user_id,
|
||||
u.dept_id,
|
||||
u.type,
|
||||
u.user_name,
|
||||
u.nick_name,
|
||||
u.email,
|
||||
|
@ -75,11 +76,13 @@
|
|||
r.role_key,
|
||||
r.role_sort,
|
||||
r.data_scope,
|
||||
r.status as role_status
|
||||
r.status as role_status,
|
||||
e.ebterprise_name
|
||||
from sys_user u
|
||||
left join sys_dept d on u.dept_id = d.dept_id
|
||||
left join sys_user_role ur on u.user_id = ur.user_id
|
||||
left join sys_role r on r.role_id = ur.role_id
|
||||
left join enterprise e on u.enterprise_id = e.id
|
||||
</sql>
|
||||
|
||||
<select id="selectUserList" parameterType="com.muyu.common.system.domain.SysUser" resultMap="SysUserResult">
|
||||
|
|
|
@ -13,6 +13,8 @@
|
|||
<module>muyu-gen</module>
|
||||
<module>muyu-job</module>
|
||||
<module>muyu-file</module>
|
||||
<module>muyu-net-working</module>
|
||||
<module>muyu-customer-business</module>
|
||||
</modules>
|
||||
|
||||
<artifactId>muyu-modules</artifactId>
|
||||
|
|
Loading…
Reference in New Issue