Merge remote-tracking branch 'origin/dev' into dev

pull/4/head
chenxinying 2024-02-01 08:27:54 +08:00
commit 94ac88f6fc
41 changed files with 12954 additions and 266 deletions

View File

@ -56,7 +56,7 @@ public class AppListManagerController extends BaseController {
*/
@RequestMapping(value = "/checkList")
@ResponseBody
@LogAnno(menuType = "手机", menuServer = "隐患排查", instructionsOperate = "清单管理", instructionsType = "列表")
@LogAnno(menuType = "手机", menuServer = "风险排查", instructionsOperate = "清单管理", instructionsType = "列表")
public Object checkList() throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";

View File

@ -0,0 +1,433 @@
package com.zcloud.controller.hiddenDangerCheckStandard;
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.check.*;
import com.zcloud.service.hiddenDangerCheckStandard.CustomCheckRecordItemService;
import com.zcloud.service.hiddenDangerCheckStandard.CustomCheckRecordService;
import com.zcloud.service.hiddenDangerCheckStandard.CustomItemService;
import com.zcloud.service.hiddenDangerCheckStandard.CustomService;
import com.zcloud.service.offduty.OffDutyService;
import com.zcloud.service.risk.IdentificationPartsService;
import com.zcloud.service.risk.RiskPointService;
import com.zcloud.service.statistics.ListStatisticsService;
import com.zcloud.service.system.DepartmentService;
import com.zcloud.service.system.UsersService;
import com.zcloud.util.DateUtil;
import com.zcloud.util.Jurisdiction;
import com.zcloud.util.Tools;
import com.zcloud.util.Warden;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* -
* luoxiaobao
* 2020-12-30
* www.zcloudchina.com
*/
@Controller
@RequestMapping("/app/hiddenDangerCheckStandardCustom")
public class AppCustomController extends BaseController {
@Autowired
private CustomService customService;
@Autowired
private CustomItemService customItemService;
@Autowired
private ListCheckItemService listcheckitemService;
@Autowired
private DepartmentService departmentService;
@Autowired
private CustomCheckRecordService customCheckRecordService;
@Autowired
private CustomCheckRecordItemService customCheckRecordItemService;
@Autowired
private RiskPointService riskpointService;
@Autowired
private ListStatisticsService listStatisticsService;
@Autowired
private IdentificationPartsService identificationPartsService;
@Autowired
private ListDisableTimeService listdisabletimeService;
@Autowired
private CheckRouteService checkRouteService;
@Autowired
private UsersService usersService;
@Autowired
private OffDutyService offdutyService;
/**
*
*
* @throws Exception
*/
@RequestMapping(value = "/checkList")
@ResponseBody
@LogAnno(menuType = "手机", menuServer = "隐患排查", instructionsOperate = "清单管理", instructionsType = "列表")
public Object checkList() throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
String USER_NAME = pd.getString("USER_NAME");
PageData cpd = new PageData();
cpd = usersService.findById(pd);
pd.put("ISLEADER", cpd.getString("ISLEADER"));
PageData dept = new PageData();
dept.put("DEPARTMENT_ID", pd.getString("CHECK_DEPARTMENT_ID"));
dept = departmentService.findById(dept);
if (dept != null && dept.getString("ISSUPERVISE").equals("1")) {
pd.put("SUP_DEPARTMENT_ID", dept.getString("DEPARTMENT_ID"));
pd.put("ISSUPERVISE", dept.getString("ISSUPERVISE"));
} else {
pd.put("DEPARTMENT_ID", pd.getString("CHECK_DEPARTMENT_ID"));
}
if (cpd.getString("ISLEADER") != null && cpd.getString("ISLEADER").equals("1")) {
String DEPARTMENT_ID = pd.getString("CHECK_DEPARTMENT_ID");
String ids = departmentService.getDEPARTMENT_IDS(DEPARTMENT_ID);
ids = pd.getString("CHECK_DEPARTMENT_ID") + "," + ids; //把自己部门插入进去
if (ids != null && Tools.notEmpty(ids) && ids.lastIndexOf(",") > -1) {
ids = ids.substring(0, ids.lastIndexOf(","));
pd.put("DEPARTMENT_IDS", ids.split(","));
} else {
pd.put("DEPARTMENT_IDS", DEPARTMENT_ID);
}
}
pd.put("orderUserId", pd.get("USER_ID"));
List<PageData> varList = customService.getMyCheckList(pd);//列出ListManager列表
for (PageData list : varList) {
String cycle = list.getString("PERIODNAME");
if (cycle.equals("每日")) {
list.put("START_DATE", DateUtil.getDay());
list.put("END_DATE", DateUtil.getDay());
} else if (cycle.equals("每周")) {
list.put("START_DATE", DateUtil.getWeekStart().substring(0, 10));
list.put("END_DATE", DateUtil.getWeekEnd().substring(0, 10));
} else if (cycle.equals("每旬")) {
//1-10
if (DateUtil.timeCalendar(new Date(), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "01 00:00:00"), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "10 23:59:59"))) {
list.put("START_DATE", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "01");
list.put("END_DATE", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "10");
}
//10-20
if (DateUtil.timeCalendar(new Date(), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "11 00:00:00"), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "20 23:59:59"))) {
list.put("START_DATE", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "11");
list.put("END_DATE", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "20");
}
//20-月底
if (DateUtil.timeCalendar(new Date(), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "21 00:00:00"), DateUtil.fomatDateTime(DateUtil.getMonthEndDay() + " 23:59:59"))) {
list.put("START_DATE", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "21");
list.put("END_DATE", DateUtil.getMonthEndDay());
}
} else if (cycle.equals("每月")) {
list.put("START_DATE", DateUtil.getMonthFirstDay());
list.put("END_DATE", DateUtil.getMonthEndDay());
} else if (cycle.equals("每季")) {
list.put("START_DATE", DateUtil.quarterStart());
list.put("END_DATE", DateUtil.quarterEnd());
} else if (cycle.equals("半年")) {
Integer bmonth = Integer.parseInt(DateUtil.getMonth().toString());
if (bmonth <= 6) {
list.put("START_DATE", DateUtil.getYear() + "-01-01");
list.put("END_DATE", DateUtil.getYear() + "-06-30");
} else if (bmonth > 6) {
list.put("START_DATE", DateUtil.getYear() + "-07-01");
list.put("END_DATE", DateUtil.getYear() + "-12-31");
}
} else if (cycle.equals("每年")) {
list.put("START_DATE", DateUtil.getCurrYearFirst());
list.put("END_DATE", DateUtil.getCurrYearLast());
}
}
map.put("varList", varList);
map.put("result", errInfo);
return map;
}
/**
*
*
* @param
* @throws Exception
*/
@RequestMapping(value = "/getCheckItem")
@ResponseBody
@LogAnno(menuType = "手机", menuServer = "隐患排查", instructionsOperate = "清单管理", instructionsType = "获取清单风险点")
public Object getRisk() throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
String USER_ID = pd.getString("USER_NAME");
List<PageData> varList = customItemService.getCheckItem(pd);
map.put("varList", varList);
pd = customService.findById(pd);
if (pd.getString("TYPE").equals("listType0005")) {
if (DateUtil.timeCalendar(new Date(), DateUtil.fomatDateTime(pd.getString("START_DATE") + " 00:00:00"), DateUtil.fomatDateTime(pd.getString("END_DATE") + " 23:59:59"))) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_XUN", 1);//查询方法和旬一样,直接借用
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
type.put("BEGINTIME", pd.getString("START_DATE") + " 00:00:00");
type.put("ENDTIME", pd.getString("END_DATE") + " 23:59:59");
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
}
map.put("result", errInfo);
return map;
}
String cycle = pd.getString("PERIODNAME");
if (cycle.equals("每日")) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_DAY", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
pd.put("checkCount", records == null ? 0 : records.size());
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
} else if (cycle.equals("每周")) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_WEEK", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
pd.put("checkCount", records == null ? 0 : records.size());
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
} else if (cycle.equals("每旬")) {
//1-10
if (DateUtil.timeCalendar(new Date(), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "01 00:00:00"), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "10 23:59:59"))) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_XUN", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
type.put("BEGINTIME", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "01 00:00:00");
type.put("ENDTIME", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "10 23:59:59");
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
}
//10-20
if (DateUtil.timeCalendar(new Date(), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "11 00:00:00"), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "20 23:59:59"))) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_XUN", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
type.put("BEGINTIME", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "11 00:00:00");
type.put("ENDTIME", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "20 23:59:59");
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
}
//20-月底
if (DateUtil.timeCalendar(new Date(), DateUtil.fomatDateTime(DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "21 00:00:00"), DateUtil.fomatDateTime(DateUtil.getMonthEndDay() + " 23:59:59"))) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_XUN", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
type.put("BEGINTIME", DateUtil.getYear() + "-" + DateUtil.getMonth() + "-" + "21 00:00:00");
type.put("ENDTIME", DateUtil.getMonthEndDay() + " 23:59:59");
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
}
} else if (cycle.equals("每月")) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_MONTH", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
pd.put("checkCount", records == null ? 0 : records.size());
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
} else if (cycle.equals("每季")) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_QUARTER", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
pd.put("checkCount", records == null ? 0 : records.size());
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
} else if (cycle.equals("半年")) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_HALFYEAR", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
pd.put("checkCount", records == null ? 0 : records.size());
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
} else if (cycle.equals("每年")) {
PageData type = new PageData();
type.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
type.put("IS_YEAR", 1);
type.put("FINISHED", '0');
type.put("USER_ID", USER_ID);
List<PageData> records = customCheckRecordService.listAllUnfinished(type);
pd.put("checkCount", records == null ? 0 : records.size());
if (records != null && records.size() > 0) {
PageData record = new PageData();
record.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
List<PageData> checkedList = customCheckRecordItemService.listAll(record);
Map<String, Integer> checkmap = new HashMap<String, Integer>();//记录所有风险点
for (PageData item : checkedList) {
if (!checkmap.containsKey(item.getString("IDENTIFICATION_ID"))) {
checkmap.put(item.getString("IDENTIFICATION_ID"), 1);
} else {
checkmap.put(item.getString("IDENTIFICATION_ID"), checkmap.get(item.getString("IDENTIFICATION_ID")) + 1);
}
}
map.put("CHECKRECORD_ID", records.get(0).get("CHECKRECORD_ID"));
map.put("checkmap", checkmap);
}
}
map.put("result", errInfo);
return map;
}
}

View File

@ -45,7 +45,8 @@ public class CommonController extends BaseController {
String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件
if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim());
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业
pd = corpinfoService.findById(pd); //根据ID读取
PageData corpinfo = corpinfoService.findById(pd); //根据ID读取
pd.put("CORP_TYPE_NAME", corpinfo.getString("CORP_TYPE_NAME"));
page.setPd(pd);
List<PageData> varList = commonService.list(page); //列出RiskCheckItem列表
map.put("varList", varList);

View File

@ -5,23 +5,23 @@ import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.logs.LogAnno;
import com.zcloud.service.check.*;
import com.zcloud.service.hiddenDangerCheckStandard.CustomItemService;
import com.zcloud.service.hiddenDangerCheckStandard.CustomService;
import com.zcloud.service.hiddenDangerCheckStandard.*;
import com.zcloud.service.offduty.OffDutyService;
import com.zcloud.service.risk.IdentificationPartsService;
import com.zcloud.service.risk.RiskPointService;
import com.zcloud.service.statistics.ListStatisticsService;
import com.zcloud.service.system.DepartmentService;
import com.zcloud.service.system.UsersService;
import com.zcloud.util.DateUtil;
import com.zcloud.util.Jurisdiction;
import com.zcloud.util.Tools;
import com.zcloud.util.Warden;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@ -41,17 +41,15 @@ public class CustomController extends BaseController {
@Autowired
private CustomItemService customItemService;
@Autowired
private ListCheckItemService listcheckitemService;
private CustomDisableTimeService customDisableTimeService;
@Autowired
private DepartmentService departmentService;
@Autowired
private CheckRecordService checkrecordService;
private CustomCheckRecordService customCheckRecordService;
@Autowired
private RecordItemService recordItemService;
@Autowired
private RiskPointService riskpointService;
@Autowired
private ListStatisticsService listStatisticsService;
private CustomStatisticsService customStatisticsService;
@Autowired
private IdentificationPartsService identificationPartsService;
@Autowired
@ -97,17 +95,145 @@ public class CustomController extends BaseController {
Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success";
PageData pd = new PageData();
PageData npd = new PageData();
pd = this.getPageData();
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件
if(Tools.notEmpty(KEYWORDS))npd.put("KEYWORDS", KEYWORDS.trim());
List<PageData> varList = customService.listAll(pd);
if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim());
page.setPd(pd);
List<PageData> varList = customService.list(page);
map.put("varList", varList);
map.put("result", errInfo);
return map;
}
/**
* @param out
* @throws Exception
*/
@RequestMapping(value="/delete")
@ResponseBody
@LogAnno(menuType= "双重预防",menuServer= "隐患排查",instructionsOperate = "清单管理",instructionsType = "禁用")
public Object delete() throws Exception{
Map<String,String> map = new HashMap<String,String>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
pd.put("OPERATOR", Jurisdiction.getUsername()); //修改人
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
customService.delete(pd);
pd = customService.findById(pd);
// 记录清单禁用开始时间
PageData disPd = new PageData();
disPd = this.getPageData();
disPd.put("CUSTOMDISABLETIME_ID", this.get32UUID()); //主键
disPd.put("CUSTOM_ID", pd.get("CUSTOM_ID"));
disPd.put("CORPINFO_ID", pd.get("CORPINFO_ID"));
disPd.put("STARTTIME", DateUtil.date2Str(new Date())); //开始时间
disPd.put("ISDELETE", "0"); //是否删除 0 未删除 1已删除
disPd.put("OPERATOR", Jurisdiction.getUsername()); //操作人
disPd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
disPd.put("CREATOR", Jurisdiction.getUsername()); //创建人
disPd.put("CREATTIME", DateUtil.date2Str(new Date())); //创建时间
customDisableTimeService.save(disPd);
// 修改清单统计
if(pd.get("TYPE") != null && Tools.notEmpty(pd.get("TYPE").toString())) {
if("listType0005".equals(pd.get("TYPE").toString())) {
pd.put("CUSTOMSTATISTICS_ID", this.get32UUID()); //主键
pd.put("STARTTIME", pd.get("START_DATE").toString()+" 00:00:00");
pd.put("ENDTIME", pd.get("END_DATE").toString()+" 23:59:59");
pd.put("PERIOD", null);
PageData statistics = customStatisticsService.findByCondition(pd);
if(statistics != null && statistics.get("LISTSTATISTICS_ID") != null) {
statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-2);
customStatisticsService.edit(statistics);
}
pd.put("ISSTATISTICS", '0');
// 本期已检查的不计入统计
customCheckRecordService.editStatistics(pd);
} else {
if(pd.get("PERIOD") != null && Tools.notEmpty(pd.get("PERIOD").toString())) {
String period = pd.get("PERIOD").toString();
switch (period) {
case "checkPeriod0001"://每日
pd.put("STARTTIME", DateUtil.getDay()+" 00:00:00");
pd.put("ENDTIME", DateUtil.getDay()+" 23:59:59");
break;
case "checkPeriod0002"://每周
pd.put("STARTTIME", DateUtil.getWeekStart());
pd.put("ENDTIME", DateUtil.getWeekEnd());
break;
case "checkPeriod0003"://每旬
String year = DateUtil.getYear().toString();
String month = DateUtil.getMonth().toString();
Integer day = Integer.parseInt(DateUtil.getOnlyDay().toString());
String startTime = year + "-" + month + "-";
String endTime = year + "-" + month + "-";
if(day <= 10) {
startTime = startTime+"01 00:00:00";
endTime = endTime+"10 23:59:59";
} else if(day > 10 && day <= 20) {
startTime = startTime+"11 00:00:00";
endTime = endTime+"20 23:59:59";
} else {
startTime = startTime+"21 00:00:00";
endTime = DateUtil.getMonthEndDay()+" 23:59:59";
}
pd.put("STARTTIME", startTime);
pd.put("ENDTIME", endTime);
break;
case "checkPeriod0004"://每月
pd.put("STARTTIME", DateUtil.getMonthFirstDay()+" 00:00:00");
pd.put("ENDTIME", DateUtil.getMonthEndDay()+" 23:59:59");
break;
case "checkPeriod0005"://每季
pd.put("STARTTIME", DateUtil.quarterStart()+" 00:00:00");
pd.put("ENDTIME", DateUtil.quarterEnd()+" 23:59:59");
break;
case "checkPeriod0006"://每年
pd.put("STARTTIME", DateUtil.getCurrYearFirst()+" 00:00:00");
pd.put("ENDTIME", DateUtil.getCurrYearLast()+" 23:59:59");
break;
case "checkPeriod0007"://半年
String byear = DateUtil.getYear().toString();
Integer bmonth = Integer.parseInt(DateUtil.getMonth().toString());
if(bmonth <= 6) {
pd.put("STARTTIME", byear+"-01-01 00:00:00");
pd.put("ENDTIME", byear+"-06-30 23:59:59");
} else if(bmonth > 6) {
pd.put("STARTTIME", byear+"-07-01 00:00:00");
pd.put("ENDTIME", byear+"-12-31 23:59:59");
}
break;
default:
break;
}
}
PageData statistics = customStatisticsService.findByCondition(pd);
if(statistics != null && statistics.get("LISTSTATISTICS_ID") != null) {
statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-1);
customStatisticsService.edit(statistics);
}
pd.put("ISSTATISTICS", '0');
// 本期已检查的不计入统计
customCheckRecordService.editStatistics(pd);
}
}
// 将本频率内已检查的记录,改为不计入
map.put("result", errInfo); //返回结果
return map;
}
// /**列表
// * @param page
// * @throws Exception
@ -317,173 +443,173 @@ public class CustomController extends BaseController {
// map.put("result", errInfo);
// return map;
// }
//
// /**批量删除
// * @param
// * @throws Exception
// */
// @RequestMapping(value="/deleteAll")
// @RequiresPermissions("listmanager:del")
// @ResponseBody
// @LogAnno(menuType= "双重预防",menuServer= "隐患排查",instructionsOperate = "清单管理",instructionsType = "批量删除")
// public Object deleteAll() throws Exception{
// Map<String,Object> map = new HashMap<String,Object>();
// String errInfo = "success";
// PageData pd = new PageData();
// pd = this.getPageData();
// String DATA_IDS = pd.getString("DATA_IDS");
// if(Tools.notEmpty(DATA_IDS)){
// String ArrayDATA_IDS[] = DATA_IDS.split(",");
// for(int i = 0; i < ArrayDATA_IDS.length; i++) {
// PageData pd1 = new PageData();
// pd1.put("OPERATOR", Jurisdiction.getUsername()); //修改人
// pd1.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
// pd1.put("LISTMANAGER_ID", ArrayDATA_IDS[i]);
// listmanagerService.remove(pd1);
// pd1 = listmanagerService.findById(pd1);
// if(pd1.get("TYPE") != null && Tools.notEmpty(pd1.get("TYPE").toString())) {
// if("listType0005".equals(pd1.get("TYPE").toString())) {
// pd1.put("LISTSTATISTICS_ID", this.get32UUID()); //主键
// pd1.put("STARTTIME", pd1.get("START_DATE").toString()+" 00:00:00");
// pd1.put("ENDTIME", pd1.get("END_DATE").toString()+" 23:59:59");
// pd1.put("PERIOD", null);
// PageData statistics = listStatisticsService.findByCondition(pd1);
// if(statistics != null && statistics.get("LISTSTATISTICS_ID") != null) {
// statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-2);
// listStatisticsService.edit(statistics);
// }
// pd1.put("ISSTATISTICS", '0');
// // 本期已检查的不计入统计
// checkrecordService.editStatistics(pd1);
// } else {
// if(pd1.get("PERIOD") != null && Tools.notEmpty(pd1.get("PERIOD").toString())) {
// String period = pd1.get("PERIOD").toString();
// switch (period) {
// case "checkPeriod0001"://每日
// pd1.put("STARTTIME", DateUtil.getDay()+" 00:00:00");
// pd1.put("ENDTIME", DateUtil.getDay()+" 23:59:59");
// break;
//
// case "checkPeriod0002"://每周
// pd1.put("STARTTIME", DateUtil.getWeekStart());
// pd1.put("ENDTIME", DateUtil.getWeekEnd());
// break;
//
// case "checkPeriod0003"://每旬
// String year = DateUtil.getYear().toString();
// String month = DateUtil.getMonth().toString();
// Integer day = Integer.parseInt(DateUtil.getOnlyDay().toString());
// String startTime = year + "-" + month + "-";
// String endTime = year + "-" + month + "-";
// if(day <= 10) {
// startTime = startTime+"01 00:00:00";
// endTime = endTime+"10 23:59:59";
// } else if(day > 10 && day <= 20) {
// startTime = startTime+"11 00:00:00";
// endTime = endTime+"20 23:59:59";
// } else {
// startTime = startTime+"21 00:00:00";
// endTime = DateUtil.getMonthEndDay()+" 23:59:59";
// }
// pd1.put("STARTTIME", startTime);
// pd1.put("ENDTIME", endTime);
// break;
//
// case "checkPeriod0004"://每月
// pd1.put("STARTTIME", DateUtil.getMonthFirstDay()+" 00:00:00");
// pd1.put("ENDTIME", DateUtil.getMonthEndDay()+" 23:59:59");
// break;
//
// case "checkPeriod0005"://每季
// pd1.put("STARTTIME", DateUtil.quarterStart()+" 00:00:00");
// pd1.put("ENDTIME", DateUtil.quarterEnd()+" 23:59:59");
// break;
//
// case "checkPeriod0006"://每年
// pd1.put("STARTTIME", DateUtil.getCurrYearFirst()+" 00:00:00");
// pd1.put("ENDTIME", DateUtil.getCurrYearLast()+" 23:59:59");
// break;
//
// case "checkPeriod0007"://半年
// String byear = DateUtil.getYear().toString();
// Integer bmonth = Integer.parseInt(DateUtil.getMonth().toString());
// if(bmonth <= 6) {
// pd1.put("STARTTIME", byear+"-01-01 00:00:00");
// pd1.put("ENDTIME", byear+"-06-30 23:59:59");
// } else if(bmonth > 6) {
// pd1.put("STARTTIME", byear+"-07-01 00:00:00");
// pd1.put("ENDTIME", byear+"-12-31 23:59:59");
// }
// break;
//
// default:
// break;
// }
// }
// PageData statistics = listStatisticsService.findByCondition(pd1);
// if(statistics != null && statistics.get("LISTSTATISTICS_ID") != null) {
// statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-1);
// listStatisticsService.edit(statistics);
// }
//
// pd1.put("ISSTATISTICS", '0');
// // 本期已检查的不计入统计
// checkrecordService.editStatistics(pd1);
// }
// }
// }
// errInfo = "success";
// }else{
// errInfo = "error";
// }
// map.put("result", errInfo); //返回结果
// return map;
// }
//
// /**批量删除
// * @param
// * @throws Exception
// */
// @RequestMapping(value="/deleteAlltemp")
// @ResponseBody
// @LogAnno(menuType= "双重预防",menuServer= "隐患排查",instructionsOperate = "清单管理",instructionsType = "批量删除")
// public Object deleteAlltemp() throws Exception{
// Map<String,Object> map = new HashMap<String,Object>();
// String errInfo = "success";
// PageData pd = new PageData();
// pd = this.getPageData();
// String DATA_IDS = pd.getString("DATA_IDS");
// if(Tools.notEmpty(DATA_IDS)){
// String ArrayDATA_IDS[] = DATA_IDS.split(",");
// for(int i = 0; i < ArrayDATA_IDS.length; i++) {
// PageData pd1 = new PageData();
// pd1.put("OPERATOR", Jurisdiction.getUsername()); //修改人
// pd1.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
// pd1.put("LISTMANAGER_ID", ArrayDATA_IDS[i]);
// listmanagerService.deleted(pd1);
// pd1 = listmanagerService.findById(pd1);
// if(pd1.get("TYPE") != null && Tools.notEmpty(pd1.get("TYPE").toString())) {
// pd1.put("LISTSTATISTICS_ID", this.get32UUID()); //主键
// pd1.put("STARTTIME", pd1.get("START_DATE").toString()+" 00:00:00");
// pd1.put("ENDTIME", pd1.get("END_DATE").toString()+" 23:59:59");
// pd1.put("PERIOD", null);
// PageData statistics = listStatisticsService.findByCondition(pd1);
// if(statistics != null && statistics.get("LISTSTATISTICS_ID") != null) {
// statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-1);
// listStatisticsService.edit(statistics);
// }
// pd1.put("ISSTATISTICS", '0');
// // 本期已检查的不计入统计
// checkrecordService.editStatistics(pd1);
// }
// }
// errInfo = "success";
// }else{
// errInfo = "error";
// }
// map.put("result", errInfo); //返回结果
// return map;
// }
/**
* @param
* @throws Exception
*/
@RequestMapping(value="/deleteAll")
@RequiresPermissions("listmanager:del")
@ResponseBody
@LogAnno(menuType= "双重预防",menuServer= "隐患排查",instructionsOperate = "清单管理",instructionsType = "批量删除")
public Object deleteAll() throws Exception{
Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
String DATA_IDS = pd.getString("DATA_IDS");
if(Tools.notEmpty(DATA_IDS)){
String ArrayDATA_IDS[] = DATA_IDS.split(",");
for(int i = 0; i < ArrayDATA_IDS.length; i++) {
PageData pd1 = new PageData();
pd1.put("OPERATOR", Jurisdiction.getUsername()); //修改人
pd1.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
pd1.put("CUSTOM_ID", ArrayDATA_IDS[i]);
customService.remove(pd1);
pd1 = customService.findById(pd1);
if(pd1.get("TYPE") != null && Tools.notEmpty(pd1.get("TYPE").toString())) {
if("listType0005".equals(pd1.get("TYPE").toString())) {
pd1.put("CUSTOMSTATISTICS_ID", this.get32UUID()); //主键
pd1.put("STARTTIME", pd1.get("START_DATE").toString()+" 00:00:00");
pd1.put("ENDTIME", pd1.get("END_DATE").toString()+" 23:59:59");
pd1.put("PERIOD", null);
PageData statistics = customStatisticsService.findByCondition(pd1);
if(statistics != null && statistics.get("CUSTOMSTATISTICS_ID") != null) {
statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-2);
customStatisticsService.edit(statistics);
}
pd1.put("ISSTATISTICS", '0');
// 本期已检查的不计入统计
customCheckRecordService.editStatistics(pd1);
} else {
if(pd1.get("PERIOD") != null && Tools.notEmpty(pd1.get("PERIOD").toString())) {
String period = pd1.get("PERIOD").toString();
switch (period) {
case "checkPeriod0001"://每日
pd1.put("STARTTIME", DateUtil.getDay()+" 00:00:00");
pd1.put("ENDTIME", DateUtil.getDay()+" 23:59:59");
break;
case "checkPeriod0002"://每周
pd1.put("STARTTIME", DateUtil.getWeekStart());
pd1.put("ENDTIME", DateUtil.getWeekEnd());
break;
case "checkPeriod0003"://每旬
String year = DateUtil.getYear().toString();
String month = DateUtil.getMonth().toString();
Integer day = Integer.parseInt(DateUtil.getOnlyDay().toString());
String startTime = year + "-" + month + "-";
String endTime = year + "-" + month + "-";
if(day <= 10) {
startTime = startTime+"01 00:00:00";
endTime = endTime+"10 23:59:59";
} else if(day > 10 && day <= 20) {
startTime = startTime+"11 00:00:00";
endTime = endTime+"20 23:59:59";
} else {
startTime = startTime+"21 00:00:00";
endTime = DateUtil.getMonthEndDay()+" 23:59:59";
}
pd1.put("STARTTIME", startTime);
pd1.put("ENDTIME", endTime);
break;
case "checkPeriod0004"://每月
pd1.put("STARTTIME", DateUtil.getMonthFirstDay()+" 00:00:00");
pd1.put("ENDTIME", DateUtil.getMonthEndDay()+" 23:59:59");
break;
case "checkPeriod0005"://每季
pd1.put("STARTTIME", DateUtil.quarterStart()+" 00:00:00");
pd1.put("ENDTIME", DateUtil.quarterEnd()+" 23:59:59");
break;
case "checkPeriod0006"://每年
pd1.put("STARTTIME", DateUtil.getCurrYearFirst()+" 00:00:00");
pd1.put("ENDTIME", DateUtil.getCurrYearLast()+" 23:59:59");
break;
case "checkPeriod0007"://半年
String byear = DateUtil.getYear().toString();
Integer bmonth = Integer.parseInt(DateUtil.getMonth().toString());
if(bmonth <= 6) {
pd1.put("STARTTIME", byear+"-01-01 00:00:00");
pd1.put("ENDTIME", byear+"-06-30 23:59:59");
} else if(bmonth > 6) {
pd1.put("STARTTIME", byear+"-07-01 00:00:00");
pd1.put("ENDTIME", byear+"-12-31 23:59:59");
}
break;
default:
break;
}
}
PageData statistics = customStatisticsService.findByCondition(pd1);
if(statistics != null && statistics.get("CUSTOMSTATISTICS_ID") != null) {
statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-1);
customStatisticsService.edit(statistics);
}
pd1.put("ISSTATISTICS", '0');
// 本期已检查的不计入统计
customCheckRecordService.editStatistics(pd1);
}
}
}
errInfo = "success";
}else{
errInfo = "error";
}
map.put("result", errInfo); //返回结果
return map;
}
/**
* @param
* @throws Exception
*/
@RequestMapping(value="/deleteAlltemp")
@ResponseBody
@LogAnno(menuType= "双重预防",menuServer= "隐患排查",instructionsOperate = "清单管理",instructionsType = "批量删除")
public Object deleteAlltemp() throws Exception{
Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
String DATA_IDS = pd.getString("DATA_IDS");
if(Tools.notEmpty(DATA_IDS)){
String ArrayDATA_IDS[] = DATA_IDS.split(",");
for(int i = 0; i < ArrayDATA_IDS.length; i++) {
PageData pd1 = new PageData();
pd1.put("OPERATOR", Jurisdiction.getUsername()); //修改人
pd1.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
pd1.put("CUSTOM_ID", ArrayDATA_IDS[i]);
customService.deleted(pd1);
pd1 = customService.findById(pd1);
if(pd1.get("TYPE") != null && Tools.notEmpty(pd1.get("TYPE").toString())) {
pd1.put("CUSTOMSTATISTICS_ID", this.get32UUID()); //主键
pd1.put("STARTTIME", pd1.get("START_DATE").toString()+" 00:00:00");
pd1.put("ENDTIME", pd1.get("END_DATE").toString()+" 23:59:59");
pd1.put("PERIOD", null);
PageData statistics = customStatisticsService.findByCondition(pd1);
if(statistics != null && statistics.get("CUSTOMSTATISTICS_ID") != null) {
statistics.put("NOTEXAMINEDNUM", Integer.parseInt(statistics.get("NOTEXAMINEDNUM").toString())-1);
customStatisticsService.edit(statistics);
}
pd1.put("ISSTATISTICS", '0');
// 本期已检查的不计入统计
customCheckRecordService.editStatistics(pd1);
}
}
errInfo = "success";
}else{
errInfo = "error";
}
map.put("result", errInfo); //返回结果
return map;
}
//
// /**导出到excel
// * @param
@ -735,7 +861,7 @@ public class CustomController extends BaseController {
// planMap.put(pageData.getString("type_bianma") + "," + pageData.getString("level_bianma") + "," + pageData.getString("period_bianma"),pageData);
// }
// //企业所有应查数
// List<PageData> staList = listStatisticsService.listAllForPlan(pd);
// List<PageData> staList = customStatisticsService.listAllForPlan(pd);
// for (PageData pageData : staList) {
// String rowName = pageData.getString("TYPE") + "," + pageData.getString("level_bianma") + "," + pageData.getString("PERIOD");
// PageData row = planMap.get(rowName);

View File

@ -34,7 +34,6 @@ public class StandardDictionaryController extends BaseController {
* @throws Exception
*/
@RequestMapping(value = "/list")
@RequiresPermissions("hiddendictionary:list")
@ResponseBody
public Object list() throws Exception {
Map<String, Object> map = new HashMap<String, Object>();

View File

@ -11,12 +11,21 @@ import java.util.List;
*/
public interface HotworkMapper {
PageData getCode(PageData pd);
PageData findById(PageData pd);
void save(PageData pd);
void delete(PageData pd);
void edit(PageData pd);
void editGasTime(PageData pd);
void editStep(PageData pd);
void setPosition(PageData pd);
List<PageData> datalistPage(Page page);
List<PageData> namelist(PageData pd);
@ -26,4 +35,5 @@ public interface HotworkMapper {
List<PageData> checkWorkCount(PageData pd);
List<PageData> getFlowList(PageData pd);
}

View File

@ -0,0 +1,67 @@
package com.zcloud.mapper.datasource.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
public interface CustomCheckRecordItemMapper {
/**
* @param pd
* @throws Exception
*/
void save(PageData pd);
/**
* @param pd
* @throws Exception
*/
void delete(PageData pd);
/**
* @param pd
* @throws Exception
*/
void edit(PageData pd);
/**
* @param page
* @throws Exception
*/
List<PageData> datalistPage(Page page);
/**()
* @param pd
* @throws Exception
*/
List<PageData> listAll(PageData pd);
/**id
* @param pd
* @throws Exception
*/
PageData findById(PageData pd);
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
void deleteAll(String[] ArrayDATA_IDS);
List<PageData> listAllForMap(PageData pd);
/**
* @param pd
* @throws Exception
*/
void editIsnormal(PageData pd);
}

View File

@ -0,0 +1,177 @@
package com.zcloud.mapper.datasource.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
public interface CustomCheckRecordMapper {
/**
* @param pd
* @throws Exception
*/
void save(PageData pd);
/**
* @param pd
* @throws Exception
*/
void delete(PageData pd);
/**
* @param pd
* @throws Exception
*/
void edit(PageData pd);
/**
* @param pd
* @throws Exception
*/
int countOverTime(PageData pd);
/**
* @param page
* @throws Exception
*/
List<PageData> datalistPage(Page page);
/**
* @param page
* @throws Exception
*/
List<PageData> listlistPage(Page page);
/**()
* @param pd
* @throws Exception
*/
List<PageData> listAll(PageData pd);
List<PageData> findRiskPointByLId(PageData pd);
/**id
* @param pd
* @throws Exception
*/
PageData findById(PageData pd);
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
void deleteAll(String[] ArrayDATA_IDS);
List<PageData> listAllUnfinished(PageData pd);
/* 统计功能 */
List<PageData> listCountDay(PageData pd);/* 统计日 */
List<PageData> listCountWeek(PageData pd);/* 统计周 */
List<PageData> listCountTenDays(PageData pd);/* 统计旬 */
List<PageData> listCountMonth(PageData pd);/* 统计功月 */
List<PageData> listCountQuarter(PageData pd);/* 统计季 */
List<PageData> listCountHalfYear(PageData pd);/* 统计半年 */
List<PageData> listCountYear(PageData pd);/* 统计年 */
Integer listCountJjr(PageData pd);/* 统计节假日 */
/**
* @param pd
* @throws Exception
*/
void editStatistics(PageData pd);
/**
*
* @param pd
* @return
*/
List<PageData> listLogByIde(PageData pd);
/**
*
* @param pd
* @return
*/
List<PageData> recordByIde(PageData pd);
/**
* @param pd
* @throws Exception
*/
void recording(PageData pd);
/**
* APP
* @param pd
* @return
*/
List<PageData> appdatalist(PageData pd);
/**
*
* @param pd
* @return
*/
List<PageData> countByPeriodUser(PageData pd);
/**
*
* @param pd
* @return
*/
int getWorkedUserCount(PageData pd);
/**
*
* @param pd
* @return
*/
public int getWorkedDepCount(PageData pd);
List<PageData> listTypeBi(PageData pd);
List<PageData> listForDocking(PageData pd);
void updateDocking(PageData pageData);
/**
* (ids)
* @param pd
* @return
*/
List<PageData> listForIdsAndMonth(PageData pd);
List<PageData> anaysis(PageData util);
PageData findByNumber(PageData condition);
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> listAllYearForDay(PageData pd);
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> listAllYearForWeek(PageData pd);
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> listAllYearForTenday(PageData pd);
}

View File

@ -0,0 +1,75 @@
package com.zcloud.mapper.datasource.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
* -
* luoxiaobao
* 2020-12-31
* www.zcloudchina.com
*/
public interface CustomDisableTimeMapper {
/**
* @param pd
* @throws Exception
*/
void save(PageData pd);
/**
* @param pd
* @throws Exception
*/
void delete(PageData pd);
/**
* @param pd
* @throws Exception
*/
void edit(PageData pd);
/**
* @param pd
* @throws Exception
*/
void editEndTime(PageData pd);
/**
* @param page
* @throws Exception
*/
List<PageData> datalistPage(Page page);
/**()
* @param pd
* @throws Exception
*/
List<PageData> listAll(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> listByFull(PageData pd);
/**id
* @param pd
* @throws Exception
*/
PageData findById(PageData pd);
/**
* @param pd
* @throws Exception
*/
PageData findByList(PageData pd);
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
void deleteAll(String[] ArrayDATA_IDS);
}

View File

@ -0,0 +1,312 @@
package com.zcloud.mapper.datasource.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
public interface CustomHiddenMapper {
/**
* @param pd
* @throws Exception
*/
void save(PageData pd);
/**
* @param pd
* @throws Exception
*/
void delete(PageData pd);
/**
* @param pd
* @throws Exception
*/
void edit(PageData pd);
/**
* @param pd
* @throws Exception
*/
void editInfo(PageData pd);
void editISCONFIRM(PageData pd);
void editHIDDENLEVEL(PageData pd);
/**
* @param pd
* @throws Exception
*/
void editDeadline(PageData pd);
/**
* @param pd
* @throws Exception
*/
void rectify(PageData pd);
/**
* @param pd
* @throws Exception
*/
void review(PageData pd);
/**
* @param pd
* @throws Exception
*/
void check(PageData pd);
/**
* @param page
* @throws Exception
*/
List<PageData> datalistPage(Page page);
/**()
* @param pd
* @throws Exception
*/
List<PageData> listAll(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> getYestoday(PageData pd);
/**()
* @param pd
* @throws Exception
*/
List<PageData> listAllToPrint(PageData pd);
List<PageData> listHiddenAll(PageData pd);
/**
*
* @param pd
* @return
*/
List<PageData> getHiddenByRecord(PageData pd);
/**id
* @param pd
* @throws Exception
*/
PageData findById(PageData pd);
/**ID
* @param pd
* @throws Exception
*/
List<PageData> getCountByCheckorId(PageData pd);
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
void deleteAll(String[] ArrayDATA_IDS);
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
void updateAll(PageData hiddens);
List<PageData> hiddenStatisticsByDay(PageData pd);
List<PageData> hiddenStatisticsAll(PageData pd);
List<PageData> getCountByCreatorId(PageData pd);
List<PageData> getCountByRectifiCationorId(PageData pd);
void changeState(PageData pd);
List<PageData> getBICount(PageData pd);
void submit(PageData pd);
/**
* ()
* @param pd
*/
void submitList(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> getOtherHidden(PageData pd);
List<PageData> getCountByHiddenType(PageData pd);
/**()
* @param pd
* @throws Exception
*/
List<PageData> getHiddenNum(PageData pd);
/**(
* @param pd
* @throws Exception
*/
List<PageData> listAllRoll(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> getDeptExamine(PageData pd);
List<PageData> getUserExamine(PageData pd);
List<PageData> listAllForDiagnosis(PageData pd);
List<PageData> listForDocking(PageData pd);
void updateDocking(PageData pageData);
PageData getUserIndexData(PageData pd);
PageData getDeptIndexData(PageData pd);
PageData getSuperviseDeptIndexData(PageData pd);
List<PageData> findByMainId(PageData x);
List<PageData> anaysis(PageData util);
List<PageData> findByKey(PageData condition);
List<PageData> findByQue(PageData condition);
List<PageData> findByYin(PageData condition);
List<PageData> findByTs(PageData condition);
List<PageData> findByInspectionId(PageData pd);
/**
*
* @param pd
* @return
* @throws Exception
*/
List<PageData> listAllInspection(PageData pd);
/**
*
* @param pd
*/
void editStateInspection(PageData pd);
void deleteByKey(PageData pd);
void deleteArray(PageData pd);
List<PageData> getCountByConfirmId(PageData pd);
List<PageData> getCountSpecialByhId(PageData pd);
void editInformation(PageData pd);
void editstate(PageData hiddenExa);
/**
*
* @param pd
* @return
*/
List<PageData> listOtherNotAccept(PageData pd);
/**
* --
* @param page
* @return
* @throws Exception
*/
List<PageData> listGwjdatalistPage (Page page);
/**
* --
* @param page
* @return
* @throws Exception
*/
List<PageData> listIgnoredatalistPage (Page page);
void saveForEmis(PageData pd);
void deleteForEmis(PageData pd);
/**
*
* @param pd
* @throws Exception
*/
void confirmHidden(PageData pd);
List<PageData> hiddenInspectionlistPage(Page page);
/**
*
* @param pd
* @return
* @throws Exception
*/
List<PageData> listOtherNotAssign(PageData pd);
/**
*
* @param pd
* @throws Exception
*/
void assign(PageData pd);
/**
* @param pd
* @throws Exception
*/
public void finalcheck(PageData pd);
List<PageData> listOtherNotAccept4pc(PageData pd);
/**
* @param page
* @throws Exception
*/
List<PageData> getListForTianzhangdatalistPage(Page page);
/**
*
* @param pd
* @throws Exception
*/
void confirmUpdate(PageData pd);
/**
*
*/
void updateStateByHidden (PageData pd);
List<PageData> majordatalistPage(Page page);
List<PageData> verifydatalistPage(Page page);
List<PageData> majormanagelistPage(Page page);
/**id
* @param pd
* @throws Exception
*/
PageData findByEmisId(PageData pd);
List<PageData> getListForemisdatalistPage(Page page);
}

View File

@ -2,6 +2,8 @@ package com.zcloud.mapper.datasource.hiddenDangerCheckStandard;
import com.zcloud.entity.PageData;
import java.util.List;
/**
* -
* luoxiaobao
@ -15,5 +17,11 @@ public interface CustomItemMapper {
* @throws Exception
*/
void save(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> getCheckItem(PageData pd);
}

View File

@ -54,6 +54,7 @@ public interface CustomMapper {
* @throws Exception
*/
List<PageData> datalistPage(Page page);
List<PageData> stopdatalistPage(Page page);
/**()
@ -226,5 +227,11 @@ public interface CustomMapper {
List<PageData> findByCondition(PageData util);
List<PageData> analysis(PageData util);
/**
* @param pd
* @throws Exception
*/
List<PageData> getMyCheckList(PageData pd);
}

View File

@ -0,0 +1,108 @@
package com.zcloud.mapper.datasource.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-27
* www.zcloudchina.com
*/
public interface CustomStatisticsMapper {
/**
* @param pd
* @throws Exception
*/
void save(PageData pd);
/**
* @param pd
* @throws Exception
*/
void delete(PageData pd);
/**
* @param pd
* @throws Exception
*/
void deletewl(PageData pd);
/**
* @param pd
* @throws Exception
*/
void edit(PageData pd);
/**
* @param page
* @throws Exception
*/
List<PageData> datalistPage(Page page);
/**()
* @param pd
* @throws Exception
*/
List<PageData> listAll(PageData pd);
/**()
* @param pd
* @throws Exception
*/
List<PageData> getCountList(PageData pd);
/**id
* @param pd
* @throws Exception
*/
PageData findById(PageData pd);
/**
* @param pd
* @throws Exception
*/
PageData findByCondition(PageData pd);
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
void deleteAll(String[] ArrayDATA_IDS);
PageData getTimeAstrict(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> countStaByUser(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> countSta(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> checkSituation(PageData pd);
/**1
* @param pd
* @throws Exception
*/
List<PageData> countListStaByUser(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> countByPeriodUser(PageData pd);
List<PageData> listAllForPlan(PageData pd);
}

View File

@ -9,10 +9,7 @@ import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.eightwork.*;
import com.zcloud.service.eightwork.HotworkService;
import com.zcloud.service.mq.SendMessageService;
import com.zcloud.util.Const;
import com.zcloud.util.DateUtil;
import com.zcloud.util.Smb;
import com.zcloud.util.UuidUtil;
import com.zcloud.util.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
@ -74,6 +71,7 @@ public class HotworkServiceImpl implements HotworkService {
PageData flow = getStep(pd.get("TASK_ID"),"1");
saveLog(pd,pd.getString("CREATOR"),"1");
saveNextSigner(pd,flow);
setPosition(pd);
}
}
@ -89,6 +87,7 @@ public class HotworkServiceImpl implements HotworkService {
PageData flow = getStep(pd.get("TASK_ID"),"1");
saveLog(pd,pd.getString("CREATOR"),"1");
saveNextSigner(pd,flow);
setPosition(pd);
}
}
@ -393,14 +392,12 @@ public class HotworkServiceImpl implements HotworkService {
eightWorkFlowLogMapper.save(log);
}
// private void saveNext(PageData pd,PageData flow) throws Exception {
// PageData log = new PageData();
// log.put("LOG_ID", UuidUtil.get32UUID());
// log.put("WORK_ID", pd.get(primary_key));
// log.put("TASK_ID", pd.get("TASK_ID"));
// log.put("STEP_ID", flow.get("NEXT_STEP_ID"));
// log.put("STATUS", "0");
// eightWorkFlowLogMapper.save(log);
// }
private void setPosition(PageData pd) throws Exception {
JSONObject body = PLSUtil.getRyRegionInfo(Jurisdiction.getCORPINFO_ID(),Integer.parseInt(pd.getString("PLS_ID")));
List pointList = (List)((Map) body.get("data")).get("list");
List<String> positions = PLSUtil.getRandomPointInPolygon(pointList);
pd.put("WORK_POSITION", String.join(",",positions));
hotworkMapper.setPosition(pd);
}
}

View File

@ -0,0 +1,67 @@
package com.zcloud.service.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
public interface CustomCheckRecordItemService {
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception;
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception;
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception;
List<PageData> listAllForMap(PageData pd) throws Exception;
/**
* @param pd
* @throws Exception
*/
public void editIsnormal(PageData pd)throws Exception;
}

View File

@ -0,0 +1,178 @@
package com.zcloud.service.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
public interface CustomCheckRecordService {
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public int countOverTime(PageData pd)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> listAllList(Page page)throws Exception;
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception;
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAllUnfinished(PageData pd)throws Exception;
/**ID
* @param pd
* @throws Exception
*/
public List<PageData> findRiskPointByLId(PageData pd)throws Exception;
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception;
/* 统计功能 */
public List<PageData> listCountDay(PageData pd)throws Exception;/* 统计日 */
public List<PageData> listCountWeek(PageData pd)throws Exception;/* 统计周 */
public List<PageData> listCountTenDays(PageData pd)throws Exception;/* 统计旬 */
public List<PageData> listCountMonth(PageData pd)throws Exception;/* 统计功月 */
public List<PageData> listCountQuarter(PageData pd)throws Exception;/* 统计季 */
public List<PageData> listCountHalfYear(PageData pd)throws Exception;/* 统计半年 */
public List<PageData> listCountYear(PageData pd)throws Exception;/* 统计年 */
public Integer listCountJjr(PageData pd)throws Exception;/* 统计节假日 */
/**
* @param pd
* @throws Exception
*/
public void editStatistics(PageData pd)throws Exception;
/**
*
* @param pd
* @return
*/
public List<PageData> listLogByIde(PageData pd)throws Exception;
/**
*
* @param pd
* @return
*/
public List<PageData> recordByIde(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void recording(PageData pd)throws Exception;
/**
* APP
* @param pd
* @return
*/
public List<PageData> appdatalist(PageData pd)throws Exception;
/**
*
* @param pd
* @return
*/
public List<PageData> countByPeriodUser(PageData pd)throws Exception;
/**
*
* @param pd
* @return
*/
public int getWorkedUserCount(PageData pd) throws Exception;
/**
*
* @param pd
* @return
*/
public int getWorkedDepCount(PageData pd)throws Exception;
public List<PageData> listTypeBi(PageData pd)throws Exception;
/**
* (ids)
* @param pd
* @return
*/
public List<PageData> listForIdsAndMonth(PageData pd)throws Exception;
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> listAllYearForDay(PageData pd)throws Exception;
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> listAllYearForWeek(PageData pd)throws Exception;
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> statisticsListCheckTenday(PageData pd)throws Exception;
}

View File

@ -0,0 +1,68 @@
package com.zcloud.service.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
public interface CustomDisableTimeService {
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void editEndTime(PageData pd)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception;
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public List<PageData> listByFull(PageData pd)throws Exception;
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public PageData findByList(PageData pd)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception;
}

View File

@ -0,0 +1,375 @@
package com.zcloud.service.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
public interface CustomHiddenService {
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void editInfo(PageData pd)throws Exception;
public void editISCONFIRM(PageData pd)throws Exception;
public void editHIDDENLEVEL(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void editDeadline(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void rectify(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void review(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void check(PageData pd)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception;
/**
* @param pd
* @throws Exception
*/
public List<PageData> getYestoday(PageData pd)throws Exception;
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception;
/**(使)
* @param pd
* @throws Exception
*/
public List<PageData> listAllToPrint(PageData pd)throws Exception;
public List<PageData> listHiddenAll(PageData pd)throws Exception;
/**
*
* @param pd
* @return
* @throws Exception
*/
public List<PageData> getHiddenByRecord(PageData pd)throws Exception;
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void updateAll(PageData hiddens)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public List<PageData> hiddenStatisticsByDay(PageData pd)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public List<PageData> hiddenStatisticsAll(PageData pd)throws Exception;
/**ID
* @param pd
* @throws Exception
*/
public List<PageData> getCountByCheckorId(PageData pd) throws Exception;
/**
* app ID
* @param pd CREATOR
* @return
* @throws Exception
*/
public List<PageData> getCountByCreatorId(PageData pd) throws Exception;
/**
* app ID
* @param pd CREATOR
* @return
* @throws Exception
*/
public List<PageData> getCountByRectifiCationorId(PageData pd)throws Exception;
void changeState(PageData pd) throws Exception;
List<PageData> getBICount(PageData pd) throws Exception;
void submit(PageData pd) throws Exception;
/**
* ()
* @param pd
* @throws Exception
*/
void submitList(PageData pd) throws Exception;
/**
*
* @param pd
* @return
* @throws Exception
*/
public List<PageData> getOtherHidden(PageData pd) throws Exception;
public List<PageData> getCountByHiddenType(PageData pd) throws Exception;
/**
*
* @param pd
* @return
* @throws Exception
*/
public List<PageData> getHiddenNum(PageData pd) throws Exception;
/**(
* @param pd
* @throws Exception
*/
public List<PageData> listAllRoll(PageData pd);
/**
* @param pd
* @throws Exception
*/
List<PageData> getDeptExamine(PageData pd)throws Exception;
List<PageData> getUserExamine(PageData pd)throws Exception;
List<PageData> listAllForDiagnosis(PageData pd)throws Exception;
PageData getUserIndexData(PageData pd)throws Exception;
PageData getDeptIndexData(PageData pd)throws Exception;
PageData getSuperviseDeptIndexData(PageData pd)throws Exception;
void createExcel(HttpServletResponse response, PageData condition) throws Exception;
List<PageData> findByKey(PageData condition) throws Exception;
List<PageData> findByQue(PageData condition) throws Exception;
List<PageData> findByYin(PageData condition) throws Exception;
List<PageData> findByTs(PageData condition) throws Exception;
/**
* ID
* @param pd
* @return
* @throws Exception
*/
List<PageData> findByInspectionId(PageData pd)throws Exception;
/**
*
* @param pd
* @return
* @throws Exception
*/
public List<PageData> listAllInspection(PageData pd)throws Exception;
/**
*
* @param pd
*/
void editStateInspection(PageData pd)throws Exception;
void deleteByKey(PageData pd) throws Exception;
/**
* @param pd
* @throws Exception
*/
public void deleteArray(PageData pd)throws Exception;
/**ID
* @param pd
* @throws Exception
*/
public List<PageData> getCountByConfirmId(PageData pd) throws Exception;
/**ID
* @param pd
* @throws Exception
*/
public List<PageData> getCountSpecialByhId(PageData pd) throws Exception;
/**
* @param pd
* @throws Exception
*/
public void editInformation(PageData pd)throws Exception;
void editstate(PageData hiddenExa);
/**
*
* @param pd
* @return
* @throws Exception
*/
List<PageData> listOtherNotAccept(PageData pd)throws Exception;
/**
* --
* @param page
* @return
* @throws Exception
*/
public List<PageData> listGwj(Page page) throws Exception;
/**
* --
* @param page
* @return
* @throws Exception
*/
public List<PageData> listIgnore(Page page) throws Exception;
public String goEmis (PageData pd) throws Exception;
/**
*
* @param pd
* @throws Exception
*/
public void confirmHidden (PageData pd) throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> listForSafetyEnvironmental(Page page)throws Exception;
/**
*
* @param pd
* @return
* @throws Exception
*/
List<PageData> listOtherNotAssign(PageData pd)throws Exception;
/**
*
* @param pd
* @throws Exception
*/
void assign(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void finalcheck(PageData pd)throws Exception;
List<PageData> listOtherNotAccept4pc(PageData pd)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> getListForTianzhang(Page page)throws Exception;
/**
*
* @param pd
* @throws Exception
*/
public void confirmUpdate(PageData pd) throws Exception;
/**
*
*/
public void updteStateBySpecialExamine(PageData pageData)throws Exception;
/**
*
* @param page
* @return
* @throws Exception
*/
public List<PageData> majorlist(Page page) throws Exception;
/**
*
* @param page
* @return
* @throws Exception
*/
List<PageData> verifylist(Page page) throws Exception;
/**
*
* @param page
* @return
* @throws Exception
*/
List<PageData> majormanage(Page page) throws Exception;
/**id
* @param pd
* @throws Exception
*/
public PageData findByEmisId(PageData pd)throws Exception;
public List<PageData> getListForemis(Page page)throws Exception;
}

View File

@ -2,6 +2,8 @@ package com.zcloud.service.hiddenDangerCheckStandard;
import com.zcloud.entity.PageData;
import java.util.List;
/**
* -
* luoxiaobao
@ -17,5 +19,11 @@ public interface CustomItemService {
*/
void save(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
List<PageData> getCheckItem(PageData pd)throws Exception;
}

View File

@ -1,5 +1,6 @@
package com.zcloud.service.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
@ -24,5 +25,45 @@ public interface CustomService {
*/
public List<PageData> listAll(PageData pd)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void remove(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void deleted(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void enable(PageData pd)throws Exception;
/**id
* @param pd
* @throws Exception
*/
PageData findById(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
List<PageData> getMyCheckList(PageData pd)throws Exception;
}

View File

@ -0,0 +1,110 @@
package com.zcloud.service.hiddenDangerCheckStandard;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-27
* www.zcloudchina.com
*/
public interface CustomStatisticsService {
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void deletewl(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception;
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception;
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception;
/**()
* @param pd
* @throws Exception
*/
public List<PageData> getCountList(PageData pd)throws Exception;
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception;
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception;
/**
* @param pd
* @throws Exception
*/
public PageData findByCondition(PageData pd)throws Exception;
public PageData getTimeAstrict(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public List<PageData> countStaByUser(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public List<PageData> countSta(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public List<PageData> checkSituation(PageData pd)throws Exception;
/**1
* @param pd
* @throws Exception
*/
public List<PageData> countListStaByUser(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public List<PageData> countByPeriodUser(PageData pd)throws Exception;
public List<PageData> listAllForPlan(PageData pd)throws Exception;
}

View File

@ -0,0 +1,100 @@
package com.zcloud.service.hiddenDangerCheckStandard.impl;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomCheckRecordItemMapper;
import com.zcloud.service.hiddenDangerCheckStandard.CustomCheckRecordItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
@Service
@Transactional //开启事物
public class CustomCheckRecordItemServiceImpl implements CustomCheckRecordItemService {
@Autowired
private CustomCheckRecordItemMapper customCheckRecordItemMapper;
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception{
customCheckRecordItemMapper.save(pd);
}
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception{
customCheckRecordItemMapper.delete(pd);
}
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception{
customCheckRecordItemMapper.edit(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception{
return customCheckRecordItemMapper.datalistPage(page);
}
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception{
return customCheckRecordItemMapper.listAll(pd);
}
/**()
* @param pd
* @throws Exception
*/
@Override
public List<PageData> listAllForMap(PageData pd)throws Exception{
return customCheckRecordItemMapper.listAllForMap(pd);
}
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception{
return customCheckRecordItemMapper.findById(pd);
}
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception{
customCheckRecordItemMapper.deleteAll(ArrayDATA_IDS);
}
/**
* @param pd
* @throws Exception
*/
public void editIsnormal(PageData pd)throws Exception{
customCheckRecordItemMapper.editIsnormal(pd);
}
}

View File

@ -0,0 +1,794 @@
package com.zcloud.service.hiddenDangerCheckStandard.impl;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomCheckRecordMapper;
import com.zcloud.service.hiddenDangerCheckStandard.CustomCheckRecordService;
import com.zcloud.util.DateSysUtil;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
@Service
@Transactional //开启事物
public class CustomCheckRecordServiceImpl implements CustomCheckRecordService {
@Autowired
private CustomCheckRecordMapper customCheckRecordMapper;
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception{
customCheckRecordMapper.save(pd);
}
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception{
customCheckRecordMapper.delete(pd);
}
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception{
customCheckRecordMapper.edit(pd);
}
/**
* @param pd
* @throws Exception
*/
public int countOverTime(PageData pd)throws Exception{
return customCheckRecordMapper.countOverTime(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception{
return customCheckRecordMapper.datalistPage(page);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> listAllList(Page page)throws Exception{
return customCheckRecordMapper.listlistPage(page);
}
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception{
return customCheckRecordMapper.listAll(pd);
}
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAllUnfinished(PageData pd)throws Exception{
return customCheckRecordMapper.listAllUnfinished(pd);
}
/**ID
* @param pd
* @throws Exception
*/
public List<PageData> findRiskPointByLId(PageData pd)throws Exception{
return customCheckRecordMapper.findRiskPointByLId(pd);
}
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception{
return customCheckRecordMapper.findById(pd);
}
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception{
customCheckRecordMapper.deleteAll(ArrayDATA_IDS);
}
/* 统计功能 */
@Override
public List<PageData> listCountDay(PageData pd) throws Exception {
return customCheckRecordMapper.listCountDay(pd);
}
@Override
public List<PageData> listCountWeek(PageData pd) throws Exception {
return customCheckRecordMapper.listCountWeek(pd);
}
@Override
public List<PageData> listCountTenDays(PageData pd) throws Exception {
return customCheckRecordMapper.listCountTenDays(pd);
}
@Override
public List<PageData> listCountMonth(PageData pd) throws Exception {
return customCheckRecordMapper.listCountMonth(pd);
}
@Override
public List<PageData> listCountQuarter(PageData pd) throws Exception {
return customCheckRecordMapper.listCountQuarter(pd);
}
@Override
public List<PageData> listCountHalfYear(PageData pd) throws Exception {
return customCheckRecordMapper.listCountHalfYear(pd);
}
@Override
public List<PageData> listCountYear(PageData pd) throws Exception {
return customCheckRecordMapper.listCountYear(pd);
}
@Override
public Integer listCountJjr(PageData pd) throws Exception {
return customCheckRecordMapper.listCountJjr(pd);
}
/**
* @param pd
* @throws Exception
*/
public void editStatistics(PageData pd)throws Exception{
customCheckRecordMapper.editStatistics(pd);
}
/**
*
* @param pd
* @return
*/
public List<PageData> listLogByIde(PageData pd)throws Exception{
return customCheckRecordMapper.listLogByIde(pd);
}
/**
*
* @param pd
* @return
*/
public List<PageData> recordByIde(PageData pd)throws Exception{
return customCheckRecordMapper.recordByIde(pd);
}
/**
* @param pd
* @throws Exception
*/
public void recording(PageData pd)throws Exception{
customCheckRecordMapper.recording(pd);
}
/**APP
* @param page
* @throws Exception
*/
public List<PageData> appdatalist(PageData pd)throws Exception{
return customCheckRecordMapper.appdatalist(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> countByPeriodUser(PageData pd)throws Exception{
return customCheckRecordMapper.countByPeriodUser(pd);
}
/**
*
* @param pd
* @return
*/
public int getWorkedUserCount(PageData pd) throws Exception{
return customCheckRecordMapper.getWorkedUserCount(pd);
}
/**
*
* @param pd
* @return
*/
public int getWorkedDepCount(PageData pd)throws Exception{
return customCheckRecordMapper.getWorkedDepCount(pd);
}
public List<PageData> listTypeBi(PageData pd)throws Exception{
return customCheckRecordMapper.listTypeBi(pd);
}
/**
* (ids)
* @param pd
* @return
*/
public List<PageData> listForIdsAndMonth(PageData pd)throws Exception{
return customCheckRecordMapper.listForIdsAndMonth(pd);
}
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> listAllYearForDay(PageData pd)throws Exception {
List<PageData> list = new ArrayList<>();
List<PageData> recordList = customCheckRecordMapper.listAllYearForDay(pd);
List<PageData> trList = new ArrayList<>();
for (int i = 0; i < 12; i++) {
PageData month = new PageData();
month.put("MONTH",(i+1)+"");
List<PageData> dayList = new ArrayList<>();
List<PageData> tdList = new ArrayList<>();
int days = DateSysUtil.getMonthDays(Integer.parseInt(pd.getString("YEAR")), i);
for (int j = 1; j <= days; j++) {
PageData day = new PageData();
day.put("DAY", j+"");
day.put("CHECKDATA","△"); // 默认离岗
String curDay = pd.getString("YEAR") + "-" + ((i+1) <= 9 ? "0"+(i+1) : (i+1)) + "-" + (j <= 9 ? ("0"+j) : j);
//清单生成日期在遍历日期之后(未建立清单)
if (DateSysUtil.fomatDate(pd.getString("CREATTIME").substring(0,10)).after(DateSysUtil.fomatDate(curDay))) {
day.put("CHECKDATA","-");
}
else {
for (PageData r : recordList) {
if (curDay.equals(r.getString("PERIODSTART").substring(0,10))) {
if ("1".equals(r.getString("TYPE"))) {
day.put("CHECKDATA", "√"); // 已检查(隐患数)
break;
} else if ("2".equals(r.getString("TYPE"))) {
day.put("CHECKDATA","×"); // 未排查
break;
}
}
}
}
dayList.add(day);
if (j % 7 == 0) {
PageData dayPd = new PageData();
dayPd.put("DAYLIST", dayList);
tdList.add(dayPd);
dayList = new ArrayList<>();
}
}
if (dayList.size() > 0) {
PageData dayPd = new PageData();
dayPd.put("DAYLIST", dayList);
tdList.add(dayPd);
}
String curMonth = pd.getString("YEAR") + "-" + ((i+1) <= 9 ? "0"+(i+1) : (i+1));
List<String> hdList = new ArrayList<>();
recordList.forEach(record -> {
if(DateSysUtil.isSameMonth(record.getString("CREATTIME"),curMonth)) {//如果清单创建时间是查询月
String hddesc = record.getString("HIDDEN_DESC");
if (StringUtils.isNotBlank(hddesc)) {
String[] hddescArr = hddesc.split("[$]");
for (int k = 0; k < hddescArr.length; k++) {
hdList.add(hddescArr[k]);
}
}
}
});
month.put("HDLIST", hdList);
month.put("TDLIST", tdList);
trList.add(month);
if (i!=0 && (i+1) % 2 == 0) {
PageData tr = new PageData();
tr.put("TRLIST", trList);
list.add(tr);
trList = new ArrayList<>();
}
}
if (trList.size() > 0) {
PageData tr = new PageData();
tr.put("TRLIST", trList);
list.add(tr);
}
return list;
}
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> listAllYearForWeek(PageData pd)throws Exception {
List<PageData> list = new ArrayList<>();
List<PageData> recordList = customCheckRecordMapper.listAllYearForWeek(pd);
recordList.forEach( record -> {
String week = DateSysUtil.getMonthNoAndWeekNo(record.getString("PERIODSTART")); // 按照排查任务的周期开始时间计算该任务是哪月第几周,例如:12,2
record.put("RECORD_WEEK", week);
});
String listWeek = DateSysUtil.getMonthNoAndWeekNo(pd.getString("CREATTIME"));
int index = 0, colIndex0 = 0, colIndex2 = 0, colIndex3 = 0, colIndex4 = 0, colIndex5 = 0;
for (int z = 0; z < 24; z++) {
List<PageData> trList = new ArrayList<>();
PageData col0 = new PageData();
col0.put("VALUETYPE","string");
col0.put("COLSPAN",2);
col0.put("ROWSPAN",1);
switch (index){
case 0:
col0.put("VALUE","月份");
trList.add(col0);
for (int i = 1; i <= 3; i++) {
PageData month = new PageData();
month.put("VALUETYPE","string");
month.put("VALUE", (colIndex0 * 3 + i) + "月");
month.put("COLSPAN", 5);
month.put("ROWSPAN", 1);
trList.add(month);
}
colIndex0++;
break;
case 1:
col0.put("VALUE","检查日期");
trList.add(col0);
for (int i = 1; i <= 3; i++) {
for (int j = 1; j <= 5; j++) {
PageData week = new PageData();
week.put("VALUETYPE","string");
week.put("VALUE", "第" + j + "周");
week.put("COLSPAN", 1);
week.put("ROWSPAN", 1);
trList.add(week);
}
}
break;
case 2:
col0.put("VALUE","检查情况");
col0.put("COLSPAN",1);
col0.put("ROWSPAN",4);
trList.add(col0);
PageData col1 = new PageData();
col1.put("VALUETYPE","string");
col1.put("VALUE","是否检查");
col1.put("COLSPAN",1);
col1.put("ROWSPAN",1);
trList.add(col1);
for (int i = 1; i <= 3; i++) {
for (int j = 1; j <= 5; j++) {
int month = colIndex2 * 3 + i;
String curWeek = pd.getString("YEAR") + "," + (month <= 9 ? "0"+month : month) + "," + j;
PageData col = new PageData();
col.put("VALUETYPE","string");
col.put("COLSPAN", 1);
col.put("ROWSPAN", 1);
col.put("VALUE","△"); // 默认离岗
//清单生成日期在遍历日期之后(未建立清单)
if (Integer.parseInt(listWeek.replace(",",""))>Integer.parseInt(curWeek.replace(",",""))) {
col.put("VALUE","-");
}
else {
for (PageData r : recordList) {
if (curWeek.equals(r.getString("RECORD_WEEK"))) {
if ("1".equals(r.getString("TYPE"))) {
col.put("VALUE", "√"); // 已检查(隐患数)
break;
} else if ("2".equals(r.getString("TYPE"))) {
col.put("VALUE","×"); // 未排查
break;
}
}
}
}
trList.add(col);
}
}
colIndex2++;
break;
case 3:
col0.put("VALUE","发现隐患数");
col0.put("COLSPAN",1);
col0.put("ROWSPAN",1);
trList.add(col0);
PageData col = new PageData();
col.put("VALUETYPE","array");
col.put("COLSPAN", 15);
col.put("ROWSPAN", 1);
for (int i = 1; i <= 3; i++) {
for (int j = 1; j <= 5; j++) {
int month = colIndex3 * 3 + i;
String curWeek = pd.getString("YEAR") + "," + (month <= 9 ? "0"+month : month) + "," + j;
PageData col01 = new PageData();
col01.put("VALUETYPE","string");
col01.put("COLSPAN", 1);
col01.put("ROWSPAN", 1);
col01.put("VALUE","0"); // 默认离岗
//清单生成日期在遍历日期之后(未建立清单)
if (Integer.parseInt(listWeek.replace(",",""))>Integer.parseInt(curWeek.replace(",",""))) {
col01.put("VALUE","0");
}
else {
int hiddenCount = 0;
for (PageData r : recordList) {
if (curWeek.equals(r.getString("RECORD_WEEK"))) {
if ("1".equals(r.getString("TYPE"))) {
hiddenCount += Integer.parseInt(r.getString("HIDDEN_COUNT"));
// col01.put("VALUE", r.getString("HIDDEN_COUNT")); // 已检查(隐患数)
} else if ("2".equals(r.getString("TYPE"))) {
hiddenCount = 0;
// col01.put("VALUE","0"); // 未排查
break;
}
}
}
col01.put("VALUE",hiddenCount); // 未排查
}
trList.add(col01);
}
}
// trList.add(col);
colIndex3++;
break;
case 4:
col0.put("VALUE","检查时间");
col0.put("COLSPAN",1);
trList.add(col0);
col = new PageData();
col.put("VALUETYPE","array");
col.put("COLSPAN", 15);
col.put("ROWSPAN", 1);
for (int i = 1; i <= 3; i++) {
for (int j = 1; j <= 5; j++) {
int month = colIndex4 * 3 + i;
String curWeek = pd.getString("YEAR") + "," + (month <= 9 ? "0"+month : month) + "," + j;
PageData col01 = new PageData();
col01.put("VALUETYPE","string");
col01.put("COLSPAN", 1);
col01.put("ROWSPAN", 1);
col01.put("VALUE",""); // 默认离岗
//清单生成日期在遍历日期之后(未建立清单)
if (Integer.parseInt(listWeek.replace(",",""))>Integer.parseInt(curWeek.replace(",",""))) {
col01.put("VALUE","");
}
else {
for (PageData r : recordList) {
if (curWeek.equals(r.getString("RECORD_WEEK"))) {
if ("1".equals(r.getString("TYPE"))) {
col01.put("VALUE", r.getString("CREATTIME")); // 已检查(隐患数)
break;
} else if ("2".equals(r.getString("TYPE"))) {
col01.put("VALUE",""); // 未排查
break;
}
}
}
}
trList.add(col01);
}
}
// trList.add(col);
colIndex4++;
break;
case 5:
col0.put("VALUE","发现问题");
col0.put("COLSPAN",1);
trList.add(col0);
PageData col02 = new PageData();
for (int i = 1; i <= 3; i++) {
List<String> descList = new ArrayList<>();
col02 = new PageData();
col02.put("VALUETYPE","array");
col02.put("COLSPAN", 5);
col02.put("ROWSPAN", 1);
// for (int j = 1; j <= 5; j++) {
int month = colIndex5 * 3 + i;
// String curWeek = pd.getString("YEAR") + "," + (month <= 9 ? "0"+month : month) + "," + j;
String curMonth = pd.getString("YEAR") + "-" + (month <= 9 ? "0"+month : month);
for (PageData r : recordList) {
// if (curWeek.equals(r.getString("RECORD_WEEK")) && StringUtils.isNotBlank(r.getString("HIDDENDESCR"))) {
if (DateSysUtil.isSameMonth(r.getString("PERIODSTART"),curMonth) && StringUtils.isNotBlank(r.getString("HIDDENDESCR"))) {
String[] hddescArr = r.getString("HIDDENDESCR").split("[$]");
for (int k = 0; k < hddescArr.length; k++) {
descList.add(hddescArr[k]);
}
}
}
// }
col02.put("VALUE",descList);
trList.add(col02);
}
colIndex5++;
break;
}
PageData tr = new PageData();
tr.put("TRLIST", trList);
list.add(tr);
index++;
if (index==6) { index = 0;}
}
return list;
}
/**
* (ID)
* @param pd
* @return
*/
public List<PageData> statisticsListCheckTenday(PageData pd)throws Exception {
List<PageData> list = new ArrayList<>();
List<PageData> recordList = customCheckRecordMapper.listAllYearForTenday(pd);
String[] tendayList = {"上旬", "中旬", "下旬"};
String listCreateDate = pd.getString("CREATTIME").substring(0, 10);
int index = 0, colIndex0 = 0, colIndex2 = 0, colIndex3 = 0, colIndex4 = 0, colIndex5 = 0;
for (int z = 0; z < 24; z++) {
List<PageData> trList = new ArrayList<>();
PageData col0 = new PageData();
col0.put("VALUETYPE","string");
col0.put("COLSPAN",2);
col0.put("ROWSPAN",1);
switch (index){
case 0:
col0.put("VALUE","月份");
trList.add(col0);
for (int i = 1; i <= 3; i++) {
PageData month = new PageData();
month.put("VALUETYPE","string");
month.put("VALUE", (colIndex0 * 3 + i) + "月");
month.put("COLSPAN", 3);
month.put("ROWSPAN", 1);
trList.add(month);
}
colIndex0++;
break;
case 1:
col0.put("VALUE","检查日期");
trList.add(col0);
for (int i = 1; i <= 3; i++) {
for (int j = 0; j < tendayList.length; j++) {
PageData week = new PageData();
week.put("VALUETYPE","string");
week.put("VALUE", tendayList[j]);
week.put("COLSPAN", 1);
week.put("ROWSPAN", 1);
trList.add(week);
}
}
break;
case 2:
col0.put("VALUE","检查情况");
col0.put("COLSPAN",1);
col0.put("ROWSPAN",4);
trList.add(col0);
PageData col1 = new PageData();
col1.put("VALUETYPE","string");
col1.put("VALUE","是否检查");
col1.put("COLSPAN",1);
col1.put("ROWSPAN",1);
trList.add(col1);
for (int i = 1; i <= 3; i++) {
for (int j = 0; j < tendayList.length; j++) {
int month = colIndex2 * 3 + i;
String curTendy = pd.getString("YEAR") + "-" + (month <= 9 ? "0"+month : month);
String dateBegin = "", dateEnd = "";
if (j == 0) {
dateBegin = curTendy + "-01";
dateEnd = curTendy + "-10";
} else if (j == 1) {
dateBegin = curTendy + "-11";
dateEnd = curTendy + "-20";
} else {
dateBegin = curTendy + "-21";
int lastDays = DateSysUtil.getMonthDays(Integer.parseInt(pd.getString("YEAR")),month-1);
dateEnd = curTendy + "-" + lastDays;
}
PageData col = new PageData();
col.put("VALUETYPE","string");
col.put("COLSPAN", 1);
col.put("ROWSPAN", 1);
col.put("VALUE","△"); // 默认离岗
//清单生成日期在遍历日期之后(未建立清单)
if (DateSysUtil.fomatDate(listCreateDate).getTime()>DateSysUtil.fomatDate(dateEnd).getTime()) {
col.put("VALUE","-");
}else {
for (PageData r : recordList) {
if (DateSysUtil.fomatDate(dateBegin).getTime() <= DateSysUtil.fomatDate(r.getString("PERIODSTART").substring(0, 10)).getTime()
&& DateSysUtil.fomatDate(r.getString("PERIODSTART").substring(0, 10)).getTime() <= DateSysUtil.fomatDate(dateEnd).getTime()) {
if ("1".equals(r.getString("TYPE"))) {
col.put("VALUE","√"); // 已检查(隐患数)
break;
} else if ("2".equals(r.getString("TYPE"))) {
col.put("VALUE","×"); // 未排查
break;
}
}
}
}
trList.add(col);
}
}
colIndex2++;
break;
case 3:
col0.put("VALUE","发现隐患数");
col0.put("COLSPAN",1);
trList.add(col0);
PageData col = new PageData();
col.put("VALUETYPE","array");
col.put("COLSPAN", 9);
col.put("ROWSPAN", 1);
for (int i = 1; i <= 3; i++) {
for (int j = 0; j < tendayList.length; j++) {
int month = colIndex3 * 3 + i;
String curTendy = pd.getString("YEAR") + "-" + (month <= 9 ? "0"+month : month);
String dateBegin = "", dateEnd = "";
if (j == 0) {
dateBegin = curTendy + "-01";
dateEnd = curTendy + "-10";
} else if (j == 1) {
dateBegin = curTendy + "-11";
dateEnd = curTendy + "-20";
} else {
dateBegin = curTendy + "-21";
int lastDays = DateSysUtil.getMonthDays(Integer.parseInt(pd.getString("YEAR")),month-1);
dateEnd = curTendy + "-" + lastDays;
}
PageData col2 = new PageData();
col2.put("VALUETYPE","string");
col2.put("COLSPAN", 1);
col2.put("ROWSPAN", 1);
col2.put("VALUE","0"); // 默认离岗
//清单生成日期在遍历日期之后(未建立清单)
if (DateSysUtil.fomatDate(listCreateDate).getTime()>DateSysUtil.fomatDate(dateEnd).getTime()) {
col2.put("VALUE","0");
}else {
int hiddenCount = 0;
for (PageData r : recordList) {
if (DateSysUtil.fomatDate(dateBegin).getTime() <= DateSysUtil.fomatDate(r.getString("PERIODSTART").substring(0, 10)).getTime()
&& DateSysUtil.fomatDate(r.getString("PERIODSTART").substring(0, 10)).getTime() <= DateSysUtil.fomatDate(dateEnd).getTime()) {
if ("1".equals(r.getString("TYPE"))) {
hiddenCount += Integer.parseInt(r.getString("HIDDEN_COUNT"));
// col2.put("VALUE",r.getString("HIDDEN_COUNT")); // 已检查(隐患数)
} else if ("2".equals(r.getString("TYPE"))) {
hiddenCount = 0;
break;
}
}
}
col2.put("VALUE",hiddenCount); // 未排查
}
trList.add(col2);
}
}
colIndex3++;
break;
case 4:
col0.put("VALUE","检查时间");
col0.put("COLSPAN",1);
trList.add(col0);
col = new PageData();
col.put("VALUETYPE","array");
col.put("COLSPAN", 9);
col.put("ROWSPAN", 1);
for (int i = 1; i <= 3; i++) {
for (int j = 0; j < tendayList.length; j++) {
int month = colIndex4 * 3 + i;
String curTendy = pd.getString("YEAR") + "-" + (month <= 9 ? "0"+month : month);
String dateBegin = "", dateEnd = "";
if (j == 0) {
dateBegin = curTendy + "-01";
dateEnd = curTendy + "-10";
} else if (j == 1) {
dateBegin = curTendy + "-11";
dateEnd = curTendy + "-20";
} else {
dateBegin = curTendy + "-21";
int lastDays = DateSysUtil.getMonthDays(Integer.parseInt(pd.getString("YEAR")),month-1);
dateEnd = curTendy + "-" + lastDays;
}
PageData col2 = new PageData();
col2.put("VALUETYPE","string");
col2.put("COLSPAN", 1);
col2.put("ROWSPAN", 1);
col2.put("VALUE",""); // 默认离岗
//清单生成日期在遍历日期之后(未建立清单)
if (DateSysUtil.fomatDate(listCreateDate).getTime()>DateSysUtil.fomatDate(dateEnd).getTime()) {
col2.put("VALUE","");
}else {
for (PageData r : recordList) {
if (DateSysUtil.fomatDate(dateBegin).getTime() <= DateSysUtil.fomatDate(r.getString("PERIODSTART").substring(0, 10)).getTime()
&& DateSysUtil.fomatDate(r.getString("PERIODSTART").substring(0, 10)).getTime() <= DateSysUtil.fomatDate(dateEnd).getTime()) {
if ("1".equals(r.getString("TYPE"))) {
col2.put("VALUE",r.getString("CREATTIME")); // 已检查(隐患数)
break;
} else if ("2".equals(r.getString("TYPE"))) {
col2.put("VALUE",""); // 未排查
break;
}
}
}
}
trList.add(col2);
}
}
colIndex4++;
break;
case 5:
col0.put("VALUE","发现问题");
col0.put("COLSPAN",1);
trList.add(col0);
PageData col02 = new PageData();
for (int i = 1; i <= 3; i++) {
col02 = new PageData();
col02.put("VALUETYPE","array");
col02.put("COLSPAN", 3);
col02.put("ROWSPAN", 1);
for (int j = 0; j < tendayList.length; j++) {
List<String> descList = new ArrayList<>();
int month = colIndex5 * 3 + i;
String curTendy = pd.getString("YEAR") + "-" + (month <= 9 ? "0"+month : month);
String dateBegin = "", dateEnd = "";
if (j == 0) {
dateBegin = curTendy + "-01";
dateEnd = curTendy + "-10";
} else if (j == 1) {
dateBegin = curTendy + "-11";
dateEnd = curTendy + "-20";
} else {
dateBegin = curTendy + "-21";
int lastDays = DateSysUtil.getMonthDays(Integer.parseInt(pd.getString("YEAR")),month-1);
dateEnd = curTendy + "-" + lastDays;
}
for (PageData r : recordList) {
if (DateSysUtil.isSameMonth(r.getString("PERIODSTART"),dateBegin.substring(0,7))
&& StringUtils.isNotBlank(r.getString("HIDDENDESCR")) ) {
String[] hddescArr = r.getString("HIDDENDESCR").split("[$]");
for (int k = 0; k < hddescArr.length; k++) {
descList.add(hddescArr[k]);
}
}
}
col02.put("VALUE",descList);
}
trList.add(col02);
}
colIndex5++;
break;
}
PageData tr = new PageData();
tr.put("TRLIST", trList);
list.add(tr);
index++;
if (index==6) { index = 0;}
}
return list;
}
}

View File

@ -0,0 +1,106 @@
package com.zcloud.service.hiddenDangerCheckStandard.impl;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomDisableTimeMapper;
import com.zcloud.mapper.datasource.hiddenDangerCheckStandard.ListCheckStandardItemMapper;
import com.zcloud.service.hiddenDangerCheckStandard.CustomDisableTimeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;
/**
*
* luoxiaobao
* 2020-12-30
* www.zcloudchina.com
*/
@Service
@Transactional //开启事物
public class CustomDisableTimeServiceImpl implements CustomDisableTimeService {
@Autowired
private CustomDisableTimeMapper customDisableTimeMapper;
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception{
customDisableTimeMapper.save(pd);
}
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception{
customDisableTimeMapper.delete(pd);
}
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception{
customDisableTimeMapper.edit(pd);
}
/**
* @param pd
* @throws Exception
*/
public void editEndTime(PageData pd)throws Exception{
customDisableTimeMapper.editEndTime(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception{
return customDisableTimeMapper.datalistPage(page);
}
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception{
return customDisableTimeMapper.listAll(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> listByFull(PageData pd)throws Exception{
return customDisableTimeMapper.listByFull(pd);
}
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception{
return customDisableTimeMapper.findById(pd);
}
/**
* @param pd
* @throws Exception
*/
public PageData findByList(PageData pd)throws Exception{
return customDisableTimeMapper.findByList(pd);
}
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception{
customDisableTimeMapper.deleteAll(ArrayDATA_IDS);
}
}

View File

@ -0,0 +1,791 @@
package com.zcloud.service.hiddenDangerCheckStandard.impl;
import com.alibaba.excel.EasyExcel;
import com.alibaba.excel.write.metadata.style.WriteCellStyle;
import com.alibaba.excel.write.style.HorizontalCellStyleStrategy;
import com.alibaba.excel.write.style.column.SimpleColumnWidthStyleStrategy;
import com.alibaba.fastjson.JSONObject;
import com.zcloud.entity.HiddenExcel;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.entity.system.Dictionaries;
import com.zcloud.mapper.datasource.bus.HiddenExamineMapper;
import com.zcloud.mapper.datasource.hidden.HiddenCheckMapper;
import com.zcloud.mapper.datasource.hidden.HiddenMapper;
import com.zcloud.mapper.datasource.hidden.HiddenSchemeMapper;
import com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomHiddenMapper;
import com.zcloud.service.bus.HiddenRegionService;
import com.zcloud.service.hiddenDangerCheckStandard.CustomHiddenService;
import com.zcloud.service.system.DepartmentService;
import com.zcloud.service.system.DictionariesService;
import com.zcloud.service.system.ImgFilesService;
import com.zcloud.service.system.UsersService;
import com.zcloud.util.*;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletResponse;
import java.util.*;
import java.util.stream.Collectors;
/**
*
* luoxiaobao
* 2021-01-04
* www.zcloudchina.com
*/
@Service
@Transactional //开启事物
public class CustomHiddenServiceImpl implements CustomHiddenService {
@Resource
private CustomHiddenMapper customHiddenServiceMapper;
@Resource
private DictionariesService dictionariesService;
@Resource
private UsersService usersService;
@Resource
private DepartmentService departmentService;
@Resource
private HiddenSchemeMapper hiddenSchemeMapper;
@Resource
private HiddenCheckMapper hiddenCheckMapper;
@Resource
private ImgFilesService imgFilesService;
@Resource
private HiddenExamineMapper hiddenexamineMapper;
@Autowired
private HiddenRegionService hiddenRegionService; // 隐患区域维护
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception{
customHiddenServiceMapper.save(pd);
}
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception{
customHiddenServiceMapper.delete(pd);
}
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception{
customHiddenServiceMapper.edit(pd);
}
/**
* @param pd
* @throws Exception
*/
public void editInfo(PageData pd)throws Exception{
customHiddenServiceMapper.editInfo(pd);
}
public void editISCONFIRM(PageData pd)throws Exception{
customHiddenServiceMapper.editISCONFIRM(pd);
}
public void editHIDDENLEVEL(PageData pd)throws Exception{
customHiddenServiceMapper.editHIDDENLEVEL(pd);
}
/**
* @throws Exception
*/
public void submit(PageData pd)throws Exception{
customHiddenServiceMapper.submit(pd);
}
/**
* @param pd
* @throws Exception
*/
public void changeState(PageData pd)throws Exception{
customHiddenServiceMapper.changeState(pd);
}
/**
* @param pd
* @throws Exception
*/
public void editDeadline(PageData pd)throws Exception{
customHiddenServiceMapper.editDeadline(pd);
}
/**
* @param pd
* @throws Exception
*/
public void check(PageData pd)throws Exception{
customHiddenServiceMapper.check(pd);
}
/**
* @param pd
* @throws Exception
*/
public void review(PageData pd)throws Exception{
customHiddenServiceMapper.review(pd);
}
/**
* @param pd
* @throws Exception
*/
public void rectify(PageData pd)throws Exception{
customHiddenServiceMapper.rectify(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception{
return customHiddenServiceMapper.datalistPage(page);
}
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception{
return customHiddenServiceMapper.listAll(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> getYestoday(PageData pd)throws Exception{
return customHiddenServiceMapper.getYestoday(pd);
}
/**(,使)
* @param pd
* @throws Exception
*/
public List<PageData> listAllToPrint(PageData pd)throws Exception{
return customHiddenServiceMapper.listAllToPrint(pd);
}
public List<PageData> listHiddenAll(PageData pd)throws Exception{
return customHiddenServiceMapper.listHiddenAll(pd);
}
/**
*
* @param pd
* @throws Exception
*/
public List<PageData> getHiddenByRecord(PageData pd)throws Exception{
return customHiddenServiceMapper.getHiddenByRecord(pd);
}
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception{
return customHiddenServiceMapper.findById(pd);
}
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception{
customHiddenServiceMapper.deleteAll(ArrayDATA_IDS);
}
/**
* @throws Exception
*/
public void updateAll(PageData hiddens)throws Exception{
customHiddenServiceMapper.updateAll(hiddens);
}
/**
* @throws Exception
*/
public List<PageData> hiddenStatisticsByDay(PageData pd)throws Exception{
return customHiddenServiceMapper.hiddenStatisticsByDay(pd);
}
/**
* @throws Exception
*/
public List<PageData> hiddenStatisticsAll(PageData pd)throws Exception{
return customHiddenServiceMapper.hiddenStatisticsAll(pd);
}
/**
*app ID
* @param pd CREATOR
* @return
* @throws Exception
*/
public List<PageData> getCountByCreatorId(PageData pd) throws Exception{
return customHiddenServiceMapper.getCountByCreatorId(pd);
}
/**
* app ID
* @param pd CREATOR
* @return
* @throws Exception
*/
public List<PageData> getCountByRectifiCationorId(PageData pd) throws Exception{
return customHiddenServiceMapper.getCountByRectifiCationorId(pd);
}
/**
* appID
* @param pd
* @return
* @throws Exception
*/
public List<PageData> getCountByCheckorId(PageData pd) throws Exception{
return customHiddenServiceMapper.getCountByCheckorId(pd);
}
/**
*ID
* @return
* @throws Exception
*/
public List<PageData> getBICount(PageData pd) throws Exception{
return customHiddenServiceMapper.getBICount(pd);
}
/**
*
* @return
* @throws Exception
*/
@Override
public List<PageData> getOtherHidden(PageData pd) throws Exception {
return customHiddenServiceMapper.getOtherHidden(pd);
}
/**
* ()
*/
@Override
public void submitList(PageData pd) throws Exception {
customHiddenServiceMapper.submitList(pd);
}
public List<PageData> getCountByHiddenType(PageData pd) throws Exception{
return customHiddenServiceMapper.getCountByHiddenType(pd);
}
/**
* @throws Exception
*/
public List<PageData> getHiddenNum(PageData pd)throws Exception{
return customHiddenServiceMapper.getHiddenNum(pd);
}
/**(
* @param pd
* @throws Exception
*/
public List<PageData> listAllRoll(PageData pd){
return customHiddenServiceMapper.listAllRoll(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> getDeptExamine(PageData pd)throws Exception{
return customHiddenServiceMapper.getDeptExamine(pd);
}
public List<PageData> getUserExamine(PageData pd)throws Exception{
return customHiddenServiceMapper.getUserExamine(pd);
}
public List<PageData> listAllForDiagnosis(PageData pd)throws Exception{
return customHiddenServiceMapper.listAllForDiagnosis(pd);
}
public PageData getUserIndexData(PageData pd)throws Exception{
return customHiddenServiceMapper.getUserIndexData(pd);
}
public PageData getDeptIndexData(PageData pd)throws Exception{
return customHiddenServiceMapper.getDeptIndexData(pd);
}
public PageData getSuperviseDeptIndexData(PageData pd)throws Exception{
return customHiddenServiceMapper.getSuperviseDeptIndexData(pd);
}
@Override
public List<PageData> findByKey(PageData condition) throws Exception {
return customHiddenServiceMapper.findByKey(condition);
}
@Override
public List<PageData> findByQue(PageData condition) throws Exception {
return customHiddenServiceMapper.findByQue(condition);
}
@Override
public List<PageData> findByYin(PageData condition) throws Exception {
return customHiddenServiceMapper.findByYin(condition);
}
@Override
public List<PageData> findByTs(PageData condition) throws Exception {
return customHiddenServiceMapper.findByTs(condition);
}
/**
* ID
* @param pd
* @return
* @throws Exception
*/
@Override
public List<PageData> findByInspectionId(PageData pd) throws Exception {
return customHiddenServiceMapper.findByInspectionId(pd);
}
@Override
public List<PageData> listAllInspection(PageData pd) throws Exception {
List<PageData> hiddenList = customHiddenServiceMapper.listAllInspection(pd);
for (PageData hd : hiddenList) {
PageData pd2 = new PageData();
pd2.put("FOREIGN_KEY",hd.getString("HIDDEN_ID"));
pd2.put("TYPE",3); //隐患图片
hd.put("hiddenImgs", imgFilesService.listAll(pd2));
pd2.put("TYPE",102); //隐患视频
hd.put("hiddenVideos", imgFilesService.listAll(pd2));//整改图片
}
return hiddenList;
}
@Override
public void editStateInspection(PageData pd) throws Exception {
customHiddenServiceMapper.editStateInspection(pd);
}
@Override
public void deleteByKey(PageData pd) throws Exception {
customHiddenServiceMapper.deleteByKey(pd);
}
@Override
public void deleteArray(PageData pd) throws Exception {
customHiddenServiceMapper.deleteArray(pd);
}
/**
* appID
* @param pd
* @return
* @throws Exception
*/
public List<PageData> getCountByConfirmId(PageData pd) throws Exception{
return customHiddenServiceMapper.getCountByConfirmId(pd);
}
/**
* appID
* @param pd
* @return
* @throws Exception
*/
public List<PageData> getCountSpecialByhId(PageData pd) throws Exception{
return customHiddenServiceMapper.getCountSpecialByhId(pd);
}
/**
* @param pd
* @throws Exception
*/
public void editInformation(PageData pd)throws Exception{
customHiddenServiceMapper.editInformation(pd);
}
@Override
public void editstate(PageData hiddenExa) {
customHiddenServiceMapper.editstate(hiddenExa);
}
@Override
public List<PageData> listOtherNotAccept(PageData pd) throws Exception {
return customHiddenServiceMapper.listOtherNotAccept(pd);
}
/**
* --
* @param page
* @return
* @throws Exception
*/
public List<PageData> listGwj(Page page) throws Exception{
return customHiddenServiceMapper.listGwjdatalistPage(page);
}
/**
* --
* @param page
* @return
* @throws Exception
*/
public List<PageData> listIgnore(Page page) throws Exception{
return customHiddenServiceMapper.listIgnoredatalistPage(page);
}
public void saveForEmis(String hiddenId,String resXML)throws Exception{
PageData pd = new PageData();
pd.put("HIDDEN_ID",hiddenId);
pd.put("resXML",resXML);
customHiddenServiceMapper.saveForEmis(pd);
}
/**
* @param
* @throws Exception
*/
public void deleteForEmis(String hiddenId)throws Exception{
PageData pd = new PageData();
pd.put("HIDDEN_ID",hiddenId);
customHiddenServiceMapper.deleteForEmis(pd);
}
public String goEmis (PageData pd) throws Exception{
String result = "";
// 1.整理数据
PageData hiddenPd = this.findById(pd); /** 确认之前,记录现在的隐患信息 */
// 隐患确认人
PageData dianjianUserPd = new PageData();
dianjianUserPd.put("USER_ID",hiddenPd.getString("CONFIRM_USER"));
PageData dianjianUser = usersService.findByIdForEmis(dianjianUserPd);
if(Tools.isEmpty(dianjianUser)){
return "未找到隐患确认人!";
}
if(Tools.isEmpty(dianjianUser.get("DJBM"))){
result += "隐患确认人部门没有维护对接编码!";
}
if(Tools.isEmpty(dianjianUser.get("JCR"))){
result += "隐患确认人没有维护对接编码!";
}
PageData hiddenRegion= hiddenRegionService.findById(hiddenPd.getString("CORPINFO_ID"),hiddenPd.getString("HIDDENPART"));
PageData hiddenRegionPar = new PageData();
if(null != hiddenRegion){
if(!hiddenRegion.getString("PARENT_ID").equals("0")){
hiddenRegionPar = hiddenRegionService.findById(hiddenPd.getString("CORPINFO_ID"),hiddenRegion.getString("PARENT_ID"));
if(!"0".equals(hiddenRegionPar.getString("PARENT_ID"))){
return "隐患区域等级维护错误!";
}
}
}else{
return "隐患区域等级维护错误!";
}
List<PageData> imgList = imgFilesService.getListByKeyAndType(hiddenPd.getString("HIDDEN_ID"),"3");
String imgStr = "";
for (PageData pageData:imgList){
imgStr += "192.168.192.201/file" + pageData.getString("FILEPATH")+";";
}
if (result != ""){
return result;
}
String DJSJ = DateUtil.date2Str(new Date()); // 点检时间
String BC = ""; // 班次,自动算
String DJBM = dianjianUser.get("DJBM").toString(); // 点检部门t_b_bm
String DJBC = pd.getString("DJBC"); // 点检班次
String JCR = dianjianUser.get("JCR").toString(); // 检查人
String JCLX = pd.getString("JCLX"); // 检查类型t_b_jclx--fid
String SBDL = hiddenRegionPar.getString("SBDL"); // 设备大类t_b_sbdlxx--sbdlxxdm
String SBMC = hiddenRegion.getString("SBMC");; // 设备名称t_b_shebeixx--shebeidm
String DJWT = hiddenPd.getString("HIDDENDESCR"); // 点检问题
String CJR = dianjianUser.get("JCR").toString(); // 创建人
String CJSJ = DateUtil.date2Str(new Date()); // 创建时间
String GZFL = pd.getString("GZFL"); // 故障分类 t_b_kclx
String SBZJGID = ""; // 子机构v_b_bujian_zjg
String BUJIANID = ""; // 部件v_b_bujian_bj
String PICTURE = imgStr; // 图片
StringBuffer strUrl = new StringBuffer();
strUrl.append("strDjsj=" + DJSJ);
strUrl.append("&strBc=" + "");
strUrl.append("&strDjbm=" + DJBM);
strUrl.append("&strDjbc=" + DJBC);
strUrl.append("&strJcr=" + JCR);
strUrl.append("&strJclx=" + JCLX);
strUrl.append("&strSbdl=" + SBDL);
strUrl.append("&strSbmc=" + SBMC);
strUrl.append("&strDjwt=" + DJWT);
strUrl.append("&strCjr=" + CJR);
strUrl.append("&strCjsj=" + CJSJ);
strUrl.append("&strGzfl=" + GZFL);
strUrl.append("&strSbzjgId=" + SBZJGID);
strUrl.append("&strBuJianId=" + BUJIANID);
strUrl.append("&strPicture=" + PICTURE);
String resXML = HttpEmisDuijieUtil.sendPostNoAccept(strUrl.toString());
StringBuffer strUrl2 = new StringBuffer();
strUrl2.append("djsj:" + DJSJ);
strUrl2.append(",bc:" + "");
strUrl2.append(",djbm:" + DJBM);
strUrl2.append(",djbc:" + DJBC);
strUrl2.append(",jcr:" + JCR);
strUrl2.append(",jclx:" + JCLX);
strUrl2.append(",sbdl:" + SBDL);
strUrl2.append(",sbmc:" + SBMC);
strUrl2.append(",djwt:" + DJWT);
strUrl2.append(",cjr:" + CJR);
strUrl2.append(",cjsj:" + CJSJ);
strUrl2.append(",gzfl:" + GZFL);
strUrl2.append(",sbzjgID:" + SBZJGID);
strUrl2.append(",bujianid:" + BUJIANID);
strUrl2.append(",pic:" + PICTURE);
if(strUrl2.toString().equals(resXML)){
/**
*
* 1.
* 2.
*/
this.saveForEmis(hiddenPd.getString("HIDDEN_ID"),resXML);
this.deleteForEmis(hiddenPd.getString("HIDDEN_ID"));
return "success";
}else{
//失败
return resXML;
}
}
/**
*
* @param pd
* @throws Exception
*/
public void confirmHidden (PageData pd) throws Exception{
customHiddenServiceMapper.confirmHidden(pd);
}
@Override
public List<PageData> listForSafetyEnvironmental(Page page) throws Exception {
return customHiddenServiceMapper.hiddenInspectionlistPage(page);
}
@Override
public List<PageData> listOtherNotAssign(PageData pd) throws Exception {
return customHiddenServiceMapper.listOtherNotAssign(pd);
}
@Override
public void assign(PageData pd) throws Exception {
customHiddenServiceMapper.assign(pd);
}
/**
* @param pd
* @throws Exception
*/
public void finalcheck(PageData pd)throws Exception{
customHiddenServiceMapper.finalcheck(pd);
}
@Override
public List<PageData> listOtherNotAccept4pc(PageData pd) throws Exception {
return customHiddenServiceMapper.listOtherNotAccept4pc(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> getListForTianzhang(Page page)throws Exception{
return customHiddenServiceMapper.getListForTianzhangdatalistPage(page);
}
/**
*
* @param pd
* @throws Exception
*/
public void confirmUpdate(PageData pd) throws Exception{
customHiddenServiceMapper.confirmUpdate(pd);
}
public void updateStateByHidden(String type,String hiddenId) throws Exception{
PageData pd = new PageData();
pd.put("STATE",type);
pd.put("HIDDEN_ID",hiddenId);
customHiddenServiceMapper.updateStateByHidden(pd);
}
/**
*
*/
public void updteStateBySpecialExamine(PageData pageData)throws Exception{
PageData pd = new PageData();
pd.put("HIDDENEXAMINE_ID", UuidUtil.get32UUID());
pd.put("CREATOR", Jurisdiction.getUSER_ID());
pd.put("CREATTIME", DateUtil.date2Str(new Date()));
pd.put("OPERATOR",Jurisdiction.getUSER_ID());
pd.put("OPERATTIME",DateUtil.date2Str(new Date()));
pd.put("TYPE","1");
pd.put("STATE","-1");
pd.put("EXAMINE",pageData.get("EXAMINE")); // 无法整改原因
pd.put("HIDDEN_ID",pageData.get("HIDDEN_ID"));// 隐患id
hiddenexamineMapper.save(pd);
this.updateStateByHidden("7",pageData.get("HIDDEN_ID").toString()); //修改隐患状态
}
/**
*
* @param page
* @return
* @throws Exception
*/
public List<PageData> majorlist(Page page) throws Exception{
return customHiddenServiceMapper.majordatalistPage(page);
}
/**
*
* @param page
* @return
* @throws Exception
*/
public List<PageData> verifylist(Page page) throws Exception{
return customHiddenServiceMapper.verifydatalistPage(page);
}
/**
*
* @param page
* @return
* @throws Exception
*/
public List<PageData> majormanage(Page page) throws Exception{
return customHiddenServiceMapper.majormanagelistPage(page);
}
/**id
* @param pd
* @throws Exception
*/
public PageData findByEmisId(PageData pd)throws Exception{
return customHiddenServiceMapper.findByEmisId(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> getListForemis(Page page)throws Exception{
return customHiddenServiceMapper.getListForemisdatalistPage(page);
}
@Override
public void createExcel(HttpServletResponse response, PageData request) throws Exception {
PageData lock = new PageData();
lock.putAll(request);
// 隐患级别数据字典dicMap(id:name)
String dicParentId = "5e7cf8620ba54ad89719d0be62133c7a";
List<Dictionaries> dicList = dictionariesService.listSubDictByParentId(dicParentId);// 字典
Map<String, String> dicMap = dicList.stream().collect(Collectors.toMap(Dictionaries::getBIANMA, Dictionaries::getNAME));
PageData condition = new PageData();
condition.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());// CORPINFO_ID
// 公司内所有的人员信息userList(id:name)
List<PageData> userList = usersService.listAllUser(condition);
Map<String, String> userMap = userList.stream().collect(Collectors.toMap((x -> x.getString("USER_ID")), (y -> y.getString("NAME"))));
// 公司内所有部门信息(id:name)
List<PageData> deparList = departmentService.listAll(condition);
// 查看企业下的所有部门根据部门id匹配信息
Map<String, String> deparMap = deparList.stream().collect(Collectors.toMap((x -> x.getString("DEPARTMENT_ID")), (y -> y.getString("NAME"))));
// 校验请求参数
Warden.checkRequestHiddenCreateExcel(lock);
// 查看隐患信息
condition.clear();
if ("1".equals(lock.getString("havePicture"))) {
condition.put("HIDDEN_IDS", lock.getString("hiddenIds").split(","));
} else {
condition.put("KEYWORDS", lock.getString("KEYWORDS"));
condition.put("DISPOSESTATE", lock.getString("DISPOSESTATE"));
condition.put("STATE", lock.getString("STATE"));
condition.put("STARTTIME", lock.getString("STARTTIME"));
condition.put("ENDTIME", lock.getString("ENDTIME"));
condition.put("DEPTIDS", lock.getString("DEPTIDS"));
condition.put("ISQUALIFIED", lock.getString("ISQUALIFIED"));
condition.put("HIDDENLEVEL", lock.getString("HIDDENLEVEL"));
condition.put("IS_SELF", lock.getString("IS_SELF"));
condition.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID());
}
List<PageData> varOList = customHiddenServiceMapper.listAll(condition);
Set<String> imgIds = varOList.stream().map(n -> n.getString("HIDDEN_ID")).collect(Collectors.toSet());
// 查询整改方案
List<PageData> schemeList = hiddenSchemeMapper.listExport(condition);
Map<String, PageData> schemeMap = schemeList.stream().filter(n -> "0".equals(n.getString("ISDELETE"))).collect(Collectors.toMap((n -> n.getString("HIDDEN_ID")), (m -> m)));
imgIds.addAll(schemeList.stream().map(n -> n.getString("HIDDENSCHEME_ID")).collect(Collectors.toSet()));
// 验收信息
List<PageData> checkList = hiddenCheckMapper.listExport(condition);
imgIds.addAll(checkList.stream().map(n -> n.getString("HIDDENCHECK_ID")).collect(Collectors.toSet()));
Map<String, List<PageData>> checkMap = checkList.stream().collect(Collectors.toMap((n -> n.getString("HIDDEN_ID")), (Arrays::asList)));
int checkMaxCount = checkMap.values().stream().mapToInt(List::size).max().orElse(0);
// 组织参数查询出所有跟隐患相关的图片
condition.clear();
condition.put("ArrayDATA_IDS", imgIds.toArray(new String[0]));
List<PageData> imgList = imgFilesService.listAllByIds(condition)
.stream()
.filter(n -> n.get("TYPE") != null && StringUtils.isNotBlank(n.get("TYPE").toString()))
.filter(n -> n.get("FOREIGN_KEY") != null && StringUtils.isNotBlank(n.getString("FOREIGN_KEY")))
.filter(n -> !(n.getString("FILEPATH").contains(".mp4")))//排除视频
.filter(n -> !(n.getString("FILEPATH").contains(".MP4")))
.collect(Collectors.toList());
Map<String, List<PageData>> imgMap = imgList.stream().collect(Collectors.groupingBy(m -> m.getString("FOREIGN_KEY")));
List<String> index = Arrays.asList("3", "4", "5", "8");
Map<String, Integer> limit = new HashMap<>();
for (String x : index) {
int number = imgList.stream()
.filter(n -> x.equals(n.get("TYPE").toString()))
.collect(Collectors.groupingBy(m -> m.getString("FOREIGN_KEY")))
.values().stream()
.mapToInt(List::size)
.max()
.orElse(0);
limit.put(x, number);
}
// 组装数据
HiddenExcel excel = new HiddenExcel(limit.get("3"), limit.get("4"), limit.get("8"), checkMaxCount, limit.get("5"));
excel.setHavePicture(request.getString("havePicture"));
excel.setLeveMap(dicMap);
excel.setDepMap(deparMap);
excel.setUserMap(userMap);
excel.setFoot(schemeMap);
excel.setImgMap(imgMap);
excel.setCheckMap(checkMap);
excel.setNuTitle(JSONObject.parseArray(request.getString("options"), String.class));
excel.initHead();
excel.addAllBody(varOList);
// 组装表格样式
WriteCellStyle headWriteCellStyle = HiddenExcel.getHeadStyle();
WriteCellStyle cellStyle = HiddenExcel.getHeadStyle();
HorizontalCellStyleStrategy horizontalCellStyleStrategy = new HorizontalCellStyleStrategy(headWriteCellStyle, cellStyle);
EasyExcel.write(response.getOutputStream())
.useDefaultStyle(true)
.relativeHeadRowIndex(1)
.registerWriteHandler(horizontalCellStyleStrategy)
.registerWriteHandler(new SimpleColumnWidthStyleStrategy(25))
.sheet("隐患台账")
.head(excel.getHead())
.doWrite(excel.getHand());
}
}

View File

@ -7,6 +7,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;
/**
* -
* luoxiaobao
@ -29,6 +31,11 @@ public class CustomItemServiceImpl implements CustomItemService {
customItemMapper.save(pd);
}
@Override
public List<PageData> getCheckItem(PageData pd)throws Exception {
return customItemMapper.getCheckItem(pd);
}
}

View File

@ -1,5 +1,6 @@
package com.zcloud.service.hiddenDangerCheckStandard.impl;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomMapper;
import com.zcloud.service.hiddenDangerCheckStandard.CustomService;
@ -38,6 +39,62 @@ public class CustomServiceImpl implements CustomService {
public List<PageData> listAll(PageData pd)throws Exception{
return customMapper.listAll(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception{
return customMapper.datalistPage(page);
}
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception{
customMapper.delete(pd);
}
/**
* @param pd
* @throws Exception
*/
public void remove(PageData pd)throws Exception{
customMapper.remove(pd);
}
/**
* @param pd
* @throws Exception
*/
public void deleted(PageData pd)throws Exception{
customMapper.deleted(pd);
}
/**
* @param pd
* @throws Exception
*/
public void enable(PageData pd)throws Exception{
customMapper.enable(pd);
}
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception{
return customMapper.findById(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> getMyCheckList(PageData pd)throws Exception{
return customMapper.getMyCheckList(pd);
}
}

View File

@ -0,0 +1,157 @@
package com.zcloud.service.hiddenDangerCheckStandard.impl;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomStatisticsMapper;
import com.zcloud.service.hiddenDangerCheckStandard.CustomStatisticsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;
/**
*
* luoxiaobao
* 2021-01-27
* www.zcloudchina.com
*/
@Service
@Transactional //开启事物
public class CustomStatisticsServiceImpl implements CustomStatisticsService {
@Autowired
private CustomStatisticsMapper customStatisticsMapper;
/**
* @param pd
* @throws Exception
*/
public void save(PageData pd)throws Exception{
customStatisticsMapper.save(pd);
}
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception{
customStatisticsMapper.delete(pd);
}
/**
* @param pd
* @throws Exception
*/
public void deletewl(PageData pd)throws Exception{
customStatisticsMapper.deletewl(pd);
}
/**
* @param pd
* @throws Exception
*/
public void edit(PageData pd)throws Exception{
customStatisticsMapper.edit(pd);
}
/**
* @param page
* @throws Exception
*/
public List<PageData> list(Page page)throws Exception{
return customStatisticsMapper.datalistPage(page);
}
/**()
* @param pd
* @throws Exception
*/
public List<PageData> listAll(PageData pd)throws Exception{
return customStatisticsMapper.listAll(pd);
}
/**id
* @param pd
* @throws Exception
*/
public PageData findById(PageData pd)throws Exception{
return customStatisticsMapper.findById(pd);
}
/**
* @param ArrayDATA_IDS
* @throws Exception
*/
public void deleteAll(String[] ArrayDATA_IDS)throws Exception{
customStatisticsMapper.deleteAll(ArrayDATA_IDS);
}
/**
* @param pd
* @throws Exception
*/
@Override
public PageData findByCondition(PageData pd) throws Exception {
/* PageData ls = new PageData();
List<PageData> lsList = customStatisticsMapper.findByCondition(pd);
if(lsList != null && lsList.size() > 0) {
ls = lsList.get(0);
}*/
return customStatisticsMapper.findByCondition(pd);
}
@Override
public List<PageData> getCountList(PageData pd) throws Exception {
return customStatisticsMapper.getCountList(pd);
}
@Override
public PageData getTimeAstrict(PageData pd) throws Exception {
return customStatisticsMapper.getTimeAstrict(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> countStaByUser(PageData pd)throws Exception{
return customStatisticsMapper.countStaByUser(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> countSta(PageData pd)throws Exception{
return customStatisticsMapper.countSta(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> checkSituation(PageData pd)throws Exception{
return customStatisticsMapper.checkSituation(pd);
}
/**1
* @param pd
* @throws Exception
*/
public List<PageData> countListStaByUser(PageData pd)throws Exception{
return customStatisticsMapper.countListStaByUser(pd);
}
/**
* @param pd
* @throws Exception
*/
public List<PageData> countByPeriodUser(PageData pd)throws Exception{
return customStatisticsMapper.countByPeriodUser(pd);
}
public List<PageData> listAllForPlan(PageData pd)throws Exception{
return customStatisticsMapper.listAllForPlan(pd);
}
}

View File

@ -515,4 +515,55 @@ public class PLSUtil {
}
return pageData;
}
/**
*
*
* @param polygon [[lng,lat,alt],[lng,lat,alt],[lng,lat,alt],...]
* @return [lng,lat,alt]
* @throws IOException
*/
public static List<String> getRandomPointInPolygon(List<List<Double>> polygon) {
double minX = Double.POSITIVE_INFINITY;
double minY = Double.POSITIVE_INFINITY;
double maxX = Double.NEGATIVE_INFINITY;
double maxY = Double.NEGATIVE_INFINITY;
for (List<Double> point : polygon) {
minX = Math.min(minX, point.get(0));
minY = Math.min(minY, point.get(1));
maxX = Math.max(maxX, point.get(0));
maxY = Math.max(maxY, point.get(1));
}
Random rand = new Random();
while (true) {
Double x = minX + rand.nextDouble() * (maxX - minX);
Double y = minY + rand.nextDouble() * (maxY - minY);
if (pointInPolygon(polygon, x, y)) {
List<String> point = Arrays.asList(x.toString(),y.toString(),polygon.get(0).get(2).toString());
return point;
}
}
}
/**
*
* @param polygon
* @param lng
* @param lat
* @return
*/
private static boolean pointInPolygon(List<List<Double>> polygon,double lng, double lat) {
boolean inside = false;
int n = polygon.size();
for (int i = 0, j = n - 1; i < n; j = i++) {
if (((polygon.get(i).get(1) > lat) != (polygon.get(j).get(1) > lat)) &&
(lng < (polygon.get(j).get(0) - polygon.get(i).get(0)) * (lat - polygon.get(i).get(1)) / (polygon.get(j).get(1) - polygon.get(i).get(1)) + polygon.get(i).get(0))) {
inside = !inside;
}
}
return inside;
}
}

View File

@ -143,7 +143,7 @@
un.RISKUNIT_ID,
id.IDENTIFICATIONPARTS_ID,
id.PARTSNAME,
id.ELECTRONIC_FENCE,
id.ELECTRONIC_FENCE_NAME,
id.ELECTRONIC_FENCE_ID,
d5.BIANMA BIANMA5,
d5.NAME DNAME5,

View File

@ -1519,7 +1519,7 @@
id.PARTSNAME,
id.IDENTIFICATIONPARTS_ID,
id.ELECTRONIC_FENCE_ID,
id.ELECTRONIC_FENCE,
id.ELECTRONIC_FENCE_NAME,
un.RISKUNITNAME,
de.NAME DEPT_NAME,
count(r.RISKPOINT_ID) as RISK_COUNT

View File

@ -393,6 +393,16 @@
HOTWORK_ID = #{HOTWORK_ID}
</update>
<!-- 修改位置 -->
<update id="setPosition" parameterType="pd">
update
<include refid="tableName"></include>
set
WORK_POSITION = #{WORK_POSITION}
where
HOTWORK_ID = #{HOTWORK_ID}
</update>
<!-- 列表 -->
<select id="datalistPage" parameterType="page" resultType="pd">
select

View File

@ -96,7 +96,8 @@
f.ISDELETE = 0
and bhci.ISDELETE = 0
and f.COMMON_STATUS = 1
and f.INDUSTRY_TYPE_NAMES = #{pd.CORP_TYPE_NAME}
and bhci.COMMON_ITEM_STATUS = 1
<!-- and f.INDUSTRY_TYPE_NAMES = #{pd.CORP_TYPE_NAME} -->
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
and
(

View File

@ -0,0 +1,202 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomCheckRecordItemMapper">
<!--表名 -->
<sql id="tableName">
BUS_HIDDENDANGERCHECKSTANDARD_RECORDITEM
</sql>
<!--数据字典表名 -->
<sql id="dicTableName">
SYS_DICTIONARIES
</sql>
<!-- 字段 -->
<sql id="Field">
f.CHECKRECORD_ID,
f.CUSTOM_ID,
f.CUSTOM_ITEM_ID,
f.CHECK_CATEGORY,
f.CHECK_CATEGORY_NAME,
f.CHECK_ITEM,
f.CHECK_ITEM_NAME,
f.CHECK_CONTENT,
f.CHECK_STANDARD,
f.REFERENCE_BASIS,
f.ISNORMAL,
f.CHECK_RESULT,
f.COMMON_ITEM_SORT,
f.LONGITUDE,
f.LATITUDE,
f.CORPINFO_ID,
f.ISDELETE,
f.CREATOR_ID,
f.CREATOR_NAME,
f.CREATE_TIME,
f.RECORDITEM_ID
</sql>
<!-- 字段用于新增 -->
<sql id="Field2">
CHECKRECORD_ID,
CUSTOM_ID,
CUSTOM_ITEM_ID,
CHECK_CATEGORY,
CHECK_CATEGORY_NAME,
CHECK_ITEM,
CHECK_ITEM_NAME,
CHECK_CONTENT,
CHECK_STANDARD,
REFERENCE_BASIS,
ISNORMAL,
CHECK_RESULT,
COMMON_ITEM_SORT,
LONGITUDE,
LATITUDE,
CORPINFO_ID,
ISDELETE,
CREATOR_ID,
CREATOR_NAME,
CREATE_TIME,
RECORDITEM_ID
</sql>
<!-- 字段值 -->
<sql id="FieldValue">
#{CHECKRECORD_ID},
#{CUSTOM_ID},
#{CUSTOM_ITEM_ID},
#{CHECK_CATEGORY},
#{CHECK_CATEGORY_NAME},
#{CHECK_ITEM},
#{CHECK_ITEM_NAME},
#{CHECK_CONTENT},
#{CHECK_STANDARD},
#{REFERENCE_BASIS},
#{ISNORMAL},
#{CHECK_RESULT},
#{COMMON_ITEM_SORT},
#{LONGITUDE},
#{LATITUDE},
#{CORPINFO_ID},
#{ISDELETE},
#{CREATOR_ID},
#{CREATOR_NAME},
#{CREATE_TIME},
#{RECORDITEM_ID}
</sql>
<!-- 新增-->
<insert id="save" parameterType="pd">
insert into
<include refid="tableName"></include>
(
<include refid="Field2"></include>
) values (
<include refid="FieldValue"></include>
)
</insert>
<!-- 删除-->
<delete id="delete" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '1'
where
CHECKRECORD_ID = #{CHECKRECORD_ID}
</delete>
<!-- 修改 -->
<update id="edit" parameterType="pd">
update
<include refid="tableName"></include>
set
ISNORMAL = #{ISNORMAL},
LONGITUDE=#{LONGITUDE},
LATITUDE=#{LATITUDE}
where
RECORDITEM_ID = #{RECORDITEM_ID}
</update>
<!-- 通过ID获取数据 -->
<select id="findById" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where
f.RECORDITEM_ID = #{RECORDITEM_ID}
</select>
<!-- 列表 -->
<select id="datalistPage" parameterType="page" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where f.ISDELETE = '0'
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
and
(
<!-- 根据需求自己加检索条件
字段1 LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
or
字段2 LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
-->
)
</if>
</select>
<!-- 列表(全部) -->
<select id="listAll" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>,
(select h.HIDDEN_ID from BUS_HIDDENDANGERCHECKSTANDARD_HIDDEN h where h.RECORDITEM_ID=f.RECORDITEM_ID and h.CHECKRECORD_ID=f.CHECKRECORD_ID and h.ISDELETE= '0') as HIDDEN_ID,
( select count(1) from bus_imgfiles i where i.FOREIGN_KEY = f.RECORDITEM_ID and i.TYPE = '14' ) AS IMGCOUNT,
r.IDENTIFICATION_ID
from
<include refid="tableName"></include> f
where f.CHECKRECORD_ID=#{CHECKRECORD_ID}
ORDER BY f.COMMON_ITEM_SORT
</select>
<!-- 列表(全部) -->
<select id="listAllForMap" parameterType="pd" resultType="pd">
select
f.CHECK_CONTENT,
f.LONGITUDE,
f.LATITUDE
from
<include refid="tableName"></include> f
where f.CHECKRECORD_ID=#{CHECKRECORD_ID}
group by f.CHECK_CONTENT, f.LONGITUDE, f.LATITUDE
</select>
<!-- 批量删除 -->
<delete id="deleteAll" parameterType="String">
update
<include refid="tableName"></include>
set
ISDELETE = '1'
where
RECORDITEM_ID in
<foreach item="item" index="index" collection="ArrayDATA_IDS" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
<!-- 修改状态 -->
<update id="editIsnormal" parameterType="pd">
update
<include refid="tableName"></include>
set
ISNORMAL = #{ISNORMAL}
where
CHECKRECORD_ID = #{CHECKRECORD_ID}
AND CUSTOM_ID = #{CUSTOM_ID}
AND CUSTOM_ITEM_ID = #{CUSTOM_ITEM_ID}
</update>
</mapper>

View File

@ -0,0 +1,180 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.zcloud.mapper.datasource.hiddenDangerCheckStandard.CustomDisableTimeMapper">
<!--表名 -->
<sql id="tableName">
BUS_HIDDENDANGERCHECKSTANDARD_CUSTOMDISABLETIME
</sql>
<!--数据字典表名 -->
<sql id="dicTableName">
SYS_DICTIONARIES
</sql>
<!-- 字段 -->
<sql id="Field">
f.CUSTOMDISABLETIME_ID,
f.CUSTOM_ID
f.CORPINFO_ID,
f.STARTTIME,
f.ENDTIME,
f.ISDELETE,
f.CREATOR,
f.CREATTIME,
f.OPERATOR,
f.OPERATTIME
</sql>
<!-- 字段用于新增 -->
<sql id="Field2">
CUSTOM_ID,
CORPINFO_ID,
STARTTIME,
ENDTIME,
ISDELETE,
CREATOR,
CREATTIME,
OPERATOR,
OPERATTIME,
CUSTOMDISABLETIME_ID
</sql>
<!-- 字段值 -->
<sql id="FieldValue">
#{CUSTOM_ID},
#{CORPINFO_ID},
#{STARTTIME},
#{ENDTIME},
#{ISDELETE},
#{CREATOR},
#{CREATTIME},
#{OPERATOR},
#{OPERATTIME},
#{CUSTOMDISABLETIME_ID}
</sql>
<!-- 新增-->
<insert id="save" parameterType="pd">
insert into
<include refid="tableName"></include>
(
<include refid="Field2"></include>
) values (
<include refid="FieldValue"></include>
)
</insert>
<!-- 删除-->
<delete id="delete" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '1'
where
CUSTOMDISABLETIME_ID = #{CUSTOMDISABLETIME_ID}
</delete>
<!-- 修改 -->
<update id="edit" parameterType="pd">
update
<include refid="tableName"></include>
set
LISTMANAGER_ID = #{LISTMANAGER_ID},
CORPINFO_ID = #{CORPINFO_ID},
STARTTIME = #{STARTTIME},
ENDTIME = #{ENDTIME},
CUSTOMDISABLETIME_ID = CUSTOMDISABLETIME_ID
where
CUSTOMDISABLETIME_ID = #{CUSTOMDISABLETIME_ID}
</update>
<!-- 修改 -->
<update id="editEndTime" parameterType="pd">
update
<include refid="tableName"></include>
set
ENDTIME = #{ENDTIME},
OPERATOR = #{OPERATOR},
OPERATTIME = #{OPERATTIME}
where
CUSTOMDISABLETIME_ID = #{CUSTOMDISABLETIME_ID}
</update>
<!-- 通过ID获取数据 -->
<select id="findById" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where
f.CUSTOMDISABLETIME_ID = #{CUSTOMDISABLETIME_ID}
</select>
<!-- 通过清单获取数据 -->
<select id="findByList" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where
f.CUSTOM_ID = #{CUSTOM_ID}
and f.CORPINFO_ID = #{CORPINFO_ID}
and f.ISDELETE = '0'
and f.STARTTIME &lt;= NOW()
and f.ENDTIME is null
</select>
<!-- 列表 -->
<select id="datalistPage" parameterType="page" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where f.ISDELETE = '0'
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
and
(
<!-- 根据需求自己加检索条件
字段1 LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
or
字段2 LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
-->
)
</if>
</select>
<!-- 列表(全部) -->
<select id="listAll" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
</select>
<!-- 查找完整数据 -->
<select id="listByFull" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where f.ISDELETE = '0'
AND CUSTOM_ID = #{CUSTOM_ID}
AND CORPINFO_ID =#{CORPINFO_ID}
AND STARTTIME IS NOT NULL
AND ENDTIME IS NOT NULL
</select>
<!-- 批量删除 -->
<delete id="deleteAll" parameterType="String">
update
<include refid="tableName"></include>
set
ISDELETE = '1'
where
CUSTOMDISABLETIME_ID in
<foreach item="item" index="index" collection="ArrayDATA_IDS" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
</mapper>

View File

@ -107,4 +107,24 @@
)
</insert>
<!-- 获取用户检查清单的检查项目 -->
<select id="getCheckItem" parameterType="pd" resultType="pd">
select
f.CUSTOM_ID,
f.CHECK_ITEM,
d.DICTIONARY_NAMES
from
<include refid="tableName"></include> f
left join BUS_HIDDENDANGERCHECKSTANDARD_DICTIONARY d on d.DICTIONARY_ID = t.CHECK_ITEM
where f.ISDELETE = '0' and d.ISDELETE = '0'
<if test="CUSTOM_ID != null and CUSTOM_ID != ''"><!-- 关键词检索 -->
and f.CUSTOM_ID = #{CUSTOM_ID}
</if>
<if test="CORPINFO_ID != null and CORPINFO_ID != ''"><!-- 关键词检索 -->
and f.CORPINFO_ID = #{CORPINFO_ID}
</if>
GROUP BY f.CHECK_ITEM
ORDER BY d.DICTIONARY_SORT ASC
</select>
</mapper>

View File

@ -16,64 +16,73 @@
<!-- 字段 -->
<sql id="Field">
f.CUSTOM_ID,
f.NAME,
f.PERIOD,
f.TYPE,
f.CORPINFO_ID,
f.INDUSTRY_TYPE,
f.INDUSTRY_TYPE_TREE,
f.INDUSTRY_TYPE_NAMES,
f.CHECK_STANDARD_NAME,
f.COMMON_STATUS,
f.CREATOR,
f.CREATTIME,
f.OPERATOR,
f.OPERATTIME,
f.ISDELETE,
f.CREATOR_ID,
f.CREATOR_NAME,
f.CREATE_TIME,
f.OPERATOR_ID,
f.OPERATOR_NAME,
f.OPERATE_TIME,
f.DELETEOR_ID,
f.DELETEOR_NAME,
f.DELETE_TIME
f.DEPARTMENT_ID,
f.POST_ID,
f.USER_ID,
f.START_DATE,
f.END_DATE,
f.SCREENTYPE,
f.BAO_BAO_DEPARTMENT_ID,
f.BAO_BAO_USER_ID,
f.BAO_BAO_TYPE,
f.TASK_TYPE
</sql>
<!-- 字段用于新增 -->
<sql id="Field2">
CUSTOM_ID,
NAME,
PERIOD,
TYPE,
CORPINFO_ID,
INDUSTRY_TYPE,
INDUSTRY_TYPE_TREE,
INDUSTRY_TYPE_NAMES,
CHECK_STANDARD_NAME,
COMMON_STATUS,
CREATOR,
CREATTIME,
OPERATOR,
OPERATTIME,
ISDELETE,
CREATOR_ID,
CREATOR_NAME,
CREATE_TIME,
OPERATOR_ID,
OPERATOR_NAME,
OPERATE_TIME,
DELETEOR_ID,
DELETEOR_NAME,
DELETE_TIME
DEPARTMENT_ID,
POST_ID,
USER_ID,
START_DATE,
END_DATE,
SCREENTYPE,
BAO_BAO_DEPARTMENT_ID,
BAO_BAO_USER_ID,
BAO_BAO_TYPE,
TASK_TYPE
</sql>
<!-- 字段值 -->
<sql id="FieldValue">
#{CUSTOM_ID},
#{NAME},
#{PERIOD},
#{TYPE},
#{CORPINFO_ID},
#{INDUSTRY_TYPE},
#{INDUSTRY_TYPE_TREE},
#{INDUSTRY_TYPE_NAMES},
#{CHECK_STANDARD_NAME},
#{COMMON_STATUS},
#{CREATOR},
#{CREATTIME},
#{OPERATOR},
#{OPERATTIME},
#{ISDELETE},
#{CREATOR_ID},
#{CREATOR_NAME},
#{CREATE_TIME},
#{OPERATOR_ID},
#{OPERATOR_NAME},
#{OPERATE_TIME},
#{DELETEOR_ID},
#{DELETEOR_NAME},
#{DELETE_TIME}
#{DEPARTMENT_ID},
#{POST_ID},
#{USER_ID},
#{START_DATE},
#{END_DATE},
#{SCREENTYPE},
#{BAO_BAO_DEPARTMENT_ID},
#{BAO_BAO_USER_ID},
#{BAO_BAO_TYPE},
#{TASK_TYPE}
</sql>
<!-- 新增 -->
@ -90,32 +99,245 @@
<!-- 列表(全部) -->
<select id="listAll" parameterType="pd" resultType="pd">
select
f.CUSTOM_ID,
f.CORPINFO_ID,
f.INDUSTRY_TYPE,
f.INDUSTRY_TYPE_TREE,
f.INDUSTRY_TYPE_NAMES,
f.CHECK_STANDARD_NAME,
bhci.CUSTOM_ITEM_ID,
bhci.CUSTOM_ID,
bhci.CHECK_CATEGORY,
bhci.CHECK_ITEM,
bhci.CHECK_CONTENT,
bhci.CHECK_STANDARD,
bhci.REFERENCE_BASIS,
bhci.CHECK_QUALIFIED,
bhci.CHECK_UNQUALIFIED,
bhci.OPERATION_TYPE,
bhci.COMMON_ITEM_SORT,
bhci.COMMON_ID,
bhci.COMMON_ITEM_ID,
bhd1.DICTIONARY_NAME as CHECK_CATEGORY_NAME,
bhd2.DICTIONARY_NAME as CHECK_ITEM_NAME
<include refid="Field"></include>,
p.NAME PERIODNAME,
t.NAME TYPENAME,
d.NAME as DEPARTMENT_NAME,
sp.NAME as POST_NAME,
u.NAME USER_NAME,
bb.NAME as TASK_TYPE_NAME,
s.NAME as SCREENTYPENAME,
(select count(1) from bus_hiddendangercheckstandard_custom_item ch where
ch.CUSTOM_ID = f.CUSTOM_ID and ch.ISDELETE = '0') as count ,
(SELECT count(1) FROM bus_hiddendangercheckstandard_checkrecord ch WHERE ch.CUSTOM_ID =
f.CUSTOM_ID AND ch.FINISHED = '1' AND ch.ISDELETE = 0 ) as cdcount
from
<include refid="tableName"></include> f
left join bus_hiddendangercheckstandard_custom_item bhci on bhci.CUSTOM_ID = f.CUSTOM_ID
left join bus_hiddendangercheckstandard_dictionary bhd1 on bhd1.DICTIONARY_ID = bhci.CHECK_CATEGORY and bhd1.ISDELETE = 0
left join bus_hiddendangercheckstandard_dictionary bhd2 on bhd2.DICTIONARY_ID = bhci.CHECK_ITEM and bhd2.ISDELETE = 0
left join sys_dictionaries p on f.PERIOD = p.BIANMA
left join sys_dictionaries t on f.TYPE = t.BIANMA
left join sys_dictionaries s on f.SCREENTYPE = s.BIANMA
left join sys_dictionaries bb on f.TASK_TYPE = bb.DICTIONARIES_ID
left join OA_DEPARTMENT d on d.DEPARTMENT_ID=f.DEPARTMENT_ID
left join SYS_POST sp on sp.POST_ID = f.POST_ID
left join sys_user u on u.USER_ID = f.USER_ID
where f.CORPINFO_ID = #{pd.CORPINFO_ID}
and f.ISDELETE != '2'
and f.ISDELETE !='-1'
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
and
(
f.NAME LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
)
</if>
<if test="pd.POST_ID != null and pd.POST_ID != ''"><!-- 关键词检索 -->
and
(
f.POST_ID = #{pd.POST_ID}
)
</if>
<if test="pd.PERIOD != null and pd.PERIOD != ''"><!-- 关键词检索 -->
and f.PERIOD = #{pd.PERIOD}
</if>
<if test="pd.USERNAME != null and pd.USERNAME != ''"><!-- 关键词检索 -->
and u.NAME LIKE CONCAT(CONCAT('%', #{pd.USERNAME}),'%')
</if>
<if test="pd.TYPE != null and pd.TYPE != ''"><!-- 关键词检索 -->
and f.TYPE = #{pd.TYPE}
</if>
<if test="pd.LISTINGLEVEL != null and pd.LISTINGLEVEL != ''"><!-- 关键词检索 -->
<choose>
<when test='pd.LISTINGLEVEL == "1"'>
and d.LEVEL = ''
</when>
<otherwise>
and d.LEVEL = #{pd.LISTINGLEVEL}
</otherwise>
</choose>
</if>
<if test="pd.SCREENTYPE != null and pd.SCREENTYPE != ''"><!-- 关键词检索 -->
and f.SCREENTYPE = #{pd.SCREENTYPE}
</if>
order by f.ISDELETE,f.OPERATTIME desc
</select>
<!-- 列表(全部) -->
<select id="datalistPage" parameterType="page" resultType="pd">
select
<include refid="Field"></include>,
p.NAME PERIODNAME,
t.NAME TYPENAME,
d.NAME as DEPARTMENT_NAME,
sp.NAME as POST_NAME,
u.NAME USER_NAME,
bb.NAME as TASK_TYPE_NAME,
s.NAME as SCREENTYPENAME,
(select count(1) from bus_hiddendangercheckstandard_custom_item ch where
ch.CUSTOM_ID = f.CUSTOM_ID and ch.ISDELETE = '0') as count ,
(SELECT count(1) FROM bus_hiddendangercheckstandard_checkrecord ch WHERE ch.CUSTOM_ID =
f.CUSTOM_ID AND ch.FINISHED = '1' AND ch.ISDELETE = 0 ) as cdcount
from
<include refid="tableName"></include> f
left join sys_dictionaries p on f.PERIOD = p.BIANMA
left join sys_dictionaries t on f.TYPE = t.BIANMA
left join sys_dictionaries s on f.SCREENTYPE = s.BIANMA
left join sys_dictionaries bb on f.TASK_TYPE = bb.DICTIONARIES_ID
left join OA_DEPARTMENT d on d.DEPARTMENT_ID=f.DEPARTMENT_ID
left join SYS_POST sp on sp.POST_ID = f.POST_ID
left join sys_user u on u.USER_ID = f.USER_ID
where f.CORPINFO_ID = #{pd.CORPINFO_ID}
and f.ISDELETE != '2'
and f.ISDELETE !='-1'
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
and
(
f.NAME LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
)
</if>
<if test="pd.POST_ID != null and pd.POST_ID != ''"><!-- 关键词检索 -->
and
(
f.POST_ID = #{pd.POST_ID}
)
</if>
<if test="pd.PERIOD != null and pd.PERIOD != ''"><!-- 关键词检索 -->
and f.PERIOD = #{pd.PERIOD}
</if>
<if test="pd.USERNAME != null and pd.USERNAME != ''"><!-- 关键词检索 -->
and u.NAME LIKE CONCAT(CONCAT('%', #{pd.USERNAME}),'%')
</if>
<if test="pd.TYPE != null and pd.TYPE != ''"><!-- 关键词检索 -->
and f.TYPE = #{pd.TYPE}
</if>
<if test="pd.LISTINGLEVEL != null and pd.LISTINGLEVEL != ''"><!-- 关键词检索 -->
<choose>
<when test='pd.LISTINGLEVEL == "1"'>
and d.LEVEL = ''
</when>
<otherwise>
and d.LEVEL = #{pd.LISTINGLEVEL}
</otherwise>
</choose>
</if>
<if test="pd.SCREENTYPE != null and pd.SCREENTYPE != ''"><!-- 关键词检索 -->
and f.SCREENTYPE = #{pd.SCREENTYPE}
</if>
order by f.ISDELETE,f.OPERATTIME desc
</select>
<!-- 禁用 -->
<delete id="delete" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '1'
<if test="OPERATTIME != null or OPERATTIME != ''">
,OPERATTIME =#{OPERATTIME}
</if>
<if test="OPERATOR != null or OPERATOR != ''">
,OPERATOR =#{OPERATOR}
</if>
where
CUSTOM_ID = #{CUSTOM_ID}
</delete>
<!-- 删除 -->
<delete id="remove" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '2'
<if test="OPERATTIME != null or OPERATTIME != ''">
,OPERATTIME =#{OPERATTIME}
</if>
<if test="OPERATOR != null or OPERATOR != ''">
,OPERATOR =#{OPERATOR}
</if>
where
CUSTOM_ID = #{CUSTOM_ID}
</delete>
<!-- 删除 -->
<delete id="deleted" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '-1'
<if test="OPERATTIME != null or OPERATTIME != ''">
,OPERATTIME =#{OPERATTIME}
</if>
<if test="OPERATOR != null or OPERATOR != ''">
,OPERATOR =#{OPERATOR}
</if>
where
CUSTOM_ID = #{CUSTOM_ID}
</delete>
<!-- 启用 -->
<update id="enable" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '0'
<if test="OPERATTIME != null or OPERATTIME != ''">
,OPERATTIME =#{OPERATTIME}
</if>
<if test="OPERATOR != null or OPERATOR != ''">
,OPERATOR =#{OPERATOR}
</if>
where
CUSTOM_ID = #{CUSTOM_ID}
</update>
<!-- 通过ID获取数据 -->
<select id="findById" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>,
p.NAME PERIODNAME,
t.NAME TYPENAME,
d.NAME as DEPARTMENT_NAME,
tt.NAME as TASK_TYPE_NAME,
sp.NAME
AS POST_NAME,
s.NAME AS SCREENTYPENAME,
u.NAME AS USER_NAME,
bb.NAME as BAO_BAO_USER_NAME,
bbd.NAME as BAO_BAO_DEPARTMENT_NAME
from
<include refid="tableName"></include>
f
left join sys_dictionaries p on f.PERIOD = p.BIANMA
left join sys_dictionaries t on f.TYPE = t.BIANMA
left join sys_dictionaries s on f.SCREENTYPE = s.BIANMA
left join sys_dictionaries tt on f.TASK_TYPE = tt.DICTIONARIES_ID
left join OA_DEPARTMENT d on d.DEPARTMENT_ID=f.DEPARTMENT_ID
left join SYS_POST sp on sp.POST_ID = f.POST_ID
LEFT JOIN SYS_USER u on u.USER_ID = f.USER_ID
LEFT JOIN SYS_USER bb on bb.USER_ID = f.BAO_BAO_USER_ID
left join OA_DEPARTMENT bbd on bbd.DEPARTMENT_ID=f.DEPARTMENT_ID
where
f.CUSTOM_ID = #{CUSTOM_ID}
</select>
<!-- 列表(全部) -->
<select id="getMyCheckList" parameterType="pd" resultType="pd">
select
f.CUSTOM_ID,
f.CORPINFO_ID,
f.NAME,
t.NAME TYPENAME,
p.NAME PERIODNAME,
f.USER_ID
u.NAME USER_NAME,
f.START_DATE,
f.END_DATE,
f.BAO_BAO_TYPE,
COUNT(bhci.CUSTOM_ITEM_ID) count,
getStandardCheckedNum(f.CUSTOM_ID) checkCount
from
<include refid="tableName"></include> f
left join sys_dictionaries t on f.TYPE = t.BIANMA
left join sys_dictionaries p on f.PERIOD = p.BIANMA
left join OA_DEPARTMENT d on d.DEPARTMENT_ID=f.DEPARTMENT_ID
left join sys_user u on u.USER_ID = f.USER_ID
left join bus_hiddendangercheckstandard_custom_item bhci on bhci.CUSTOM_ID = f.CUSTOM_ID and bhci.ISDELETE = '0'
where
f.ISDELETE = 0
and bhci.ISDELETE = 0
@ -127,6 +349,7 @@
bhci.CHECK_CONTENT LIKE CONCAT(CONCAT('%', #{KEYWORDS}),'%')
)
</if>
order by bhci.CHECK_CATEGORY,bhci.CHECK_ITEM,bhci.COMMON_ITEM_SORT
GROUP BY f.CUSTOM_ID
ORDER BY f.COMMON_ITEM_SORT ASC
</select>
</mapper>