@@ -6,10 +6,7 @@ import cn.com.taiji.core.model.comm.protocol.ias.ass.PlateOccupyQueryRequest; | |||
import cn.com.taiji.core.model.comm.protocol.ias.ass.PlateOccupyQueryResponse; | |||
import cn.com.taiji.iaw.api.MyValidController; | |||
import cn.com.taiji.iaw.dto.ass.*; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateDetailRequestDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateDetailResponseDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateListRequestDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateListResponDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.*; | |||
import cn.com.taiji.iaw.manager.ass.ReleasePlateManager; | |||
import io.swagger.annotations.Api; | |||
import io.swagger.annotations.ApiOperation; | |||
@@ -50,13 +47,13 @@ public class ReleasePlateController extends MyValidController { | |||
return ApiResponse.of(responDTO); | |||
} | |||
//客服查询、列表 | |||
// @ApiOperation("客服查询列表") | |||
// @PostMapping("/relesePlateList") | |||
// public ApiResponse<ReleasePlateListResponDTO> relesePlateList(@Validated @RequestBody RelesePlateListkfRequestDTO req) throws ManagerException { | |||
// ReleasePlateListResponDTO responDTO = releasePlateManager.relesePlateList(req); | |||
// return ApiResponse.of(responDTO); | |||
// } | |||
// 客服查询、列表 | |||
@ApiOperation("客服查询列表") | |||
@PostMapping("/relesePlateList") | |||
public ApiResponse<ReleasePlateListResponDTO> relesePlateList(@Validated @RequestBody RelesePlateListkfRequestDTO req) throws ManagerException { | |||
ReleasePlateListResponDTO responDTO = releasePlateManager.relesePlateList(req); | |||
return ApiResponse.of(responDTO); | |||
} | |||
@ApiOperation("单一订单查询") | |||
@PostMapping("/view") |
@@ -0,0 +1,25 @@ | |||
package cn.com.taiji.iaw.dto.ass.releasePlate; | |||
import cn.com.taiji.core.dto.AbstractStaffBizRequestDTO; | |||
import cn.com.taiji.core.entity.dict.basic.PlateColorType; | |||
import cn.com.taiji.core.model.comm.protocol.constraint.EnumInteger; | |||
import cn.com.taiji.core.model.comm.protocol.constraint.VehiclePlate; | |||
import io.swagger.annotations.ApiModel; | |||
import io.swagger.annotations.ApiModelProperty; | |||
import lombok.Data; | |||
import javax.validation.constraints.NotBlank; | |||
import javax.validation.constraints.NotNull; | |||
@Data | |||
@ApiModel(description = "售后订单-解除车牌占用情况客服列表查询") | |||
public class RelesePlateListkfRequestDTO extends AbstractStaffBizRequestDTO { | |||
@ApiModelProperty(value = "车牌号", required = true) | |||
@NotBlank | |||
@VehiclePlate | |||
private String vehiclePlate; | |||
@ApiModelProperty(value = "车牌颜色", required = true) | |||
@NotNull | |||
@EnumInteger(enumClazz = PlateColorType.class) | |||
private Integer vehiclePlateColor; | |||
} |
@@ -5,10 +5,7 @@ import cn.com.taiji.common.manager.net.http.ServiceHandleException; | |||
import cn.com.taiji.core.model.comm.protocol.ias.ass.PlateOccupyQueryRequest; | |||
import cn.com.taiji.core.model.comm.protocol.ias.ass.PlateOccupyQueryResponse; | |||
import cn.com.taiji.iaw.dto.ass.RealsePlateRequestDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateDetailRequestDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateDetailResponseDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateListRequestDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.ReleasePlateListResponDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.*; | |||
/** | |||
* @Author:ChenChao | |||
@@ -24,4 +21,6 @@ public interface ReleasePlateManager { | |||
ReleasePlateListResponDTO list(ReleasePlateListRequestDTO req) throws ServiceHandleException; | |||
ReleasePlateDetailResponseDTO detail(ReleasePlateDetailRequestDTO req) throws ManagerException; | |||
ReleasePlateListResponDTO relesePlateList(RelesePlateListkfRequestDTO req); | |||
} |
@@ -19,6 +19,7 @@ import cn.com.taiji.iaw.dto.ass.AssOrderInfoResponseDTO; | |||
import cn.com.taiji.iaw.dto.ass.RealsePlateRequestDTO; | |||
import cn.com.taiji.iaw.dto.ass.releasePlate.*; | |||
import cn.com.taiji.iaw.manager.AbstractIawManager; | |||
import org.apache.kafka.common.protocol.types.Field; | |||
import org.springframework.beans.factory.annotation.Autowired; | |||
import org.springframework.stereotype.Service; | |||
import java.util.List; | |||
@@ -86,4 +87,19 @@ public class ReleasePlateManagerImpl extends AbstractIawManager implements Relea | |||
res.setAssOrderInfo(assOrderInfo); | |||
return res; | |||
} | |||
@Override | |||
public ReleasePlateListResponDTO relesePlateList(RelesePlateListkfRequestDTO req) { | |||
String vehicleId = req.getVehiclePlate() + "_" + req.getVehiclePlateColor(); | |||
List<AssOrderinfo> assOrderinfoList = assOrderinfoRepo.findRelasePlateByVehicleId(vehicleId); | |||
ReleasePlateListResponDTO responDTO = new ReleasePlateListResponDTO(); | |||
if (!isEmpty(assOrderinfoList)){ | |||
List<AssOrderInfoResponseDTO> dtoList = assOrderinfoList.stream().map(t -> { | |||
AssOrderInfoResponseDTO dtoModel = copyProperties(t, new AssOrderInfoResponseDTO()); | |||
return dtoModel; | |||
}).collect(Collectors.toList()); | |||
responDTO.setAssOrders(dtoList); | |||
} | |||
return responDTO; | |||
} | |||
} |