Commit e50fd0d4 by 杨林龙

车辆信息导入时 添加车架号和组织名联合校验

1 parent c0518829
......@@ -79,6 +79,10 @@ public class VehicleController {
@SysLog(module = MODULE, value = "查询该组织下没有绑定为试驾车辆的列表", action = OperateType.QUERY)
@GetMapping("/drivevehicle/listtestdrive")
public R listTestDriveVehicle(TestVehicleSearch testVehicleVo) {
String shopId = testVehicleVo.getShopId();
if (StringUtils.isNotEmpty(shopId)) {
testVehicleVo.setShopId(shopId.replaceAll("u", ""));
}
PageInfo<TestVehicleDTO> testDriveVehicleList = vehicleService.listTestDriveVehicle(testVehicleVo);
return R.ok().putPageData(testDriveVehicleList);
}
......@@ -312,7 +316,7 @@ public class VehicleController {
@ApiOperation(value = "导入车辆信息列表")
@PostMapping(value = "/vehicleinfo/import", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
public R importVehicleInfo(@RequestParam("file") MultipartFile file) throws IOException {
VehicleInfoImportListener listener = new VehicleInfoImportListener(vehicleService, deviceService,userApiService);
VehicleInfoImportListener listener = new VehicleInfoImportListener(vehicleService, deviceService, userApiService);
EasyExcel.read(file.getInputStream(), VehicleInfoImport.class, listener)
.head(VehicleInfoImport.class)
.ignoreEmptyRow(false)
......
......@@ -46,5 +46,5 @@ public class TestVehicleSearch extends Page {
/**
* 特约店id
*/
private Integer shopId;
private String shopId;
}
......@@ -419,7 +419,7 @@
<if test="buyDateEnd != null and buyDateEnd !=''">
and tv.buy_date &lt;= #{buyDateEnd}
</if>
<if test="shopId != null ">
<if test="shopId != null and shopId !=''">
and tu.id = #{shopId}
</if>
GROUP BY tv.vin
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!