From 86d82ec17e363affb7008ea96d8834cbcdb6c642 Mon Sep 17 00:00:00 2001 From: xiepeng Date: Thu, 28 Mar 2024 18:32:23 +0800 Subject: [PATCH] =?UTF-8?q?BUG=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/beidou/BeidouController.java | 76 +++++++++++++++ .../EnterpriseSafetyProductionController.java | 3 - .../InspectAnnuallyController.java | 2 + .../controller/insure/InsureController.java | 81 ++++++++++++++++ .../maintenance/MaintenanceController.java | 80 ++++++++++++++++ .../OperatingVehiclesController.java | 3 +- .../operations/OperationsController.java | 94 ++++++++++++++++++- .../scrapManage/ScrapManageController.java | 10 ++ .../OperatingVehiclesMapper.java | 2 +- .../OperatingVehiclesService.java | 2 +- .../impl/OperatingVehiclesServiceImpl.java | 4 +- .../EnterpriseSafetyProductionMapper.xml | 1 + .../FirefightingEquipmentFacilityMapper.xml | 1 + .../OperatingVehiclesMapper.xml | 4 +- .../ReportedIncidentMapper.xml | 6 +- .../taxationManage/TaxationManageMapper.xml | 2 +- 16 files changed, 354 insertions(+), 17 deletions(-) diff --git a/src/main/java/com/zcloud/controller/beidou/BeidouController.java b/src/main/java/com/zcloud/controller/beidou/BeidouController.java index 2241261..6432e50 100644 --- a/src/main/java/com/zcloud/controller/beidou/BeidouController.java +++ b/src/main/java/com/zcloud/controller/beidou/BeidouController.java @@ -5,6 +5,7 @@ import com.zcloud.entity.Page; import com.zcloud.entity.PageData; import com.zcloud.logs.LogAnno; import com.zcloud.service.beidou.BeidouService; +import com.zcloud.service.freighttrailer.FreightTrailerService; import com.zcloud.service.maintenance.MaintenanceService; import com.zcloud.service.operatingvehicles.OperatingVehiclesService; import com.zcloud.service.operations.OperationsService; @@ -45,6 +46,9 @@ public class BeidouController extends BaseController { @Autowired private OperatingVehiclesService operatingVehiclesService; + @Autowired + private FreightTrailerService freightTrailerService; + /** * 新增 * @@ -242,5 +246,77 @@ public class BeidouController extends BaseController { return map; } + @RequestMapping(value = "/vehicleList") + @ResponseBody + public Object vehicleList(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + pd.put("CORPINFO_ID",Jurisdiction.getCORPINFO_ID()); + if(!StringUtils.isEmpty(pd.getString("TRAFFIC_TYPE")) && pd.getString("TRAFFIC_TYPE").equals("1")) { + // 营运车辆 + List operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List insAnnually = beidouService.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"))) { + operatingList.remove(j); + } + } + } + if(pd.containsKey("ID")){ + pd.put("OPERATING_ID", pd.getString("ID")); + pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + operatingList.forEach(operating -> { + operating.put("ID", operating.getString("OPERATING_ID")); + }); + map.put("list", operatingList); + map.put("result", errInfo); + return map; + } + if("2".equals(pd.getString("TRAFFIC_TYPE"))) { + // 货运挂车 + List freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List insAnnually = beidouService.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 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 resData = freightTrailerService.vehicleList(pd); + if(pd.containsKey("ID")){ + pd.put("FOREIGN_KEY", pd.getString("ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + map.put("list", resData); + map.put("result", errInfo); + return map; + } } diff --git a/src/main/java/com/zcloud/controller/enterpriseSafetyProduction/EnterpriseSafetyProductionController.java b/src/main/java/com/zcloud/controller/enterpriseSafetyProduction/EnterpriseSafetyProductionController.java index 8b9b59f..752bdc1 100644 --- a/src/main/java/com/zcloud/controller/enterpriseSafetyProduction/EnterpriseSafetyProductionController.java +++ b/src/main/java/com/zcloud/controller/enterpriseSafetyProduction/EnterpriseSafetyProductionController.java @@ -48,9 +48,6 @@ public class EnterpriseSafetyProductionController extends BaseController { pd.put("CREATOR", Jurisdiction.getUSER_ID()); //添加人id pd.put("CREATORNAME", Jurisdiction.getUsername()); //添加人名字 pd.put("CREATTIME", DateUtil.date2Str(new Date())); //添加时间 - pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //修改人id - pd.put("OPERATORNAME", Jurisdiction.getUsername()); // 修改人名字 - pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间 enterpriseSafetyProductionService.save(pd); map.put("pd", pd); map.put("result", errInfo); diff --git a/src/main/java/com/zcloud/controller/inspectAnnually/InspectAnnuallyController.java b/src/main/java/com/zcloud/controller/inspectAnnually/InspectAnnuallyController.java index b8d7ac9..3a86a98 100644 --- a/src/main/java/com/zcloud/controller/inspectAnnually/InspectAnnuallyController.java +++ b/src/main/java/com/zcloud/controller/inspectAnnually/InspectAnnuallyController.java @@ -10,6 +10,7 @@ import com.zcloud.service.operatingvehicles.OperatingVehiclesService; import com.zcloud.service.system.ImgFilesService; import com.zcloud.util.DateUtil; import com.zcloud.util.Jurisdiction; +import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; @@ -227,4 +228,5 @@ public class InspectAnnuallyController extends BaseController { } + } diff --git a/src/main/java/com/zcloud/controller/insure/InsureController.java b/src/main/java/com/zcloud/controller/insure/InsureController.java index a09f8bf..ff177dc 100644 --- a/src/main/java/com/zcloud/controller/insure/InsureController.java +++ b/src/main/java/com/zcloud/controller/insure/InsureController.java @@ -4,11 +4,14 @@ import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; import com.zcloud.logs.LogAnno; +import com.zcloud.service.freighttrailer.FreightTrailerService; import com.zcloud.service.inspectAnnually.InspectAnnuallyService; import com.zcloud.service.insure.InsureService; +import com.zcloud.service.operatingvehicles.OperatingVehiclesService; import com.zcloud.service.system.ImgFilesService; import com.zcloud.util.DateUtil; import com.zcloud.util.Jurisdiction; +import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; @@ -31,6 +34,12 @@ public class InsureController extends BaseController { @Autowired private ImgFilesService imgfilesService; + @Autowired + private OperatingVehiclesService operatingVehiclesService; + + @Autowired + private FreightTrailerService freightTrailerService; + /** * 新增 * @@ -184,5 +193,77 @@ public class InsureController extends BaseController { return map; } + @RequestMapping(value = "/vehicleList") + @ResponseBody + public Object vehicleList(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + pd.put("CORPINFO_ID",Jurisdiction.getCORPINFO_ID()); + if(!StringUtils.isEmpty(pd.getString("TRAFFIC_TYPE")) && pd.getString("TRAFFIC_TYPE").equals("1")) { + // 营运车辆 + List operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List 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"))) { + operatingList.remove(j); + } + } + } + if(pd.containsKey("ID")){ + pd.put("OPERATING_ID", pd.getString("ID")); + pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + operatingList.forEach(operating -> { + operating.put("ID", operating.getString("OPERATING_ID")); + }); + map.put("list", operatingList); + map.put("result", errInfo); + return map; + } + if("2".equals(pd.getString("TRAFFIC_TYPE"))) { + // 货运挂车 + List freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List insAnnually = 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"))) { + 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 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 resData = freightTrailerService.vehicleList(pd); + if(pd.containsKey("ID")){ + pd.put("FOREIGN_KEY", pd.getString("ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + map.put("list", resData); + map.put("result", errInfo); + return map; + } } diff --git a/src/main/java/com/zcloud/controller/maintenance/MaintenanceController.java b/src/main/java/com/zcloud/controller/maintenance/MaintenanceController.java index 8f757a1..e28c101 100644 --- a/src/main/java/com/zcloud/controller/maintenance/MaintenanceController.java +++ b/src/main/java/com/zcloud/controller/maintenance/MaintenanceController.java @@ -4,10 +4,13 @@ import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; import com.zcloud.logs.LogAnno; +import com.zcloud.service.freighttrailer.FreightTrailerService; import com.zcloud.service.maintenance.MaintenanceService; +import com.zcloud.service.operatingvehicles.OperatingVehiclesService; import com.zcloud.service.system.ImgFilesService; import com.zcloud.util.DateUtil; import com.zcloud.util.Jurisdiction; +import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; @@ -30,6 +33,12 @@ public class MaintenanceController extends BaseController { @Autowired private ImgFilesService imgfilesService; + @Autowired + private OperatingVehiclesService operatingVehiclesService; + + @Autowired + private FreightTrailerService freightTrailerService; + /** * 新增 * @@ -180,5 +189,76 @@ public class MaintenanceController extends BaseController { return map; } + @RequestMapping(value = "/vehicleList") + @ResponseBody + public Object vehicleList(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + pd.put("CORPINFO_ID",Jurisdiction.getCORPINFO_ID()); + if(!StringUtils.isEmpty(pd.getString("TRAFFIC_TYPE")) && pd.getString("TRAFFIC_TYPE").equals("1")) { + // 营运车辆 + List operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List insAnnually = maintenanceService.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"))) { + operatingList.remove(j); + } + } + } + if(pd.containsKey("ID")){ + pd.put("OPERATING_ID", pd.getString("ID")); + pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + operatingList.forEach(operating -> { + operating.put("ID", operating.getString("OPERATING_ID")); + }); + map.put("list", operatingList); + map.put("result", errInfo); + return map; + } + if("2".equals(pd.getString("TRAFFIC_TYPE"))) { + // 货运挂车 + List freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List 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 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 resData = freightTrailerService.vehicleList(pd); + if(pd.containsKey("ID")){ + pd.put("FOREIGN_KEY", pd.getString("ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + map.put("list", resData); + map.put("result", errInfo); + return map; + } } diff --git a/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java b/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java index 6999445..bfe2067 100644 --- a/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java +++ b/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java @@ -64,6 +64,7 @@ public class OperatingVehiclesController extends BaseController { pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间 pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); pd.put("NETWORK_STATUS", "未入网"); + pd.put("ISSCRAP", "0"); operatingVehiclesService.save(pd); map.put("pd", pd); map.put("result", errInfo); @@ -252,7 +253,7 @@ public class OperatingVehiclesController extends BaseController { PageData pd = new PageData(); pd = this.getPageData(); pd.put("CORPINFO_ID",Jurisdiction.getCORPINFO_ID()); - pd = operatingVehiclesService.setScrapStatus(pd); + operatingVehiclesService.setScrapStatus(pd); map.put("pd", pd); map.put("result", errInfo); return map; diff --git a/src/main/java/com/zcloud/controller/operations/OperationsController.java b/src/main/java/com/zcloud/controller/operations/OperationsController.java index f19aa0f..9bef7ca 100644 --- a/src/main/java/com/zcloud/controller/operations/OperationsController.java +++ b/src/main/java/com/zcloud/controller/operations/OperationsController.java @@ -4,10 +4,13 @@ import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; import com.zcloud.logs.LogAnno; +import com.zcloud.service.freighttrailer.FreightTrailerService; +import com.zcloud.service.operatingvehicles.OperatingVehiclesService; import com.zcloud.service.operations.OperationsService; import com.zcloud.service.system.ImgFilesService; import com.zcloud.util.DateUtil; import com.zcloud.util.Jurisdiction; +import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; @@ -30,6 +33,12 @@ public class OperationsController extends BaseController { @Autowired private ImgFilesService imgfilesService; + @Autowired + private OperatingVehiclesService operatingVehiclesService; + + @Autowired + private FreightTrailerService freightTrailerService; + /** * 新增 * @@ -52,7 +61,6 @@ public class OperationsController extends BaseController { pd.put("ISDELETE", "0"); //是否删除(0:有效 1:删除) pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业ID pd.put("ARCHIVES_TYPE", "正常"); //档案状态 - operationsService.save(pd); map.put("pd", pd); map.put("result", errInfo); @@ -164,13 +172,21 @@ public class OperationsController extends BaseController { // @RequiresPermissions( value = {"question:edit" , "courseware:edit"}, logical = Logical.OR) @ResponseBody @LogAnno(menuType = "机务档案", menuServer = "营运管理", instructionsOperate = "营运管理", instructionsType = "去修改页面获取数据") - public Object goEdit() throws Exception { + public Object goEdit(Page page) throws Exception { Map map = new HashMap(); String errInfo = "success"; PageData pd = new PageData(); pd = this.getPageData(); pd = operationsService.findById(pd); //根据ID读取 - + PageData pd2 = new PageData(); + pd2.put("CORPINFO_ID", pd.get("CORPINFO_ID")); //企业ID + page.setPd(pd2); + List operationList = operationsService.list(page); + for (int i = 0; i < operationList.size(); i++) { + if(pd.get("OPERATIONS_ID").equals(operationList.get(i).get("OPERATIONS_ID"))) { + pd.put("CYCLE_NAME",operationList.get(i).get("CYCLE_NAME")); + } + } pd.put("FOREIGN_KEY", pd.getString("OPERATIONS_ID")); pd.put("TYPE",126); List operationsinfoImgs = imgfilesService.listAll(pd);//营运证资料图片 @@ -180,5 +196,77 @@ public class OperationsController extends BaseController { return map; } + @RequestMapping(value = "/vehicleList") + @ResponseBody + public Object vehicleList(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + pd.put("CORPINFO_ID",Jurisdiction.getCORPINFO_ID()); + if(!StringUtils.isEmpty(pd.getString("TRAFFIC_TYPE")) && pd.getString("TRAFFIC_TYPE").equals("1")) { + // 营运车辆 + List operatingList = operatingVehiclesService.operationVehicleList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List insAnnually = 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"))) { + operatingList.remove(j); + } + } + } + if(pd.containsKey("ID")){ + pd.put("OPERATING_ID", pd.getString("ID")); + pd.put("FOREIGN_KEY", pd.getString("OPERATING_ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + operatingList.forEach(operating -> { + operating.put("ID", operating.getString("OPERATING_ID")); + }); + map.put("list", operatingList); + map.put("result", errInfo); + return map; + } + if("2".equals(pd.getString("TRAFFIC_TYPE"))) { + // 货运挂车 + List freightList = freightTrailerService.trailerList(pd.getString("CORPINFO_ID")); + page.setPd(pd); + List insAnnually = 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"))) { + 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 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 resData = freightTrailerService.vehicleList(pd); + if(pd.containsKey("ID")){ + pd.put("FOREIGN_KEY", pd.getString("ID")); + pd.put("TYPE",121); + List drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 + map.put("drivingLicenseImgs", drivingLicenseImgs); + } + map.put("list", resData); + map.put("result", errInfo); + return map; + } } diff --git a/src/main/java/com/zcloud/controller/scrapManage/ScrapManageController.java b/src/main/java/com/zcloud/controller/scrapManage/ScrapManageController.java index f3b7b66..32e5784 100644 --- a/src/main/java/com/zcloud/controller/scrapManage/ScrapManageController.java +++ b/src/main/java/com/zcloud/controller/scrapManage/ScrapManageController.java @@ -75,6 +75,16 @@ public class ScrapManageController extends BaseController { pd.put("DELETOR", Jurisdiction.getUSER_ID()); pd.put("DELETORNAME", Jurisdiction.getUsername()); pd.put("DELETTIME", DateUtil.date2Str(new Date())); + pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); + PageData pageData = scrapManageService.findById(pd); + if("运输车辆".equals(pageData.getString("SCRAP_VEHICLEMODEL"))) { + PageData pd2 = new PageData(); + pd2.put("PLATE_NUMBER", pageData.get("PLATE_NUMBER")); + pd2.put("CORPINFO_ID", pageData.get("CORPINFO_ID")); + PageData scrapVehicle = operatingVehiclesService.findByfindByPlateNumber(pd2); + scrapVehicle.put("ISSCRAP", "0"); + operatingVehiclesService.edit(scrapVehicle); + } scrapManageService.delete(pd); map.put("result", errInfo); //返回结果 return map; diff --git a/src/main/java/com/zcloud/mapper/datasource/operatingvehicles/OperatingVehiclesMapper.java b/src/main/java/com/zcloud/mapper/datasource/operatingvehicles/OperatingVehiclesMapper.java index 8bc7314..0755e0f 100644 --- a/src/main/java/com/zcloud/mapper/datasource/operatingvehicles/OperatingVehiclesMapper.java +++ b/src/main/java/com/zcloud/mapper/datasource/operatingvehicles/OperatingVehiclesMapper.java @@ -40,5 +40,5 @@ public interface OperatingVehiclesMapper { PageData findByfindByPlateNumber(PageData pd); - PageData setScrapStatus(PageData pd); + void setScrapStatus(PageData pd); } diff --git a/src/main/java/com/zcloud/service/operatingvehicles/OperatingVehiclesService.java b/src/main/java/com/zcloud/service/operatingvehicles/OperatingVehiclesService.java index 01785b5..adbc037 100644 --- a/src/main/java/com/zcloud/service/operatingvehicles/OperatingVehiclesService.java +++ b/src/main/java/com/zcloud/service/operatingvehicles/OperatingVehiclesService.java @@ -40,5 +40,5 @@ public interface OperatingVehiclesService { PageData findByfindByPlateNumber(PageData pd); - PageData setScrapStatus(PageData pd); + void setScrapStatus(PageData pd); } diff --git a/src/main/java/com/zcloud/service/operatingvehicles/impl/OperatingVehiclesServiceImpl.java b/src/main/java/com/zcloud/service/operatingvehicles/impl/OperatingVehiclesServiceImpl.java index f05eb48..f4f7c02 100644 --- a/src/main/java/com/zcloud/service/operatingvehicles/impl/OperatingVehiclesServiceImpl.java +++ b/src/main/java/com/zcloud/service/operatingvehicles/impl/OperatingVehiclesServiceImpl.java @@ -58,7 +58,7 @@ public class OperatingVehiclesServiceImpl implements OperatingVehiclesService { } @Override - public PageData setScrapStatus(PageData pd) { - return operatingVehiclesMapper.setScrapStatus(pd); + public void setScrapStatus(PageData pd) { + operatingVehiclesMapper.setScrapStatus(pd); } } diff --git a/src/main/resources/mybatis/datasource/enterpriseSafetyProduction/EnterpriseSafetyProductionMapper.xml b/src/main/resources/mybatis/datasource/enterpriseSafetyProduction/EnterpriseSafetyProductionMapper.xml index fc4502b..0a68cf8 100644 --- a/src/main/resources/mybatis/datasource/enterpriseSafetyProduction/EnterpriseSafetyProductionMapper.xml +++ b/src/main/resources/mybatis/datasource/enterpriseSafetyProduction/EnterpriseSafetyProductionMapper.xml @@ -340,6 +340,7 @@ and f.WATCH_DATE LIKE CONCAT(CONCAT('%', #{pd.WATCH_DATE}),'%') + ORDER BY f.OPERATTIME DESC @@ -542,6 +541,7 @@ f where f.CORPINFO_ID = #{corpId} and f.ISDELETE = '0' + and f.ISSCRAP = '0' diff --git a/src/main/resources/mybatis/datasource/reportedIncident/ReportedIncidentMapper.xml b/src/main/resources/mybatis/datasource/reportedIncident/ReportedIncidentMapper.xml index 5d84885..ec90bfb 100644 --- a/src/main/resources/mybatis/datasource/reportedIncident/ReportedIncidentMapper.xml +++ b/src/main/resources/mybatis/datasource/reportedIncident/ReportedIncidentMapper.xml @@ -147,7 +147,6 @@ f.CORPINFO_ID = #{CORPINFO_ID} - diff --git a/src/main/resources/mybatis/datasource/taxationManage/TaxationManageMapper.xml b/src/main/resources/mybatis/datasource/taxationManage/TaxationManageMapper.xml index 352e95d..9034d8b 100644 --- a/src/main/resources/mybatis/datasource/taxationManage/TaxationManageMapper.xml +++ b/src/main/resources/mybatis/datasource/taxationManage/TaxationManageMapper.xml @@ -446,7 +446,7 @@ AND f.TRANSPORT_ENTERPRISES = #{pd.TRANSPORT_ENTERPRISES} ORDER BY f.OPERATTIME DESC - ORDER BY OPERATTIME DESC +