forked from integrated_whb/integrated_whb
BUG优化
parent
06395c0c05
commit
faabbc8b54
|
@ -35,7 +35,9 @@ public class AssignedManageController extends BaseController {
|
||||||
@Autowired
|
@Autowired
|
||||||
private FreightTrailerService freightTrailerService;
|
private FreightTrailerService freightTrailerService;
|
||||||
|
|
||||||
/**新增
|
/**
|
||||||
|
* 新增
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -82,7 +84,9 @@ public class AssignedManageController extends BaseController {
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**删除
|
/**
|
||||||
|
* 删除
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -126,7 +130,9 @@ public class AssignedManageController extends BaseController {
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**修改
|
/**
|
||||||
|
* 修改
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -157,7 +163,10 @@ public class AssignedManageController extends BaseController {
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
/**去修改页面获取数据
|
|
||||||
|
/**
|
||||||
|
* 去修改页面获取数据
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -230,26 +239,6 @@ public class AssignedManageController extends BaseController {
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*@RequestMapping(value = "/getassignedoperationvehiclelist")
|
|
||||||
@ResponseBody
|
|
||||||
public Object getAssignedOperationVehicleList() throws Exception {
|
|
||||||
Map<String, Object> map = new HashMap<String, Object>();
|
|
||||||
String errInfo = "success";
|
|
||||||
String corpId = Jurisdiction.getCORPINFO_ID();
|
|
||||||
List<PageData> operationList = operatingVehiclesService.operationVehicleList(corpId); //列出Question列表
|
|
||||||
List<PageData> assignedList = assignedManageService.assignedList(corpId);
|
|
||||||
for (int i = 0; i < assignedList.size(); i++) {
|
|
||||||
for (int j = 0; j < operationList.size(); j++) {
|
|
||||||
if(assignedList.get(i).get("RAW_PLATE_NUMBER").equals(operationList.get(j).get("PLATE_NUMBER"))) {
|
|
||||||
operationList.remove(j);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
map.put("varList", operationList);
|
|
||||||
map.put("result", errInfo);
|
|
||||||
return map;
|
|
||||||
}*/
|
|
||||||
|
|
||||||
@RequestMapping(value = "/getAssignedVehicleList")
|
@RequestMapping(value = "/getAssignedVehicleList")
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public Object getAssignedVehicleList() throws Exception {
|
public Object getAssignedVehicleList() throws Exception {
|
||||||
|
@ -260,16 +249,13 @@ public class AssignedManageController extends BaseController {
|
||||||
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
||||||
List<PageData> allOperatingVehicleList = operatingVehiclesService.getPulldownVehicleList(pd); // 查询出所有不包括 删除、报废的营运车辆
|
List<PageData> allOperatingVehicleList = operatingVehiclesService.getPulldownVehicleList(pd); // 查询出所有不包括 删除、报废的营运车辆
|
||||||
List<PageData> allAssignedList = assignedManageService.assignedList(corpId); // 所有过户的车辆
|
List<PageData> allAssignedList = assignedManageService.assignedList(corpId); // 所有过户的车辆
|
||||||
|
|
||||||
List<PageData> varList = new ArrayList<>();
|
List<PageData> varList = new ArrayList<>();
|
||||||
if(!CollectionUtil.isEmpty(allAssignedList)) {
|
if (!CollectionUtils.isEmpty(allAssignedList)) {
|
||||||
varList = allOperatingVehicleList.stream().filter(operating -> {
|
varList = allOperatingVehicleList.stream().parallel()
|
||||||
for (PageData assigned : allAssignedList) {
|
.filter(operating -> allAssignedList.stream()
|
||||||
if(!StringUtils.equals(operating.getString("OPERATING_ID"),assigned.getString("RAW_PLATE_NUMBER"))) {
|
.noneMatch(assigned -> StringUtils.equals(operating.getString("OPERATING_ID"), assigned.getString("RAW_PLATE_NUMBER"))))
|
||||||
return true;
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}).collect(Collectors.toList());
|
|
||||||
} else {
|
} else {
|
||||||
varList = allOperatingVehicleList;
|
varList = allOperatingVehicleList;
|
||||||
}
|
}
|
||||||
|
@ -286,19 +272,17 @@ public class AssignedManageController extends BaseController {
|
||||||
String corpId = Jurisdiction.getCORPINFO_ID();
|
String corpId = Jurisdiction.getCORPINFO_ID();
|
||||||
List<PageData> freightList = freightTrailerService.getPulldownVehicleList(corpId);
|
List<PageData> freightList = freightTrailerService.getPulldownVehicleList(corpId);
|
||||||
List<PageData> assignedList = assignedManageService.assignedList(corpId);
|
List<PageData> assignedList = assignedManageService.assignedList(corpId);
|
||||||
|
|
||||||
List<PageData> varList = new ArrayList<>();
|
List<PageData> varList = new ArrayList<>();
|
||||||
if (!CollectionUtils.isEmpty(assignedList)) {
|
if (!CollectionUtils.isEmpty(assignedList)) {
|
||||||
varList = freightList.stream().filter(freight -> {
|
varList = freightList.stream().parallel()
|
||||||
for (PageData assigned : assignedList) {
|
.filter(freight -> assignedList.stream()
|
||||||
if(!StringUtils.equals(freight.getString("FREIGHTTRAILER_ID"),assigned.getString("RAW_PLATE_NUMBER"))) {
|
.noneMatch(assigned -> StringUtils.equals(freight.getString("FREIGHTTRAILER_ID"), assigned.getString("RAW_PLATE_NUMBER"))))
|
||||||
return true;
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}).collect(Collectors.toList());
|
|
||||||
} else {
|
} else {
|
||||||
varList = freightList;
|
varList = freightList;
|
||||||
}
|
}
|
||||||
|
|
||||||
map.put("varList", varList);
|
map.put("varList", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
|
|
|
@ -232,7 +232,6 @@ public class TrafficSecurityWaybillRegistrationController extends BaseController
|
||||||
PageData contactInfo = trafficSecurityCustomerManagementService.findByContactName(pd2);
|
PageData contactInfo = trafficSecurityCustomerManagementService.findByContactName(pd2);
|
||||||
if(!ObjectUtil.isEmpty(contactInfo)) {
|
if(!ObjectUtil.isEmpty(contactInfo)) {
|
||||||
pd.put("ENTRUST_PERSON", contactInfo.getString("CONTACT_ID"));
|
pd.put("ENTRUST_PERSON", contactInfo.getString("CONTACT_ID"));
|
||||||
}
|
|
||||||
if(!contactInfo.getString("CONTACTPHONE").equals(pd.getString("CLIENTCONTACTPHONE"))) {
|
if(!contactInfo.getString("CONTACTPHONE").equals(pd.getString("CLIENTCONTACTPHONE"))) {
|
||||||
PageData entrust = new PageData();
|
PageData entrust = new PageData();
|
||||||
entrust.put("CONTACTPHONE", pd.getString("CLIENTCONTACTPHONE"));
|
entrust.put("CONTACTPHONE", pd.getString("CLIENTCONTACTPHONE"));
|
||||||
|
@ -242,13 +241,13 @@ public class TrafficSecurityWaybillRegistrationController extends BaseController
|
||||||
entrust.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
|
entrust.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
|
||||||
trafficSecurityCustomerManagementService.editContactPhone(entrust);
|
trafficSecurityCustomerManagementService.editContactPhone(entrust);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
PageData pd3 = new PageData();
|
PageData pd3 = new PageData();
|
||||||
pd3.put("CONTACT", pd.getString("CONFIRM_PERSON"));
|
pd3.put("CONTACT", pd.getString("CONFIRM_PERSON"));
|
||||||
PageData pageData = trafficSecurityCustomerManagementService.findByContactName(pd3);
|
PageData pageData = trafficSecurityCustomerManagementService.findByContactName(pd3);
|
||||||
if(!ObjectUtil.isEmpty(pageData)) {
|
if(!ObjectUtil.isEmpty(pageData)) {
|
||||||
pd.put("CONFIRM_PERSON", pageData.getString("CONTACT_ID"));
|
pd.put("CONFIRM_PERSON", pageData.getString("CONTACT_ID"));
|
||||||
}
|
if(!pd.getString("CONFIRMINGPHONE").equals(pageData.getString("CONTACTPHONE"))) {
|
||||||
if(!pageData.getString("CONTACTPHONE").equals(pd.getString("CONFIRMINGPHONE"))) {
|
|
||||||
PageData entrust = new PageData();
|
PageData entrust = new PageData();
|
||||||
entrust.put("CONTACTPHONE", pd.getString("CONFIRMINGPHONE"));
|
entrust.put("CONTACTPHONE", pd.getString("CONFIRMINGPHONE"));
|
||||||
entrust.put("CUSTOMERCONTACT_ID",pageData.getString("CUSTOMERCONTACT_ID"));
|
entrust.put("CUSTOMERCONTACT_ID",pageData.getString("CUSTOMERCONTACT_ID"));
|
||||||
|
@ -257,6 +256,7 @@ public class TrafficSecurityWaybillRegistrationController extends BaseController
|
||||||
entrust.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
|
entrust.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
|
||||||
trafficSecurityCustomerManagementService.editContactPhone(entrust);
|
trafficSecurityCustomerManagementService.editContactPhone(entrust);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
trafficSecurityWaybillRegistrationService.edit(pd);
|
trafficSecurityWaybillRegistrationService.edit(pd);
|
||||||
|
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
|
|
|
@ -14,6 +14,7 @@ import com.zcloud.service.taxationManage.TaxationManageService;
|
||||||
import com.zcloud.util.*;
|
import com.zcloud.util.*;
|
||||||
import org.apache.commons.io.FileUtils;
|
import org.apache.commons.io.FileUtils;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.apache.shiro.util.CollectionUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
@ -540,13 +541,27 @@ public class FreighttTrailerController extends BaseController {
|
||||||
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> insAnnually = inspectAnnuallyService.annuallyList(page);
|
List<PageData> insAnnually = inspectAnnuallyService.annuallyList(page);
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
|
// 获取所有的营运车辆
|
||||||
|
List<PageData> operatings = insAnnually.stream().filter(data -> StringUtils.equals("1",data.getString("VEHICLE_MODEL")))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
|
||||||
|
// 过滤掉年检车辆中已经存在的营运车辆
|
||||||
|
List<PageData> varList = new ArrayList<>();
|
||||||
|
if(!CollectionUtils.isEmpty(operatings)) {
|
||||||
|
varList = operatingList.stream().parallel().filter(operating -> operatings.stream()
|
||||||
|
.noneMatch(ins -> Objects.equals(operating.getString("OPERATING_ID"), ins.getString("VEHICLE"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
}else{
|
||||||
|
varList = operatingList;
|
||||||
|
}
|
||||||
|
/*for (int i = 0; i < insAnnually.size(); i++) {
|
||||||
for (int j = 0; j < operatingList.size(); j++) {
|
for (int j = 0; j < operatingList.size(); j++) {
|
||||||
if(operatingList.get(j).get("OPERATING_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
if(operatingList.get(j).get("OPERATING_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
||||||
operatingList.remove(j);
|
operatingList.remove(j);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}*/
|
||||||
if(pd.containsKey("ID")){
|
if(pd.containsKey("ID")){
|
||||||
pd.put("OPERATING_ID", pd.getString("ID"));
|
pd.put("OPERATING_ID", pd.getString("ID"));
|
||||||
pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID"));
|
pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID"));
|
||||||
|
@ -554,10 +569,10 @@ public class FreighttTrailerController extends BaseController {
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
||||||
}
|
}
|
||||||
operatingList.forEach(operating -> {
|
varList.forEach(operating -> {
|
||||||
operating.put("ID", operating.getString("OPERATING_ID"));
|
operating.put("ID", operating.getString("OPERATING_ID"));
|
||||||
});
|
});
|
||||||
map.put("list", operatingList);
|
map.put("list", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
@ -566,13 +581,28 @@ public class FreighttTrailerController extends BaseController {
|
||||||
List<PageData> freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID"));
|
List<PageData> freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID"));
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> insAnnually = inspectAnnuallyService.annuallyList(page);
|
List<PageData> insAnnually = inspectAnnuallyService.annuallyList(page);
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
|
// 获取所有的货运挂车
|
||||||
|
List<PageData> freights = insAnnually.stream().filter(data -> "2".equals(data.getString("VEHICLE_MODEL")))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
|
||||||
|
// 过滤掉年检列表中的所有货运挂车信息
|
||||||
|
List<PageData> varList = new ArrayList<>();
|
||||||
|
if(!CollectionUtils.isEmpty(freights)) {
|
||||||
|
varList = freightList.stream().parallel().filter(freight -> freights.stream()
|
||||||
|
.noneMatch(ins -> freight.getString("FREIGHTTRAILER_ID").equals(ins.getString("VEHICLE"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
}else{
|
||||||
|
varList = freightList;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*for (int i = 0; i < insAnnually.size(); i++) {
|
||||||
for (int j = 0; j < freightList.size(); j++) {
|
for (int j = 0; j < freightList.size(); j++) {
|
||||||
if(freightList.get(j).get("FREIGHTTRAILER_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
if(freightList.get(j).get("FREIGHTTRAILER_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
||||||
freightList.remove(j);
|
freightList.remove(j);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}*/
|
||||||
if(pd.containsKey("ID")){
|
if(pd.containsKey("ID")){
|
||||||
pd.put("FREIGHTTRAILER_ID", pd.getString("ID"));
|
pd.put("FREIGHTTRAILER_ID", pd.getString("ID"));
|
||||||
pd.put("FOREIGN_KEY", pd.getString("FREIGHTTRAILER_ID"));
|
pd.put("FOREIGN_KEY", pd.getString("FREIGHTTRAILER_ID"));
|
||||||
|
@ -580,10 +610,10 @@ public class FreighttTrailerController extends BaseController {
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
||||||
}
|
}
|
||||||
freightList.forEach(freight -> {
|
varList.forEach(freight -> {
|
||||||
freight.put("ID", freight.getString("FREIGHTTRAILER_ID"));
|
freight.put("ID", freight.getString("FREIGHTTRAILER_ID"));
|
||||||
});
|
});
|
||||||
map.put("list", freightList);
|
map.put("list", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
|
@ -239,7 +239,9 @@ public class InspectAnnuallyController extends BaseController {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**导出到excel
|
/**
|
||||||
|
* 导出到excel
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -304,5 +306,4 @@ public class InspectAnnuallyController extends BaseController {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,15 +12,14 @@ import com.zcloud.service.system.ImgFilesService;
|
||||||
import com.zcloud.util.DateUtil;
|
import com.zcloud.util.DateUtil;
|
||||||
import com.zcloud.util.Jurisdiction;
|
import com.zcloud.util.Jurisdiction;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.apache.shiro.util.CollectionUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.ResponseBody;
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
import java.util.stream.Collectors;
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 保险管理
|
* 保险管理
|
||||||
|
@ -217,13 +216,23 @@ public class InsureController extends BaseController {
|
||||||
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> insAnnually = insureService.list(page);
|
List<PageData> insAnnually = insureService.list(page);
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
for (int j = 0; j < operatingList.size(); j++) {
|
// 获取保险列表中所有的营运车辆
|
||||||
if(operatingList.get(j).get("OPERATING_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
List<PageData> insures = insAnnually.stream()
|
||||||
operatingList.remove(j);
|
.filter(data -> StringUtils.equals(data.getString("VEHICLE_MODEL"), "1"))
|
||||||
}
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
|
// 过滤掉保险列表中所有的营运车辆
|
||||||
|
List<PageData> varList = new ArrayList<>();
|
||||||
|
if (!CollectionUtils.isEmpty(insures)) {
|
||||||
|
varList = operatingList.stream().parallel()
|
||||||
|
.filter(operating -> insures.stream()
|
||||||
|
.noneMatch(ins -> StringUtils.equals(operating.getString("OPERATING_ID"), ins.getString("VEHICLE"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
} else {
|
||||||
|
varList = operatingList;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pd.containsKey("ID")) {
|
if (pd.containsKey("ID")) {
|
||||||
pd.put("OPERATING_ID", pd.getString("ID"));
|
pd.put("OPERATING_ID", pd.getString("ID"));
|
||||||
pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID"));
|
pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID"));
|
||||||
|
@ -231,10 +240,10 @@ public class InsureController extends BaseController {
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
||||||
}
|
}
|
||||||
operatingList.forEach(operating -> {
|
varList.forEach(operating -> {
|
||||||
operating.put("ID", operating.getString("OPERATING_ID"));
|
operating.put("ID", operating.getString("OPERATING_ID"));
|
||||||
});
|
});
|
||||||
map.put("list", operatingList);
|
map.put("list", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
@ -242,14 +251,23 @@ public class InsureController extends BaseController {
|
||||||
// 货运挂车
|
// 货运挂车
|
||||||
List<PageData> freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID"));
|
List<PageData> freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID"));
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> insAnnually = insureService.list(page);
|
List<PageData> insureList = insureService.list(page);
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
for (int j = 0; j < freightList.size(); j++) {
|
// 获取保险列表中所有挂车信息
|
||||||
if(freightList.get(j).get("FREIGHTTRAILER_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
List<PageData> insures = insureList.stream().filter(data -> StringUtils.equals(data.getString("VEHICLE_MODEL"), "2"))
|
||||||
freightList.remove(j);
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
}
|
// 过滤掉保险列表中所有已存在的挂车
|
||||||
|
List<PageData> varList = new ArrayList<>();
|
||||||
|
if (!CollectionUtils.isEmpty(insures)) {
|
||||||
|
varList = freightList.stream().parallel()
|
||||||
|
.filter(freight -> insures.stream()
|
||||||
|
.noneMatch(ins -> StringUtils.equals(freight.getString("FREIGHTTRAILER_ID"), ins.getString("VEHICLE"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
} else {
|
||||||
|
varList = freightList;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pd.containsKey("ID")) {
|
if (pd.containsKey("ID")) {
|
||||||
pd.put("FREIGHTTRAILER_ID", pd.getString("ID"));
|
pd.put("FREIGHTTRAILER_ID", pd.getString("ID"));
|
||||||
pd.put("FOREIGN_KEY", pd.getString("FREIGHTTRAILER_ID"));
|
pd.put("FOREIGN_KEY", pd.getString("FREIGHTTRAILER_ID"));
|
||||||
|
@ -257,10 +275,10 @@ public class InsureController extends BaseController {
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
||||||
}
|
}
|
||||||
freightList.forEach(freight -> {
|
varList.forEach(freight -> {
|
||||||
freight.put("ID", freight.getString("FREIGHTTRAILER_ID"));
|
freight.put("ID", freight.getString("FREIGHTTRAILER_ID"));
|
||||||
});
|
});
|
||||||
map.put("list", freightList);
|
map.put("list", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,15 +11,14 @@ import com.zcloud.service.system.ImgFilesService;
|
||||||
import com.zcloud.util.DateUtil;
|
import com.zcloud.util.DateUtil;
|
||||||
import com.zcloud.util.Jurisdiction;
|
import com.zcloud.util.Jurisdiction;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.apache.shiro.util.CollectionUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.ResponseBody;
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
import java.util.stream.Collectors;
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 维保管理
|
* 维保管理
|
||||||
|
@ -206,17 +205,19 @@ public class MaintenanceController extends BaseController {
|
||||||
PageData pd = new PageData();
|
PageData pd = new PageData();
|
||||||
pd = this.getPageData();
|
pd = this.getPageData();
|
||||||
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
||||||
if(!StringUtils.isEmpty(pd.getString("TRAFFIC_TYPE")) && pd.getString("TRAFFIC_TYPE").equals("1")) {
|
|
||||||
// 营运车辆
|
// 营运车辆
|
||||||
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> insAnnually = maintenanceService.list(page);
|
List<PageData> maintenanceList = maintenanceService.list(page);
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
for (int j = 0; j < operatingList.size(); j++) {
|
List<PageData> varList = new ArrayList<>();
|
||||||
if(operatingList.get(j).get("OPERATING_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
if (!CollectionUtils.isEmpty(maintenanceList)) {
|
||||||
operatingList.remove(j);
|
varList = operatingList.stream().parallel()
|
||||||
}
|
.filter(operating -> maintenanceList.stream()
|
||||||
}
|
.noneMatch(maintenance -> StringUtils.equals(operating.getString("OPERATING_ID"), maintenance.getString("VEHICLE"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
} else {
|
||||||
|
varList = operatingList;
|
||||||
}
|
}
|
||||||
if (pd.containsKey("ID")) {
|
if (pd.containsKey("ID")) {
|
||||||
pd.put("OPERATING_ID", pd.getString("ID"));
|
pd.put("OPERATING_ID", pd.getString("ID"));
|
||||||
|
@ -225,48 +226,10 @@ public class MaintenanceController extends BaseController {
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
||||||
}
|
}
|
||||||
operatingList.forEach(operating -> {
|
varList.forEach(operating -> {
|
||||||
operating.put("ID", operating.getString("OPERATING_ID"));
|
operating.put("ID", operating.getString("OPERATING_ID"));
|
||||||
});
|
});
|
||||||
map.put("list", operatingList);
|
map.put("list", varList);
|
||||||
map.put("result", errInfo);
|
|
||||||
return map;
|
|
||||||
}
|
|
||||||
if("2".equals(pd.getString("TRAFFIC_TYPE"))) {
|
|
||||||
// 货运挂车
|
|
||||||
List<PageData> freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID"));
|
|
||||||
page.setPd(pd);
|
|
||||||
List<PageData> insAnnually = maintenanceService.list(page);
|
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
for (int j = 0; j < freightList.size(); j++) {
|
|
||||||
if(freightList.get(j).get("FREIGHTTRAILER_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
|
||||||
freightList.remove(j);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if(pd.containsKey("ID")){
|
|
||||||
pd.put("FREIGHTTRAILER_ID", pd.getString("ID"));
|
|
||||||
pd.put("FOREIGN_KEY", pd.getString("FREIGHTTRAILER_ID"));
|
|
||||||
pd.put("TYPE",121);
|
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
|
||||||
}
|
|
||||||
freightList.forEach(freight -> {
|
|
||||||
freight.put("ID", freight.getString("FREIGHTTRAILER_ID"));
|
|
||||||
});
|
|
||||||
map.put("list", freightList);
|
|
||||||
map.put("result", errInfo);
|
|
||||||
return map;
|
|
||||||
}
|
|
||||||
|
|
||||||
List<PageData> resData = freightTrailerService.vehicleList(pd);
|
|
||||||
if(pd.containsKey("ID")){
|
|
||||||
pd.put("FOREIGN_KEY", pd.getString("ID"));
|
|
||||||
pd.put("TYPE",121);
|
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
|
||||||
}
|
|
||||||
map.put("list", resData);
|
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
|
@ -61,7 +61,7 @@ public class OperatingVehiclesController extends BaseController {
|
||||||
pd.put("OPERATING_ID", this.get32UUID()); //运营车辆主键
|
pd.put("OPERATING_ID", this.get32UUID()); //运营车辆主键
|
||||||
pd.put("ISDELETE", "0"); //是否删除(0:有效 1:删除)
|
pd.put("ISDELETE", "0"); //是否删除(0:有效 1:删除)
|
||||||
pd.put("CREATOR", Jurisdiction.getUSER_ID()); //添加人id
|
pd.put("CREATOR", Jurisdiction.getUSER_ID()); //添加人id
|
||||||
pd.put("CREATORNAME", Jurisdiction.getUsername()); //添加人名字
|
pd.put("CREATORNAME", Jurisdiction.getName()); //添加人名字
|
||||||
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //添加时间
|
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //添加时间
|
||||||
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
||||||
pd.put("NETWORK_STATUS", "未入网");
|
pd.put("NETWORK_STATUS", "未入网");
|
||||||
|
|
|
@ -11,15 +11,14 @@ import com.zcloud.service.system.ImgFilesService;
|
||||||
import com.zcloud.util.DateUtil;
|
import com.zcloud.util.DateUtil;
|
||||||
import com.zcloud.util.Jurisdiction;
|
import com.zcloud.util.Jurisdiction;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.apache.shiro.util.CollectionUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.ResponseBody;
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
import java.util.stream.Collectors;
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 营运管理
|
* 营运管理
|
||||||
|
@ -217,14 +216,23 @@ public class OperationsController extends BaseController {
|
||||||
// 营运车辆
|
// 营运车辆
|
||||||
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
List<PageData> operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID"));
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> insAnnually = operationsService.list(page);
|
List<PageData> operationsList = operationsService.list(page);
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
for (int j = 0; j < operatingList.size(); j++) {
|
// 获取营运车辆列表中所有的运营车辆
|
||||||
if(operatingList.get(j).get("OPERATING_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
List<PageData> operations = operationsList.stream().filter(data -> StringUtils.equals(data.getString("VEHICLE_MODEL"), "1"))
|
||||||
operatingList.remove(j);
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
}
|
// 过滤掉营运管理列表中所有营运车辆信息
|
||||||
|
List<PageData> varList = new ArrayList<>();
|
||||||
|
if(!CollectionUtils.isEmpty(operations)) {
|
||||||
|
varList = operatingList.stream().parallel()
|
||||||
|
.filter(operating -> operations.stream().
|
||||||
|
noneMatch(operation -> StringUtils.equals(operating.getString("OPERATING_ID"), operation.getString("VEHICLE"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
}else{
|
||||||
|
varList = operatingList;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(pd.containsKey("ID")){
|
if(pd.containsKey("ID")){
|
||||||
pd.put("OPERATING_ID", pd.getString("ID"));
|
pd.put("OPERATING_ID", pd.getString("ID"));
|
||||||
pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID"));
|
pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID"));
|
||||||
|
@ -232,10 +240,10 @@ public class OperationsController extends BaseController {
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
||||||
}
|
}
|
||||||
operatingList.forEach(operating -> {
|
varList.forEach(operating -> {
|
||||||
operating.put("ID", operating.getString("OPERATING_ID"));
|
operating.put("ID", operating.getString("OPERATING_ID"));
|
||||||
});
|
});
|
||||||
map.put("list", operatingList);
|
map.put("list", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
@ -243,14 +251,23 @@ public class OperationsController extends BaseController {
|
||||||
// 货运挂车
|
// 货运挂车
|
||||||
List<PageData> freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID"));
|
List<PageData> freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID"));
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> insAnnually = operationsService.list(page);
|
List<PageData> operationsList = operationsService.list(page);
|
||||||
for (int i = 0; i < insAnnually.size(); i++) {
|
|
||||||
for (int j = 0; j < freightList.size(); j++) {
|
// 获取营运管理列表中所有的货运挂车
|
||||||
if(freightList.get(j).get("FREIGHTTRAILER_ID").equals(insAnnually.get(i).get("VEHICLE"))) {
|
List<PageData> operations = operationsList.stream()
|
||||||
freightList.remove(j);
|
.filter(data -> StringUtils.equals(data.getString("VEHICLE_MODEL"), "2"))
|
||||||
}
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
|
List<PageData> varList = new ArrayList<>();
|
||||||
|
if(!CollectionUtils.isEmpty(operations)) {
|
||||||
|
varList = freightList.stream().parallel()
|
||||||
|
.filter(freight -> operations.stream()
|
||||||
|
.noneMatch(operation -> StringUtils.equals(freight.getString("FREIGHTTRAILER_ID"), operation.getString("VEHICLE"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
}else{
|
||||||
|
varList = freightList;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(pd.containsKey("ID")){
|
if(pd.containsKey("ID")){
|
||||||
pd.put("FREIGHTTRAILER_ID", pd.getString("ID"));
|
pd.put("FREIGHTTRAILER_ID", pd.getString("ID"));
|
||||||
pd.put("FOREIGN_KEY", pd.getString("FREIGHTTRAILER_ID"));
|
pd.put("FOREIGN_KEY", pd.getString("FREIGHTTRAILER_ID"));
|
||||||
|
@ -258,10 +275,10 @@ public class OperationsController extends BaseController {
|
||||||
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
|
||||||
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
map.put("drivingLicenseImgs", drivingLicenseImgs);
|
||||||
}
|
}
|
||||||
freightList.forEach(freight -> {
|
varList.forEach(freight -> {
|
||||||
freight.put("ID", freight.getString("FREIGHTTRAILER_ID"));
|
freight.put("ID", freight.getString("FREIGHTTRAILER_ID"));
|
||||||
});
|
});
|
||||||
map.put("list", freightList);
|
map.put("list", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
|
@ -212,11 +212,20 @@ public class ScrapManageController extends BaseController {
|
||||||
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
|
||||||
List<PageData> operationList = operatingVehiclesService.getScrapPulldownVehicleList(pd); //列出Question列表
|
List<PageData> operationList = operatingVehiclesService.getScrapPulldownVehicleList(pd); //列出Question列表
|
||||||
List<PageData> scrapList = scrapManageService.scrapListAll(corpId);
|
List<PageData> scrapList = scrapManageService.scrapListAll(corpId);
|
||||||
|
|
||||||
List<PageData> varList = new ArrayList<>();
|
List<PageData> varList = new ArrayList<>();
|
||||||
if(!CollectionUtils.isEmpty(scrapList)) {
|
if(!CollectionUtils.isEmpty(scrapList)) {
|
||||||
|
varList = operationList.stream().parallel()
|
||||||
|
.filter(operating -> scrapList.stream()
|
||||||
|
.noneMatch(scrap -> StringUtils.equals(operating.getString("PLATE_NUMBER"), scrap.getString("PLATE_NUMBER"))))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
}else {
|
||||||
|
varList = operationList;
|
||||||
|
}
|
||||||
|
/*if(!CollectionUtils.isEmpty(scrapList)) {
|
||||||
varList = operationList.stream().filter(operation -> {
|
varList = operationList.stream().filter(operation -> {
|
||||||
for (PageData scrap : scrapList) {
|
for (PageData scrap : scrapList) {
|
||||||
if(StringUtils.equals(operation.getString("PLATE_NUMBER"),scrap.getString("PLATE_NUMBER"))) {
|
if(!StringUtils.equals(operation.getString("PLATE_NUMBER"),scrap.getString("PLATE_NUMBER"))) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -224,7 +233,7 @@ public class ScrapManageController extends BaseController {
|
||||||
}).collect(Collectors.toList());
|
}).collect(Collectors.toList());
|
||||||
}else {
|
}else {
|
||||||
varList = operationList;
|
varList = operationList;
|
||||||
}
|
}*/
|
||||||
map.put("varList", varList);
|
map.put("varList", varList);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
|
@ -238,16 +247,13 @@ public class ScrapManageController extends BaseController {
|
||||||
String corpId = Jurisdiction.getCORPINFO_ID();
|
String corpId = Jurisdiction.getCORPINFO_ID();
|
||||||
List<PageData> freightList = freightTrailerService.getScrapPulldownVehicleList(corpId);
|
List<PageData> freightList = freightTrailerService.getScrapPulldownVehicleList(corpId);
|
||||||
List<PageData> scrapList = scrapManageService.scrapListAll(corpId);
|
List<PageData> scrapList = scrapManageService.scrapListAll(corpId);
|
||||||
|
|
||||||
List<PageData> varList = new ArrayList<>();
|
List<PageData> varList = new ArrayList<>();
|
||||||
if(!CollectionUtils.isEmpty(scrapList)) {
|
if(!CollectionUtils.isEmpty(scrapList)) {
|
||||||
varList = freightList.stream().filter(freight -> {
|
varList = freightList.stream().parallel()
|
||||||
for (PageData scrap : scrapList) {
|
.filter(freight -> scrapList.stream()
|
||||||
if(StringUtils.equals(freight.getString("PLATE_NUMBER"),scrap.getString("PLATE_NUMBER"))){
|
.noneMatch(scrap -> StringUtils.equals(freight.getString("PLATE_NUMBER"), scrap.getString("PLATE_NUMBER"))))
|
||||||
return true;
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}).collect(Collectors.toList());
|
|
||||||
}else{
|
}else{
|
||||||
varList = freightList;
|
varList = freightList;
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,7 +41,9 @@ public class TaxationManageController extends BaseController {
|
||||||
@Autowired
|
@Autowired
|
||||||
private FreightTrailerService freightTrailerService;
|
private FreightTrailerService freightTrailerService;
|
||||||
|
|
||||||
/**新增
|
/**
|
||||||
|
* 新增
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -75,7 +77,9 @@ public class TaxationManageController extends BaseController {
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**删除
|
/**
|
||||||
|
* 删除
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -94,7 +98,9 @@ public class TaxationManageController extends BaseController {
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**修改
|
/**
|
||||||
|
* 修改
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -122,7 +128,10 @@ public class TaxationManageController extends BaseController {
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
/**去修改页面获取数据
|
|
||||||
|
/**
|
||||||
|
* 去修改页面获取数据
|
||||||
|
*
|
||||||
* @param
|
* @param
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
@ -185,23 +194,19 @@ public class TaxationManageController extends BaseController {
|
||||||
pd = this.getPageData();
|
pd = this.getPageData();
|
||||||
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业ID
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业ID
|
||||||
page.setPd(pd);
|
page.setPd(pd);
|
||||||
List<PageData> varList = freightTrailerService.list(page); // 列出所有挂车列表
|
List<PageData> freightTrailerList = freightTrailerService.list(page); // 列出所有挂车列表
|
||||||
List<PageData> taxationList = taxationManageService.taxationList(pd.getString("CORPINFO_ID")); // 列出车船税列表
|
List<PageData> taxationList = taxationManageService.taxationList(pd.getString("CORPINFO_ID")); // 列出车船税列表
|
||||||
List<PageData> pageDataStream = new ArrayList<>();
|
|
||||||
|
List<PageData> varList = new ArrayList<>();
|
||||||
if (!CollectionUtils.isEmpty(taxationList)) {
|
if (!CollectionUtils.isEmpty(taxationList)) {
|
||||||
pageDataStream = varList.stream().filter(trailer -> { // 去除车船税类表中已有的车辆
|
varList = freightTrailerList.stream().parallel()
|
||||||
for (PageData taxation : taxationList) {
|
.filter(freight -> taxationList.stream()
|
||||||
if (!StringUtils.equals(taxation.getString("PLATE_NUMBER"), trailer.getString("PLATE_NUMBER"))) {
|
.noneMatch(taxation -> StringUtils.equals(freight.getString("PLATE_NUMBER"), taxation.getString("PLATE_NUMBER"))))
|
||||||
return true;
|
.collect(Collectors.toList());
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}).collect(Collectors.toList());
|
|
||||||
}else{
|
|
||||||
pageDataStream = varList;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 过滤掉车船税下拉列表中已报废的车辆信息
|
// 过滤掉车船税下拉列表中已报废的车辆信息
|
||||||
List<PageData> choiceTrailerList = pageDataStream.stream().filter(data -> !"1".equals(data.get("ISSCRAP"))).collect(Collectors.toList());
|
List<PageData> choiceTrailerList = varList.stream().filter(data -> !"1".equals(data.get("ISSCRAP"))).collect(Collectors.toList());
|
||||||
map.put("varList", choiceTrailerList);
|
map.put("varList", choiceTrailerList);
|
||||||
map.put("page", page);
|
map.put("page", page);
|
||||||
map.put("result", errInfo);
|
map.put("result", errInfo);
|
||||||
|
|
Loading…
Reference in New Issue