Commit 3ce6e3ba authored by hanfeng's avatar hanfeng

修改车辆信息下载

parent 115a4023
......@@ -18,6 +18,7 @@ import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import lombok.extern.slf4j.Slf4j;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
......@@ -54,6 +55,17 @@ public class VehicleModelController extends CommonBaseController {
return objectRestResponse;
}
@ApiOperation("车型详情")
@GetMapping(value = "/detail")
@IgnoreUserToken
public ObjectRestResponse<VModelDetailVO> getDetails(@RequestParam("id") @ApiParam("车型名称") Integer id) {
ObjectRestResponse<VModelDetailVO> objectRestResponse = vehicleFeign.detailByParam(BeanUtil.beanToMap(new VehicleModel(){{
setId(id);
}}, false, true));
objectRestResponse.getData().setUccnCataList(initUccnCataCollect(objectRestResponse.getData().getConfig()));
return objectRestResponse;
}
/**
* 车型列表查
*
......
......@@ -87,14 +87,18 @@ public class VehicleInformationDownloadBiz extends BaseBiz<VehicleMapper, Vehicl
ArrayList<VehicleExcelVo> arrayList = Lists.newArrayList();
resultVehicleVoList.stream().forEach(result->{
try {
Integer belongTo = result.getBelongTo();
if (belongTo!=null&& belongTo==1) {
System.out.println(belongTo);
}
VehicleExcelVo build = VehicleExcelVo.builder()
.code(result.getCode())
.numberPlate(result.getNumberPlate())
.parkBranchCompanyName(result.getParkBranchCompanyId()==1?"欣新房车有限公司":result.getParkBranchCompanyName())
.parkBranchCompanyName(result.getParkBranchCompanyName())
.status(result.getStatus())
.useTypeName(result.getUseTypeName())
.vehicleType(result.getVehicleType())
.belongToName(result.getBelongToName())
.belongToName(result.getBelongTo()!=null&&result.getBelongTo()==1?"欣新房车有限公司":result.getBelongToName())
.build();
arrayList.add(build);
} catch (Exception e) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment