2023-11-02
This commit is contained in:
commit
4d129332cf
|
@ -0,0 +1,11 @@
|
|||
/nuzar-customer-business/target/
|
||||
/nuzar-customer-client/target/
|
||||
/nuzar-customer-common/target/
|
||||
/nuzar-customer-controller/target/
|
||||
/nuzar-customer-domain/target/
|
||||
/nuzar-customer-proxy/target/
|
||||
/nuzar-customer-repository/target/
|
||||
/.idea/
|
||||
/logs/
|
||||
*.iml
|
||||
/nuzar-customer-repository/nuzar-customer-repository.iml
|
|
@ -0,0 +1,7 @@
|
|||
# nuzar-cloud-ddd-archetype
|
||||
|
||||
#### 介绍
|
||||
nuzar-cloud-ddd-archetype 提供了一个基于领域驱动设计分层模型的脚手架
|
||||
|
||||
#### 软件架构
|
||||
|
|
@ -0,0 +1,52 @@
|
|||
<?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">
|
||||
<parent>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>nuzar-customer-business</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<properties>
|
||||
<maven.deploy.skip>true</maven.deploy.skip>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer-client</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
<!-- domain -->
|
||||
<dependency>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer-domain</artifactId>
|
||||
</dependency>
|
||||
<!-- facade -->
|
||||
<dependency>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer-proxy</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.nuzar</groupId>
|
||||
<artifactId>nuzar-redis-starter</artifactId>
|
||||
</dependency>
|
||||
<!--<dependency>
|
||||
<groupId>com.nuzar</groupId>
|
||||
<artifactId>nuzar-xxl-starter</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.nuzar</groupId>
|
||||
<artifactId>nuzar-stream-starter</artifactId>
|
||||
</dependency>-->
|
||||
<dependency>
|
||||
<groupId>com.nuzar</groupId>
|
||||
<artifactId>nuzar-core</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,42 @@
|
|||
package com.haitonggauto.rtosc.business.converter;
|
||||
|
||||
import com.haitonggauto.rtosc.domain.entity.Order;
|
||||
import com.haitonggauto.rtosc.dto.OrderDTO;
|
||||
import com.haitonggauto.rtosc.repository.dataobject.OrderDO;
|
||||
import java.util.List;
|
||||
import org.mapstruct.InheritInverseConfiguration;
|
||||
import org.mapstruct.Mapper;
|
||||
import org.mapstruct.Mapping;
|
||||
import org.mapstruct.factory.Mappers;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Order 对象转换
|
||||
* </p>
|
||||
*
|
||||
* @author admin
|
||||
* @since 2023/4/4 9:38
|
||||
*/
|
||||
@Mapper
|
||||
public interface OrderConverter {
|
||||
|
||||
OrderConverter INSTANCE = Mappers.getMapper(OrderConverter.class);
|
||||
|
||||
@Mapping(target = "id", ignore = true)
|
||||
@Mapping(target = "createTime" ,source = "createTime", dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@Mapping(target = "updateTime" ,source = "updateTime", dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
OrderDTO convert(OrderDO orderDO);
|
||||
|
||||
@InheritInverseConfiguration
|
||||
OrderDO convert(OrderDTO orderDTO);
|
||||
|
||||
@Mapping(target = "id", ignore = true)
|
||||
@Mapping(target = "createTime" ,source = "createTime", dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@Mapping(target = "updateTime" ,source = "updateTime", dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
OrderDTO convertToDTO(Order order);
|
||||
|
||||
@Mapping(target = "id", ignore = true)
|
||||
Order convertToOrder(OrderDTO order);
|
||||
|
||||
List<OrderDTO> convertToListDTO(List<OrderDO> orderList);
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package com.haitonggauto.rtosc.business.dto;
|
||||
|
||||
public class TestDTO {
|
||||
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
package com.haitonggauto.rtosc.business.service;
|
||||
|
||||
import com.haitonggauto.rtosc.dto.OrderDTO;
|
||||
import com.haitonggauto.rtosc.request.OrderPageRequest;
|
||||
import com.nuzar.cloud.common.exception.BizException;
|
||||
import com.nuzar.cloud.web.model.PageResult;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface OrderBiz {
|
||||
|
||||
/**
|
||||
* 下单
|
||||
*
|
||||
* @param orderDTO
|
||||
* @return
|
||||
* @throws BizException
|
||||
*/
|
||||
void createOrder(OrderDTO orderDTO)
|
||||
throws BizException;
|
||||
|
||||
/**
|
||||
* 发货
|
||||
*
|
||||
* @param orderId
|
||||
*/
|
||||
void deliveryOrder(Long orderId);
|
||||
|
||||
/**
|
||||
* 翻页查询订单列表
|
||||
*
|
||||
* @param request
|
||||
* @return
|
||||
*/
|
||||
PageResult<OrderDTO> queryPage(OrderPageRequest request);
|
||||
|
||||
List<OrderDTO> list();
|
||||
}
|
|
@ -0,0 +1,82 @@
|
|||
package com.haitonggauto.rtosc.business.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.haitonggauto.rtosc.business.converter.OrderConverter;
|
||||
import com.haitonggauto.rtosc.domain.entity.Order;
|
||||
import com.haitonggauto.rtosc.domain.service.OrderService;
|
||||
import com.haitonggauto.rtosc.dto.OrderDTO;
|
||||
import com.haitonggauto.rtosc.enums.OrderStatusEnum;
|
||||
import com.haitonggauto.rtosc.business.service.OrderBiz;
|
||||
import com.nuzar.cloud.web.model.PageResult;
|
||||
import com.nuzar.cloud.web.model.QueryPage;
|
||||
import com.haitonggauto.rtosc.repository.service.OrderRepository;
|
||||
import com.haitonggauto.rtosc.repository.dataobject.OrderDO;
|
||||
import com.haitonggauto.rtosc.request.OrderPageRequest;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class OrderBizImpl implements OrderBiz {
|
||||
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
|
||||
@Autowired
|
||||
private OrderRepository orderRepository;
|
||||
|
||||
@Override
|
||||
// @GlobalTransactional
|
||||
public void createOrder(OrderDTO orderDTO) {
|
||||
// save order
|
||||
Order order = OrderConverter.INSTANCE.convertToOrder(orderDTO);
|
||||
order.setStatus(OrderStatusEnum.PAID.getCode());
|
||||
order.setCreateTime(LocalDateTime.now());
|
||||
order.setUpdateTime(LocalDateTime.now());
|
||||
orderService.createOrder(order);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deliveryOrder(Long orderId) {
|
||||
orderService.deliveryOrder(orderId);
|
||||
OrderDTO orderDTO = new OrderDTO();
|
||||
orderDTO.setStatus(OrderStatusEnum.DELIVERED.getCode());
|
||||
orderDTO.setId(orderId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageResult<OrderDTO> queryPage(OrderPageRequest request) {
|
||||
QueryWrapper<OrderDO> wrapper = new QueryWrapper<OrderDO>();
|
||||
wrapper.eq(StringUtils.isNotBlank(request.getUserId()),"user_id", request.getUserId());
|
||||
wrapper.eq(StringUtils.isNotBlank(request.getStatus()),"status", request.getStatus());
|
||||
QueryPage<OrderDO> page = new QueryPage<>();
|
||||
page.setCurrent(request.getPageNo());
|
||||
page.setSize(request.getPageSize());
|
||||
//根据条件查询数据
|
||||
IPage<OrderDO> iPage = this.orderRepository.page(page, wrapper);
|
||||
List<OrderDO> orders = iPage.getRecords();
|
||||
List<OrderDTO> orderDTOList = OrderConverter.INSTANCE.convertToListDTO(orders);
|
||||
|
||||
PageResult<OrderDTO> orderPage = new PageResult<>();
|
||||
orderPage.setTotal(iPage.getTotal());
|
||||
orderPage.setList(orderDTOList);
|
||||
return orderPage;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<OrderDTO> list() {
|
||||
List<OrderDO> orderDOList = orderRepository.list();
|
||||
List<OrderDTO> orderList = OrderConverter.INSTANCE.convertToListDTO(orderDOList);
|
||||
return orderList;
|
||||
}
|
||||
|
||||
// @Override
|
||||
// public IService<OrderDO> getRepository() {
|
||||
// return this.orderRepository;
|
||||
// }
|
||||
|
||||
}
|
|
@ -0,0 +1,51 @@
|
|||
<?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">
|
||||
<parent>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer-client</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<properties>
|
||||
<maven.deploy.skip>true</maven.deploy.skip>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.springframework.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-openfeign</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-annotations</artifactId>
|
||||
<version>1.5.22</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer-common</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer-repository</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>easyexcel</artifactId>
|
||||
<version>${easyexcel.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
|
@ -0,0 +1,25 @@
|
|||
package com.haitonggauto.rtosc.api;
|
||||
|
||||
import com.haitonggauto.rtosc.dto.OrderDTO;
|
||||
import com.haitonggauto.rtosc.request.OrderPageRequest;
|
||||
import com.nuzar.cloud.common.web.CommonResult;
|
||||
import com.nuzar.cloud.web.model.PageResult;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@FeignClient(name = "nuzar-mydemo-archetype-web")
|
||||
public interface OrderApi {
|
||||
|
||||
@PostMapping("/order/create")
|
||||
CommonResult<Boolean> createOrder(@RequestBody OrderDTO orderDTO);
|
||||
|
||||
@GetMapping("/order/list")
|
||||
CommonResult<List<OrderDTO>> list();
|
||||
|
||||
@PostMapping("/order/page")
|
||||
CommonResult<PageResult<OrderDTO>> queryPage(@RequestBody OrderPageRequest request);
|
||||
}
|
|
@ -0,0 +1,60 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "批量修改船名、航次")
|
||||
public class BatchUpdateShipVo implements Serializable {
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船ID不能为空")
|
||||
private String shipId;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
// /**
|
||||
// * 开始时间
|
||||
// */
|
||||
// @JsonFormat(pattern = "yyyy-MM-dd")
|
||||
// @ApiModelProperty(value = "开始时间", required = true)
|
||||
// @NotNull(groups = {ValidationGroup.insert.class}, message = "开始时间不能为空")
|
||||
// private Date beginDate;
|
||||
//
|
||||
// /**
|
||||
// * 结束时间
|
||||
// */
|
||||
// @JsonFormat(pattern = "yyyy-MM-dd")
|
||||
// @ApiModelProperty(value = "结束时间", required = true)
|
||||
// @NotNull(groups = {ValidationGroup.insert.class}, message = "结束时间不能为空")
|
||||
// private Date endDate;
|
||||
|
||||
}
|
|
@ -0,0 +1,26 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "车辆状态",description = "")
|
||||
public class CargoStatus implements Serializable {
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "车辆状态")
|
||||
@ApiModelProperty("车辆状态, 0为取消,1为正常")
|
||||
private Integer status;
|
||||
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "车架号必填!" )
|
||||
@ApiModelProperty("车架号")
|
||||
private String vin;
|
||||
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "取消恢复车架号",description = "")
|
||||
public class CargoStatusVo implements Serializable {
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "船ID不能为空")
|
||||
@ApiModelProperty(value = "船ID")
|
||||
private String shipId;
|
||||
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "航次ID为空")
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
private String voyageId;
|
||||
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "提单号不能为空")
|
||||
@ApiModelProperty(value = "提单号")
|
||||
private String billNo;
|
||||
|
||||
/**
|
||||
* 单票重量
|
||||
*/
|
||||
@ApiModelProperty(value = "单票重量")
|
||||
private BigDecimal eachWeight;
|
||||
|
||||
/**
|
||||
* 单票数量
|
||||
*/
|
||||
@ApiModelProperty(value = "单票数量")
|
||||
private Integer eachQuantity;
|
||||
|
||||
/**
|
||||
* 单票体积
|
||||
*/
|
||||
@ApiModelProperty(value = "单票体积")
|
||||
private BigDecimal eachVolume;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "车架号必填!" )
|
||||
@Size(min = 1 , message = "车架号必填要有一个")
|
||||
private List<CargoStatus> vins;
|
||||
|
||||
}
|
|
@ -0,0 +1,78 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "提离港区货物表",description = "")
|
||||
public class DepartureCargoVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
/**
|
||||
* 提离港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "提离港区ID", hidden = true)
|
||||
private Long departureId;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提单号不能为空")
|
||||
@ApiModelProperty(value = "提单号", required = true)
|
||||
private String billNo;
|
||||
|
||||
/**
|
||||
* 品牌ID
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌ID不能为空")
|
||||
private String brandId;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌不能为空")
|
||||
@ApiModelProperty(value = "品牌", required = true)
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 货物类型
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "货物类型不能为空")
|
||||
@ApiModelProperty(value = "货物类型", required = true)
|
||||
private String cargoType;
|
||||
|
||||
/**
|
||||
* 车架号/条码
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车架号/条码不能为空")
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 17, max = 17, message = "车架号长度为17位")
|
||||
@ApiModelProperty(value = "车架号/条码", required = true)
|
||||
private String vin;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "数量不能为空")
|
||||
@ApiModelProperty(value = "数量", required = true)
|
||||
private Integer quantity;
|
||||
|
||||
/**
|
||||
* 是否退关
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "是否退关不能为空")
|
||||
@ApiModelProperty(value = "是否退关", required = true)
|
||||
private Integer isShutout;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
|
@ -0,0 +1,51 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "提离港区审核")
|
||||
public class DepartureCheckVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "提离港区ID列表")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提离港区ID不能为空")
|
||||
private List<Long> ids;
|
||||
|
||||
@ApiModelProperty(value = "审核人ID")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人ID不能为空")
|
||||
private String checkManId;
|
||||
|
||||
/**
|
||||
* 审核人
|
||||
*/
|
||||
@ApiModelProperty(value = "审核人")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人不能为空")
|
||||
private String checkMan;
|
||||
|
||||
/**
|
||||
* 审核时间
|
||||
*/
|
||||
// private Date checkTime;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
@NotNull(groups = {ValidationGroup.insert.class}, message = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
/**
|
||||
* 审核原因
|
||||
*/
|
||||
@ApiModelProperty(value = "审核原因")
|
||||
private String checkResult;
|
||||
|
||||
}
|
|
@ -0,0 +1,45 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "提离港区司机表")
|
||||
public class DepartureDriverVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
/**
|
||||
* 提离港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "提离港区ID", hidden = true)
|
||||
private Long departureId;
|
||||
|
||||
/**
|
||||
* 司机名称
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "司机名称不能为空")
|
||||
@ApiModelProperty(value = "司机名称", required = true)
|
||||
private String driverName;
|
||||
|
||||
/**
|
||||
* 车牌号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车牌号不能为空")
|
||||
@ApiModelProperty(value = "车牌号", required = true)
|
||||
private String carNo;
|
||||
|
||||
/**
|
||||
* 联系电话
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系电话不能为空")
|
||||
@ApiModelProperty(value = "联系电话", required = true)
|
||||
private String contactPhone;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
}
|
|
@ -0,0 +1,42 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
public class DepartureLetterVo implements Serializable {
|
||||
private Long id;
|
||||
/**
|
||||
* 提离港区ID
|
||||
*/
|
||||
private Long departureId;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 进港日期
|
||||
*/
|
||||
private Date enterTime;
|
||||
|
||||
/**
|
||||
* 提货日期
|
||||
*/
|
||||
private Date departureTime;
|
||||
|
||||
/**
|
||||
* 返回日期
|
||||
*/
|
||||
private Date returnTime;
|
||||
|
||||
/**
|
||||
* 事由
|
||||
*/
|
||||
private String reason;
|
||||
|
||||
private Integer version;
|
||||
}
|
|
@ -0,0 +1,80 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "提离港区操作计划表")
|
||||
public class DeparturePlanVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
/**
|
||||
* 提离港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "提离港区ID", hidden = true)
|
||||
private Long departureId;
|
||||
|
||||
/**
|
||||
* 品牌ID
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌ID不能为空")
|
||||
private String brandId;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@TableField(value = "brand")
|
||||
@ApiModelProperty(value = "品牌")
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 计划提货时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "计划提货时间", required = true, example="2023-06-12")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "计划提货时间不能为空")
|
||||
private Date pickTime;
|
||||
|
||||
/**
|
||||
* 计划车辆数量
|
||||
*/
|
||||
@ApiModelProperty(value = "计划车辆数量", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "计划车辆数量不能为空")
|
||||
private Integer carQuantity;
|
||||
|
||||
/**
|
||||
* 计划备件数量
|
||||
*/
|
||||
@ApiModelProperty(value = "计划备件数量", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "计划备件数量不能为空")
|
||||
private Integer partQuantity;
|
||||
|
||||
/**
|
||||
* 工作过程
|
||||
*/
|
||||
@ApiModelProperty(value = "工作过程", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "工作过程不能为空")
|
||||
private String workStatus;
|
||||
|
||||
@ApiModelProperty(value = "工作过程", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "工作过程名称不能为空")
|
||||
private String workStatusName;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,203 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "提离港区",description = "")
|
||||
public class DepartureVo implements Serializable {
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "编辑时请进场ID不能为空")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ApiModelProperty(value = "受理号")
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "受理号不能为空")
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船ID不能为空")
|
||||
private String shipId;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船名", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 英文船名
|
||||
*/
|
||||
@ApiModelProperty(value = "英文船名")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "英文船名不能为空")
|
||||
private String shipEnName;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
/**
|
||||
* 港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区ID不能为空")
|
||||
private String portAreaId;
|
||||
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@ApiModelProperty(value = "港区", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
private String portArea;
|
||||
|
||||
/**
|
||||
* 贸易类型
|
||||
*/
|
||||
@ApiModelProperty(value = "贸易类型", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "贸易类型不能为空")
|
||||
private String tradType;
|
||||
|
||||
/**
|
||||
* 收货单位ID
|
||||
*/
|
||||
@ApiModelProperty(value = "收货单位ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "收货单位ID不能为空")
|
||||
private String receiveCompanyId;
|
||||
|
||||
/**
|
||||
* 收货单位
|
||||
*/
|
||||
@ApiModelProperty(value = "收货单位", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "收货单位不能为空")
|
||||
private String receiveCompany;
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ApiModelProperty(value = "联系人", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系人不能为空")
|
||||
private String contact;
|
||||
|
||||
/**
|
||||
* 联系方式
|
||||
*/
|
||||
@ApiModelProperty(value = "联系方式", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系方式不能为空")
|
||||
private String contactPhone;
|
||||
|
||||
/**
|
||||
* 堆放港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "堆放港区ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "堆放港区ID不能为空")
|
||||
private String retainPortId;
|
||||
|
||||
/**
|
||||
* 堆放港区
|
||||
*/
|
||||
@ApiModelProperty(value = "堆放港区", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "堆放港区不能为空")
|
||||
private String retainPort;
|
||||
|
||||
|
||||
/**
|
||||
* 进港日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "进港日期", required = true, example="2023-06-12")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "进港日期不能为空")
|
||||
private Date arrivalTime;
|
||||
|
||||
/**
|
||||
* 提货日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "提货日期", required = true, example="2023-06-12")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提货日期不能为空")
|
||||
private Date deliveryTime;
|
||||
|
||||
/**
|
||||
* 返回日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "返回日期", required = true, example="2023-06-12")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "返回日期不能为空")
|
||||
private Date returnTime;
|
||||
|
||||
/**
|
||||
* 申请时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "申请时间", hidden = true)
|
||||
private Date applyTime;
|
||||
|
||||
/**
|
||||
* 申请人ID
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人Id")
|
||||
private String applicantId;
|
||||
|
||||
/**
|
||||
* 申请人
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人")
|
||||
private String applicant;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 事由
|
||||
*/
|
||||
@ApiModelProperty(value = "事由")
|
||||
private String reason;
|
||||
|
||||
@ApiModelProperty(value = "版本号", hidden = true)
|
||||
private Integer version;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口海关查验货物必须填!" )
|
||||
@Size(min = 1 , message = "提离港区验货物至少要有一个")
|
||||
private List<DepartureCargoVo> cargos;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口海关查验司机必须填!" )
|
||||
@Size(min = 1 , message = "提离港区司机至少要有一个")
|
||||
private List<DepartureDriverVo> drivers;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口海关查验保函必须填!" )
|
||||
@Size(min = 1 , message = "提离港区保函至少要有一个")
|
||||
private List<DeparturePlanVo> plans;
|
||||
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 出口进场货物表
|
||||
* @TableName customer_export_in_cargo
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "出口进场货物表",description = "")
|
||||
public class ExportInCargoVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
/**
|
||||
* 出口进场ID
|
||||
*/
|
||||
@ApiModelProperty(value = "出口进场ID", hidden = true)
|
||||
private Long exportInId;
|
||||
|
||||
@ApiModelProperty(value = "货物类型, 0代表车辆内,1代表备件")
|
||||
private Integer cargoType;
|
||||
|
||||
/**
|
||||
* 车架号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车架号不能为空")
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 17, max = 17, message = "车架号长度为17位")
|
||||
@ApiModelProperty(value = "车架号", required = true)
|
||||
private String vin;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
}
|
|
@ -0,0 +1,29 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口进场审核",description = "")
|
||||
public class ExportInCheckDetailVo implements Serializable {
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "进场ID不能为空")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ApiModelProperty(value = "航次")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class}, message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
}
|
|
@ -0,0 +1,50 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口进场审核")
|
||||
public class ExportInCheckVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "出口进场ID")
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口进场ID不能为空")
|
||||
@Size(min = 1, message = "出口进场ID不能为空")
|
||||
private List<Long> ids;
|
||||
|
||||
@ApiModelProperty(value = "审核人ID")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人ID不能为空")
|
||||
private String checkManId;
|
||||
|
||||
/**
|
||||
* 审核人
|
||||
*/
|
||||
@ApiModelProperty(value = "审核人")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人不能为空")
|
||||
private String checkMan;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
@NotNull(groups = {ValidationGroup.insert.class}, message = "审核状态不能为空")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
/**
|
||||
* 审核原因
|
||||
*/
|
||||
@ApiModelProperty(value = "审核原因")
|
||||
private String checkResult;
|
||||
|
||||
}
|
|
@ -0,0 +1,48 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.Future;
|
||||
import javax.validation.constraints.Min;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 出口进场时间表
|
||||
* @TableName customer_export_in_times
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "出口进场时间表",description = "")
|
||||
public class ExportInTimesVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
/**
|
||||
* 出口进场ID
|
||||
*/
|
||||
@ApiModelProperty(value = "出口进场ID", hidden = true)
|
||||
private Long exportInId;
|
||||
|
||||
/**
|
||||
* 进场时间
|
||||
*/
|
||||
@NotNull(message = "进场时间不能空")
|
||||
@Future(message = "进场时间必须大于当前时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "进场时间", required = true)
|
||||
private Date enterTime;
|
||||
|
||||
/**
|
||||
* 进场数量
|
||||
*/
|
||||
@NotNull(message = "进场数量不能空")
|
||||
@Min(value = 1, message = "进场数量必须大于0")
|
||||
@ApiModelProperty(value = "进场数量", required = true)
|
||||
private Integer enterQuantity;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
}
|
|
@ -0,0 +1,366 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.common.validate.MoreThan;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 出口进场基本表
|
||||
*
|
||||
* @TableName customer_export_in
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "出口进场基本表", description = "")
|
||||
@MoreThan(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, field1 = "quantity", field2 = "eachQuantity", message = "数量不得超过单票件数")
|
||||
public class ExportInVo implements Serializable {
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "编辑时请进场ID不能为空")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "受理号不能为空")
|
||||
@ApiModelProperty(value = "受理号", required = false)
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(value = "船ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船ID不能为空")
|
||||
private String shipId;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船名不能为空")
|
||||
@ApiModelProperty(value = "船名", required = true)
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "英文船名")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "英文船名不能为空")
|
||||
private String shipEnName;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次不能为空")
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
private String voyage;
|
||||
|
||||
/**
|
||||
* 港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区ID不能为空")
|
||||
private String portAreaId;
|
||||
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
@ApiModelProperty(value = "港区", required = true)
|
||||
private String portArea;
|
||||
|
||||
// @NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "货代ID不能为空")
|
||||
@ApiModelProperty(value = "货代ID", required = true)
|
||||
private String freightId;
|
||||
|
||||
/**
|
||||
* 货代
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "货代不能为空")
|
||||
@ApiModelProperty(value = "货代", required = true)
|
||||
private String freight;
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系人不能为空")
|
||||
@ApiModelProperty(value = "联系人", required = true)
|
||||
private String contact;
|
||||
|
||||
/**
|
||||
* 联系方式
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系人电话号码不能为空")
|
||||
@ApiModelProperty(value = "联系方式", required = true)
|
||||
private String contactPhone;
|
||||
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "国家ID不能为空")
|
||||
@ApiModelProperty(value = "国家ID", required = true)
|
||||
private String countryId;
|
||||
/**
|
||||
* 国家
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "国家不能为空")
|
||||
@ApiModelProperty(value = "国家", required = true)
|
||||
private String country;
|
||||
|
||||
/**
|
||||
* 产地ID
|
||||
*/
|
||||
@ApiModelProperty(value = "产地ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "产地ID不能为空")
|
||||
private String originPlaceId;
|
||||
|
||||
/**
|
||||
* 产地
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "产地不能为空")
|
||||
@ApiModelProperty(value = "产地", required = true)
|
||||
private String originPlace;
|
||||
|
||||
/**
|
||||
* 港口
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港口ID不能为空")
|
||||
@ApiModelProperty(value = "港口ID", required = true)
|
||||
private String portId;
|
||||
|
||||
/**
|
||||
* 港口名称
|
||||
*/
|
||||
@ApiModelProperty(value = "港口名称")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港口名称不能为空")
|
||||
private String portName;
|
||||
|
||||
/**
|
||||
* 运输方式ID
|
||||
*/
|
||||
@ApiModelProperty(value = "运输方式ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "运输方式ID不能为空")
|
||||
private String transportWayId;
|
||||
|
||||
/**
|
||||
* 运输方式
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "运输方式不能为空")
|
||||
@ApiModelProperty(value = "运输方式", required = true)
|
||||
private String transportWay;
|
||||
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "进场开始时间不能为空")
|
||||
@ApiModelProperty(value = "进场开始时间", required = true)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date beginEnterTime;
|
||||
|
||||
/**
|
||||
* 进场开始时间
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "进场结束时间不能为空")
|
||||
@ApiModelProperty(value = "进场结束时间", required = true)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date endEnterTime;
|
||||
|
||||
/**
|
||||
* 品牌ID
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌ID不能为空")
|
||||
private String brandId;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌不能为空")
|
||||
@ApiModelProperty(value = "品牌", required = true)
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 车型ID
|
||||
*/
|
||||
@ApiModelProperty(value = "车型ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车型ID不能为空")
|
||||
private String cartTypeId;
|
||||
|
||||
/**
|
||||
* 车型
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车型不能为空")
|
||||
@ApiModelProperty(value = "车型", required = true)
|
||||
private String cartType;
|
||||
|
||||
/**
|
||||
* 车型明细ID
|
||||
*/
|
||||
@ApiModelProperty(value = "车型明细ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车型明细ID不能为空")
|
||||
private String cartTypeDetailId;
|
||||
|
||||
/**
|
||||
* 车型明细
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车型明细不能为空")
|
||||
@ApiModelProperty(value = "车型明细", required = true)
|
||||
private String cartTypeDetail;
|
||||
|
||||
/**
|
||||
* 型号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "型号不能为空")
|
||||
@ApiModelProperty(value = "型号", required = true)
|
||||
private String models;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "数量不能为空")
|
||||
@ApiModelProperty(value = "数量", required = true)
|
||||
private Integer quantity;
|
||||
|
||||
/**
|
||||
* 单票重量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "单票重量不能为空")
|
||||
@ApiModelProperty(value = "单票重量", required = true)
|
||||
private BigDecimal eachWeight;
|
||||
|
||||
/**
|
||||
* 单票数量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "单票数量不能为空")
|
||||
@ApiModelProperty(value = "单票数量", required = true)
|
||||
private Integer eachQuantity;
|
||||
|
||||
/**
|
||||
* 进场数量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "进场数量不能为空")
|
||||
@ApiModelProperty(value = "进场数量", required = true)
|
||||
private Integer enterQuantity;
|
||||
|
||||
/**
|
||||
* 单票体积
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "单票体积不能为空")
|
||||
@ApiModelProperty(value = "单票体积", required = true)
|
||||
private BigDecimal eachVolume;
|
||||
|
||||
/**
|
||||
* 体积
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "体积不能为空")
|
||||
@ApiModelProperty(value = "体积", required = true)
|
||||
private BigDecimal volume;
|
||||
|
||||
/**
|
||||
* 长
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "长不能为空")
|
||||
@ApiModelProperty(value = "长", required = true)
|
||||
private BigDecimal length;
|
||||
|
||||
/**
|
||||
* 宽
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "宽不能为空")
|
||||
@ApiModelProperty(value = "宽", required = true)
|
||||
private BigDecimal width;
|
||||
|
||||
/**
|
||||
* 高
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "高不能为空")
|
||||
@ApiModelProperty(value = "高", required = true)
|
||||
private BigDecimal height;
|
||||
|
||||
/**
|
||||
* 重量(吨)
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "重量不能为空")
|
||||
@ApiModelProperty(value = "重量", required = true)
|
||||
private BigDecimal weight;
|
||||
|
||||
|
||||
/**
|
||||
* 操作模式ID
|
||||
*/
|
||||
@ApiModelProperty(value = "操作模式ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "操作模式ID不能为空")
|
||||
private String operateTypeId;
|
||||
|
||||
/**
|
||||
* 操作模式
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "操作模式不能为空")
|
||||
@ApiModelProperty(value = "操作模式", required = true)
|
||||
private String operateType;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提单号不能为空")
|
||||
@ApiModelProperty(value = "提单号", required = true)
|
||||
private String billNum;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 源类型
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "源类型不能为空")
|
||||
@ApiModelProperty(value = "源类型", required = true)
|
||||
private String energyType;
|
||||
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "源类型名称不能为空")
|
||||
@ApiModelProperty(value = "源类型名称", required = true)
|
||||
private String energyTypeName;
|
||||
|
||||
/**
|
||||
* 申请人ID
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人Id")
|
||||
private String applicantId;
|
||||
|
||||
/**
|
||||
* 申请人
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人", required = true)
|
||||
private String applicant;
|
||||
|
||||
/**
|
||||
* 申请时间
|
||||
*/
|
||||
@ApiModelProperty(value = "申请时间", required = true)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date applyTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号", required = true)
|
||||
private Integer version;
|
||||
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "货物列表不能为空")
|
||||
private List<ExportInCargoVo> cargos;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口进场时间必须填!")
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 1, message = "出口进场时间至少要有一个")
|
||||
private List<ExportInTimesVo> times;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "备件列表不能为空")
|
||||
private List<ExportInCargoVo> spares;
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,72 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口查验货物表")
|
||||
public class ExportInspectCargoVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
/**
|
||||
* 出口查验ID
|
||||
*/
|
||||
@ApiModelProperty(value = "出口查验ID", hidden = true)
|
||||
private Long exportInspectId;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
@ApiModelProperty(value = "车型ID")
|
||||
// @NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车型ID不能为空")
|
||||
private String cartTypeId;
|
||||
|
||||
/**
|
||||
* 车型
|
||||
*/
|
||||
@ApiModelProperty(value = "车型")
|
||||
// @NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车型不能为空")
|
||||
private String cartType;
|
||||
|
||||
/**
|
||||
* 车架号
|
||||
*/
|
||||
@ApiModelProperty(value = "车架号", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车架号/条码不能为空")
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 17, max = 17, message = "车架号长度为17位")
|
||||
private String vin;
|
||||
|
||||
/**
|
||||
* 区域( 从基础数据获取区道位信息)
|
||||
*/
|
||||
@ApiModelProperty(value = "区域", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "区域不能为空")
|
||||
private String area;
|
||||
|
||||
/**
|
||||
* 品牌ID
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌ID不能为空")
|
||||
private String brandId;
|
||||
|
||||
/**
|
||||
* 区域ID
|
||||
*/
|
||||
@ApiModelProperty(value = "区域ID")
|
||||
// @NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "区域ID不能为空")
|
||||
private String areaId;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "海关查验审核")
|
||||
public class ExportInspectCheckVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "海关查验ID")
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "海关查验ID不能为空")
|
||||
@Size(min = 1, message = "海关查验ID不能为空")
|
||||
private List<Long> ids;
|
||||
|
||||
@ApiModelProperty(value = "审核人ID")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人ID不能为空")
|
||||
private String checkManId;
|
||||
|
||||
/**
|
||||
* 审核人
|
||||
*/
|
||||
@ApiModelProperty(value = "审核人")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人不能为空")
|
||||
private String checkMan;
|
||||
|
||||
/**
|
||||
* 审核时间
|
||||
*/
|
||||
// private Date checkTime;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
@NotNull(groups = {ValidationGroup.insert.class}, message = "审核状态不能为空")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
/**
|
||||
* 审核原因
|
||||
*/
|
||||
@ApiModelProperty(value = "审核原因")
|
||||
private String checkReason;
|
||||
|
||||
}
|
|
@ -0,0 +1,165 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口查验表")
|
||||
public class ExportInspectVo implements Serializable {
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "编辑时ID不能为空")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ApiModelProperty(value = "batchNo", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "受理号不能为空")
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船名", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@ApiModelProperty(value = "提单号", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提单号不能为空")
|
||||
private String billNo;
|
||||
|
||||
/**
|
||||
* 报关单号
|
||||
*/
|
||||
@ApiModelProperty(value = "passport", required = true)
|
||||
private String passport;
|
||||
|
||||
/**
|
||||
* 查验日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "查验日期", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "查验日期不能为空")
|
||||
private Date inspectTime;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@ApiModelProperty(value = "查验车辆数", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "查验车辆数不能为空")
|
||||
private Integer plannedCargoQuantity;
|
||||
|
||||
/**
|
||||
* 查验备件数
|
||||
*/
|
||||
@ApiModelProperty(value = "查验备件数", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "查验备件数不能为空")
|
||||
private Integer plannedSpareQuantity;
|
||||
|
||||
/**
|
||||
* 公司名
|
||||
*/
|
||||
@ApiModelProperty(value = "公司名", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "公司名不能为空")
|
||||
private String company;
|
||||
|
||||
@ApiModelProperty(value = "申请对象ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "申请对象ID不能为空")
|
||||
private String applyObjId;
|
||||
|
||||
/**
|
||||
* 申请对象(从基础数据库获取客户类型为进口货代的数据)
|
||||
*/
|
||||
@ApiModelProperty(value = "申请对象", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审请对象不能为空")
|
||||
private String applyObj;
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ApiModelProperty(value = "联系人", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系人不能为空")
|
||||
private String contact;
|
||||
|
||||
/**
|
||||
* 联系电话
|
||||
*/
|
||||
@ApiModelProperty(value = "联系电话", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系电话不能为空")
|
||||
private String contactPhone;
|
||||
|
||||
/**
|
||||
* 申请人
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人", required = true)
|
||||
private String applicant;
|
||||
|
||||
/**
|
||||
* 申请时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "申请时间", required = true)
|
||||
private Date applyTime;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船ID不能为空")
|
||||
private String shipId;
|
||||
|
||||
/**
|
||||
* 英文船名
|
||||
*/
|
||||
@ApiModelProperty(value = "英文船名")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "英文船名不能为空")
|
||||
private String shipEnName;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区ID不能为空")
|
||||
private String portAreaId;
|
||||
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@ApiModelProperty(value = "港区")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
private String portArea;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口查验表货物必须填!" )
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 1 , message = "出口查验表至少要有一个")
|
||||
private List<ExportInspectCargoVo> cargos;
|
||||
}
|
|
@ -0,0 +1,94 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口装船货物表",description = "")
|
||||
public class ExportLoadCargoVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ApiModelProperty(value = "受理号", hidden = true)
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌不能为空")
|
||||
@ApiModelProperty(value = "品牌", required = true)
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 型号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "型号不能为空")
|
||||
@ApiModelProperty(value = "型号", required = true)
|
||||
private String models;
|
||||
|
||||
/**
|
||||
* 车架号/条码
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车架号/条码不能为空")
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 17, max = 17, message = "车架号长度为17位")
|
||||
@ApiModelProperty(value = "车架号/条码", required = true)
|
||||
private String vin;
|
||||
|
||||
/**
|
||||
* 作业状态(未进港:未收车扫描, 已收车:收车扫描作业完成, 已理货:理货作业完成, 已装船:装船作业完成, 退关:退关扫描完成, 退运:退运扫描完成)
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "作业状态")
|
||||
@ApiModelProperty(value = "作业状态", required = true)
|
||||
private String workStatus;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
/**
|
||||
* 货物类型ID,0代表车辆,1代表备件
|
||||
*/
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Integer cargoType;
|
||||
|
||||
/**
|
||||
* 品牌ID
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌ID不能为空")
|
||||
private String brandId;
|
||||
|
||||
/**
|
||||
* 结算单位ID
|
||||
*/
|
||||
@ApiModelProperty(value = "结算单位ID")
|
||||
private String settleCompId;
|
||||
|
||||
/**
|
||||
* 结算单位名称
|
||||
*/
|
||||
@ApiModelProperty(value = "结算单位")
|
||||
private String settleCompName;
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ApiModelProperty(value = "联系人")
|
||||
private String contact;
|
||||
|
||||
/**
|
||||
* 联系方式
|
||||
*/
|
||||
@ApiModelProperty(value = "联系方式")
|
||||
private String contactPhone;
|
||||
|
||||
}
|
|
@ -0,0 +1,27 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "审核货物列表")
|
||||
public class ExportLoadCheckCargoVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "货物ID")
|
||||
@NotNull(message = "货物ID不能为空")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "匹配结果")
|
||||
@TableField(value = "result")
|
||||
private String result;
|
||||
|
||||
@ApiModelProperty(value = "原因")
|
||||
@TableField(value = "reason")
|
||||
private String reason;
|
||||
|
||||
}
|
|
@ -0,0 +1,65 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口装船审核")
|
||||
public class ExportLoadCheckVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "船ID")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船ID不能为空")
|
||||
private String shipId;
|
||||
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
@ApiModelProperty(value = "审核人ID")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人ID不能为空")
|
||||
private String checkManId;
|
||||
|
||||
/**
|
||||
* 审核人
|
||||
*/
|
||||
@ApiModelProperty(value = "审核人")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人不能为空")
|
||||
private String checkMan;
|
||||
|
||||
/**
|
||||
* 审核时间
|
||||
*/
|
||||
// private Date checkTime;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
@NotNull(groups = {ValidationGroup.insert.class}, message = "审核状态不能为空")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
/**
|
||||
* 审核原因
|
||||
*/
|
||||
@ApiModelProperty(value = "审核原因")
|
||||
private String checkResult;
|
||||
|
||||
@ApiModelProperty(value = "审核拒绝时,没有核验通过的装船ID")
|
||||
private List<Long> ids;
|
||||
|
||||
// @Valid
|
||||
// @NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口装船货物必须填!" )
|
||||
// @Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 1 , message = "出口装船货物至少要有一个")
|
||||
// private List<ExportLoadCheckCargoVo> cargos;
|
||||
|
||||
}
|
|
@ -0,0 +1,135 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口装船表",description = "")
|
||||
public class ExportLoadVo implements Serializable {
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "编辑时请ID不能为空")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "受理号不能为空")
|
||||
@ApiModelProperty(value = "受理号", required = true)
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船名不能为空")
|
||||
@ApiModelProperty(value = "船名", required = true)
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次不能为空")
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
private String voyage;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提单号不能为空")
|
||||
@ApiModelProperty(value = "提单号", required = true)
|
||||
private String billNo;
|
||||
|
||||
/**
|
||||
* 品牌ID
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌ID不能为空")
|
||||
private String brandId;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌不能为空")
|
||||
@ApiModelProperty(value = "品牌", required = true)
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "数量不能为空")
|
||||
@ApiModelProperty(value = "数量", required = true)
|
||||
private Integer quantity;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
@ApiModelProperty(value = "备件数", required = true)
|
||||
private Integer spareQuantity;
|
||||
|
||||
/**
|
||||
* 申请人
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "申请人不能为空")
|
||||
@ApiModelProperty(value = "申请人", required = true)
|
||||
private String applicant;
|
||||
|
||||
|
||||
/**
|
||||
* 贸易类型
|
||||
*/
|
||||
@ApiModelProperty(value = "贸易类型")
|
||||
private String tradType;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船ID不能为空")
|
||||
private String shipId;
|
||||
|
||||
/**
|
||||
* 英文船名
|
||||
*/
|
||||
@ApiModelProperty(value = "英文船名")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "英文船名不能为空")
|
||||
private String shipEnName;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 申请人ID
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人Id")
|
||||
private String applicantId;
|
||||
|
||||
/**
|
||||
* 申请时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "申请时间不能为空")
|
||||
@ApiModelProperty(value = "申请时间", required = true)
|
||||
private Date applyTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "出口装船货物必须填!" )
|
||||
@Size(min = 1 , message = "出口装船货物至少要有一个")
|
||||
private List<ExportLoadCargoVo> cargos;
|
||||
}
|
|
@ -0,0 +1,51 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "特保区审核")
|
||||
public class FreeTradeCheckVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "特保区ID")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "特保区ID不能为空")
|
||||
private List<Long> ids;
|
||||
|
||||
@ApiModelProperty(value = "审核人ID")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人ID不能为空")
|
||||
private String checkManId;
|
||||
|
||||
/**
|
||||
* 审核人
|
||||
*/
|
||||
@ApiModelProperty(value = "审核人")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人不能为空")
|
||||
private String checkMan;
|
||||
|
||||
/**
|
||||
* 审核时间
|
||||
*/
|
||||
// private Date checkTime;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
@NotNull(groups = {ValidationGroup.insert.class}, message = "审核状态不能为空")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
/**
|
||||
* 审核原因
|
||||
*/
|
||||
@ApiModelProperty(value = "审核原因")
|
||||
private String checkResult;
|
||||
|
||||
}
|
|
@ -0,0 +1,161 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "特保区基本信息表")
|
||||
public class FreeTradeVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "编辑时ID不能为空")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
@ApiModelProperty(value = "批次号", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "批次号不能为空")
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 企业编码
|
||||
*/
|
||||
@ApiModelProperty(value = "企业编码", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "企业编码不能为空")
|
||||
private String companyCode;
|
||||
|
||||
/**
|
||||
* 企业社会信用代码
|
||||
*/
|
||||
@ApiModelProperty(value = "企业社会信用代码", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "企业社会信用代码不能为空")
|
||||
private String companySocialCode;
|
||||
|
||||
/**
|
||||
* 企业名称
|
||||
*/
|
||||
@ApiModelProperty(value = "企业名称", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "企业名称不能为空")
|
||||
private String companyName;
|
||||
|
||||
/**
|
||||
* 国家
|
||||
*/
|
||||
@ApiModelProperty(value = "国家", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "国家不能为空")
|
||||
private String country;
|
||||
|
||||
/**
|
||||
* 城市
|
||||
*/
|
||||
@ApiModelProperty(value = "城市", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "城市不能为空")
|
||||
private String city;
|
||||
|
||||
/**
|
||||
* 商品料号
|
||||
*/
|
||||
@ApiModelProperty(value = "商品料号", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "商品料号不能为空")
|
||||
private String cargoItemNo;
|
||||
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty(value = "商品编码", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "商品编码不能为空")
|
||||
private String cargoCode;
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty(value = "商品名称", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "商品名称不能为空")
|
||||
private String cargoName;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty(value = "规格型号", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "规格型号不能为空")
|
||||
private String spec;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty(value = "币制", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "币制不能为空")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty(value = "总价", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "总价不能为空")
|
||||
private BigDecimal totalPrice;
|
||||
|
||||
/**
|
||||
* 净重
|
||||
*/
|
||||
@ApiModelProperty(value = "净重", required = true)
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "净重不能为空")
|
||||
private Integer netWeight;
|
||||
|
||||
/**
|
||||
* 申报计量单位
|
||||
*/
|
||||
@ApiModelProperty(value = "申报计量单位", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "申报计量单位不能为空")
|
||||
private String unitMeasure;
|
||||
|
||||
/**
|
||||
* 法定单位
|
||||
*/
|
||||
@ApiModelProperty(value = "法定单位", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "法定单位不能为空")
|
||||
private String unitLegal;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty(value = "原产国", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "原产国不能为空")
|
||||
private String originArea;
|
||||
|
||||
/**
|
||||
* 是否激活
|
||||
*/
|
||||
@ApiModelProperty(value = "是否激活", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "是否激活不能为空")
|
||||
private String isActivate;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
/**
|
||||
* 港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@ApiModelProperty(value = "港区")
|
||||
private String portArea;
|
||||
|
||||
/**
|
||||
* 车架号
|
||||
*/
|
||||
@ApiModelProperty(value = "车架号")
|
||||
private String vin;
|
||||
|
||||
}
|
|
@ -0,0 +1,89 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "进口提货货物表",description = "")
|
||||
public class ImportTakeCargoVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌不能为空")
|
||||
@ApiModelProperty(value = "品牌", required = true)
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 查验
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "查验不能为空")
|
||||
@ApiModelProperty(value = "查验", required = true)
|
||||
private Integer examine;
|
||||
|
||||
/**
|
||||
* 受理
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "受理不能为空")
|
||||
@ApiModelProperty(value = "受理", required = true)
|
||||
private Integer accept;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提单号不能为空")
|
||||
@ApiModelProperty(value = "提单号", required = true)
|
||||
private String billNo;
|
||||
|
||||
/**
|
||||
* 报关单号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "报关单号不能为空")
|
||||
@ApiModelProperty(value = "报关单号", required = true)
|
||||
private String customsNo;
|
||||
|
||||
/**
|
||||
* 车辆数量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "车辆数量不能为空")
|
||||
@ApiModelProperty(value = "车辆数量", required = true)
|
||||
private Integer carNum;
|
||||
|
||||
/**
|
||||
* 备件数量
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "备件数量不能为空")
|
||||
@ApiModelProperty(value = "备件数量", required = true)
|
||||
private Integer spareNum;
|
||||
|
||||
/**
|
||||
* 总数
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "总数不能为空")
|
||||
@ApiModelProperty(value = "总数", required = true)
|
||||
private Integer totalNum;
|
||||
|
||||
/**
|
||||
* 货物类型ID,0代表车辆,1代表备件
|
||||
*/
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Integer cargoType;
|
||||
|
||||
/**
|
||||
* 品牌ID
|
||||
*/
|
||||
@ApiModelProperty(value = "品牌ID")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "品牌ID不能为空")
|
||||
private String brandId;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
}
|
|
@ -0,0 +1,51 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "进口提货审核")
|
||||
public class ImportTakeCheckVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "进口提货ID")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "进口提货ID不能为空")
|
||||
private List<Long> ids;
|
||||
|
||||
@ApiModelProperty(value = "审核人ID")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人ID不能为空")
|
||||
private String checkManId;
|
||||
|
||||
/**
|
||||
* 审核人
|
||||
*/
|
||||
@ApiModelProperty(value = "审核人")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人不能为空")
|
||||
private String checkMan;
|
||||
|
||||
/**
|
||||
* 审核时间
|
||||
*/
|
||||
// private Date checkTime;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
@NotNull(groups = {ValidationGroup.insert.class}, message = "审核状态不能为空")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
/**
|
||||
* 审核原因
|
||||
*/
|
||||
@ApiModelProperty(value = "审核原因")
|
||||
private String checkResult;
|
||||
|
||||
}
|
|
@ -0,0 +1,49 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "进口提货工作过程表",description = "")
|
||||
public class ImportTakeJobVo implements Serializable {
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 类型
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "类型不能为空")
|
||||
@ApiModelProperty(value = "类型", required = true)
|
||||
private Integer jobType;
|
||||
|
||||
/**
|
||||
* 作业过程
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "作业过程不能为空")
|
||||
@ApiModelProperty(value = "作业过程", required = true)
|
||||
private String jobProcess;
|
||||
|
||||
/**
|
||||
* 作业方式
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "作业方式不能为空")
|
||||
@ApiModelProperty(value = "作业方式", required = true)
|
||||
private String jobMode;
|
||||
|
||||
/**
|
||||
* 使用机械
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "使用机械不能为空")
|
||||
@ApiModelProperty(value = "使用机械", required = true)
|
||||
private String jobMachine;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
}
|
|
@ -0,0 +1,94 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 计划号 按照年月日时分秒生成唯一字符串,只生成一次
|
||||
* 计划类型 取作业模式下的作业过程字段
|
||||
* 作业方式 取作业模式下的作业方式字段
|
||||
* 船名
|
||||
* 航次
|
||||
* 提单号
|
||||
* 货名 取作业模式下的类型字段(既有车辆又有备件分开打印,计划号不同)
|
||||
* 作业日期
|
||||
* 件数
|
||||
* 重量 取舱单的重量,随车备件没有重量则为空
|
||||
* 立方 取舱单的体积,随车备件没有体积则为空
|
||||
* 申请单位 取申请对象对应的单位名称
|
||||
* 申请人 取申请对象对应的申请人
|
||||
* 联系电话 取申请人对应的联系电话
|
||||
* 申请说明 显示备注内容
|
||||
* 受理人 显示实际受理人姓名
|
||||
* 受理时间 显示实际受理时间,精确到秒
|
||||
*
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "进口提货小票打印", description = "")
|
||||
public class ImportTakePrintVo implements Serializable {
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ApiModelProperty(value = "计划号", required = false)
|
||||
private String batchNo;
|
||||
|
||||
// 计划类型
|
||||
private Integer jobProcess;
|
||||
|
||||
// 作业方式
|
||||
private String jobMode;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船名", required = true)
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
private String voyage;
|
||||
|
||||
// 提单号
|
||||
private String billNo;
|
||||
|
||||
// 货名
|
||||
private Integer jobType;
|
||||
|
||||
// 作业日期
|
||||
private Date jobTime;
|
||||
|
||||
// 件数
|
||||
private Integer takeCarNum;
|
||||
|
||||
// 重量
|
||||
|
||||
// 立方
|
||||
|
||||
// 申请单位
|
||||
|
||||
// 申请人
|
||||
private String applicant;
|
||||
|
||||
// 联系电话
|
||||
private String phone;
|
||||
|
||||
// 申请说明
|
||||
private String remark;
|
||||
|
||||
// 受理人
|
||||
|
||||
// 受理时间
|
||||
}
|
|
@ -0,0 +1,224 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 出口进场基本表
|
||||
*
|
||||
* @TableName customer_export_in
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "进口提货基本表", description = "")
|
||||
public class ImportTakeVo implements Serializable {
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "编辑时请进场ID不能为空")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "受理号不能为空")
|
||||
@ApiModelProperty(value = "受理号", required = false)
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 贸易类型
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.update.class, ValidationGroup.insert.class}, message = "贸易类型不能为空")
|
||||
@ApiModelProperty(value = "贸易类型")
|
||||
private String tradType;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船名不能为空")
|
||||
@ApiModelProperty(value = "船名", required = true)
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次不能为空")
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
private String voyage;
|
||||
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
@ApiModelProperty(value = "港区", required = true)
|
||||
private String portArea;
|
||||
|
||||
/**
|
||||
* 提车总数
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "提车总数不能为空")
|
||||
@ApiModelProperty(value = "提车总数", required = true)
|
||||
private Integer takeCarNum;
|
||||
|
||||
/**
|
||||
* 计划备件数
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "计划备件数不能为空")
|
||||
@ApiModelProperty(value = "计划备件数", required = true)
|
||||
private Integer planSpareNum;
|
||||
|
||||
/**
|
||||
* 计划车辆数
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "计划车辆数不能为空")
|
||||
@ApiModelProperty(value = "计划车辆数", required = true)
|
||||
private Integer planCarNum;
|
||||
|
||||
/**
|
||||
* 货物进场时间
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "货物进场时间不能为空")
|
||||
@ApiModelProperty(value = "货物进场时间", required = true)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date cargoEnterTime;
|
||||
|
||||
/**
|
||||
* 船舶到港日期
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "船舶到港日期不能为空")
|
||||
@ApiModelProperty(value = "船舶到港日期", required = true)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date shipEnterTime;
|
||||
|
||||
/**
|
||||
* 作业时间
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "作业时间不能为空")
|
||||
@ApiModelProperty(value = "作业时间", required = true)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date jobTime;
|
||||
|
||||
/**
|
||||
* 通关性质
|
||||
*/
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "通关性质不能为空")
|
||||
@ApiModelProperty(value = "通关性质", required = true)
|
||||
private Integer clearanceType;
|
||||
|
||||
/**
|
||||
* 收货单位
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
@ApiModelProperty(value = "港区", required = true)
|
||||
private String consignee;
|
||||
|
||||
/**
|
||||
* 付款单位
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
@ApiModelProperty(value = "港区", required = true)
|
||||
private String payer;
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
@ApiModelProperty(value = "港区", required = true)
|
||||
private String linkMan;
|
||||
|
||||
/**
|
||||
* 联系电话
|
||||
*/
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "港区不能为空")
|
||||
@ApiModelProperty(value = "港区", required = true)
|
||||
private String phone;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 申请人
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人", required = true)
|
||||
private String applicant;
|
||||
|
||||
/**
|
||||
* 申请时间
|
||||
*/
|
||||
@ApiModelProperty(value = "申请时间", required = true)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date applyTime;
|
||||
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船ID")
|
||||
@NotBlank(groups = {ValidationGroup.update.class, ValidationGroup.insert.class}, message = "船ID不能为空")
|
||||
private String shipId;
|
||||
|
||||
/**
|
||||
* 英文船名
|
||||
*/
|
||||
@ApiModelProperty(value = "英文船名")
|
||||
@NotBlank(groups = {ValidationGroup.update.class, ValidationGroup.insert.class}, message = "英文船名不能为空")
|
||||
private String shipEnName;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.update.class, ValidationGroup.insert.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 港区ID
|
||||
*/
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
@NotBlank(groups = {ValidationGroup.update.class, ValidationGroup.insert.class}, message = "港区ID不能为空")
|
||||
private String portAreaId;
|
||||
|
||||
/**
|
||||
* 收货单位ID
|
||||
*/
|
||||
@ApiModelProperty(value = "收货单位ID")
|
||||
@NotBlank(groups = {ValidationGroup.update.class, ValidationGroup.insert.class}, message = "收货单位ID不能为空")
|
||||
private String consigneeId;
|
||||
|
||||
/**
|
||||
* 付款单位Id
|
||||
*/
|
||||
@ApiModelProperty(value = "付款单位Id")
|
||||
@NotBlank(groups = {ValidationGroup.update.class, ValidationGroup.insert.class}, message = "付款单位Id不能为空")
|
||||
private String payerId;
|
||||
|
||||
/**
|
||||
* 申请人ID
|
||||
*/
|
||||
@ApiModelProperty(value = "申请人ID")
|
||||
private String applicantId;
|
||||
|
||||
@ApiModelProperty(value = "版本号", required = true)
|
||||
private Integer version;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "货物列表不能为空")
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 1, message = "货物列表至少要有一个")
|
||||
private List<ImportTakeCargoVo> cargos;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "工作过程必须填!")
|
||||
@Size(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, min = 1, message = "工作过程至少要有一个")
|
||||
private List<ImportTakeJobVo> jobs;
|
||||
}
|
|
@ -0,0 +1,51 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "进口卸船审核")
|
||||
public class ImportUnloadCheckVo implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "进口卸船ID")
|
||||
@NotNull(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "进口卸船ID不能为空")
|
||||
private List<Long> ids;
|
||||
|
||||
@ApiModelProperty(value = "审核人ID")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人ID不能为空")
|
||||
private String checkManId;
|
||||
|
||||
/**
|
||||
* 审核人
|
||||
*/
|
||||
@ApiModelProperty(value = "审核人")
|
||||
// @NotEmpty(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "审核人不能为空")
|
||||
private String checkMan;
|
||||
|
||||
/**
|
||||
* 审核时间
|
||||
*/
|
||||
// private Date checkTime;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
@NotNull(groups = {ValidationGroup.insert.class}, message = "审核状态不能为空")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
/**
|
||||
* 审核原因
|
||||
*/
|
||||
@ApiModelProperty(value = "审核原因")
|
||||
private String checkResult;
|
||||
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.excel.ExportVinExcel;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "车架号导入")
|
||||
public class ImportVinVo implements Serializable {
|
||||
|
||||
@NotNull(message = "出口进场ID不能为空")
|
||||
private Long id;
|
||||
|
||||
@Valid
|
||||
@NotNull(message = "车架号列表不能为空")
|
||||
@Size(min = 1, message = "车架号列表不能为空")
|
||||
private List<ExportVinExcel> data;
|
||||
}
|
|
@ -0,0 +1,58 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "联系人",description = "")
|
||||
public class LinkmanVo implements Serializable {
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "联系人ID不能为空")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Long id;
|
||||
|
||||
|
||||
/**
|
||||
* 货代
|
||||
*/
|
||||
@ApiModelProperty(value ="货代")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "货代不能为空")
|
||||
private String freight;
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ApiModelProperty(value ="联系人")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系人不能为空")
|
||||
private String contact;
|
||||
|
||||
/**
|
||||
* 联系方式
|
||||
*/
|
||||
@ApiModelProperty(value ="联系方式")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "联系方式不能为空")
|
||||
private String contactPhone;
|
||||
|
||||
/**
|
||||
* 外勤联系人
|
||||
*/
|
||||
@ApiModelProperty(value ="外勤联系人")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "外勤联系人不能为空")
|
||||
private String fieldContact;
|
||||
|
||||
/**
|
||||
* 外勤联系方式
|
||||
*/
|
||||
@ApiModelProperty(value ="外勤联系方式")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "外勤联系方式不能为空")
|
||||
private String fieldContactPhone;
|
||||
|
||||
@ApiModelProperty(value = "版本号", hidden = true)
|
||||
private Integer version;
|
||||
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value ="用户登录")
|
||||
public class LoginDTO implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "账号")
|
||||
@NotNull(message = "账号不能为空")
|
||||
private String account;
|
||||
|
||||
@ApiModelProperty(value = "密码")
|
||||
@NotNull(message = "密码不能为空")
|
||||
private String password;
|
||||
|
||||
@ApiModelProperty(value = "手机号")
|
||||
@NotNull(message = "手机号不能为空")
|
||||
private String mobile;
|
||||
}
|
|
@ -0,0 +1,35 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.nuzar.cloud.web.model.QueryModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
import lombok.ToString;
|
||||
|
||||
@ToString
|
||||
@Data
|
||||
public class OrderDTO extends QueryModel {
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "用户编号", required = true)
|
||||
@Size(max = 20)
|
||||
@NotBlank(message = "用户编号不能为空")
|
||||
private String userId;
|
||||
|
||||
private String commodityCode;
|
||||
|
||||
@ApiModelProperty(value = "金额", required = true)
|
||||
@Size(max = 20)
|
||||
@NotNull(message = "金额不能为空")
|
||||
private Integer count;
|
||||
|
||||
private Integer money;
|
||||
|
||||
private String status;
|
||||
|
||||
private String createTime;
|
||||
|
||||
private String updateTime;
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "船名航次列表")
|
||||
public class ShipVoyageVo implements Serializable {
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "船ID")
|
||||
private String shipId;
|
||||
|
||||
/**
|
||||
* 中文船名
|
||||
*/
|
||||
@ApiModelProperty(value = "中文船名")
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 英文船名
|
||||
*/
|
||||
@ApiModelProperty(value = "英文船名")
|
||||
private String shipEnName;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "批量修改船名、航次")
|
||||
public class UpdateShipVo implements Serializable {
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ApiModelProperty(value = "计划ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "计划ID不能为空")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 航次ID
|
||||
*/
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次ID不能为空")
|
||||
private String voyageId;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ApiModelProperty(value = "航次", required = true)
|
||||
@NotBlank(groups = {ValidationGroup.insert.class, ValidationGroup.update.class}, message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.utils.ValidationGroup;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "工作状态",description = "")
|
||||
public class WorkStatusVo implements Serializable {
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ApiModelProperty(value = "工作状态")
|
||||
@NotBlank(groups = {ValidationGroup.update.class}, message = "工作状态不能为空")
|
||||
private String workStatus;
|
||||
|
||||
@Valid
|
||||
@NotNull(groups = {ValidationGroup.update.class}, message = "车架号不能为空!" )
|
||||
@Size(min = 1 , message = "车架号至少要有一个")
|
||||
private List<String> vins;
|
||||
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
package com.haitonggauto.rtosc.dto;
|
||||
|
||||
import com.haitonggauto.rtosc.common.dto.LoginUser;
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class WsnetUser extends LoginUser {
|
||||
private String username; // 用户名称
|
||||
|
||||
private Long customerId; // 客户ID
|
||||
|
||||
private String customerName; // 客户名称
|
||||
}
|
|
@ -0,0 +1,47 @@
|
|||
package com.haitonggauto.rtosc.enums;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public enum OrderStatusEnum {
|
||||
INIT("INIT","初始状态"),
|
||||
PAID("PAID","已支付"),
|
||||
|
||||
DELIVERED("DELIVERED","已发货"),
|
||||
|
||||
RECEIVED("RECEIVED","已收货"),
|
||||
|
||||
CANCELED("CANCELED","交易取消");
|
||||
|
||||
|
||||
private String code;
|
||||
|
||||
private String value;
|
||||
|
||||
OrderStatusEnum(String code,String value){
|
||||
this.code = code;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public String getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public String getValueByCode(String code) {
|
||||
for (OrderStatusEnum statusEnum : OrderStatusEnum.values()) {
|
||||
if(statusEnum.getCode().equals(code)){
|
||||
return statusEnum.value;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public OrderStatusEnum getByCode(String code){
|
||||
for (OrderStatusEnum statusEnum : OrderStatusEnum.values()) {
|
||||
if(statusEnum.getCode().equals(code)){
|
||||
return statusEnum;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,227 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 出口进场基本表
|
||||
* @TableName customer_export_in
|
||||
*/
|
||||
@Data
|
||||
public class ExportInExcel {
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ExcelProperty("受理号")
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ExcelProperty("船名")
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ExcelProperty("航次")
|
||||
private String voyage;
|
||||
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@ExcelProperty("港区")
|
||||
private String portArea;
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ExcelProperty("联系人")
|
||||
private String contact;
|
||||
|
||||
/**
|
||||
* 联系方式
|
||||
*/
|
||||
@ExcelProperty("联系方式")
|
||||
private String contactPhone;
|
||||
|
||||
/**
|
||||
* 国家
|
||||
*/
|
||||
@ExcelProperty("国家")
|
||||
private String country;
|
||||
|
||||
/**
|
||||
* 港口
|
||||
*/
|
||||
@ExcelProperty("港口")
|
||||
private String portName;
|
||||
|
||||
/**
|
||||
* 运输方式
|
||||
*/
|
||||
@ExcelProperty("运输方式")
|
||||
private String transportWay;
|
||||
|
||||
/**
|
||||
* 进场时间
|
||||
*/
|
||||
@ExcelProperty("进场时间")
|
||||
private String enterTime;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@ExcelProperty("品牌")
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 车型
|
||||
*/
|
||||
@ExcelProperty("车型")
|
||||
private String cartType;
|
||||
|
||||
/**
|
||||
* 车型明细
|
||||
*/
|
||||
@ExcelProperty("车型明细")
|
||||
private String cartTypeDetail;
|
||||
|
||||
/**
|
||||
* 型号
|
||||
*/
|
||||
@ExcelProperty("型号")
|
||||
private String models;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
@ExcelProperty("数量")
|
||||
private Integer quantity;
|
||||
|
||||
@ExcelProperty("进场数量")
|
||||
private Integer enterQuantity;
|
||||
|
||||
/**
|
||||
* 单票重量
|
||||
*/
|
||||
@ExcelProperty("单票重量(吨)")
|
||||
private BigDecimal eachWeight;
|
||||
|
||||
/**
|
||||
* 单票数量
|
||||
*/
|
||||
@ExcelProperty("单票件数")
|
||||
private Integer eachQuantity;
|
||||
|
||||
/**
|
||||
* 单票体积
|
||||
*/
|
||||
@ExcelProperty("单票体积")
|
||||
private BigDecimal eachVolume;
|
||||
|
||||
/**
|
||||
* 体积
|
||||
*/
|
||||
@ExcelProperty("体积")
|
||||
private BigDecimal volume;
|
||||
|
||||
/**
|
||||
* 长
|
||||
*/
|
||||
@ExcelProperty("长")
|
||||
private Integer length;
|
||||
|
||||
/**
|
||||
* 宽
|
||||
*/
|
||||
@ExcelProperty("宽")
|
||||
private Integer width;
|
||||
|
||||
/**
|
||||
* 高
|
||||
*/
|
||||
@ExcelProperty("高")
|
||||
private Integer height;
|
||||
|
||||
/**
|
||||
* 重量(吨)
|
||||
*/
|
||||
@ExcelProperty("重量(吨)")
|
||||
private Integer weight;
|
||||
|
||||
/**
|
||||
* 操作模式
|
||||
*/
|
||||
@ExcelProperty("操作模式")
|
||||
private String operateType;
|
||||
|
||||
/**
|
||||
* 操作模式
|
||||
*/
|
||||
@ExcelProperty("货代")
|
||||
private String freight;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@ExcelProperty("提单号")
|
||||
private String billNum;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@ExcelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 源类型
|
||||
*/
|
||||
@ExcelProperty("源类型")
|
||||
private String energyTypeName;
|
||||
|
||||
@ExcelProperty("产地")
|
||||
private String originPlace;
|
||||
// /**
|
||||
// * 申请人
|
||||
// */
|
||||
// @ExcelProperty("申请人")
|
||||
// private String applicant;
|
||||
//
|
||||
// /**
|
||||
// * 申请时间
|
||||
// */
|
||||
// @ExcelProperty("申请时间")
|
||||
// private Date applyTime;
|
||||
//
|
||||
// /**
|
||||
// * 审核人
|
||||
// */
|
||||
// @ExcelProperty("审核人")
|
||||
// private String checkMan;
|
||||
//
|
||||
// /**
|
||||
// * 审核时间
|
||||
// */
|
||||
// @ExcelProperty("审核时间")
|
||||
// private Date checkTime;
|
||||
//
|
||||
// /**
|
||||
// * 审核状态
|
||||
// */
|
||||
// @ExcelProperty("审核状态")
|
||||
// private String checkStatus;
|
||||
//
|
||||
// /**
|
||||
// * 审核原因
|
||||
// */
|
||||
// @ExcelProperty("审核原因")
|
||||
// private String checkResult;
|
||||
|
||||
}
|
|
@ -0,0 +1,240 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.alibaba.excel.annotation.format.DateTimeFormat;
|
||||
import com.alibaba.excel.annotation.format.NumberFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 导入说明:
|
||||
* 1.港区必须是基础数据的港区,否则导入不成功
|
||||
* 2.船名必须是基础数据的船名,否则导入不成功
|
||||
* 3.航次必须是HT6、HTTC、HTLG,否则导入不成功
|
||||
* 4.联系方式必须要校验手机号是否正确,不正确导入不成功
|
||||
* 5.港口必须是基础数据的港口,否则导入不成功
|
||||
* 6.运输方式必须是板车运输、商品车自开、驳船,否则导入不成功
|
||||
* 7.进场时间格式为2023-09-08 12:00,否则导入不成功
|
||||
* 8.进场数量:必须是整数,否则导入不成功
|
||||
* 9.单票件数必须是整数,否则导入不成功
|
||||
* 10.单票体积最多四位小数,否则导入不成功
|
||||
* 11.单票重量最多四位小数,否则导入不成功
|
||||
* 12.品牌必须是基础数据的品牌,否则导入不成功
|
||||
* 13.车型必须是基础数据的车型,否则导入不成功
|
||||
* 14.车型明细必须是和车型关联的车型明细,否则导入不成功
|
||||
* 15.产地必须是基础数据的城市否则导入不成功
|
||||
* 16.数量必须是整数,否则导入不成功
|
||||
* 17.长、宽、高、重量最多保留四位小数,否则导入不成功
|
||||
* 18.操作模式:如果是车辆为港机作业,客户自开,如果是备件为铲车、吊车、浮吊,否则导入不成功
|
||||
* 19.源类型必须是是新能源、不是新能源,否则的导入不成功
|
||||
*/
|
||||
@Data
|
||||
public class ExportInPlanExcel {
|
||||
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@ExcelProperty("*港区")
|
||||
@NotBlank(message = "港区不能为空")
|
||||
private String portArea;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ExcelProperty("*船名")
|
||||
@NotBlank(message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ExcelProperty("*航次")
|
||||
@NotBlank(message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
|
||||
/**
|
||||
* 货代
|
||||
*/
|
||||
@ExcelProperty("*货代")
|
||||
@NotBlank(message = "货代不能为空")
|
||||
private String freight;
|
||||
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ExcelProperty("*联系人")
|
||||
@NotBlank(message = "联系人不能为空")
|
||||
private String contact;
|
||||
|
||||
/**
|
||||
* 联系方式
|
||||
*/
|
||||
@ExcelProperty("*联系方式")
|
||||
@NotBlank(message = "联系方式不能为空")
|
||||
private String contactPhone;
|
||||
|
||||
/**
|
||||
* 港口
|
||||
*/
|
||||
@ExcelProperty("*港口")
|
||||
@NotBlank(message = "港口不能为空")
|
||||
private String portName;
|
||||
|
||||
/**
|
||||
* 运输方式
|
||||
*/
|
||||
@ExcelProperty("*运输方式")
|
||||
@NotBlank(message = "运输方式不能为空")
|
||||
private String transportWay;
|
||||
|
||||
/**
|
||||
* 进场时间
|
||||
*/
|
||||
// @DateTimeFormat("yyyy-MM-dd HH:mm")
|
||||
@ExcelProperty("*进场时间")
|
||||
@NotNull(message = "进场时间不能为空")
|
||||
private String enterTime;
|
||||
|
||||
/**
|
||||
* 进场数量
|
||||
*/
|
||||
@ExcelProperty("*进场数量")
|
||||
@NotNull(message = "进场数量不能为空")
|
||||
private Integer enterQuantity;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@ExcelProperty("*提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
private String billNum;
|
||||
|
||||
/**
|
||||
* 单票数量
|
||||
*/
|
||||
@ExcelProperty("*单票件数")
|
||||
@NotNull(message = "单票件数不能为空")
|
||||
private Integer eachQuantity;
|
||||
|
||||
// /**
|
||||
// * 单票件数
|
||||
// */
|
||||
// @ExcelProperty("单票件数")
|
||||
// @NotNull(message = "单票件数不能为空")
|
||||
// private Integer eachPieces;
|
||||
|
||||
/**
|
||||
* 单票体积
|
||||
*/
|
||||
@ExcelProperty("*单票体积")
|
||||
@NotNull(message = "单票体积不能为空")
|
||||
@NumberFormat("#.####")
|
||||
private BigDecimal eachVolume;
|
||||
|
||||
/**
|
||||
* 单票重量
|
||||
*/
|
||||
@ExcelProperty("*单票重量(吨)")
|
||||
@NotNull(message = "单票重量不能为空")
|
||||
@NumberFormat("#.####")
|
||||
private BigDecimal eachWeight;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@ExcelProperty("*品牌")
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 车型
|
||||
*/
|
||||
@ExcelProperty("*车型")
|
||||
@NotBlank(message = "车型不能为空")
|
||||
private String cartType;
|
||||
|
||||
/**
|
||||
* 车型明细
|
||||
*/
|
||||
@ExcelProperty("*车型明细")
|
||||
@NotBlank(message = "车型明细不能为空")
|
||||
private String cartTypeDetail;
|
||||
|
||||
/**
|
||||
* 型号
|
||||
*/
|
||||
@ExcelProperty("*型号")
|
||||
@NotBlank(message = "型号不能为空")
|
||||
private String models;
|
||||
|
||||
/**
|
||||
* 产地
|
||||
*/
|
||||
@ExcelProperty("*产地")
|
||||
@NotBlank(message = "产地不能为空")
|
||||
private String originPlace;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
@ExcelProperty("*数量")
|
||||
@NotNull(message = "数量不能为空")
|
||||
private Integer quantity;
|
||||
|
||||
/**
|
||||
* 长
|
||||
*/
|
||||
@ExcelProperty("*长")
|
||||
@NotNull(message = "长不能为空")
|
||||
@NumberFormat("#.####")
|
||||
private BigDecimal length;
|
||||
|
||||
/**
|
||||
* 宽
|
||||
*/
|
||||
@ExcelProperty("*宽")
|
||||
@NotNull(message = "宽不能为空")
|
||||
@NumberFormat("#.####")
|
||||
private BigDecimal width;
|
||||
|
||||
/**
|
||||
* 高
|
||||
*/
|
||||
@ExcelProperty("*高")
|
||||
@NotNull(message = "高不能为空")
|
||||
@NumberFormat("#.####")
|
||||
private BigDecimal height;
|
||||
|
||||
/**
|
||||
* 重量(吨)
|
||||
*/
|
||||
@ExcelProperty("*重量(吨)")
|
||||
@NotNull(message = "重量不能为空")
|
||||
@NumberFormat("#.####")
|
||||
private BigDecimal weight;
|
||||
|
||||
@ExcelProperty("*体积")
|
||||
@ApiModelProperty(value = "体积")
|
||||
private BigDecimal volume;
|
||||
|
||||
/**
|
||||
* 操作模式
|
||||
*/
|
||||
@ExcelProperty("*操作模式")
|
||||
@NotBlank(message = "操作模式不能为空")
|
||||
private String operateType;
|
||||
|
||||
/**
|
||||
* 源类型
|
||||
*/
|
||||
@ExcelProperty("*源类型")
|
||||
@NotBlank(message = "源类型不能为空")
|
||||
private String energyTypeName;
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 出口进场货物名比较喜欢导出
|
||||
* @TableName customer_export_in
|
||||
*/
|
||||
@Data
|
||||
public class ExportInVinExportExcel {
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ExcelProperty("序号")
|
||||
private Integer serialNo;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@ExcelProperty("船名")
|
||||
private String shipName;
|
||||
|
||||
/**
|
||||
* 航次
|
||||
*/
|
||||
@ExcelProperty("航次")
|
||||
private String voyage;
|
||||
|
||||
/**
|
||||
* 提单号
|
||||
*/
|
||||
@ExcelProperty("提单号")
|
||||
private String billNum;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
@ExcelProperty("品牌")
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 型号
|
||||
*/
|
||||
@ExcelProperty("型号")
|
||||
private String models;
|
||||
|
||||
/**
|
||||
* 车架号
|
||||
*/
|
||||
@ExcelProperty("车架号")
|
||||
private String vin;
|
||||
|
||||
}
|
|
@ -0,0 +1,36 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
|
||||
@Data
|
||||
public class ExportLoadExcel {
|
||||
|
||||
@ExcelProperty("*船名")
|
||||
@NotBlank(message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
@ExcelProperty("*航次")
|
||||
@NotBlank(message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
@ExcelProperty("*提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
private String billNo;
|
||||
|
||||
@ExcelProperty("*品牌")
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
@ExcelProperty("*型号")
|
||||
@NotBlank(message = "型号不能为空")
|
||||
private String models;
|
||||
|
||||
@ExcelProperty("*车架号")
|
||||
@NotBlank(message = "车架号不能为空")
|
||||
@Size(min = 17, max = 17, message = "车架号长度为17位")
|
||||
private String vin;
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
|
||||
@Data
|
||||
public class ExportLoadInsideExcel {
|
||||
|
||||
@ExcelProperty("*船名")
|
||||
@NotBlank(message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
@ExcelProperty("*航次")
|
||||
@NotBlank(message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
@ExcelProperty("*港区")
|
||||
@NotBlank(message = "港区不能为空")
|
||||
private String portArea;
|
||||
|
||||
@ExcelProperty("*提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
private String billNo;
|
||||
|
||||
@ExcelProperty("*品牌")
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
@ExcelProperty("*目的港")
|
||||
private String destPort;
|
||||
|
||||
@ExcelProperty("*车架号")
|
||||
@NotBlank(message = "车架号不能为空")
|
||||
@Size(min = 17, max = 17, message = "车架号长度为17位")
|
||||
private String vin;
|
||||
|
||||
@ExcelProperty("*结算单位")
|
||||
@ApiModelProperty(value = "结算单位")
|
||||
@NotBlank(message = "结算单位不能为空")
|
||||
private String settleCompName;
|
||||
|
||||
@ExcelProperty("*联系人")
|
||||
@ApiModelProperty(value = "联系人")
|
||||
@NotBlank(message = "联系人不能为空")
|
||||
private String contact;
|
||||
|
||||
@ExcelProperty("*联系方式")
|
||||
@ApiModelProperty(value = "联系方式")
|
||||
@NotBlank(message = "联系方式不能为空")
|
||||
private String contactPhone;
|
||||
}
|
|
@ -0,0 +1,49 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.Min;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
@Data
|
||||
public class ExportLoadInsideSpareExcel {
|
||||
|
||||
@ExcelProperty("船名")
|
||||
@NotBlank(message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
@ExcelProperty("航次")
|
||||
@NotBlank(message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
@ExcelProperty("提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
private String billNo;
|
||||
|
||||
@ExcelProperty("品牌")
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
@ExcelProperty("数量")
|
||||
@NotNull(message = "数量不能为空")
|
||||
@Min(value = 1, message = "数量必须大于0")
|
||||
private Integer num;
|
||||
|
||||
@ExcelProperty("结算单位")
|
||||
@ApiModelProperty(value = "结算单位")
|
||||
@NotBlank(message = "结算单位不能为空")
|
||||
private String settleCompName;
|
||||
|
||||
@ExcelProperty("联系人")
|
||||
@ApiModelProperty(value = "联系人")
|
||||
@NotBlank(message = "联系人不能为空")
|
||||
private String contact;
|
||||
|
||||
@ExcelProperty("联系方式")
|
||||
@ApiModelProperty(value = "联系方式")
|
||||
@NotBlank(message = "联系方式不能为空")
|
||||
private String contactPhone;
|
||||
}
|
|
@ -0,0 +1,33 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
|
||||
@Data
|
||||
public class ExportLoadSpareExcel {
|
||||
|
||||
@ExcelProperty("*船名")
|
||||
@NotBlank(message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
@ExcelProperty("*航次")
|
||||
@NotBlank(message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
@ExcelProperty("*提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
private String billNo;
|
||||
|
||||
@ExcelProperty("*品牌")
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
@ExcelProperty("*数量")
|
||||
@NotNull(message = "数量不能为空")
|
||||
private Integer num;
|
||||
|
||||
}
|
|
@ -0,0 +1,37 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
|
||||
|
||||
/**
|
||||
* 出口进场基本表
|
||||
* @TableName customer_export_in
|
||||
*/
|
||||
@Data
|
||||
@ApiModel
|
||||
public class ExportVinExcel {
|
||||
|
||||
/**
|
||||
* 受理号
|
||||
*/
|
||||
@ApiModelProperty(value = "提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
@ExcelProperty("*提单号")
|
||||
private String billNo;
|
||||
|
||||
/**
|
||||
* 船名
|
||||
*/
|
||||
@NotBlank(message = "车架号不能为空")
|
||||
@Size(min = 17, max = 17, message = "车架号长度为17位")
|
||||
@ApiModelProperty(value = "车架号")
|
||||
@ExcelProperty("*车架号")
|
||||
private String vin;
|
||||
|
||||
}
|
|
@ -0,0 +1,121 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
@Data
|
||||
@ApiModel
|
||||
public class FreeTradeExcel {
|
||||
/**
|
||||
* 港区
|
||||
*/
|
||||
@NotBlank(message = "港区不能为空")
|
||||
@ExcelProperty("*港区")
|
||||
@ApiModelProperty(value = "港区")
|
||||
private String portArea;
|
||||
|
||||
// 批次号
|
||||
@ApiModelProperty(value = "批次号")
|
||||
@NotBlank(message = "批次号不能为空")
|
||||
@ExcelProperty("批次号")
|
||||
private String batchNo;
|
||||
|
||||
// 企业编码
|
||||
@ApiModelProperty(value = "企业编码")
|
||||
@NotBlank(message = "企业编码不能为空")
|
||||
@ExcelProperty("*企业编码")
|
||||
private String companyCode;
|
||||
|
||||
// 企业社会信用代码
|
||||
@ApiModelProperty(value = "企业社会信用代码")
|
||||
@NotBlank(message = "企业社会信用代码不能为空")
|
||||
@ExcelProperty("*企业社会信用代码")
|
||||
private String companySocialCode;
|
||||
|
||||
// 企业名称
|
||||
@ApiModelProperty(value = "企业名称")
|
||||
@NotBlank(message = "企业名称不能为空")
|
||||
@ExcelProperty("*企业名称")
|
||||
private String companyName;
|
||||
|
||||
// 企业所在国家
|
||||
@ApiModelProperty(value = "企业所在国家")
|
||||
@NotBlank(message = "企业所在国家不能为空")
|
||||
@ExcelProperty("*企业所在国家")
|
||||
private String country;
|
||||
|
||||
// 企业所在城市
|
||||
@ApiModelProperty(value = "企业所在城市")
|
||||
@NotBlank(message = "企业所在城市不能为空")
|
||||
@ExcelProperty("*企业所在城市")
|
||||
private String city;
|
||||
|
||||
// 商品料号
|
||||
@ApiModelProperty(value = "商品料号")
|
||||
@NotBlank(message = "商品料号不能为空")
|
||||
@ExcelProperty("*商品料号")
|
||||
private String cargoCode;
|
||||
|
||||
// 商品名称
|
||||
@ApiModelProperty(value = "商品名称")
|
||||
@NotBlank(message = "商品名称不能为空")
|
||||
@ExcelProperty("*商品名称")
|
||||
private String cargoName;
|
||||
|
||||
// 规格型号
|
||||
@ApiModelProperty(value = "规格型号")
|
||||
@NotBlank(message = "规格型号不能为空")
|
||||
@ExcelProperty("*规格型号")
|
||||
private String spec;
|
||||
|
||||
// 币制
|
||||
@ApiModelProperty(value = "币制")
|
||||
@NotBlank(message = "币制不能为空")
|
||||
@ExcelProperty("*币制")
|
||||
private String currency;
|
||||
|
||||
// 总价
|
||||
@ApiModelProperty(value = "总价")
|
||||
@NotNull(message = "总价不能为空")
|
||||
@ExcelProperty("*总价")
|
||||
private BigDecimal totalPrice;
|
||||
|
||||
// 净重
|
||||
@ApiModelProperty(value = "净重")
|
||||
@NotNull(message = "净重不能为空")
|
||||
@ExcelProperty("*净重")
|
||||
private BigDecimal netWeight;
|
||||
|
||||
// 申报计量单位
|
||||
@ApiModelProperty(value = "申报计量单位")
|
||||
@NotBlank(message = "申报计量单位不能为空")
|
||||
@ExcelProperty("*申报计量单位")
|
||||
private String unitMeasure;
|
||||
|
||||
// 法定单位
|
||||
@ApiModelProperty(value = "法定单位")
|
||||
@NotBlank(message = "法定单位不能为空")
|
||||
@ExcelProperty("*法定单位")
|
||||
private String unitLegal;
|
||||
|
||||
// 原产国(地区)
|
||||
@ApiModelProperty(value = "原产国")
|
||||
@NotBlank(message = "原产国不能为空")
|
||||
@ExcelProperty("*原产国(地区)")
|
||||
private String originArea;
|
||||
|
||||
// 车架号
|
||||
@ApiModelProperty(value = "车架号")
|
||||
@NotBlank(message = "车架号不能为空")
|
||||
@Size(min = 17, max = 17, message = "车架号长度为17位")
|
||||
@ExcelProperty("*车架号")
|
||||
private String vin;
|
||||
}
|
|
@ -0,0 +1,114 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
@Data
|
||||
@ApiModel
|
||||
public class FreeTradeExportExcel {
|
||||
@ExcelProperty("ID")
|
||||
private String id;
|
||||
|
||||
// 批次号
|
||||
@ApiModelProperty(value = "批次号")
|
||||
@ExcelProperty("批次号")
|
||||
private String batchNo;
|
||||
|
||||
// 车架号
|
||||
@ApiModelProperty(value = "车架号")
|
||||
@ExcelProperty("车架号")
|
||||
private String vin;
|
||||
|
||||
// 导入日期
|
||||
@ExcelProperty("导入日期")
|
||||
private String createDate;
|
||||
|
||||
// 导入人
|
||||
@ExcelProperty("导入人")
|
||||
private String createBy;
|
||||
|
||||
// 企业编码
|
||||
@ApiModelProperty(value = "企业编码")
|
||||
@ExcelProperty("企业编码")
|
||||
private String companyCode;
|
||||
|
||||
// 企业社会信用代码
|
||||
@ApiModelProperty(value = "企业社会信用代码")
|
||||
@ExcelProperty("企业社会信用代码")
|
||||
private String companySocialCode;
|
||||
|
||||
// 企业名称
|
||||
@ApiModelProperty(value = "企业名称")
|
||||
@ExcelProperty("企业名称")
|
||||
private String companyName;
|
||||
|
||||
// 企业所在国家
|
||||
@ApiModelProperty(value = "企业所在国家")
|
||||
@ExcelProperty("企业所在国家")
|
||||
private String country;
|
||||
|
||||
// 企业所在城市
|
||||
@ApiModelProperty(value = "企业所在城市")
|
||||
@ExcelProperty("企业所在城市")
|
||||
private String city;
|
||||
|
||||
// 商品料号
|
||||
@ApiModelProperty(value = "商品料号")
|
||||
@ExcelProperty("商品料号")
|
||||
private String cargoCode;
|
||||
|
||||
// 商品名称
|
||||
@ApiModelProperty(value = "商品名称")
|
||||
@ExcelProperty("商品名称")
|
||||
private String cargoName;
|
||||
|
||||
// 规格型号
|
||||
@ApiModelProperty(value = "规格型号")
|
||||
@ExcelProperty("规格型号")
|
||||
private String spec;
|
||||
|
||||
// 币制
|
||||
@ApiModelProperty(value = "币制")
|
||||
@ExcelProperty("币制")
|
||||
private String currency;
|
||||
|
||||
// 总价
|
||||
@ApiModelProperty(value = "总价")
|
||||
@ExcelProperty("总价")
|
||||
private BigDecimal totalPrice;
|
||||
|
||||
// 净重
|
||||
@ApiModelProperty(value = "净重")
|
||||
@ExcelProperty("净重")
|
||||
private BigDecimal netWeight;
|
||||
|
||||
// 申报计量单位
|
||||
@ApiModelProperty(value = "申报计量单位")
|
||||
@ExcelProperty("申报计量单位")
|
||||
private String unitMeasure;
|
||||
|
||||
// 法定单位
|
||||
@ApiModelProperty(value = "法定单位")
|
||||
@ExcelProperty("法定单位")
|
||||
private String unitLegal;
|
||||
|
||||
// 原产国(地区)
|
||||
@ApiModelProperty(value = "原产国")
|
||||
@ExcelProperty("原产国(地区)")
|
||||
private String originArea;
|
||||
|
||||
@ExcelProperty("是否激活")
|
||||
private String isActivate;
|
||||
|
||||
@ExcelProperty("操作人")
|
||||
private String operator;
|
||||
|
||||
@ExcelProperty("操作日期")
|
||||
private String exportDate;
|
||||
}
|
|
@ -0,0 +1,36 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
|
||||
@Data
|
||||
public class ImportUnloadExcel {
|
||||
|
||||
@ExcelProperty("*船名")
|
||||
@NotBlank(message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
@ExcelProperty("*航次")
|
||||
@NotBlank(message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
@ExcelProperty("*提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
private String billNo;
|
||||
|
||||
@ExcelProperty("*品牌")
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
@ExcelProperty("*型号")
|
||||
@NotBlank(message = "型号不能为空")
|
||||
private String models;
|
||||
|
||||
@ExcelProperty("*车架号")
|
||||
@NotBlank(message = "车架号不能为空")
|
||||
@Size(min = 17, max = 17, message = "车架号长度为17位")
|
||||
private String vin;
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
package com.haitonggauto.rtosc.excel;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
@Data
|
||||
public class ImportUnloadSpareExcel {
|
||||
|
||||
@ExcelProperty("*船名")
|
||||
@NotBlank(message = "船名不能为空")
|
||||
private String shipName;
|
||||
|
||||
@ExcelProperty("*航次")
|
||||
@NotBlank(message = "航次不能为空")
|
||||
private String voyage;
|
||||
|
||||
@ExcelProperty("*提单号")
|
||||
@NotBlank(message = "提单号不能为空")
|
||||
private String billNo;
|
||||
|
||||
@ExcelProperty("*品牌")
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
private String brand;
|
||||
|
||||
@ExcelProperty("*数量")
|
||||
@NotNull(message = "数量不能为空")
|
||||
private Integer num;
|
||||
|
||||
}
|
|
@ -0,0 +1,14 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "货物明细查询")
|
||||
public class CargoQuery extends BaseQuery {
|
||||
@ApiModelProperty(value = "货物类型, 0代表车辆,1代表备件")
|
||||
private Integer cargoType;
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel
|
||||
public class DepartureQuery extends BaseQuery {
|
||||
@ApiModelProperty(value = "受理号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String batchNo;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "开始申请时间")
|
||||
@DbQuery(field = "applyTime", symbol = SqlSymbol.GTE)
|
||||
private Date beginApplyTime;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "结束申请时间")
|
||||
@DbQuery(field = "applyTime", symbol = SqlSymbol.LTE)
|
||||
private Date endApplyTime;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(value = "贸易类型")
|
||||
private String tradType;
|
||||
|
||||
@ApiModelProperty(value = "受理号")
|
||||
@DbQuery(field = "batchNo", symbol = SqlSymbol.IN)
|
||||
private List<String> batchNos;
|
||||
|
||||
@ApiModelProperty(value = "收货单位ID")
|
||||
private String receiveCompanyId;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
// 明细表查询时会用到
|
||||
private Long departureId;
|
||||
}
|
|
@ -0,0 +1,83 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口进场查询")
|
||||
public class ExportInCheckQuery extends BaseQuery {
|
||||
|
||||
@ApiModelProperty(value = "船名")
|
||||
@DbQuery(field = "shipId")
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
private String voyageId;
|
||||
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "开始进场时间")
|
||||
@DbQuery(field = "applyTime", symbol = SqlSymbol.GTE)
|
||||
private Date beginEnterTime;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "结束进场时间")
|
||||
@DbQuery(field = "applyTime", symbol = SqlSymbol.LTE)
|
||||
private Date endEnterTime;
|
||||
|
||||
@ApiModelProperty(value = "贸易类型")
|
||||
private String tradType;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(value = "品牌")
|
||||
@DbQuery(field = "brandId")
|
||||
private String brand;
|
||||
|
||||
@ApiModelProperty(value = "车型")
|
||||
@DbQuery(field = "cartTypeId")
|
||||
private String cartType;
|
||||
|
||||
@ApiModelProperty(value = "车型明细")
|
||||
@DbQuery(field = "cartTypeDetailId")
|
||||
private String cartTypeDetail;
|
||||
|
||||
@ApiModelProperty(value = "提单号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String billNum;
|
||||
|
||||
@ApiModelProperty(value = "受理号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(value = "型号")
|
||||
private String models;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
@DbQuery(field = "vin", symbol = SqlSymbol.IN)
|
||||
private List<String> vins;
|
||||
|
||||
// 明细表查询时会用到
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long exportInId;
|
||||
|
||||
}
|
|
@ -0,0 +1,73 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口进场查询")
|
||||
public class ExportInQuery extends BaseQuery {
|
||||
|
||||
@ApiModelProperty(value = "船名")
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "开始进场时间")
|
||||
@DbQuery(field = "applyTime", symbol = SqlSymbol.GTE)
|
||||
private Date beginEnterTime;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "结束进场时间")
|
||||
@DbQuery(field = "applyTime", symbol = SqlSymbol.LTE)
|
||||
private Date endEnterTime;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(value = "品牌")
|
||||
private String brand;
|
||||
|
||||
@ApiModelProperty(value = "车型")
|
||||
private String cartType;
|
||||
|
||||
@ApiModelProperty(value = "车型明细")
|
||||
private String cartTypeDetail;
|
||||
|
||||
@ApiModelProperty(value = "提单号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String billNum;
|
||||
|
||||
@ApiModelProperty(value = "受理号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(value = "型号")
|
||||
private String models;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
@DbQuery(field = "vin", symbol = SqlSymbol.IN)
|
||||
private List<String> vins;
|
||||
|
||||
// 明细表查询时会用到
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long exportInId;
|
||||
|
||||
}
|
|
@ -0,0 +1,46 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "海关查验查询")
|
||||
public class ExportInspectCheckQuery extends BaseQuery {
|
||||
|
||||
@ApiModelProperty(value = "船名")
|
||||
@DbQuery(field = "shipId")
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
private String voyageId;
|
||||
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(value = "受理号")
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
private String tradType;
|
||||
|
||||
// 明细表查询时会用到
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long exportInspectId;
|
||||
}
|
|
@ -0,0 +1,42 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "海关查验查询")
|
||||
public class ExportInspectQuery extends BaseQuery {
|
||||
|
||||
@ApiModelProperty(value = "船名")
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(value = "受理号")
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
private String tradType;
|
||||
|
||||
// 明细表查询时会用到
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long exportInspectId;
|
||||
}
|
|
@ -0,0 +1,52 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口装船查询")
|
||||
public class ExportLoadCheckQuery extends BaseQuery {
|
||||
@ApiModelProperty(value = "受理号")
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(value = "船名")
|
||||
@DbQuery(field = "shipId")
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
private String voyageId;
|
||||
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
|
||||
@ApiModelProperty(value = "提单号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String billNo;
|
||||
|
||||
@ApiModelProperty(value = "贸易类型")
|
||||
private String tradType;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long exportLoadId;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
@DbQuery(field = "vin", symbol = SqlSymbol.IN)
|
||||
private List<String> vins;
|
||||
}
|
|
@ -0,0 +1,51 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出口装船查询")
|
||||
public class ExportLoadQuery extends BaseQuery {
|
||||
@ApiModelProperty(value = "受理号")
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(value = "船名")
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
private String voyageId;
|
||||
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
|
||||
@ApiModelProperty(value = "贸易类型")
|
||||
private String tradType;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@ApiModelProperty(value = "提单号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String billNo;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long exportLoadId;
|
||||
|
||||
@ApiModelProperty(hidden = true)
|
||||
@DbQuery(field = "vin", symbol = SqlSymbol.IN)
|
||||
private List<String> vins;
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.ActiveEnum;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "特保区查询")
|
||||
public class FreeTradeQuery extends BaseQuery {
|
||||
@ApiModelProperty(value = "批次号")
|
||||
private String batchNo;
|
||||
|
||||
@ApiModelProperty(value = "企业编码")
|
||||
private String cargoCode;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "开始时间")
|
||||
@DbQuery(field = "createDate", symbol = SqlSymbol.GT)
|
||||
private Date beginCreateDate;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "结束时间")
|
||||
@DbQuery(field = "createDate", symbol = SqlSymbol.LTE)
|
||||
private Date endCreateDate;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
@ApiModelProperty(value = "车架号")
|
||||
private String vin;
|
||||
|
||||
@ApiModelProperty(value = "港区ID")
|
||||
private String portAreaId;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(value = "是否激活")
|
||||
private ActiveEnum isActivate;
|
||||
|
||||
// 明细表查询时会用到
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long departureId;
|
||||
}
|
|
@ -0,0 +1,45 @@
|
|||
package com.haitonggauto.rtosc.query;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.repository.enums.AuditEnum;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "进口卸船查询")
|
||||
public class ImportUnloadQuery extends BaseQuery {
|
||||
|
||||
@ApiModelProperty(value = "船名")
|
||||
private String shipName;
|
||||
|
||||
@ApiModelProperty(value = "航次ID")
|
||||
private String voyageId;
|
||||
|
||||
@ApiModelProperty(value = "航次")
|
||||
private String voyage;
|
||||
|
||||
@ApiModelProperty(value = "贸易类型")
|
||||
private String tradType;
|
||||
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private AuditEnum checkStatus;
|
||||
|
||||
@ApiModelProperty(value = "审核状态", hidden = true)
|
||||
@DbQuery(field = "checkStatus", symbol = SqlSymbol.IN)
|
||||
private List<AuditEnum> checkStatusList;
|
||||
|
||||
@ApiModelProperty(value = "提单号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String billNo;
|
||||
|
||||
@ApiModelProperty(value = "受理号")
|
||||
@DbQuery(symbol = SqlSymbol.LIKE)
|
||||
private String batchNo;
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.request;
|
||||
|
||||
import com.nuzar.cloud.web.model.PageRequest;
|
||||
import lombok.Data;
|
||||
import lombok.ToString;
|
||||
|
||||
@Data
|
||||
@ToString
|
||||
public class OrderPageRequest extends PageRequest {
|
||||
|
||||
private String userId;
|
||||
|
||||
private String status;
|
||||
|
||||
}
|
|
@ -0,0 +1,62 @@
|
|||
<?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">
|
||||
<parent>
|
||||
<groupId>com.haitonggauto.rtosc</groupId>
|
||||
<artifactId>nuzar-customer</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>nuzar-customer-common</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<properties>
|
||||
<maven.deploy.skip>false</maven.deploy.skip>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.nuzar</groupId>
|
||||
<artifactId>nuzar-core</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!--mapStruct依赖 高性能对象映射-->
|
||||
<!--mapstruct核心-->
|
||||
<dependency>
|
||||
<groupId>org.mapstruct</groupId>
|
||||
<artifactId>mapstruct</artifactId>
|
||||
<version>1.5.3.Final</version>
|
||||
</dependency>
|
||||
<!--mapstruct编译-->
|
||||
<dependency>
|
||||
<groupId>org.mapstruct</groupId>
|
||||
<artifactId>mapstruct-processor</artifactId>
|
||||
<version>1.5.3.Final</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-annotations</artifactId>
|
||||
<version>1.5.22</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.google.guava</groupId>
|
||||
<artifactId>guava</artifactId>
|
||||
<version>${guava.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.commons</groupId>
|
||||
<artifactId>commons-collections4</artifactId>
|
||||
<version>${commons-collections.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.alibaba.fastjson2</groupId>
|
||||
<artifactId>fastjson2</artifactId>
|
||||
<version>${fastjson2.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.alicp.jetcache</groupId>
|
||||
<artifactId>jetcache-starter-redis</artifactId>
|
||||
<version>${jetcache.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
|
@ -0,0 +1,105 @@
|
|||
package com.haitonggauto.rtosc.common.aop;
|
||||
|
||||
import org.aspectj.lang.JoinPoint;
|
||||
import org.aspectj.lang.ProceedingJoinPoint;
|
||||
import org.aspectj.lang.annotation.*;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.web.context.request.RequestAttributes;
|
||||
import org.springframework.web.context.request.RequestContextHolder;
|
||||
import org.springframework.web.context.request.ServletRequestAttributes;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import java.util.Arrays;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Description:
|
||||
* </p>
|
||||
*
|
||||
* @author songzixian
|
||||
* @version v1.0.0
|
||||
* @create 2021-06-07 0:05
|
||||
*/
|
||||
//@Aspect
|
||||
//@ConditionalOnClass(HttpServletRequest.class)
|
||||
//@Component
|
||||
//@Order(100)
|
||||
//@Profile({"dev", "test"}) 加这个注解代表只会在开发环境生效,配置需要改完开发环境
|
||||
public class BaseHandlerLogAspect {
|
||||
private static final Logger logger = LoggerFactory.getLogger(BaseHandlerLogAspect.class);
|
||||
private ThreadLocal<Map<String, Object>> threadLocal = new ThreadLocal<Map<String, Object>>();
|
||||
/**
|
||||
* 横切点
|
||||
*/
|
||||
@Pointcut("(target(com.haitonggauto.rtosc.common.handler.BaseHandler))")
|
||||
public void webLog() {
|
||||
}
|
||||
/**
|
||||
* 接收请求,并记录数据
|
||||
* @param joinPoint
|
||||
*/
|
||||
@Before(value = "webLog()")
|
||||
public void doBefore(JoinPoint joinPoint) {
|
||||
// 接收到请求
|
||||
RequestAttributes ra = RequestContextHolder.getRequestAttributes();
|
||||
ServletRequestAttributes sra = (ServletRequestAttributes) ra;
|
||||
HttpServletRequest request = sra.getRequest();
|
||||
// 记录请求内容,threadInfo存储所有内容
|
||||
Map<String, Object> threadInfo = new LinkedHashMap<>();
|
||||
threadInfo.put("ip", request.getRemoteAddr());
|
||||
// threadInfo.put("url", request.getRequestURL());
|
||||
threadInfo.put("uri", request.getRequestURI());
|
||||
// threadInfo.put("httpMethod", request.getMethod());
|
||||
threadInfo.put("classMethod",
|
||||
joinPoint.getSignature().getDeclaringTypeName() + "." + joinPoint.getSignature().getName());
|
||||
threadInfo.put("args", Arrays.toString(joinPoint.getArgs()));
|
||||
threadInfo.put("userAgent", request.getHeader("User-Agent"));
|
||||
threadLocal.set(threadInfo);
|
||||
}
|
||||
/**
|
||||
* 执行成功后处理
|
||||
* @param ret
|
||||
* @throws Throwable
|
||||
*/
|
||||
@AfterReturning(value = "webLog()", returning = "ret")
|
||||
public void doAfterReturning(JoinPoint joinPoint, Object ret) throws Throwable {
|
||||
Map<String, Object> threadInfo = threadLocal.get();
|
||||
threadInfo.put("result", ret);
|
||||
// if (controllerWebLog.intoDb()) {
|
||||
// //插入数据库操作
|
||||
// //insertResult(threadInfo);
|
||||
// }
|
||||
// 处理完请求,返回内容
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取执行时间
|
||||
* @param proceedingJoinPoint
|
||||
* @return
|
||||
* @throws Throwable
|
||||
*/
|
||||
@Around(value = "webLog()")
|
||||
public Object doAround(ProceedingJoinPoint proceedingJoinPoint) throws Throwable {
|
||||
long startTime = System.currentTimeMillis();
|
||||
Object ob = proceedingJoinPoint.proceed();
|
||||
Map<String, Object> threadInfo = threadLocal.get();
|
||||
Long takeTime = System.currentTimeMillis() - startTime;
|
||||
threadInfo.put("takeTime", takeTime);
|
||||
threadLocal.set(threadInfo);
|
||||
logger.info("{}", threadInfo);
|
||||
return ob;
|
||||
}
|
||||
/**
|
||||
* 异常处理
|
||||
* @param throwable
|
||||
*/
|
||||
@AfterThrowing(value = "webLog()", throwing = "throwable")
|
||||
public void doAfterThrowing(Throwable throwable) {
|
||||
Map<String, Object> threadInfo = threadLocal.get();
|
||||
// 异常信息
|
||||
logger.error("{}接口调用异常,异常信息{}", threadInfo, throwable);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,92 @@
|
|||
package com.haitonggauto.rtosc.common.aop;
|
||||
|
||||
import org.aspectj.lang.JoinPoint;
|
||||
import org.aspectj.lang.ProceedingJoinPoint;
|
||||
import org.aspectj.lang.annotation.*;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Description:
|
||||
* </p>
|
||||
*
|
||||
* @author songzixian
|
||||
* @version v1.0.0
|
||||
* @create 2021-06-07 0:05
|
||||
*/
|
||||
//@Aspect
|
||||
//@Component
|
||||
//@Order(100)
|
||||
//@Profile({"dev", "test"}) 加这个注解代表只会在开发环境生效,配置需要改完开发环境
|
||||
public class BaseServiceLogAspect {
|
||||
private static final Logger logger = LoggerFactory.getLogger(BaseServiceLogAspect.class);
|
||||
private ThreadLocal<Map<String, Object>> threadLocal = new ThreadLocal<Map<String, Object>>();
|
||||
/**
|
||||
* 横切点
|
||||
*/
|
||||
@Pointcut("(target(com.haitonggauto.rtosc.common.service.BaseDubboService))")
|
||||
public void serviceLog() {
|
||||
}
|
||||
/**
|
||||
* 接收请求,并记录数据
|
||||
* @param joinPoint
|
||||
*/
|
||||
@Before(value = "serviceLog()")
|
||||
public void doBefore(JoinPoint joinPoint) {
|
||||
// 接收到请求
|
||||
// 记录请求内容,threadInfo存储所有内容
|
||||
Map<String, Object> threadInfo = new LinkedHashMap<>();
|
||||
threadInfo.put("classMethod",
|
||||
joinPoint.getSignature().getDeclaringTypeName() + "." + joinPoint.getSignature().getName());
|
||||
threadInfo.put("args", Arrays.toString(joinPoint.getArgs()));
|
||||
threadLocal.set(threadInfo);
|
||||
}
|
||||
/**
|
||||
* 执行成功后处理
|
||||
* @param ret
|
||||
* @throws Throwable
|
||||
*/
|
||||
@AfterReturning(value = "serviceLog()", returning = "ret")
|
||||
public void doAfterReturning(JoinPoint joinPoint, Object ret) throws Throwable {
|
||||
Map<String, Object> threadInfo = threadLocal.get();
|
||||
threadInfo.put("result", ret);
|
||||
// if (controllerWebLog.intoDb()) {
|
||||
// //插入数据库操作
|
||||
// //insertResult(threadInfo);
|
||||
// }
|
||||
// 处理完请求,返回内容
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取执行时间
|
||||
* @param proceedingJoinPoint
|
||||
* @return
|
||||
* @throws Throwable
|
||||
*/
|
||||
@Around(value = "serviceLog()")
|
||||
public Object doAround(ProceedingJoinPoint proceedingJoinPoint) throws Throwable {
|
||||
long startTime = System.currentTimeMillis();
|
||||
Object ob = proceedingJoinPoint.proceed();
|
||||
Map<String, Object> threadInfo = threadLocal.get();
|
||||
Long takeTime = System.currentTimeMillis() - startTime;
|
||||
threadInfo.put("takeTime", takeTime);
|
||||
threadLocal.set(threadInfo);
|
||||
logger.info("{}", threadInfo);
|
||||
return ob;
|
||||
}
|
||||
/**
|
||||
* 异常处理
|
||||
* @param throwable
|
||||
*/
|
||||
@AfterThrowing(value = "serviceLog()", throwing = "throwable")
|
||||
public void doAfterThrowing(Throwable throwable) {
|
||||
Map<String, Object> threadInfo = threadLocal.get();
|
||||
// 异常信息
|
||||
logger.error("{}接口调用异常,异常信息{}", threadInfo, throwable);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package com.haitonggauto.rtosc.common.constants;
|
||||
|
||||
public interface Constant {
|
||||
String TOKEN = "X-Token";
|
||||
String ADMIN_APP_ID = "admin_app";
|
||||
String WX_APP_ID = "wx_app";
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
package com.haitonggauto.rtosc.common.context;
|
||||
|
||||
import com.haitonggauto.rtosc.common.dto.LoginUser;
|
||||
|
||||
public class UserContext {
|
||||
private static ThreadLocal<LoginUser> userHolder = new ThreadLocal<LoginUser>();
|
||||
|
||||
public static void setUser(LoginUser loginUser) {
|
||||
userHolder.set(loginUser);
|
||||
}
|
||||
|
||||
public static LoginUser getUser() {
|
||||
return userHolder.get();
|
||||
}
|
||||
|
||||
public static void clear() {
|
||||
userHolder.remove();
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
package com.haitonggauto.rtosc.common.db.anno;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Target({ElementType.FIELD, ElementType.METHOD})
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
public @interface DbColumn {
|
||||
String column() default ""; //数据库字段
|
||||
String desc() default "";
|
||||
}
|
|
@ -0,0 +1,19 @@
|
|||
package com.haitonggauto.rtosc.common.db.anno;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
/**
|
||||
* 当symbol为EXISTS或NOT_EXISTS时column对应的是子句
|
||||
*/
|
||||
@Target({ElementType.FIELD, ElementType.METHOD})
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
public @interface DbQuery {
|
||||
String alias() default "";
|
||||
String field() default ""; //对应类的字段名
|
||||
SqlSymbol symbol() default SqlSymbol.EQ;//比较符号 其它可选项有>=, <=, >,<, like
|
||||
}
|
|
@ -0,0 +1,19 @@
|
|||
package com.haitonggauto.rtosc.common.db.anno;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Target({ElementType.TYPE})
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
public @interface DbTable {
|
||||
Class<?> service(); //服务提供接口
|
||||
String desc(); // 描述
|
||||
boolean dict() default false; //是不是字典,如果是字典,数据是需要进行缓存的
|
||||
String idField() default "id"; // 主键字段
|
||||
String textField() default "name"; // 显示字段
|
||||
String refField() default ""; // 外键字段
|
||||
String filterField() default ""; // 用于过滤的字段
|
||||
String[] extraField() default {}; // 额外字段
|
||||
}
|
|
@ -0,0 +1,71 @@
|
|||
package com.haitonggauto.rtosc.common.db.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.nuzar.cloud.annotation.echo.Echo;
|
||||
import com.nuzar.cloud.mapper.base.EchoEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
//@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||
public class BaseEntity implements EchoEntity, Serializable {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
//创建人
|
||||
@Echo(dictDomain = "user", ref = {"createByName"})
|
||||
@TableField(value = "create_by", fill = FieldFill.INSERT)
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String createBy;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String createByName;
|
||||
|
||||
//创建时间
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@TableField(value = "create_date", fill = FieldFill.INSERT)
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private Date createDate;
|
||||
|
||||
//修改人
|
||||
@Echo(dictDomain = "user", ref = {"updateByName"})
|
||||
@TableField(value = "update_by", fill = FieldFill.INSERT_UPDATE)
|
||||
@ApiModelProperty(value = "修改人")
|
||||
private String updateBy;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "修改人名称")
|
||||
private String updateByName;
|
||||
|
||||
//创建时间
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@TableField(value = "update_date", fill = FieldFill.INSERT_UPDATE)
|
||||
@ApiModelProperty(value = "修改时间")
|
||||
private Date updateDate;
|
||||
|
||||
@TableField(value = "termcd")
|
||||
@ApiModelProperty(value = "权限港区")
|
||||
private String termcd;
|
||||
|
||||
// 逻辑删除
|
||||
@TableLogic
|
||||
@TableField(value = "is_del")
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Integer isDel;
|
||||
|
||||
//数据的版本
|
||||
@Version
|
||||
@TableField(fill = FieldFill.INSERT)
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Integer version;
|
||||
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
package com.haitonggauto.rtosc.common.db.enums;
|
||||
|
||||
|
||||
import com.haitonggauto.rtosc.common.enums.BaseEnum;
|
||||
|
||||
public enum SqlSymbol implements BaseEnum {
|
||||
|
||||
EQ("="),
|
||||
GT(">"),
|
||||
GTE(">="),
|
||||
LTE("<="),
|
||||
LT("<"),
|
||||
NEQ("<>"),
|
||||
IN("IN"),
|
||||
LIKE("LIKE"),
|
||||
LLIKE("LLIKE"),
|
||||
RLIKE("RLIKE"),
|
||||
EXISTS("EXISTS"),
|
||||
NOT_EXISTS("NOT EXISTS"),
|
||||
EXPRESSION("EXPRESSION")
|
||||
;
|
||||
|
||||
/** 描述 */
|
||||
private String text;
|
||||
|
||||
private SqlSymbol(String text) {
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String text() {
|
||||
return this.text;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer id() {
|
||||
return null;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,229 @@
|
|||
package com.haitonggauto.rtosc.common.db.metadata;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.entity.BaseEntity;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 类的原数据
|
||||
*/
|
||||
public class ClassMetadata<T extends BaseEntity> {
|
||||
// 实体类 com.wsnet.mybatis.entity.SysUser
|
||||
private Class<T> clazz;
|
||||
|
||||
// 表名
|
||||
private String dbName;
|
||||
|
||||
// 表描述
|
||||
private String dbDesc;
|
||||
|
||||
// 服务提供方
|
||||
private Class<?> service;
|
||||
|
||||
// 是否是字典
|
||||
private boolean dict;
|
||||
|
||||
// 字典的元数据, dict=true时,才不为空
|
||||
private DictMetadata dictMetadata;
|
||||
|
||||
// 属性列表
|
||||
private List<FieldMetadata> fields;
|
||||
|
||||
public Class<T> getClazz() {
|
||||
return clazz;
|
||||
}
|
||||
|
||||
public void setClazz(Class<T> clazz) {
|
||||
this.clazz = clazz;
|
||||
}
|
||||
|
||||
public String getDbName() {
|
||||
return dbName;
|
||||
}
|
||||
|
||||
public void setDbName(String dbName) {
|
||||
this.dbName = dbName;
|
||||
}
|
||||
|
||||
public String getDbDesc() {
|
||||
return dbDesc;
|
||||
}
|
||||
|
||||
public void setDbDesc(String dbDesc) {
|
||||
this.dbDesc = dbDesc;
|
||||
}
|
||||
|
||||
public Class<?> getService() {
|
||||
return service;
|
||||
}
|
||||
|
||||
public void setService(Class<?> service) {
|
||||
this.service = service;
|
||||
}
|
||||
|
||||
public boolean isDict() {
|
||||
return dict;
|
||||
}
|
||||
|
||||
public void setDict(boolean dict) {
|
||||
this.dict = dict;
|
||||
}
|
||||
|
||||
public DictMetadata getDictMetadata() {
|
||||
return dictMetadata;
|
||||
}
|
||||
|
||||
public void setDictMetadata(DictMetadata dictMetadata) {
|
||||
this.dictMetadata = dictMetadata;
|
||||
}
|
||||
|
||||
public List<FieldMetadata> getFields() {
|
||||
return fields;
|
||||
}
|
||||
|
||||
public void setFields(List<FieldMetadata> fields) {
|
||||
this.fields = fields;
|
||||
}
|
||||
|
||||
public static class FieldMetadata {
|
||||
// 数据库中是否存在此字段
|
||||
private Boolean exist;
|
||||
|
||||
// 属性名称
|
||||
private String field;
|
||||
|
||||
// 数据库字段名称, 这里的column 如果是一对一时指的是本类的属性字段, 如果是集合,则指的是refClazz的字段
|
||||
private String column;
|
||||
|
||||
// 字段的描述
|
||||
private String desc;
|
||||
|
||||
// 字段基本数据类型 List, BaseEntity, Integer.....
|
||||
private Class<?> clazz;
|
||||
|
||||
// 引用数据类型 List<SysUser>, SysUser, 这里指的就是SysUser
|
||||
private Class<? extends BaseEntity> refClazz;
|
||||
|
||||
public FieldMetadata() {
|
||||
|
||||
}
|
||||
|
||||
public FieldMetadata(Boolean exist, String field, String column, String desc, Class<?> clazz, Class<? extends BaseEntity> refClazz) {
|
||||
this.exist = exist;
|
||||
this.field = field;
|
||||
this.column = column;
|
||||
this.desc = desc;
|
||||
this.clazz = clazz;
|
||||
this.refClazz = refClazz;
|
||||
}
|
||||
|
||||
public Boolean getExist() {
|
||||
return exist;
|
||||
}
|
||||
|
||||
public void setExist(Boolean exist) {
|
||||
this.exist = exist;
|
||||
}
|
||||
|
||||
public String getField() {
|
||||
return field;
|
||||
}
|
||||
|
||||
public void setField(String field) {
|
||||
this.field = field;
|
||||
}
|
||||
|
||||
public String getColumn() {
|
||||
return column;
|
||||
}
|
||||
|
||||
public void setColumn(String column) {
|
||||
this.column = column;
|
||||
}
|
||||
|
||||
public Class<?> getClazz() {
|
||||
return clazz;
|
||||
}
|
||||
|
||||
public void setClazz(Class<?> clazz) {
|
||||
this.clazz = clazz;
|
||||
}
|
||||
|
||||
public Class<? extends BaseEntity> getRefClazz() {
|
||||
return refClazz;
|
||||
}
|
||||
|
||||
public void setRefClazz(Class<? extends BaseEntity> refClazz) {
|
||||
this.refClazz = refClazz;
|
||||
}
|
||||
|
||||
public String getDesc() {
|
||||
return desc;
|
||||
}
|
||||
|
||||
public void setDesc(String desc) {
|
||||
this.desc = desc;
|
||||
}
|
||||
}
|
||||
|
||||
public static class DictMetadata {
|
||||
private String idField; // 主键字段
|
||||
|
||||
private String textField; // 显示字段, 默认为可过滤字段
|
||||
|
||||
private String refField; // 外键字段
|
||||
|
||||
private String filterField; // 过滤的字段, 和textField为or关系
|
||||
|
||||
private List<String> extraField; // 额外字段
|
||||
|
||||
public DictMetadata() {
|
||||
|
||||
}
|
||||
|
||||
public DictMetadata(String idField, String textField) {
|
||||
this.idField = idField;
|
||||
this.textField = textField;
|
||||
}
|
||||
|
||||
public String getIdField() {
|
||||
return idField;
|
||||
}
|
||||
|
||||
public void setIdField(String idField) {
|
||||
this.idField = idField;
|
||||
}
|
||||
|
||||
public String getTextField() {
|
||||
return textField;
|
||||
}
|
||||
|
||||
public void setTextField(String textField) {
|
||||
this.textField = textField;
|
||||
}
|
||||
|
||||
public String getRefField() {
|
||||
return refField;
|
||||
}
|
||||
|
||||
public void setRefField(String refField) {
|
||||
this.refField = refField;
|
||||
}
|
||||
|
||||
public String getFilterField() {
|
||||
return filterField;
|
||||
}
|
||||
|
||||
public void setFilterField(String filterField) {
|
||||
this.filterField = filterField;
|
||||
}
|
||||
|
||||
public List<String> getExtraField() {
|
||||
return extraField;
|
||||
}
|
||||
|
||||
public void setExtraField(List<String> extraField) {
|
||||
this.extraField = extraField;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,137 @@
|
|||
package com.haitonggauto.rtosc.common.db.query;
|
||||
|
||||
import com.haitonggauto.rtosc.common.db.anno.DbQuery;
|
||||
import com.haitonggauto.rtosc.common.db.enums.SqlSymbol;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
public class BaseQuery extends Perm {
|
||||
|
||||
// 单个查询
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
|
||||
// 批量查询
|
||||
@ApiModelProperty(hidden = true)
|
||||
@DbQuery(field = "id", symbol = SqlSymbol.IN)
|
||||
private List<Long> ids;
|
||||
|
||||
// 当前页数
|
||||
@ApiModelProperty(value = "当前页数")
|
||||
private int page = 1;
|
||||
|
||||
// 每页记录数
|
||||
@ApiModelProperty(value = "每页记录数")
|
||||
private int rows = 2000;
|
||||
|
||||
private String createBy;
|
||||
|
||||
// 排序字段
|
||||
private List<SortField> sorts = Arrays.asList(new SortField("updateDate", "desc"));
|
||||
|
||||
public BaseQuery() {}
|
||||
|
||||
public BaseQuery(String u$id, Long r$id) {
|
||||
super(u$id, r$id);
|
||||
}
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public List<Long> getIds() {
|
||||
return ids;
|
||||
}
|
||||
|
||||
public void setIds(List<Long> ids) {
|
||||
this.ids = ids;
|
||||
}
|
||||
|
||||
public int getPage() {
|
||||
return page;
|
||||
}
|
||||
|
||||
public void setPage(int page) {
|
||||
this.page = page;
|
||||
}
|
||||
|
||||
public int getRows() {
|
||||
return rows;
|
||||
}
|
||||
|
||||
public void setRows(int rows) {
|
||||
this.rows = rows;
|
||||
}
|
||||
|
||||
public List<SortField> getSorts() {
|
||||
return sorts;
|
||||
}
|
||||
|
||||
public void setSorts(List<SortField> sorts) {
|
||||
this.sorts = sorts;
|
||||
}
|
||||
|
||||
public String getCreateBy() {
|
||||
return createBy;
|
||||
}
|
||||
|
||||
public void setCreateBy(String createBy) {
|
||||
this.createBy = createBy;
|
||||
}
|
||||
|
||||
// 排序字段内部类
|
||||
public static class SortField {
|
||||
// 表的别名
|
||||
private String alias;
|
||||
// 属性名,而非数据库字段名
|
||||
private String field;
|
||||
// 排序方式
|
||||
private String sort;
|
||||
|
||||
public SortField() {
|
||||
|
||||
}
|
||||
|
||||
public SortField(String field) {
|
||||
this.field = field;
|
||||
this.sort = "desc";
|
||||
}
|
||||
|
||||
public SortField(String field, String sort) {
|
||||
this.field = field;
|
||||
this.sort = sort;
|
||||
}
|
||||
|
||||
public String getAlias() {
|
||||
return alias;
|
||||
}
|
||||
|
||||
public void setAlias(String alias) {
|
||||
this.alias = alias;
|
||||
}
|
||||
|
||||
public String getField() {
|
||||
return field;
|
||||
}
|
||||
|
||||
public void setField(String field) {
|
||||
this.field = field;
|
||||
}
|
||||
|
||||
public String getSort() {
|
||||
return sort;
|
||||
}
|
||||
|
||||
public void setSort(String sort) {
|
||||
this.sort = sort;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,73 @@
|
|||
package com.haitonggauto.rtosc.common.db.query;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
public abstract class Perm implements Serializable {
|
||||
// 用户ID
|
||||
@ApiModelProperty(hidden = true)
|
||||
private String u$id;
|
||||
// 角色ID
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Long r$id;
|
||||
// 字段组装路由
|
||||
@ApiModelProperty(hidden = true)
|
||||
private String fields = "*";
|
||||
// 排除的字段
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Set<String> excludeFields;
|
||||
// 授权的字典值
|
||||
@ApiModelProperty(hidden = true)
|
||||
private Map<String, Set<Long>> includeIds;
|
||||
|
||||
public Perm() {
|
||||
}
|
||||
|
||||
public Perm(String u$id, Long r$id) {
|
||||
this.u$id = u$id;
|
||||
this.r$id = r$id;
|
||||
}
|
||||
|
||||
public String getU$id() {
|
||||
return u$id;
|
||||
}
|
||||
|
||||
public void setU$id(String u$id) {
|
||||
this.u$id = u$id;
|
||||
}
|
||||
|
||||
public Long getR$id() {
|
||||
return r$id;
|
||||
}
|
||||
|
||||
public void setR$id(Long r$id) {
|
||||
this.r$id = r$id;
|
||||
}
|
||||
|
||||
public String getFields() {
|
||||
return fields;
|
||||
}
|
||||
|
||||
public void setFields(String fields) {
|
||||
this.fields = fields;
|
||||
}
|
||||
|
||||
public Set<String> getExcludeFields() {
|
||||
return excludeFields;
|
||||
}
|
||||
|
||||
public void setExcludeFields(Set<String> excludeFields) {
|
||||
this.excludeFields = excludeFields;
|
||||
}
|
||||
|
||||
public Map<String, Set<Long>> getIncludeIds() {
|
||||
return includeIds;
|
||||
}
|
||||
|
||||
public void setIncludeIds(Map<String, Set<Long>> includeIds) {
|
||||
this.includeIds = includeIds;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,70 @@
|
|||
package com.haitonggauto.rtosc.common.dto;
|
||||
|
||||
import com.nuzar.cloud.annotation.echo.Echo;
|
||||
import com.nuzar.cloud.mapper.base.EchoEntity;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class DictDTO implements EchoEntity, Serializable {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = -1347613740865124637L;
|
||||
@Echo(dictDomain = "PUB_BRAND_EN", ref = {"extra1"})
|
||||
private String id;
|
||||
private String text;
|
||||
private String extra1;
|
||||
private String extra2;
|
||||
private String extra3;
|
||||
|
||||
public DictDTO() {
|
||||
|
||||
}
|
||||
|
||||
public DictDTO(String id, String text) {
|
||||
this.id = id;
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getText() {
|
||||
return text;
|
||||
}
|
||||
|
||||
public void setText(String text) {
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
public String getExtra1() {
|
||||
return extra1;
|
||||
}
|
||||
|
||||
public void setExtra1(String extra1) {
|
||||
this.extra1 = extra1;
|
||||
}
|
||||
|
||||
public String getExtra2() {
|
||||
return extra2;
|
||||
}
|
||||
|
||||
public void setExtra2(String extra2) {
|
||||
this.extra2 = extra2;
|
||||
}
|
||||
|
||||
public String getExtra3() {
|
||||
return extra3;
|
||||
}
|
||||
|
||||
public void setExtra3(String extra3) {
|
||||
this.extra3 = extra3;
|
||||
}
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,60 @@
|
|||
package com.haitonggauto.rtosc.common.dto;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Set;
|
||||
|
||||
public class LoginUser implements Serializable {
|
||||
|
||||
// 是否是系统管理员
|
||||
private boolean admin;
|
||||
|
||||
// 用户ID
|
||||
private String userId;
|
||||
|
||||
// 角色ID
|
||||
private Long roleId;
|
||||
|
||||
// 可操作权限列表
|
||||
private Set<String> permList;
|
||||
|
||||
|
||||
public LoginUser() {
|
||||
}
|
||||
|
||||
public LoginUser(String userId, Long roleId) {
|
||||
this.userId = userId;
|
||||
this.roleId = roleId;
|
||||
}
|
||||
|
||||
public String getUserId() {
|
||||
return userId;
|
||||
}
|
||||
|
||||
public boolean isAdmin() {
|
||||
return admin;
|
||||
}
|
||||
|
||||
public void setAdmin(boolean admin) {
|
||||
this.admin = admin;
|
||||
}
|
||||
|
||||
public void setUserId(String userId) {
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getRoleId() {
|
||||
return roleId;
|
||||
}
|
||||
|
||||
public void setRoleId(Long roleId) {
|
||||
this.roleId = roleId;
|
||||
}
|
||||
|
||||
public Set<String> getPermList() {
|
||||
return permList;
|
||||
}
|
||||
|
||||
public void setPermList(Set<String> permList) {
|
||||
this.permList = permList;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,62 @@
|
|||
package com.haitonggauto.rtosc.common.dto;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class PermNode implements Serializable {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private String code;
|
||||
private String name;
|
||||
private String remark;
|
||||
|
||||
public PermNode() {
|
||||
}
|
||||
|
||||
public PermNode(String code, String name) {
|
||||
this.code = code;
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public PermNode(String code, String name, String remark) {
|
||||
this.code = code;
|
||||
this.name = name;
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
private List<PermNode> children;
|
||||
|
||||
public String getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(String code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public List<PermNode> getChildren() {
|
||||
return children;
|
||||
}
|
||||
|
||||
public void setChildren(List<PermNode> children) {
|
||||
this.children = children;
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
package com.haitonggauto.rtosc.common.dto;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class Result<T> implements Serializable {
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = -8179392268406183074L;
|
||||
|
||||
int code = 0;
|
||||
|
||||
T data;
|
||||
|
||||
private String msg;//提示信息
|
||||
|
||||
public int getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(int code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public T getData() {
|
||||
return data;
|
||||
}
|
||||
|
||||
public void setData(T data) {
|
||||
this.data = data;
|
||||
}
|
||||
|
||||
public String getMsg() {
|
||||
return msg;
|
||||
}
|
||||
|
||||
public void setMsg(String msg) {
|
||||
this.msg = msg;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package com.haitonggauto.rtosc.common.enums;
|
||||
|
||||
public interface BaseEnum {
|
||||
String text();
|
||||
String name();
|
||||
Integer id();
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
package com.haitonggauto.rtosc.common.enums;
|
||||
|
||||
public enum ErrorType implements BaseEnum {
|
||||
PROGRAM_ERROR(500, "程序内部异常"),
|
||||
PARAMS_ERROR(501, "参数错误"),
|
||||
NO_USERNAME(14001, "用户名为空"),
|
||||
NO_PASSWORD(14002, "密码为空"),
|
||||
ERROR_PASS(14003, "密码错误"),
|
||||
NO_USER(14004, "用户不存在"),
|
||||
NO_ROLE(14005, "用户角色不存在"),
|
||||
ROLE_NOT_USED(14010, "角色被禁用"),
|
||||
NO_LOGIN(14006, "用户未登录"),
|
||||
NOT_AVAILABLE_TOKEN(14007, "无效TOKEN"),
|
||||
NO_AUTH_PERM(14008, "无操作权限"),
|
||||
USER_NOT_USED(14009, "用户已禁用"),
|
||||
USER_NOT_PIPEI(14009, "所在公司与分配的调度组不匹配"),
|
||||
USER_NOT_BIND(14010, "账号没有绑定客户"),
|
||||
PAY_ERR(2000, "支付失败"),
|
||||
URL_ERROR(404, "地址不存在");;
|
||||
|
||||
private int id;
|
||||
private String text;
|
||||
|
||||
private ErrorType(int id, String text) {
|
||||
this.id = id;
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String text() {
|
||||
return text;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer id() {
|
||||
return id;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class AccessFrequencyException extends RuntimeException {
|
||||
|
||||
public AccessFrequencyException() {}
|
||||
|
||||
public AccessFrequencyException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class FieldNotExistsException extends RuntimeException {
|
||||
|
||||
public FieldNotExistsException() {}
|
||||
|
||||
public FieldNotExistsException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class NoAnnotationException extends RuntimeException {
|
||||
|
||||
public NoAnnotationException() {}
|
||||
|
||||
public NoAnnotationException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class NoLoginException extends RuntimeException {
|
||||
|
||||
public NoLoginException() {}
|
||||
|
||||
public NoLoginException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class NoPermException extends RuntimeException {
|
||||
|
||||
public NoPermException() {}
|
||||
|
||||
public NoPermException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class NoUserExistsException extends RuntimeException {
|
||||
|
||||
public NoUserExistsException() {}
|
||||
|
||||
public NoUserExistsException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class NotBaseEntityTypeException extends RuntimeException {
|
||||
|
||||
public NotBaseEntityTypeException() {}
|
||||
|
||||
public NotBaseEntityTypeException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class NullObjectException extends RuntimeException {
|
||||
|
||||
public NullObjectException() {}
|
||||
|
||||
public NullObjectException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.haitonggauto.rtosc.common.exception;
|
||||
|
||||
|
||||
/**
|
||||
* 这里必须继承自RuntimeException, 不然会有其它问题发生java.lang.reflect.UndeclaredThrowableException: null
|
||||
*/
|
||||
public class PasswordWrongException extends RuntimeException {
|
||||
|
||||
public PasswordWrongException() {}
|
||||
|
||||
public PasswordWrongException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
package com.haitonggauto.rtosc.common.handler;
|
||||
|
||||
public interface BaseHandler {
|
||||
|
||||
}
|
|
@ -0,0 +1,76 @@
|
|||
package com.haitonggauto.rtosc.common.handler;
|
||||
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.ReflectionKit;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.haitonggauto.rtosc.common.db.entity.BaseEntity;
|
||||
import com.haitonggauto.rtosc.common.db.query.BaseQuery;
|
||||
import com.haitonggauto.rtosc.common.dto.Result;
|
||||
import com.haitonggauto.rtosc.common.enums.ErrorType;
|
||||
import com.haitonggauto.rtosc.common.handler.anno.HandlerMethod;
|
||||
import com.haitonggauto.rtosc.common.utils.ResultUtil;
|
||||
import com.haitonggauto.rtosc.common.utils.WrapperKit;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 通用handler的封装
|
||||
* @param <T>
|
||||
*/
|
||||
public abstract class BaseLocalHandler<M extends IService<T>, T extends BaseEntity> implements BaseHandler {
|
||||
|
||||
@Autowired
|
||||
protected M service;
|
||||
|
||||
protected Class<T> entityClass = this.currentModelClass();
|
||||
|
||||
protected Class<T> currentModelClass() {
|
||||
return (Class<T>) ReflectionKit.getSuperClassGenericType(this.getClass(), BaseLocalHandler.class, 1);
|
||||
}
|
||||
|
||||
protected BaseQuery transformQuery(Map<String, Object> query) {
|
||||
JSONObject json = new JSONObject(query);
|
||||
return json.to(BaseQuery.class);
|
||||
}
|
||||
|
||||
@HandlerMethod(code="0100", name="列表")
|
||||
@PostMapping("/page")
|
||||
protected Result<IPage<T>> page(@RequestBody Map<String, Object> query) {
|
||||
BaseQuery baseQuery = transformQuery(query);
|
||||
Wrapper<T> queryWrapper = new WrapperKit(){}.changeBaseQueryToWrapper(entityClass, baseQuery);
|
||||
return ResultUtil.success(service.page(new Page<>(baseQuery.getPage(), baseQuery.getRows()), queryWrapper));
|
||||
}
|
||||
|
||||
@HandlerMethod(code="0200", name="获取")
|
||||
@PostMapping("/get")
|
||||
protected Result<T> get(@RequestParam Long id) {
|
||||
return ResultUtil.success(service.getById(id));
|
||||
}
|
||||
|
||||
@HandlerMethod(code="0300", name="保存")
|
||||
@PostMapping("/save")
|
||||
protected Result<String> save(@RequestBody T entity) {
|
||||
service.saveOrUpdate(entity);
|
||||
return ResultUtil.success("success");
|
||||
}
|
||||
|
||||
@HandlerMethod(code="0400", name="删除")
|
||||
@PostMapping("/delete")
|
||||
protected Result<String> delete(@RequestBody List<Long> ids) {
|
||||
if (CollectionUtils.isEmpty(ids)) {
|
||||
return ResultUtil.failure(ErrorType.PARAMS_ERROR.id(), "ID列表不能为空");
|
||||
}
|
||||
// service.removeBatchByIds(ids);
|
||||
return ResultUtil.success("success");
|
||||
}
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue