BUG优化

dev
xiepeng 2024-04-08 18:01:44 +08:00
parent 91cef5e03e
commit be0fb252b5
35 changed files with 343 additions and 102 deletions

View File

@ -1,5 +1,6 @@
package com.zcloud.controller.assignedManage; package com.zcloud.controller.assignedManage;
import cn.hutool.core.collection.CollectionUtil;
import com.zcloud.controller.base.BaseController; import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.Page; import com.zcloud.entity.Page;
import com.zcloud.entity.PageData; import com.zcloud.entity.PageData;
@ -8,12 +9,15 @@ import com.zcloud.service.freighttrailer.FreightTrailerService;
import com.zcloud.service.operatingvehicles.OperatingVehiclesService; import com.zcloud.service.operatingvehicles.OperatingVehiclesService;
import com.zcloud.service.system.ImgFilesService; import com.zcloud.service.system.ImgFilesService;
import com.zcloud.util.*; import com.zcloud.util.*;
import org.apache.commons.lang3.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.*; import java.util.*;
import java.util.stream.Collectors;
@Controller @Controller
@RequestMapping("/assignedmanage") @RequestMapping("/assignedmanage")
@ -195,7 +199,6 @@ public class AssignedManageController extends BaseController {
if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim()); if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim());
page.setPd(pd); page.setPd(pd);
List<PageData> varList = assignedManageService.list(page); //列出MajorDangerSource列表 List<PageData> varList = assignedManageService.list(page); //列出MajorDangerSource列表
List<PageData> vehicleList = new ArrayList<>();
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
@ -255,40 +258,26 @@ public class AssignedManageController extends BaseController {
PageData pd = new PageData(); PageData pd = new PageData();
String corpId = Jurisdiction.getCORPINFO_ID(); String corpId = Jurisdiction.getCORPINFO_ID();
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); // 所有过户的车辆
for (int i = 0; i < allAssignedList.size(); i++) { List<PageData> varList = new ArrayList<>();
for (int j = 0; j < allOperatingVehicleList.size(); j++) { if(!CollectionUtil.isEmpty(allAssignedList)) {
if(allAssignedList.get(i).get("RAW_PLATE_NUMBER").equals(allOperatingVehicleList.get(j).get("OPERATING_ID"))) { varList = allOperatingVehicleList.stream().filter(operating -> {
allOperatingVehicleList.remove(j); for (PageData assigned : allAssignedList) {
if(!StringUtils.equals(operating.getString("OPERATING_ID"),assigned.getString("RAW_PLATE_NUMBER"))) {
return true;
}
} }
} return false;
}).collect(Collectors.toList());
}else{
varList = allOperatingVehicleList;
} }
map.put("varList", allOperatingVehicleList); map.put("varList", varList);
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }
/*@RequestMapping(value = "/getassignedfreighttrailerlist")
@ResponseBody
public Object getAssignedFreightTrailerList() throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
String corpId = Jurisdiction.getCORPINFO_ID();
List<PageData> freightList = freightTrailerService.trailerList(corpId);
List<PageData> assignedList = assignedManageService.assignedList(corpId);
for (int i = 0; i < assignedList.size(); i++) {
for (int j = 0; j < freightList.size(); j++) {
if(assignedList.get(i).get("RAW_PLATE_NUMBER").equals(freightList.get(j).get("PLATE_NUMBER"))) {
freightList.remove(j);
}
}
}
map.put("varList", freightList);
map.put("result", errInfo);
return map;
}*/
@RequestMapping(value = "/getAssignedFreightTrailerList") @RequestMapping(value = "/getAssignedFreightTrailerList")
@ResponseBody @ResponseBody
public Object getAssignedFreightTrailerList() throws Exception { public Object getAssignedFreightTrailerList() throws Exception {
@ -297,14 +286,20 @@ 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);
for (int i = 0; i < assignedList.size(); i++) { List<PageData> varList = new ArrayList<>();
for (int j = 0; j < freightList.size(); j++) { if(!CollectionUtils.isEmpty(assignedList)) {
if(assignedList.get(i).get("RAW_PLATE_NUMBER").equals(freightList.get(j).get("FREIGHTTRAILER_ID"))) { varList = freightList.stream().filter(freight -> {
freightList.remove(j); for (PageData assigned : assignedList) {
if(!StringUtils.equals(freight.getString("FREIGHTTRAILER_ID"),assigned.getString("RAW_PLATE_NUMBER"))) {
return true;
}
} }
} return false;
}).collect(Collectors.toList());
}else {
varList = freightList;
} }
map.put("varList", freightList); map.put("varList", varList);
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }

View File

@ -125,4 +125,5 @@ public class TrafficDrivingTypeController extends BaseController {
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }
} }

View File

@ -1,5 +1,6 @@
package com.zcloud.controller.comprehensive; package com.zcloud.controller.comprehensive;
import com.alibaba.excel.util.DateUtils;
import com.zcloud.controller.base.BaseController; import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.Page; import com.zcloud.entity.Page;
import com.zcloud.entity.PageData; import com.zcloud.entity.PageData;
@ -58,7 +59,8 @@ public class TrafficSafetyActivitiesController extends BaseController {
map.put("msg", "文件格式不正确!"); map.put("msg", "文件格式不正确!");
return map; return map;
} }
String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")); //String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
String fileName = file.getOriginalFilename();
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile); smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName); pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
@ -85,6 +87,13 @@ public class TrafficSafetyActivitiesController extends BaseController {
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间 pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业 pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业
pd.put("ISDELETE", "0"); pd.put("ISDELETE", "0");
if(!StringUtils.isEmpty(pd.getString("EXPIRYDATE")) && DateUtil.compareDate(pd.getString("EXPIRYDATE"),DateUtil.getDay())) {
pd.put("VALIDSTATUS","1");
} else if (DateUtil.compareDate(DateUtil.getDay(),pd.getString("EXPIRYDATE"))) {
pd.put("VALIDSTATUS","0");
}
String ffile = DateUtil.getDays(); String ffile = DateUtil.getDays();
if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){ if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){
@ -96,7 +105,7 @@ public class TrafficSafetyActivitiesController extends BaseController {
map.put("msg", "文件格式不正确!"); map.put("msg", "文件格式不正确!");
return map; return map;
} }
String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")); String fileName = file.getOriginalFilename();
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile); smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName); pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
@ -138,6 +147,13 @@ public class TrafficSafetyActivitiesController extends BaseController {
page.setPd(pd); page.setPd(pd);
List<PageData> varList = activeService.listForSafetyActivitieslist(page); List<PageData> varList = activeService.listForSafetyActivitieslist(page);
varList.forEach(active -> {
if(DateUtil.getDay().equals(active.getString("EXPIRYDATE")) || DateUtil.compareDate(active.getString("EXPIRYDATE"),DateUtil.getDay())){
active.put("VALIDSTATUS","1");
} else if (DateUtil.compareDate(DateUtil.getDay(),active.getString("EXPIRYDATE"))) {
active.put("VALIDSTATUS","0");
}
});
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
map.put("result", errInfo); map.put("result", errInfo);

View File

@ -87,6 +87,7 @@ public class TrafficSafetyAssessmentController extends BaseController {
pd.put("ISDELETE", "0"); pd.put("ISDELETE", "0");
String ffile = DateUtil.getDays(); String ffile = DateUtil.getDays();
if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){ if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){
pd.put("COMPLETIONSTATUS", "1"); pd.put("COMPLETIONSTATUS", "1");
String suffixName = file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")+1).toLowerCase(); String suffixName = file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")+1).toLowerCase();
@ -96,13 +97,16 @@ public class TrafficSafetyAssessmentController extends BaseController {
map.put("msg", "文件格式不正确!"); map.put("msg", "文件格式不正确!");
return map; return map;
} }
String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")); // String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
String fileName = file.getOriginalFilename();
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile); smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName); pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date())); pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date()));
} }
safetyAssessmentService.edit(pd); safetyAssessmentService.edit(pd);
map.put("result", errInfo); map.put("result", errInfo);
@ -138,6 +142,13 @@ public class TrafficSafetyAssessmentController extends BaseController {
page.setPd(pd); page.setPd(pd);
List<PageData> varList = safetyAssessmentService.listForSafetyAssessment(page); List<PageData> varList = safetyAssessmentService.listForSafetyAssessment(page);
varList.forEach(safetyAssessment -> {
if(DateUtil.getDay().equals(safetyAssessment.get("EXPIRYDATE")) || DateUtil.compareDate(safetyAssessment.getString("EXPIRYDATE"),DateUtil.getDay())) {
safetyAssessment.put("VALIDSTATUS","1");
} else if (DateUtil.compareDate(DateUtil.getDay(),safetyAssessment.getString("EXPIRYDATE"))) {
safetyAssessment.put("VALIDSTATUS","0");
}
});
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
map.put("result", errInfo); map.put("result", errInfo);

View File

@ -57,7 +57,8 @@ public class TrafficSafetyManualController extends BaseController {
map.put("msg", "文件格式不正确!"); map.put("msg", "文件格式不正确!");
return map; return map;
} }
String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")); //String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
String fileName = file.getOriginalFilename();
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile); smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName); pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
@ -84,6 +85,14 @@ public class TrafficSafetyManualController extends BaseController {
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间 pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业 pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业
pd.put("ISDELETE", "0"); pd.put("ISDELETE", "0");
if(!StringUtils.isEmpty(pd.getString("EXPIRYDATE")) && DateUtil.compareDate(pd.getString("EXPIRYDATE"),DateUtil.getDay())) {
pd.put("VALIDSTATUS","1");
} else if (DateUtil.compareDate(DateUtil.getDay(),pd.getString("EXPIRYDATE"))) {
pd.put("VALIDSTATUS","0");
}
String ffile = DateUtil.getDays(); String ffile = DateUtil.getDays();
if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){ if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){
@ -95,7 +104,8 @@ public class TrafficSafetyManualController extends BaseController {
map.put("msg", "文件格式不正确!"); map.put("msg", "文件格式不正确!");
return map; return map;
} }
String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")); //String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
String fileName = file.getOriginalFilename();
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile); smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName); pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
@ -137,6 +147,13 @@ public class TrafficSafetyManualController extends BaseController {
page.setPd(pd); page.setPd(pd);
List<PageData> varList = safetyManualService.listForSafetyManuallist(page); List<PageData> varList = safetyManualService.listForSafetyManuallist(page);
varList.forEach(manual -> {
if(DateUtil.getDay().equals(manual.getString("EXPIRYDATE")) || DateUtil.compareDate(manual.getString("EXPIRYDATE"),DateUtil.getDay())){
manual.put("VALIDSTATUS","1");
} else if (DateUtil.compareDate(DateUtil.getDay(),manual.getString("EXPIRYDATE"))) {
manual.put("VALIDSTATUS","0");
}
});
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
map.put("result", errInfo); map.put("result", errInfo);

View File

@ -68,14 +68,14 @@ public class TrafficSafetyOccupationalHazardsController extends BaseController {
pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date())); pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date()));
} }
page.setPd(pd); /*page.setPd(pd);
List<PageData> varList = occupationalHazardsService.listForSafetyOccupationalHazardsUser(page); List<PageData> varList = occupationalHazardsService.listForSafetyOccupationalHazardsUser(page);
if (!varList.isEmpty()){ if (!varList.isEmpty()){
for(PageData varPd : varList){ for(PageData varPd : varList){
varPd.put("VALIDSTATUS", "2"); varPd.put("VALIDSTATUS", "2");
occupationalHazardsService.edit(varPd); occupationalHazardsService.edit(varPd);
} }
} }*/
occupationalHazardsService.save(pd); occupationalHazardsService.save(pd);
map.put("result", errInfo); map.put("result", errInfo);
@ -97,8 +97,14 @@ public class TrafficSafetyOccupationalHazardsController extends BaseController {
pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业 pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业
pd.put("ISDELETE", "0"); pd.put("ISDELETE", "0");
pd.put("COMPLETIONSTATUS", "1"); pd.put("COMPLETIONSTATUS", "1");
pd.put("VALIDSTATUS", "1");
pd.put("ISSIGNED", "1"); pd.put("ISSIGNED", "1");
if (DateUtil.compareDate(DateUtil.getDay(), pd.getString("EXPIRYDATE"))) {
pd.put("VALIDSTATUS", "0");
} else {
pd.put("VALIDSTATUS", "1");
}
String ffile = DateUtil.getDays(); String ffile = DateUtil.getDays();
if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){ if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){
@ -155,6 +161,8 @@ public class TrafficSafetyOccupationalHazardsController extends BaseController {
if (Tools.notEmpty(ISSIGNED)) if (Tools.notEmpty(ISSIGNED))
pd.put("ISSIGNED", ISSIGNED.trim()); pd.put("ISSIGNED", ISSIGNED.trim());
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
page.setPd(pd); page.setPd(pd);
List<PageData> varList = occupationalHazardsService.listForSecurityOccupationalHazards(page); List<PageData> varList = occupationalHazardsService.listForSecurityOccupationalHazards(page);
map.put("varList", varList); map.put("varList", varList);
@ -179,6 +187,15 @@ public class TrafficSafetyOccupationalHazardsController extends BaseController {
page.setPd(pd); page.setPd(pd);
List<PageData> varList = occupationalHazardsService.listForSafetyOccupationalHazardsUser(page); List<PageData> varList = occupationalHazardsService.listForSafetyOccupationalHazardsUser(page);
varList.forEach(occupational -> {
if(DateUtil.getDay().equals(occupational.getString("EXPIRYDATE"))) {
occupational.put("VALIDSTATUS", "1");
} else if(DateUtil.compareDate(DateUtil.getDay(), occupational.getString("EXPIRYDATE"))) {
occupational.put("VALIDSTATUS", "2");
}else{
occupational.put("VALIDSTATUS", "1");
}
});
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
map.put("result", errInfo); map.put("result", errInfo);
@ -218,4 +235,18 @@ public class TrafficSafetyOccupationalHazardsController extends BaseController {
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }
@RequestMapping(value="/getSafetyOccupationalHazardsEdit")
@ResponseBody
public Object getSafetyOccupationalHazardsEdit() throws Exception{
Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
List<PageData> varList = occupationalHazardsService.getSafetyOccupationalHazardsEdit(pd); //根据ID读取
map.put("varList", varList);
map.put("result", errInfo);
return map;
}
} }

View File

@ -42,7 +42,7 @@ public class TrafficSafetyProductionController extends BaseController {
pd.put("ISDELETE", "0"); pd.put("ISDELETE", "0");
if (DateUtil.compareDate(DateUtil.getDay(), pd.getString("EXPIRYDATE"))) { if (DateUtil.compareDate(DateUtil.getDay(), pd.getString("EXPIRYDATE"))) {
pd.put("VALIDSTATUS", "0"); pd.put("VALIDSTATUS", "2");
} else { } else {
pd.put("VALIDSTATUS", "1"); pd.put("VALIDSTATUS", "1");
} }
@ -57,11 +57,16 @@ public class TrafficSafetyProductionController extends BaseController {
map.put("msg", "文件格式不正确!"); map.put("msg", "文件格式不正确!");
return map; return map;
} }
String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")); String fileName = file.getOriginalFilename();
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile); smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName); pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date())); pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date()));
/*String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date()));*/
} }
safetyProductionService.save(pd); safetyProductionService.save(pd);
@ -84,6 +89,13 @@ public class TrafficSafetyProductionController extends BaseController {
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间 pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业 pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业
pd.put("ISDELETE", "0"); pd.put("ISDELETE", "0");
if (DateUtil.compareDate(DateUtil.getDay(), pd.getString("EXPIRYDATE"))) {
pd.put("VALIDSTATUS", "2");
} else {
pd.put("VALIDSTATUS", "1");
}
String ffile = DateUtil.getDays(); String ffile = DateUtil.getDays();
if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){ if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){
@ -95,7 +107,8 @@ public class TrafficSafetyProductionController extends BaseController {
map.put("msg", "文件格式不正确!"); map.put("msg", "文件格式不正确!");
return map; return map;
} }
String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(".")); // String fileName = this.get32UUID() + file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
String fileName = file.getOriginalFilename();
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile); smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile);
pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName); pd.put("ATTACHMENT_ROUTE", Const.FILEPATHFILE + pd.getString("OPERATINGCOMPANY") + "/" + ffile + "/" + fileName);
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
@ -137,6 +150,15 @@ public class TrafficSafetyProductionController extends BaseController {
page.setPd(pd); page.setPd(pd);
List<PageData> varList = safetyProductionService.listForSafetyProductionlist(page); List<PageData> varList = safetyProductionService.listForSafetyProductionlist(page);
varList.forEach(safetyProduction -> {
if(DateUtil.getDay().equals(safetyProduction.getString("EXPIRYDATE"))) {
safetyProduction.put("VALIDSTATUS", "1");
} else if(DateUtil.compareDate(DateUtil.getDay(), safetyProduction.getString("EXPIRYDATE"))) {
safetyProduction.put("VALIDSTATUS", "2");
}else{
safetyProduction.put("VALIDSTATUS", "1");
}
});
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
map.put("result", errInfo); map.put("result", errInfo);
@ -176,4 +198,18 @@ public class TrafficSafetyProductionController extends BaseController {
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }
@RequestMapping(value="/getSafetyProductionEdit")
@ResponseBody
public Object getSafetyProductionEdit() throws Exception{
Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
List<PageData> varList = safetyProductionService.getSafetyProductionEdit(pd); //根据ID读取
map.put("varList", varList);
map.put("result", errInfo);
return map;
}
} }

View File

@ -66,14 +66,14 @@ public class TrafficSafetyResponsibilityController extends BaseController {
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date())); pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date()));
} }
page.setPd(pd); /*page.setPd(pd);
List<PageData> varList = responseService.listForSafetyResponsibilityUser(page); List<PageData> varList = responseService.listForSafetyResponsibilityUser(page);
if (!varList.isEmpty()){ if (!varList.isEmpty()){
for(PageData varPd : varList){ for(PageData varPd : varList){
varPd.put("VALIDSTATUS", "2"); varPd.put("VALIDSTATUS", "2");
responseService.edit(varPd); responseService.edit(varPd);
} }
} }*/
responseService.save(pd); responseService.save(pd);
map.put("result", errInfo); map.put("result", errInfo);
@ -93,6 +93,12 @@ public class TrafficSafetyResponsibilityController extends BaseController {
pd.put("OPERATORNAME", Jurisdiction.getName()); // 修改人姓名 pd.put("OPERATORNAME", Jurisdiction.getName()); // 修改人姓名
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间 pd.put("OPERATTIME", DateUtil.date2Str(new Date())); // 修改时间
pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业 pd.put("OPERATINGCOMPANY", Jurisdiction.getCORPINFO_ID()); // 经营企业
if (DateUtil.compareDate(DateUtil.getDay(), pd.getString("EXPIRYDATE"))) {
pd.put("VALIDSTATUS", "0");
} else {
pd.put("VALIDSTATUS", "1");
}
String ffile = DateUtil.getDays(); String ffile = DateUtil.getDays();
if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){ if (file != null && StringUtils.isNotBlank(pd.getString("OPERATORNAME"))){
@ -149,6 +155,8 @@ public class TrafficSafetyResponsibilityController extends BaseController {
if (Tools.notEmpty(ISSIGNED)) if (Tools.notEmpty(ISSIGNED))
pd.put("ISSIGNED", ISSIGNED.trim()); pd.put("ISSIGNED", ISSIGNED.trim());
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
page.setPd(pd); page.setPd(pd);
List<PageData> varList = responseService.listForSecurityResponsibility(page); List<PageData> varList = responseService.listForSecurityResponsibility(page);
map.put("varList", varList); map.put("varList", varList);
@ -187,6 +195,15 @@ public class TrafficSafetyResponsibilityController extends BaseController {
page.setPd(pd); page.setPd(pd);
List<PageData> varList = responseService.listForSafetyResponsibilityUser(page); List<PageData> varList = responseService.listForSafetyResponsibilityUser(page);
varList.forEach(response -> {
if(DateUtil.getDay().equals(response.getString("EXPIRYDATE"))) {
response.put("VALIDSTATUS", "1");
} else if(DateUtil.compareDate(DateUtil.getDay(), response.getString("EXPIRYDATE"))) {
response.put("VALIDSTATUS", "2");
}else{
response.put("VALIDSTATUS", "1");
}
});
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
map.put("result", errInfo); map.put("result", errInfo);

View File

@ -66,14 +66,6 @@ public class TrafficSecurityCommitmentController extends BaseController {
pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME")); pd.put("ATTACHMENT_NAME",pd.getString("CREATORNAME"));
pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date())); pd.put("CONFIRM_MESSAGE_TIME",DateUtil.date2Str(new Date()));
} }
page.setPd(pd);
List<PageData> varList = securityCommitmentService.listForSecurityCommitmentUser(page);
if (!varList.isEmpty()){
for(PageData varPd : varList){
varPd.put("VALIDSTATUS", "2");
securityCommitmentService.edit(varPd);
}
}
securityCommitmentService.save(pd); securityCommitmentService.save(pd);
map.put("result", errInfo); map.put("result", errInfo);
map.put("pd", pd); map.put("pd", pd);
@ -155,6 +147,8 @@ public class TrafficSecurityCommitmentController extends BaseController {
if (Tools.notEmpty(ISSIGNED)) if (Tools.notEmpty(ISSIGNED))
pd.put("ISSIGNED", ISSIGNED.trim()); pd.put("ISSIGNED", ISSIGNED.trim());
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
page.setPd(pd); page.setPd(pd);
List<PageData> varList = securityCommitmentService.listForSecurityCommitment(page); List<PageData> varList = securityCommitmentService.listForSecurityCommitment(page);
map.put("varList", varList); map.put("varList", varList);
@ -179,7 +173,9 @@ public class TrafficSecurityCommitmentController extends BaseController {
page.setPd(pd); page.setPd(pd);
List<PageData> varList = securityCommitmentService.listForSecurityCommitmentUser(page); List<PageData> varList = securityCommitmentService.listForSecurityCommitmentUser(page);
varList.forEach(securityCommitment -> { varList.forEach(securityCommitment -> {
if(DateUtil.compareDate(DateUtil.getDay(), securityCommitment.getString("EXPIRYDATE"))) { if(DateUtil.getDay().equals(securityCommitment.getString("EXPIRYDATE"))) {
securityCommitment.put("VALIDSTATUS", "1");
} else if(DateUtil.compareDate(DateUtil.getDay(), securityCommitment.getString("EXPIRYDATE"))) {
securityCommitment.put("VALIDSTATUS", "2"); securityCommitment.put("VALIDSTATUS", "2");
}else{ }else{
securityCommitment.put("VALIDSTATUS", "1"); securityCommitment.put("VALIDSTATUS", "1");

View File

@ -140,6 +140,15 @@ public class TrafficSecurityManagementAgreementController extends BaseController
page.setPd(pd); page.setPd(pd);
List<PageData> varList = managementAgreementService.listForManagementAgreementlist(page); List<PageData> varList = managementAgreementService.listForManagementAgreementlist(page);
varList.forEach(data -> {
if(DateUtil.getDay().equals(data.getString("EXPIRYDATE"))) {
data.put("VALIDSTATUS","1");
} else if(DateUtil.compareDate( DateUtil.getDay(),data.getString("EXPIRYDATE")) ) {
data.put("VALIDSTATUS","0");
} else if (DateUtil.compareDate( data.getString("EXPIRYDATE"),DateUtil.getDay()) || DateUtil.getDay().equals(data.getString("EXPIRYDATE"))) {
data.put("VALIDSTATUS","1");
}
});
map.put("varList", varList); map.put("varList", varList);
map.put("page", page); map.put("page", page);
map.put("result", errInfo); map.put("result", errInfo);

View File

@ -13,6 +13,7 @@ import com.zcloud.util.Jurisdiction;
import com.zcloud.util.ObjectExcelView; import com.zcloud.util.ObjectExcelView;
import com.zcloud.util.Tools; import com.zcloud.util.Tools;
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;
@ -20,6 +21,7 @@ import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.ModelAndView; import org.springframework.web.servlet.ModelAndView;
import java.util.*; import java.util.*;
import java.util.stream.Collectors;
/** /**
* *
@ -157,11 +159,13 @@ public class InspectAnnuallyController 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 = inspectAnnuallyService.list(page); //列出Question列表 List<PageData> varList = inspectAnnuallyService.list(page); //列出年检列表
varList.forEach(inspectAnnually -> { varList.forEach(inspectAnnually -> {
if("1".equals(inspectAnnually.get("OPEAR_ISSCRAP")) || "1".equals(inspectAnnually.get("FREIGHT_ISSCRAP"))) { boolean isScrapFlag = varList.stream().anyMatch(data -> "1".equals(inspectAnnually.get("OPEAR_ISSCRAP")) || "1".equals(inspectAnnually.get("FREIGHT_ISSCRAP")));
boolean isAssignedFlag = varList.stream().anyMatch(data -> "1".equals(inspectAnnually.get("OPEAR_ISASSIGNED")) || "1".equals(inspectAnnually.get("FREIGHT_ISASSIGNED")));
if(isScrapFlag) {
inspectAnnually.put("ARCHIVES_TYPE","2"); inspectAnnually.put("ARCHIVES_TYPE","2");
} else if ("1".equals(inspectAnnually.get("OPEAR_ISASSIGNED")) || "1".equals(inspectAnnually.get("FREIGHT_ISASSIGNED"))) { } else if (isAssignedFlag) {
inspectAnnually.put("ARCHIVES_TYPE","1"); inspectAnnually.put("ARCHIVES_TYPE","1");
} }
}); });

View File

@ -166,7 +166,7 @@ public class OperatingVehiclesController extends BaseController {
List<PageData> headstockphoto = imgfilesService.listAll(pd);//车头照片 List<PageData> headstockphoto = imgfilesService.listAll(pd);//车头照片
pd.put("TYPE",121); pd.put("TYPE",121);
List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片 List<PageData> drivingLicenseImgs = imgfilesService.listAll(pd);//行驶证照片
pd.put("TYPE",132); pd.put("TYPE",122);
List<PageData> operatingcertificatephoto = imgfilesService.listAll(pd);//运营证照片 List<PageData> operatingcertificatephoto = imgfilesService.listAll(pd);//运营证照片
List<PageData> zdepartmentPdList = new ArrayList<PageData>(); List<PageData> zdepartmentPdList = new ArrayList<PageData>();

View File

@ -9,6 +9,8 @@ import com.zcloud.service.freighttrailer.FreightTrailerService;
import com.zcloud.service.operatingvehicles.OperatingVehiclesService; import com.zcloud.service.operatingvehicles.OperatingVehiclesService;
import com.zcloud.service.scrapManage.ScrapManageService; import com.zcloud.service.scrapManage.ScrapManageService;
import com.zcloud.util.*; import com.zcloud.util.*;
import org.apache.commons.lang3.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.util.ObjectUtils; import org.springframework.util.ObjectUtils;
@ -17,10 +19,8 @@ import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import java.util.Date; import java.util.*;
import java.util.HashMap; import java.util.stream.Collectors;
import java.util.List;
import java.util.Map;
@Controller @Controller
@RequestMapping("/scrapmanage") @RequestMapping("/scrapmanage")
@ -211,38 +211,24 @@ 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);
for (int i = 0; i < scrapList.size(); i++) { List<PageData> varList = new ArrayList<>();
for (int j = 0; j < operationList.size(); j++) { if(!CollectionUtils.isEmpty(scrapList)) {
if(scrapList.get(i).get("PLATE_NUMBER").equals(operationList.get(j).get("PLATE_NUMBER"))) { varList = operationList.stream().filter(operation -> {
operationList.remove(j); for (PageData scrap : scrapList) {
if(StringUtils.equals(operation.getString("PLATE_NUMBER"),scrap.getString("PLATE_NUMBER"))) {
return true;
}
} }
} return false;
}).collect(Collectors.toList());
}else {
varList = operationList;
} }
map.put("varList", operationList); map.put("varList", varList);
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }
/*@RequestMapping(value = "/getscrapfreighttrailerlist")
@ResponseBody
public Object getScrapFreightTrailerList() throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
String corpId = Jurisdiction.getCORPINFO_ID();
List<PageData> freightList = freightTrailerService.trailerList(corpId);
List<PageData> scrapList = scrapManageService.scrapListAll(corpId);
for (int i = 0; i < scrapList.size(); i++) {
for (int j = 0; j < freightList.size(); j++) {
if(scrapList.get(i).get("PLATE_NUMBER").equals(freightList.get(j).get("PLATE_NUMBER"))) {
freightList.remove(j);
}
}
}
map.put("varList", freightList);
map.put("result", errInfo);
return map;
}*/
@RequestMapping(value = "/getScrapFreightTrailerList") @RequestMapping(value = "/getScrapFreightTrailerList")
@ResponseBody @ResponseBody
public Object getAssignedFreightTrailerList() throws Exception { public Object getAssignedFreightTrailerList() throws Exception {
@ -251,14 +237,20 @@ 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);
for (int i = 0; i < scrapList.size(); i++) { List<PageData> varList = new ArrayList<>();
for (int j = 0; j < freightList.size(); j++) { if(!CollectionUtils.isEmpty(scrapList)) {
if(scrapList.get(i).get("PLATE_NUMBER").equals(freightList.get(j).get("PLATE_NUMBER"))) { varList = freightList.stream().filter(freight -> {
freightList.remove(j); for (PageData scrap : scrapList) {
if(StringUtils.equals(freight.getString("PLATE_NUMBER"),scrap.getString("PLATE_NUMBER"))){
return true;
}
} }
} return false;
}).collect(Collectors.toList());
}else{
varList = freightList;
} }
map.put("varList", freightList); map.put("varList", varList);
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }

View File

@ -2984,4 +2984,35 @@ public class UsersController extends BaseController {
map.put("result", errInfo); map.put("result", errInfo);
return map; return map;
} }
@RequestMapping("/getTrafficPenaltyUserList")
@ResponseBody
public Object getTrafficPenaltyUserList(Page page) throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
/*检索条件*/
String ROLE_ID = pd.getString("ROLE_ID"); //角色ID
String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件
if (Tools.notEmpty(KEYWORDS)) pd.put("KEYWORDS", KEYWORDS.trim());
String DEPARTMENT_ID = pd.getString("DEPARTMENT_ID"); //关键词检索条件
if (Tools.notEmpty(DEPARTMENT_ID)) pd.put("DEPARTMENT_ID", DEPARTMENT_ID.trim());
String STARTTIME = pd.getString("STARTTIME"); //开始时间
String ENDTIME = pd.getString("ENDTIME"); //结束时间
if (Tools.notEmpty(STARTTIME)) pd.put("STARTTIME", STARTTIME + " 00:00:00");
if (Tools.notEmpty(ENDTIME)) pd.put("ENDTIME", ENDTIME + " 00:00:00");
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
page.setPd(pd);
Object practitionerPage = this.getPractitionerPage(page);//列出用户列表
map.put("userList", practitionerPage);
map.put("page", page);
map.put("pd", pd);
map.put("result", errInfo);
return map;
}
} }

View File

@ -19,4 +19,6 @@ public interface TrafficSafetyOccupationalHazardsMapper {
List<PageData> datalistPageUser(Page page); List<PageData> datalistPageUser(Page page);
void delete(PageData pd); void delete(PageData pd);
List<PageData> getSafetyOccupationalHazardsEdit(PageData pd);
} }

View File

@ -17,4 +17,6 @@ public interface TrafficSafetyProductionMapper {
PageData findById(PageData pd); PageData findById(PageData pd);
void delete(PageData pd); void delete(PageData pd);
List<PageData> getSafetyProductionEdit(PageData pd);
} }

View File

@ -297,4 +297,5 @@ public interface UsersMapper {
List<PageData> userSelectPersonTypelist(PageData pd); List<PageData> userSelectPersonTypelist(PageData pd);
PageData getUserByUserId(PageData pd); PageData getUserByUserId(PageData pd);
} }

View File

@ -31,4 +31,5 @@ public interface TrafficDrivingTypeService {
void delete(PageData pd); void delete(PageData pd);
PageData findById(PageData pd) throws Exception; PageData findById(PageData pd) throws Exception;
} }

View File

@ -17,4 +17,6 @@ public interface TrafficSafetyOccupationalHazardsService {
List<PageData> listForSafetyOccupationalHazardsUser(Page page); List<PageData> listForSafetyOccupationalHazardsUser(Page page);
void delete(PageData pd); void delete(PageData pd);
List<PageData> getSafetyOccupationalHazardsEdit(PageData pd);
} }

View File

@ -15,4 +15,6 @@ public interface TrafficSafetyProductionService {
PageData findById(PageData pd); PageData findById(PageData pd);
void delete(PageData pd); void delete(PageData pd);
List<PageData> getSafetyProductionEdit(PageData pd);
} }

View File

@ -62,6 +62,8 @@ public class TrafficDrivingTypeServiceImpl implements TrafficDrivingTypeService
public PageData findById(PageData pd) { public PageData findById(PageData pd) {
return trafficDrivingTypeMapper.findById(pd); return trafficDrivingTypeMapper.findById(pd);
} }
@Autowired @Autowired
private TrafficDrivingSignMapper trafficDrivingSignMapper; private TrafficDrivingSignMapper trafficDrivingSignMapper;

View File

@ -43,4 +43,9 @@ public class TrafficSafetyOccupationalHazardsServiceImpl implements TrafficSafet
public void delete(PageData pd) { public void delete(PageData pd) {
occupationalHazardsMapper.delete(pd); occupationalHazardsMapper.delete(pd);
} }
@Override
public List<PageData> getSafetyOccupationalHazardsEdit(PageData pd) {
return occupationalHazardsMapper.getSafetyOccupationalHazardsEdit(pd);
}
} }

View File

@ -37,4 +37,9 @@ public class TrafficSafetyProductionServiceImpl implements TrafficSafetyProducti
public void delete(PageData pd) { public void delete(PageData pd) {
speedProductionMapper.delete(pd); speedProductionMapper.delete(pd);
} }
@Override
public List<PageData> getSafetyProductionEdit(PageData pd) {
return speedProductionMapper.getSafetyProductionEdit(pd);
}
} }

View File

@ -370,4 +370,5 @@ public interface UsersService {
List<PageData> userSelectPersonTypelist(PageData pd); List<PageData> userSelectPersonTypelist(PageData pd);
PageData getUserByUserId(PageData pd); PageData getUserByUserId(PageData pd);
} }

View File

@ -1340,4 +1340,5 @@ public class UsersServiceImpl implements UsersService {
return usersMapper.getUserByUserId(pd); return usersMapper.getUserByUserId(pd);
} }
} }

View File

@ -96,9 +96,13 @@
OPERATOR = #{OPERATOR}, OPERATOR = #{OPERATOR},
OPERATORNAME = #{OPERATORNAME}, OPERATORNAME = #{OPERATORNAME},
OPERATTIME = #{OPERATTIME}, OPERATTIME = #{OPERATTIME},
ACTIVITIESNAME = #{ACTIVITIESNAME},
EXPIRYDATE = #{EXPIRYDATE}, EXPIRYDATE = #{EXPIRYDATE},
CYCLE = #{CYCLE}, CYCLE = #{CYCLE},
ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE} ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE}
<if test="VALIDSTATUS != null">
,VALIDSTATUS = #{VALIDSTATUS}
</if>
where where
ACTIVITIES_ID = #{ACTIVITIES_ID} ACTIVITIES_ID = #{ACTIVITIES_ID}
</update> </update>

View File

@ -97,7 +97,7 @@
OPERATORNAME = #{OPERATORNAME}, OPERATORNAME = #{OPERATORNAME},
OPERATTIME = #{OPERATTIME}, OPERATTIME = #{OPERATTIME},
EXPIRYDATE = #{EXPIRYDATE}, EXPIRYDATE = #{EXPIRYDATE},
ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE}, ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE}
<if test="VALIDSTATUS != null"> <if test="VALIDSTATUS != null">
,VALIDSTATUS = #{VALIDSTATUS} ,VALIDSTATUS = #{VALIDSTATUS}
</if> </if>
@ -135,6 +135,7 @@
<if test="pd.VALIDSTATUS != null and pd.VALIDSTATUS != ''"><!-- 关键词检索-有效状态 --> <if test="pd.VALIDSTATUS != null and pd.VALIDSTATUS != ''"><!-- 关键词检索-有效状态 -->
and f.VALIDSTATUS = #{pd.VALIDSTATUS} and f.VALIDSTATUS = #{pd.VALIDSTATUS}
</if> </if>
ORDER BY f.OPERATTIME DESC
</select> </select>
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="com.zcloud.entity.PageData"> <select id="findById" resultType="com.zcloud.entity.PageData" parameterType="com.zcloud.entity.PageData">

View File

@ -93,8 +93,12 @@
OPERATOR = #{OPERATOR}, OPERATOR = #{OPERATOR},
OPERATORNAME = #{OPERATORNAME}, OPERATORNAME = #{OPERATORNAME},
OPERATTIME = #{OPERATTIME}, OPERATTIME = #{OPERATTIME},
MANUALNAME = #{MANUALNAME},
EXPIRYDATE = #{EXPIRYDATE}, EXPIRYDATE = #{EXPIRYDATE},
ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE} ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE}
<if test="VALIDSTATUS != null">
,VALIDSTATUS = #{VALIDSTATUS}
</if>
where where
MANUAL_ID = #{MANUAL_ID} MANUAL_ID = #{MANUAL_ID}
</update> </update>

View File

@ -141,6 +141,7 @@
left join bus_corp_info i on u.CORPINFO_ID = i.CORPINFO_ID left join bus_corp_info i on u.CORPINFO_ID = i.CORPINFO_ID
left join BUS_TRAFFIC_OCCUPATIONAL_HAZARDS c on u.USER_ID = c.USER_ID and c.ISDELETE !='1' left join BUS_TRAFFIC_OCCUPATIONAL_HAZARDS c on u.USER_ID = c.USER_ID and c.ISDELETE !='1'
where u.ISDELETE = '0' where u.ISDELETE = '0'
and u.CORPINFO_ID = #{pd.CORPINFO_ID}
and u.ISMAIN != '1' and u.ISMAIN != '1'
and (c.VALIDSTATUS != '2' or c.VALIDSTATUS is null) and (c.VALIDSTATUS != '2' or c.VALIDSTATUS is null)
<if test="pd.OCCUPATIONALNAME != null and pd.OCCUPATIONALNAME != ''"><!-- 关键词检索-名称 --> <if test="pd.OCCUPATIONALNAME != null and pd.OCCUPATIONALNAME != ''"><!-- 关键词检索-名称 -->
@ -177,5 +178,34 @@
<if test="pd.USER_ID != null and pd.USER_ID != ''"> <if test="pd.USER_ID != null and pd.USER_ID != ''">
and f.USER_ID = #{pd.USER_ID} and f.USER_ID = #{pd.USER_ID}
</if> </if>
ORDER BY f.OPERATTIME DESC
</select>
<!--列表-->
<select id="getSafetyOccupationalHazardsEdit" parameterType="page" resultType="pd">
select
u.NAME,
u.USER_ID,
i.CORP_NAME,
f.OCCUPATIONALNAME,
f.COMPLETIONSTATUS,
f.VALIDSTATUS,
f.EXPIRYDATE,
f.CONTENT,
f.CREATETIME,
f.OPERATTIME,
f.ATTACHMENT_ROUTE,
f.OCCUPATIONALHAZARDS_ID
from
<include refid="tableName"></include> f
left join sys_user u ON u.USER_ID = f.USER_ID and f.ISDELETE !='1'
left JOIN bus_corp_info i ON u.CORPINFO_ID = i.CORPINFO_ID
WHERE
u.ISDELETE = '0'
and (f.ISDELETE='0' or f.ISDELETE is null )
AND u.ISMAIN != '1'
AND ( f.VALIDSTATUS != '2' OR f.VALIDSTATUS IS NULL )
and f.OCCUPATIONALHAZARDS_ID = #{OCCUPATIONALHAZARDS_ID}
</select> </select>
</mapper> </mapper>

View File

@ -96,6 +96,7 @@
OPERATOR = #{OPERATOR}, OPERATOR = #{OPERATOR},
OPERATORNAME = #{OPERATORNAME}, OPERATORNAME = #{OPERATORNAME},
OPERATTIME = #{OPERATTIME}, OPERATTIME = #{OPERATTIME},
EXPIRYDATE = #{EXPIRYDATE},
ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE} ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE}
where where
SAFETYPRODUCTION_ID = #{SAFETYPRODUCTION_ID} SAFETYPRODUCTION_ID = #{SAFETYPRODUCTION_ID}
@ -131,7 +132,7 @@
<if test="pd.VALIDSTATUS != null and pd.VALIDSTATUS != ''"><!-- 关键词检索-有效状态 --> <if test="pd.VALIDSTATUS != null and pd.VALIDSTATUS != ''"><!-- 关键词检索-有效状态 -->
and f.VALIDSTATUS = #{pd.VALIDSTATUS} and f.VALIDSTATUS = #{pd.VALIDSTATUS}
</if> </if>
ORDER BY f.CREATETIME DESC ORDER BY f.OPERATTIME DESC
</select> </select>
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="com.zcloud.entity.PageData"> <select id="findById" resultType="com.zcloud.entity.PageData" parameterType="com.zcloud.entity.PageData">
@ -142,4 +143,19 @@
where where
f.SAFETYPRODUCTION_ID = #{SAFETYPRODUCTION_ID} f.SAFETYPRODUCTION_ID = #{SAFETYPRODUCTION_ID}
</select> </select>
<!--列表-->
<select id="getSafetyProductionEdit" parameterType="page" resultType="pd">
select
f.*,
i.CORP_NAME
from
<include refid="tableName"></include> f
left join bus_corp_info i on f.OPERATINGCOMPANY = i.CORPINFO_ID
WHERE
f.ISDELETE = '0'
AND f.VALIDSTATUS IS NOT NULL
and f.SAFETYPRODUCTION_ID = #{SAFETYPRODUCTION_ID}
</select>
</mapper> </mapper>

View File

@ -141,6 +141,7 @@
left join bus_corp_info i on u.CORPINFO_ID = i.CORPINFO_ID left join bus_corp_info i on u.CORPINFO_ID = i.CORPINFO_ID
left join BUS_TRAFFIC_SAFETY_RESPONSIBILITY c on u.USER_ID = c.USER_ID and c.ISDELETE !='1' left join BUS_TRAFFIC_SAFETY_RESPONSIBILITY c on u.USER_ID = c.USER_ID and c.ISDELETE !='1'
where u.ISDELETE = '0' where u.ISDELETE = '0'
and u.CORPINFO_ID = #{pd.CORPINFO_ID}
and u.ISMAIN != '1' and u.ISMAIN != '1'
and (c.VALIDSTATUS != '2' or c.VALIDSTATUS is null) and (c.VALIDSTATUS != '2' or c.VALIDSTATUS is null)
<if test="pd.RESPONSIBILITYNAME != null and pd.RESPONSIBILITYNAME != ''"><!-- 关键词检索-制度名称 --> <if test="pd.RESPONSIBILITYNAME != null and pd.RESPONSIBILITYNAME != ''"><!-- 关键词检索-制度名称 -->
@ -177,6 +178,7 @@
<if test="pd.USER_ID != null and pd.USER_ID != ''"> <if test="pd.USER_ID != null and pd.USER_ID != ''">
and f.USER_ID = #{pd.USER_ID} and f.USER_ID = #{pd.USER_ID}
</if> </if>
ORDER BY f.OPERATTIME DESC
</select> </select>
<!--列表--> <!--列表-->

View File

@ -112,7 +112,7 @@
,VALIDSTATUS = #{VALIDSTATUS} ,VALIDSTATUS = #{VALIDSTATUS}
</if> </if>
where where
SECURITYCOMMITMENT_ID = #{SECURITYCOMMITMENT_ID} SECURITYCOMMITMENT_ID = #{SECURITYCOMMITMENT_ID}
</update> </update>
<!-- 删除--> <!-- 删除-->
@ -149,6 +149,7 @@
left JOIN BUS_TRAFFIC_SECURITY_COMMITMENT c ON u.USER_ID = c.USER_ID and c.ISDELETE !='1' left JOIN BUS_TRAFFIC_SECURITY_COMMITMENT c ON u.USER_ID = c.USER_ID and c.ISDELETE !='1'
WHERE WHERE
u.ISDELETE = '0' u.ISDELETE = '0'
and u.CORPINFO_ID = #{pd.CORPINFO_ID}
and (c.ISDELETE='0' or c.ISDELETE is null ) and (c.ISDELETE='0' or c.ISDELETE is null )
AND u.ISMAIN != '1' AND u.ISMAIN != '1'
AND ( c.VALIDSTATUS != '2' OR c.VALIDSTATUS IS NULL ) AND ( c.VALIDSTATUS != '2' OR c.VALIDSTATUS IS NULL )
@ -213,7 +214,7 @@
u.ISDELETE = '0' u.ISDELETE = '0'
and (f.ISDELETE='0' or f.ISDELETE is null ) and (f.ISDELETE='0' or f.ISDELETE is null )
AND u.ISMAIN != '1' AND u.ISMAIN != '1'
AND ( f.VALIDSTATUS != '2' OR f.VALIDSTATUS IS NULL ) AND f.VALIDSTATUS IS NOT NULL
and f.SECURITYCOMMITMENT_ID = #{SECURITYCOMMITMENT_ID} and f.SECURITYCOMMITMENT_ID = #{SECURITYCOMMITMENT_ID}
and f.USER_ID = #{USER_ID} and f.USER_ID = #{USER_ID}
</select> </select>

View File

@ -97,6 +97,7 @@
OPERATOR = #{OPERATOR}, OPERATOR = #{OPERATOR},
OPERATORNAME = #{OPERATORNAME}, OPERATORNAME = #{OPERATORNAME},
OPERATTIME = #{OPERATTIME}, OPERATTIME = #{OPERATTIME},
MANAGEMENTAGREEMENTNAME = #{MANAGEMENTAGREEMENTNAME},
EXPIRYDATE = #{EXPIRYDATE}, EXPIRYDATE = #{EXPIRYDATE},
ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE} ATTACHMENT_ROUTE=#{ATTACHMENT_ROUTE}
where where

View File

@ -598,10 +598,11 @@
v.PLATE_NUMBER v.PLATE_NUMBER
from from
<include refid="tableName"></include> f <include refid="tableName"></include> f
INNER JOIN v_traffic v on v.ID = f.OPERATING_ID LEFT JOIN v_traffic v on v.ID = f.OPERATING_ID
where where
f.CORPINFO_ID = #{corpId} f.CORPINFO_ID = #{corpId}
and f.ISDELETE = '0' and f.ISSCRAP = '0' AND (f.ISDELETE = '0' OR f.ISDELETE IS NULL)
AND (f.ISSCRAP = '0' OR f.ISSCRAP IS NULL)
</select> </select>
<!-- 所属企业列表 --> <!-- 所属企业列表 -->

View File

@ -1838,4 +1838,5 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where where
USER_ID = #{USER_ID} USER_ID = #{USER_ID}
</update> </update>
</mapper> </mapper>