Merge branches 'genchuang' and 'master' of https://sinanoaq.cn:8888/r/safePlatform-out into master
| | |
| | | </foreach> |
| | | </if> |
| | | GROUP BY |
| | | DATE_FORMAT( a.gmt_create, '%Y-%m-%d' ) |
| | | DATE_FORMAT( a.gmt_create, '%Y-%m-%d' ), |
| | | DATE_FORMAT( a.gmt_create, '%d' ) |
| | | </select> |
| | | |
| | | <select id="selectByMonthAndDeptForIntegerMonth" resultMap="emergencyDrillExecuteCountRPC"> |
| | |
| | | </foreach> |
| | | </if> |
| | | GROUP BY |
| | | DATE_FORMAT( a.gmt_create, '%Y-%m' ) |
| | | DATE_FORMAT( a.gmt_create, '%Y-%m' ), |
| | | DATE_FORMAT( a.gmt_create, '%m' ) |
| | | </select> |
| | | |
| | | |
| | |
| | | repairDetail.setRepairEndDate(new Timestamp(new java.util.Date().getTime())); |
| | | repairDetail.setRepairPersonDepartmentId(0L); |
| | | repairDetail.setRepairMemo(""); |
| | | repairDetail.setRepairStatus(0); |
| | | repairDetail.setRepairStatus((byte)0); |
| | | repairDetail.setExceptionInfo(""); |
| | | repairDetails.add(repairDetail); |
| | | infoDto.setRepaireDetailList(repairDetails); |
| | |
| | | infoDto.setSetPart(""); |
| | | infoDto.setProduceTime(new Timestamp(new java.util.Date().getTime())); |
| | | infoDto.setUseEndDay(""); |
| | | infoDto.setLifeCycle(0); |
| | | infoDto.setLifeCycle((byte)0); |
| | | infoDto.setUseDate(new Timestamp(new java.util.Date().getTime())); |
| | | infoDto.setRepairStatus(0); |
| | | infoDto.setStopStatus(0); |
| | | infoDto.setRepairStatus((byte)0); |
| | | infoDto.setStopStatus((byte)0); |
| | | infoDto.setPreviousCheckDate(new Timestamp(new java.util.Date().getTime())); |
| | | infoDto.setPreviousTestDate(new Timestamp(new java.util.Date().getTime())); |
| | | infoDto.setPreviousTakecareDate(new Timestamp(new java.util.Date().getTime())); |
| | |
| | | repairDetail.setRepairEndDate(new Timestamp(new java.util.Date().getTime())); |
| | | repairDetail.setRepairPersonDepartmentId(0L); |
| | | repairDetail.setRepairMemo(""); |
| | | repairDetail.setRepairStatus(0); |
| | | repairDetail.setRepairStatus((byte)0); |
| | | repairDetail.setExceptionInfo(""); |
| | | repairDetails.add(repairDetail); |
| | | infoDto.setRepaireDetailList(repairDetails); |
| | |
| | | infoDto.setConnectPersonId(0L); |
| | | infoDto.setInputPersonId(0L); |
| | | infoDto.setResponsibilityPersonId(0L); |
| | | infoDto.setPartType(0); |
| | | infoDto.setPartType((byte)0); |
| | | infoDto.setCheckCycle(""); |
| | | infoDto.setEmergencePlanId(0L); |
| | | infoDto.setDangerousElement(""); |
| | |
| | | this.useEndDay = useEndDay; |
| | | } |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | private Integer lifeCycle; |
| | | private Byte lifeCycle; |
| | | |
| | | public Integer getLifeCycle() { |
| | | public Byte getLifeCycle() { |
| | | return lifeCycle; |
| | | } |
| | | |
| | | public void setLifeCycle(Integer lifeCycle) { |
| | | public void setLifeCycle(Byte lifeCycle) { |
| | | this.lifeCycle = lifeCycle; |
| | | } |
| | | //投用日期 |
| | |
| | | this.useDate = useDate; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | private Integer stopStatus; |
| | | private Byte stopStatus; |
| | | |
| | | public Integer getStopStatus() { |
| | | public Byte getStopStatus() { |
| | | return stopStatus; |
| | | } |
| | | |
| | | public void setStopStatus(Integer stopStatus) { |
| | | public void setStopStatus(Byte stopStatus) { |
| | | this.stopStatus = stopStatus; |
| | | } |
| | | //上次检查日期 |
| | |
| | | this.repairMemo = repairMemo; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //设施异常项 |
| | |
| | | this.responsibilityPersonName = responsibilityPersonName; |
| | | } |
| | | //装置部位分类 1:关键装置 2:重点部位 |
| | | private Integer partType; |
| | | private Byte partType; |
| | | |
| | | public Integer getPartType() { |
| | | public Byte getPartType() { |
| | | return partType; |
| | | } |
| | | |
| | | public void setPartType(Integer partType) { |
| | | public void setPartType(Byte partType) { |
| | | this.partType = partType; |
| | | } |
| | | //检查周期 |
对比新文件 |
| | |
| | | package com.gkhy.safePlatform.equipment.enums; |
| | | |
| | | import java.util.HashMap; |
| | | import java.util.Map; |
| | | |
| | | public enum EquipmentLifeCycleEnum { |
| | | |
| | | LIVE_CYCLE_ONE((byte) 1, "已投用"), |
| | | LIVE_CYCLE_TWO((byte) 2, "库存中"), |
| | | LIVE_CYCLE_THREE((byte) 3, "报废"); |
| | | |
| | | |
| | | private Byte code; |
| | | private String value; |
| | | |
| | | EquipmentLifeCycleEnum(Byte code, String value) { |
| | | this.code = code; |
| | | this.value = value; |
| | | } |
| | | |
| | | public Byte getCode() { |
| | | return code; |
| | | } |
| | | |
| | | public void setCode(Byte code) { |
| | | this.code = code; |
| | | } |
| | | |
| | | public String getValue() { |
| | | return value; |
| | | } |
| | | |
| | | public void setValue(String value) { |
| | | this.value = value; |
| | | } |
| | | |
| | | // 转换成为 MAP<Byte, String>, 对外提供查询和遍历功能 |
| | | public static Map<Byte, EquipmentLifeCycleEnum> toMap() { |
| | | Map<Byte, EquipmentLifeCycleEnum> map = new HashMap(); |
| | | for (EquipmentLifeCycleEnum accidentExpressEnum : EquipmentLifeCycleEnum.values()) { |
| | | map.put(accidentExpressEnum.getCode(), accidentExpressEnum); |
| | | } |
| | | return map; |
| | | } |
| | | public static EquipmentLifeCycleEnum getByCode(Byte code){ |
| | | return toMap().get(code); |
| | | } |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.safePlatform.equipment.enums; |
| | | |
| | | import java.util.HashMap; |
| | | import java.util.Map; |
| | | |
| | | public enum EquipmentRepairStatusEnum { |
| | | |
| | | REPAIR_STATUS_ONE((byte) 1, "维修中"), |
| | | REPAIR_STATUS_TWO((byte) 2, "已修好"); |
| | | |
| | | |
| | | private Byte code; |
| | | private String value; |
| | | |
| | | EquipmentRepairStatusEnum(Byte code, String value) { |
| | | this.code = code; |
| | | this.value = value; |
| | | } |
| | | |
| | | public Byte getCode() { |
| | | return code; |
| | | } |
| | | |
| | | public void setCode(Byte code) { |
| | | this.code = code; |
| | | } |
| | | |
| | | public String getValue() { |
| | | return value; |
| | | } |
| | | |
| | | public void setValue(String value) { |
| | | this.value = value; |
| | | } |
| | | |
| | | // 转换成为 MAP<Byte, String>, 对外提供查询和遍历功能 |
| | | public static Map<Byte, EquipmentRepairStatusEnum> toMap() { |
| | | Map<Byte, EquipmentRepairStatusEnum> map = new HashMap(); |
| | | for (EquipmentRepairStatusEnum accidentExpressEnum : EquipmentRepairStatusEnum.values()) { |
| | | map.put(accidentExpressEnum.getCode(), accidentExpressEnum); |
| | | } |
| | | return map; |
| | | } |
| | | public static EquipmentRepairStatusEnum getByCode(Byte code){ |
| | | return toMap().get(code); |
| | | } |
| | | } |
| | |
| | | |
| | | public enum EquipmentResultCodes { |
| | | |
| | | EQUIPMENT_ENUM_LIFE_CYCLE_NOT_EXIST("E1001","设备生命周期类型异常"), |
| | | |
| | | EQUIPMENT_ENUM_STOP_STATUS_NOT_EXIST("E1002","设备停用状态类型异常"), |
| | | |
| | | EQUIPMENT_ENUM_REPAIR_STATUS_NOT_EXIST("E1003","设备维修状态类型异常"), |
| | | |
| | | KEYPOINT_EQUIPMENT_ENUM_PART_TYPE_NOT_EXIST("K1001","重点设备装置部位分类类型异常"), |
| | | |
| | | ERROR("A3000", "未知错误"); |
| | | |
对比新文件 |
| | |
| | | package com.gkhy.safePlatform.equipment.enums; |
| | | |
| | | import java.util.HashMap; |
| | | import java.util.Map; |
| | | |
| | | public enum EquipmentStopStatusEnum { |
| | | |
| | | STOP_STATUS_ONE((byte) 1, "停用"), |
| | | STOP_STATUS_TWO((byte) 2, "在用"), |
| | | STOP_STATUS_THREE((byte) 3, "维修"), |
| | | STOP_STATUS_FOUR((byte) 4, "报废"); |
| | | |
| | | |
| | | private Byte code; |
| | | private String value; |
| | | |
| | | EquipmentStopStatusEnum(Byte code, String value) { |
| | | this.code = code; |
| | | this.value = value; |
| | | } |
| | | |
| | | public Byte getCode() { |
| | | return code; |
| | | } |
| | | |
| | | public void setCode(Byte code) { |
| | | this.code = code; |
| | | } |
| | | |
| | | public String getValue() { |
| | | return value; |
| | | } |
| | | |
| | | public void setValue(String value) { |
| | | this.value = value; |
| | | } |
| | | |
| | | // 转换成为 MAP<Byte, String>, 对外提供查询和遍历功能 |
| | | public static Map<Byte, EquipmentStopStatusEnum> toMap() { |
| | | Map<Byte, EquipmentStopStatusEnum> map = new HashMap(); |
| | | for (EquipmentStopStatusEnum accidentExpressEnum : EquipmentStopStatusEnum.values()) { |
| | | map.put(accidentExpressEnum.getCode(), accidentExpressEnum); |
| | | } |
| | | return map; |
| | | } |
| | | public static EquipmentStopStatusEnum getByCode(Byte code){ |
| | | return toMap().get(code); |
| | | } |
| | | } |
对比新文件 |
| | |
| | | package com.gkhy.safePlatform.equipment.enums; |
| | | |
| | | import java.util.HashMap; |
| | | import java.util.Map; |
| | | |
| | | public enum KeypointEquipmentPartTypeEnum { |
| | | |
| | | PART_TYPE_ONE((byte) 1, "关键装置"), |
| | | PART_TYPE_TWO((byte) 2, "重点部位"); |
| | | |
| | | |
| | | private Byte code; |
| | | private String value; |
| | | |
| | | KeypointEquipmentPartTypeEnum(Byte code, String value) { |
| | | this.code = code; |
| | | this.value = value; |
| | | } |
| | | |
| | | public Byte getCode() { |
| | | return code; |
| | | } |
| | | |
| | | public void setCode(Byte code) { |
| | | this.code = code; |
| | | } |
| | | |
| | | public String getValue() { |
| | | return value; |
| | | } |
| | | |
| | | public void setValue(String value) { |
| | | this.value = value; |
| | | } |
| | | |
| | | // 转换成为 MAP<Byte, String>, 对外提供查询和遍历功能 |
| | | public static Map<Byte, KeypointEquipmentPartTypeEnum> toMap() { |
| | | Map<Byte, KeypointEquipmentPartTypeEnum> map = new HashMap(); |
| | | for (KeypointEquipmentPartTypeEnum accidentExpressEnum : KeypointEquipmentPartTypeEnum.values()) { |
| | | map.put(accidentExpressEnum.getCode(), accidentExpressEnum); |
| | | } |
| | | return map; |
| | | } |
| | | public static KeypointEquipmentPartTypeEnum getByCode(Byte code){ |
| | | return toMap().get(code); |
| | | } |
| | | } |
| | |
| | | private String useEndDay; |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | @ExcelCell(index = 11) |
| | | private Integer lifeCycle; |
| | | private Byte lifeCycle; |
| | | //投用日期 |
| | | @ExcelCell(index = 12) |
| | | private Timestamp useDate; |
| | | //维修状态 1:维修中 2:已修好 |
| | | @ExcelCell(index = 13) |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | @ExcelCell(index = 14) |
| | | private Integer stopStatus; |
| | | private Byte stopStatus; |
| | | //上次检查日期 |
| | | @ExcelCell(index = 15) |
| | | private Timestamp previousCheckDate; |
| | |
| | | this.useEndDay = useEndDay; |
| | | } |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | public Integer getLifeCycle() { |
| | | public Byte getLifeCycle() { |
| | | return lifeCycle; |
| | | } |
| | | |
| | | public void setLifeCycle(Integer lifeCycle) { |
| | | public void setLifeCycle(Byte lifeCycle) { |
| | | this.lifeCycle = lifeCycle; |
| | | } |
| | | //投用日期 |
| | |
| | | this.useDate = useDate; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | public Integer getStopStatus() { |
| | | public Byte getStopStatus() { |
| | | return stopStatus; |
| | | } |
| | | |
| | | public void setStopStatus(Integer stopStatus) { |
| | | public void setStopStatus(Byte stopStatus) { |
| | | this.stopStatus = stopStatus; |
| | | } |
| | | //上次检查日期 |
| | |
| | | //使用期限(天) |
| | | private String useEndDay; |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | private Integer lifeCycle; |
| | | private Byte lifeCycle; |
| | | //投用日期 |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Timestamp useDate; |
| | | //维修状态 1:维修中 2:已修好 |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | private Integer stopStatus; |
| | | private Byte stopStatus; |
| | | //上次检查日期 |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Timestamp previousCheckDate; |
| | |
| | | this.useEndDay = useEndDay; |
| | | } |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | public Integer getLifeCycle() { |
| | | public Byte getLifeCycle() { |
| | | return lifeCycle; |
| | | } |
| | | |
| | | public void setLifeCycle(Integer lifeCycle) { |
| | | public void setLifeCycle(Byte lifeCycle) { |
| | | this.lifeCycle = lifeCycle; |
| | | } |
| | | //投用日期 |
| | |
| | | this.useDate = useDate; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | public Integer getStopStatus() { |
| | | public Byte getStopStatus() { |
| | | return stopStatus; |
| | | } |
| | | |
| | | public void setStopStatus(Integer stopStatus) { |
| | | public void setStopStatus(Byte stopStatus) { |
| | | this.stopStatus = stopStatus; |
| | | } |
| | | //上次检查日期 |
| | |
| | | private String repairMemo; |
| | | //维修状态 1:维修中 2:已修好 |
| | | @Query() |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | //设施异常项 |
| | | @Query() |
| | | private String exceptionInfo; |
| | |
| | | this.repairMemo = repairMemo; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //设施异常项 |
| | |
| | | private Long responsibilityPersonId; |
| | | //装置部位分类 1:关键装置 2:重点部位 |
| | | @ExcelCell(index = 9) |
| | | private Integer partType; |
| | | private Byte partType; |
| | | //检查周期 |
| | | @ExcelCell(index = 10) |
| | | private String checkCycle; |
| | |
| | | this.responsibilityPersonId = responsibilityPersonId; |
| | | } |
| | | //装置部位分类 1:关键装置 2:重点部位 |
| | | public Integer getPartType() { |
| | | public Byte getPartType() { |
| | | return partType; |
| | | } |
| | | |
| | | public void setPartType(Integer partType) { |
| | | public void setPartType(Byte partType) { |
| | | this.partType = partType; |
| | | } |
| | | //检查周期 |
| | |
| | | //使用期限(天) |
| | | private String useEndDay; |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | private Integer lifeCycle; |
| | | private Byte lifeCycle; |
| | | //投用日期 |
| | | private Timestamp useDate; |
| | | //维修状态 1:维修中 2:已修好 |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | private Integer stopStatus; |
| | | private Byte stopStatus; |
| | | //上次检查日期 |
| | | private Timestamp previousCheckDate; |
| | | //上次检测日期 |
| | |
| | | this.useEndDay = useEndDay; |
| | | } |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | public Integer getLifeCycle() { |
| | | public Byte getLifeCycle() { |
| | | return lifeCycle; |
| | | } |
| | | |
| | | public void setLifeCycle(Integer lifeCycle) { |
| | | public void setLifeCycle(Byte lifeCycle) { |
| | | this.lifeCycle = lifeCycle; |
| | | } |
| | | //投用日期 |
| | |
| | | this.useDate = useDate; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | public Integer getStopStatus() { |
| | | public Byte getStopStatus() { |
| | | return stopStatus; |
| | | } |
| | | |
| | | public void setStopStatus(Integer stopStatus) { |
| | | public void setStopStatus(Byte stopStatus) { |
| | | this.stopStatus = stopStatus; |
| | | } |
| | | //上次检查日期 |
| | |
| | | private String useEndDay; |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | @ExcelCell(index = 11) |
| | | private Integer lifeCycle; |
| | | private Byte lifeCycle; |
| | | //投用日期 |
| | | @ExcelCell(index = 12) |
| | | private Timestamp useDate; |
| | | //维修状态 1:维修中 2:已修好 |
| | | @ExcelCell(index = 13) |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | @ExcelCell(index = 14) |
| | | private Integer stopStatus; |
| | | private Byte stopStatus; |
| | | //上次检查日期 |
| | | @ExcelCell(index = 15) |
| | | private Timestamp previousCheckDate; |
| | |
| | | this.useEndDay = useEndDay; |
| | | } |
| | | //生命周期 1:已使用 2:库存中 3:报废 |
| | | public Integer getLifeCycle() { |
| | | public Byte getLifeCycle() { |
| | | return lifeCycle; |
| | | } |
| | | |
| | | public void setLifeCycle(Integer lifeCycle) { |
| | | public void setLifeCycle(Byte lifeCycle) { |
| | | this.lifeCycle = lifeCycle; |
| | | } |
| | | //投用日期 |
| | |
| | | this.useDate = useDate; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //停用状态 1:停用 2.在用 3.维修 4.报废 |
| | | public Integer getStopStatus() { |
| | | public Byte getStopStatus() { |
| | | return stopStatus; |
| | | } |
| | | |
| | | public void setStopStatus(Integer stopStatus) { |
| | | public void setStopStatus(Byte stopStatus) { |
| | | this.stopStatus = stopStatus; |
| | | } |
| | | //上次检查日期 |
| | |
| | | //维修情况 |
| | | private String repairMemo; |
| | | //维修状态 1:维修中 2:已修好 |
| | | private Integer repairStatus; |
| | | private Byte repairStatus; |
| | | //设施异常项 |
| | | private String exceptionInfo; |
| | | //创建日期 |
| | |
| | | this.repairMemo = repairMemo; |
| | | } |
| | | //维修状态 1:维修中 2:已修好 |
| | | public Integer getRepairStatus() { |
| | | public Byte getRepairStatus() { |
| | | return repairStatus; |
| | | } |
| | | |
| | | public void setRepairStatus(Integer repairStatus) { |
| | | public void setRepairStatus(Byte repairStatus) { |
| | | this.repairStatus = repairStatus; |
| | | } |
| | | //设施异常项 |
| | |
| | | this.responsibilityPersonName = responsibilityPersonName; |
| | | } |
| | | //装置部位分类 1:关键装置 2:重点部位 |
| | | private Integer partType; |
| | | private Byte partType; |
| | | //检查周期 |
| | | private String checkCycle; |
| | | //应急预案/外键 |
| | |
| | | this.responsibilityPersonId = responsibilityPersonId; |
| | | } |
| | | //装置部位分类 1:关键装置 2:重点部位 |
| | | public Integer getPartType() { |
| | | public Byte getPartType() { |
| | | return partType; |
| | | } |
| | | |
| | | public void setPartType(Integer partType) { |
| | | public void setPartType(Byte partType) { |
| | | this.partType = partType; |
| | | } |
| | | //检查周期 |
| | |
| | | private Long responsibilityPersonId; |
| | | //装置部位分类 1:关键装置 2:重点部位 |
| | | @ExcelCell(index = 9) |
| | | private Integer partType; |
| | | private Byte partType; |
| | | //检查周期 |
| | | @ExcelCell(index = 10) |
| | | private String checkCycle; |
| | |
| | | this.responsibilityPersonId = responsibilityPersonId; |
| | | } |
| | | //装置部位分类 1:关键装置 2:重点部位 |
| | | public Integer getPartType() { |
| | | public Byte getPartType() { |
| | | return partType; |
| | | } |
| | | |
| | | public void setPartType(Integer partType) { |
| | | public void setPartType(Byte partType) { |
| | | this.partType = partType; |
| | | } |
| | | //检查周期 |
| | |
| | | import com.gkhy.safePlatform.commons.vo.ResultVO; |
| | | import com.gkhy.safePlatform.commons.vo.SearchResultVO; |
| | | import com.gkhy.safePlatform.equipment.entity.*; |
| | | import com.gkhy.safePlatform.equipment.enums.EquipmentLifeCycleEnum; |
| | | import com.gkhy.safePlatform.equipment.enums.EquipmentRepairStatusEnum; |
| | | import com.gkhy.safePlatform.equipment.enums.EquipmentResultCodes; |
| | | import com.gkhy.safePlatform.equipment.enums.EquipmentStopStatusEnum; |
| | | import com.gkhy.safePlatform.equipment.excepiton.EquipmentException; |
| | | import com.gkhy.safePlatform.equipment.model.dto.req.*; |
| | | import com.gkhy.safePlatform.equipment.model.dto.resp.EquipmentInfoDto; |
| | |
| | | |
| | | @Override |
| | | public void addOrUpdate(EquipmentInfoSaveOrUpdate infoDto) { |
| | | |
| | | // 验证枚举 |
| | | checkEnum(infoDto); |
| | | |
| | | if(infoDto.getInfoType() == null || infoDto.getEquipmentTypeId() == null){ |
| | | throw new EquipmentException(ResultCodes.CLIENT_PARAM_ILLEGAL); |
| | | } |
| | |
| | | ExcelUtil.exportExcel(map,respList , response.getOutputStream(),DateUtils.PATTERN_STANDARD); |
| | | response.getOutputStream().close(); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 枚举验证 |
| | | * @param infoDto |
| | | */ |
| | | public void checkEnum(EquipmentInfoSaveOrUpdate infoDto){ |
| | | if (EquipmentLifeCycleEnum.getByCode(infoDto.getLifeCycle()) == null) { |
| | | throw new EquipmentException(EquipmentResultCodes.EQUIPMENT_ENUM_LIFE_CYCLE_NOT_EXIST); |
| | | } |
| | | |
| | | if (EquipmentRepairStatusEnum.getByCode(infoDto.getRepairStatus()) == null) { |
| | | throw new EquipmentException(EquipmentResultCodes.EQUIPMENT_ENUM_STOP_STATUS_NOT_EXIST); |
| | | } |
| | | |
| | | if (EquipmentStopStatusEnum.getByCode(infoDto.getStopStatus()) == null) { |
| | | throw new EquipmentException(EquipmentResultCodes.EQUIPMENT_ENUM_REPAIR_STATUS_NOT_EXIST); |
| | | } |
| | | } |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.gkhy.safePlatform.account.rpc.apimodel.AccountDepartmentService; |
| | | import com.gkhy.safePlatform.equipment.entity.*; |
| | | import com.gkhy.safePlatform.equipment.enums.EquipmentResultCodes; |
| | | import com.gkhy.safePlatform.equipment.enums.KeypointEquipmentPartTypeEnum; |
| | | import com.gkhy.safePlatform.equipment.excepiton.EquipmentException; |
| | | import com.gkhy.safePlatform.equipment.model.dto.req.*; |
| | | import com.gkhy.safePlatform.equipment.model.dto.resp.KeypointEquipmentInfoExcel; |
| | |
| | | |
| | | @Override |
| | | public void addOrUpdate(KeypointEquipmentInfoDto infoDto) { |
| | | |
| | | // 验证枚举 |
| | | checkEnum(infoDto); |
| | | |
| | | KeypointEquipmentInfo equipmentInfo = BeanCopyUtils.copyBean(infoDto, KeypointEquipmentInfo.class); |
| | | //保存主数据 |
| | | if (infoDto.getId() == null) { //新增 |
| | |
| | | ExcelUtil.exportExcel(map,respList , response.getOutputStream(),DateUtils.PATTERN_STANDARD); |
| | | response.getOutputStream().close(); |
| | | } |
| | | |
| | | /** |
| | | * 枚举验证 |
| | | * @param infoDto |
| | | */ |
| | | public void checkEnum(KeypointEquipmentInfoDto infoDto){ |
| | | if (KeypointEquipmentPartTypeEnum.getByCode(infoDto.getPartType()) == null) { |
| | | throw new EquipmentException(EquipmentResultCodes.KEYPOINT_EQUIPMENT_ENUM_PART_TYPE_NOT_EXIST); |
| | | } |
| | | } |
| | | } |
| | |
| | | AND a.gmt_create <![CDATA[ <= ]]> #{endTime} |
| | | GROUP BY |
| | | DATE_FORMAT( a.gmt_create, '%Y-%m' ), |
| | | a.accident_level |
| | | a.accident_level, |
| | | DATE_FORMAT( a.gmt_create, '%m' ) |
| | | </select> |
| | | |
| | | <select id="getCountForRPCByDeptIdAndDay" resultMap="accidentReportCountRPC"> |
| | |
| | | AND a.gmt_create <![CDATA[ <= ]]> #{endTime} |
| | | GROUP BY |
| | | DATE_FORMAT( a.gmt_create, '%Y-%m-%d' ), |
| | | a.accident_level |
| | | a.accident_level, |
| | | DATE_FORMAT( a.gmt_create, '%d' ) |
| | | </select> |
| | | </mapper> |