| | |
| | | // private IUploadService uploadService; |
| | | |
| | | private ISysBaseAPI sysBaseApi; |
| | | |
| | | @Autowired |
| | | private IAreaService areaService; |
| | | /** |
| | | * 分页列表查询 |
| | | * |
| | |
| | | calibrationOrderService.updateById(calibrationOrder); |
| | | return Result.OK("编辑成功!"); |
| | | } |
| | | |
| | | /** |
| | | *首页技术状态数量统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | @GetMapping("getEquipmentTechnologyStatusList") |
| | | public Result<?> getEquipmentTechnologyStatusList(@Param("factoryNum") String factoryNum) { |
| | | List<Area> areaList = areaService.lambdaQuery().eq(Area::getNum, factoryNum).eq(Area::getDelFlag, 0).list(); |
| | | List<Map<String, Object>> list; |
| | | if(areaList.size()>0){ |
| | | list = calibrationOrderService.getEquipmentTechnologyStatusList(areaList.get(0).getId()); |
| | | }else{ |
| | | list = null; |
| | | } |
| | | return Result.ok(list); |
| | | } |
| | | |
| | | /** |
| | | *首页设备报修情况统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | @GetMapping("getReportRepairEquipmentList") |
| | | public Result<?> getReportRepairEquipmentList(@Param("factoryNum") String factoryNum) { |
| | | List<Area> areaList = areaService.lambdaQuery().eq(Area::getNum, factoryNum).eq(Area::getDelFlag, 0).list(); |
| | | List<Map<String, Object>> list; |
| | | if(areaList.size()>0){ |
| | | list = calibrationOrderService.getReportRepairEquipmentList(areaList.get(0).getId()); |
| | | }else{ |
| | | list = null; |
| | | } |
| | | return Result.ok(list); |
| | | } |
| | | |
| | | /** |
| | | *首页本月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | @GetMapping("getThisMonthMaintenanceList") |
| | | public Result<?> getThisMonthMaintenanceList(@Param("factoryNum") String factoryNum) { |
| | | List<Area> areaList = areaService.lambdaQuery().eq(Area::getNum, factoryNum).eq(Area::getDelFlag, 0).list(); |
| | | List<Map<String, Object>> list; |
| | | if(areaList.size()>0){ |
| | | list = calibrationOrderService.getThisMonthMaintenanceList(areaList.get(0).getId()); |
| | | }else{ |
| | | list = null; |
| | | } |
| | | return Result.ok(list); |
| | | } |
| | | |
| | | /** |
| | | *首页下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | @GetMapping("getNextMonthMaintenanceList") |
| | | public Result<?> getNextMonthMaintenanceList(@Param("factoryNum") String factoryNum) { |
| | | List<Area> areaList = areaService.lambdaQuery().eq(Area::getNum, factoryNum).eq(Area::getDelFlag, 0).list(); |
| | | List<Map<String, Object>> list; |
| | | if(areaList.size()>0){ |
| | | list = calibrationOrderService.getNextMonthMaintenanceList(areaList.get(0).getId()); |
| | | }else{ |
| | | list = null; |
| | | } |
| | | return Result.ok(list); |
| | | } |
| | | |
| | | /** |
| | | *首页下下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | @GetMapping("getNextNextMonthMaintenanceList") |
| | | public Result<?> getNextNextMonthMaintenanceList(@Param("factoryNum") String factoryNum) { |
| | | List<Area> areaList = areaService.lambdaQuery().eq(Area::getNum, factoryNum).eq(Area::getDelFlag, 0).list(); |
| | | List<Map<String, Object>> list; |
| | | if(areaList.size()>0){ |
| | | list = calibrationOrderService.getNextNextMonthMaintenanceList(areaList.get(0).getId()); |
| | | }else{ |
| | | list = null; |
| | | } |
| | | return Result.ok(list); |
| | | } |
| | | |
| | | } |
| | |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | /**备用字段1*/ |
| | | @Excel(name = "备用字段1", width = 15) |
| | | @ApiModelProperty(value = "备用字段1") |
| | | @Excel(name = "管理制度号", width = 15) |
| | | @ApiModelProperty(value = "管理制度号") |
| | | private String disUda1; |
| | | /**备用字段2*/ |
| | | @Excel(name = "备用字段2", width = 15) |
| | | @ApiModelProperty(value = "备用字段2") |
| | | @Excel(name = "审核结果", width = 15) |
| | | @ApiModelProperty(value = "审核结果") |
| | | private String disUda2; |
| | | /**备用字段3*/ |
| | | @Excel(name = "备用字段3", width = 15) |
| | | @ApiModelProperty(value = "备用字段3") |
| | | @Excel(name = "审批结果", width = 15) |
| | | @ApiModelProperty(value = "审批结果") |
| | | private String disUda3; |
| | | /**备用字段4*/ |
| | | @Excel(name = "备用字段4", width = 15) |
| | |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | /**备用字段1*/ |
| | | @Excel(name = "备用字段1", width = 15) |
| | | @ApiModelProperty(value = "备用字段1") |
| | | @Excel(name = "审核结果", width = 15) |
| | | @ApiModelProperty(value = "审核结果") |
| | | private String maintenanceStandardUda1; |
| | | /**备用字段2*/ |
| | | @Excel(name = "备用字段2", width = 15) |
| | | @ApiModelProperty(value = "备用字段2") |
| | | @Excel(name = "审批结果", width = 15) |
| | | @ApiModelProperty(value = "审批结果") |
| | | private String maintenanceStandardUda2; |
| | | /**备用字段3*/ |
| | | @Excel(name = "备用字段3", width = 15) |
| | |
| | | */ |
| | | List<Map<String, Object>> getPrecisionParameterList(@Param("equipmentId")String equipmentId); |
| | | |
| | | /** |
| | | *首页技术状态数量统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | List<Map<String, Object>> getEquipmentTechnologyStatusList(@Param("factoryModelId")String factoryModelId); |
| | | |
| | | /** |
| | | *首页设备报修情况统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | List<Map<String, Object>> getReportRepairEquipmentList(@Param("factoryModelId")String factoryModelId); |
| | | |
| | | /** |
| | | *首页本月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | List<Map<String, Object>> getThisMonthMaintenanceList(@Param("factoryModelId")String factoryModelId); |
| | | |
| | | /** |
| | | *首页下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | List<Map<String, Object>> getNextMonthMaintenanceList(@Param("factoryModelId")String factoryModelId); |
| | | |
| | | /** |
| | | *首页下下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | List<Map<String, Object>> getNextNextMonthMaintenanceList(@Param("factoryModelId")String factoryModelId); |
| | | |
| | | } |
| | |
| | | LEFT JOIN mom_base_unit t3 ON t2.unit_id = t3.id |
| | | WHERE t1.del_flag = 0 and t1.equipment_id = #{equipmentId} |
| | | </select> |
| | | |
| | | <select id="getEquipmentTechnologyStatusList" parameterType="String" resultType="Map"> |
| | | SELECT |
| | | ( SELECT COUNT ( 0 ) FROM mom_eam_equipment WHERE del_flag = '0' and technology_status = 'qualified' and factory_model_id = #{factoryModelId}) as qualifiedCount, |
| | | ( SELECT COUNT ( 0 ) FROM mom_eam_equipment WHERE del_flag = '0' and technology_status = 'limitedUse' and factory_model_id = #{factoryModelId}) as limitedUseCount, |
| | | ( SELECT COUNT ( 0 ) FROM mom_eam_equipment WHERE del_flag = '0' and technology_status = 'disabled' and factory_model_id = #{factoryModelId}) as disabledCount |
| | | </select> |
| | | |
| | | <select id="getReportRepairEquipmentList" parameterType="String" resultType="Map"> |
| | | SELECT |
| | | ( select COUNT(0) from mom_eam_equipment_report_repair t1 left join mom_eam_equipment t2 on t1.equipment_id = t2.id WHERE del_flag = '0' and SUBSTRING(CONVERT(VARCHAR(10), t1.fault_time, 120), 1, 10) = SUBSTRING(CONVERT(VARCHAR(10), GETDATE(), 120), 1, 10) and t2.factory_model_id = #{factoryModelId}) as failurTotalCount, |
| | | ( select COUNT(0) from mom_eam_equipment_report_repair t1 left join mom_eam_equipment t2 on t1.equipment_id = t2.id where del_flag = '0' and t1.is_stop = '1' and SUBSTRING(CONVERT(VARCHAR(10), t1.fault_time, 120), 1, 10) = SUBSTRING(CONVERT(VARCHAR(10), GETDATE(), 120), 1, 10) and t2.factory_model_id = #{factoryModelId}) as noStopCount, |
| | | ( select COUNT(0) from mom_eam_equipment_report_repair t1 left join mom_eam_equipment t2 on t1.equipment_id = t2.id where del_flag = '0' and t1.is_stop = '2' and SUBSTRING(CONVERT(VARCHAR(10), t1.fault_time, 120), 1, 10) = SUBSTRING(CONVERT(VARCHAR(10), GETDATE(), 120), 1, 10) and t2.factory_model_id = #{factoryModelId}) as stopCount |
| | | </select> |
| | | |
| | | <select id="getThisMonthMaintenanceList" parameterType="String" resultType="Map"> |
| | | select count(0) from mom_eam_equipment t1 where t1.del_flag = '0' and SUBSTRING(CONVERT(VARCHAR(10), t1.next_third_maintenance_time, 120), 1, 7) = SUBSTRING(CONVERT(VARCHAR(10), GETDATE(), 120), 1, 7) and t2.factory_model_id = #{factoryModelId} |
| | | </select> |
| | | |
| | | <select id="getNextMonthMaintenanceList" parameterType="String" resultType="Map"> |
| | | select count(0) from mom_eam_equipment t1 where t1.del_flag = '0' and SUBSTRING(CONVERT(VARCHAR(10), t1.next_third_maintenance_time, 120), 1, 7) = SUBSTRING(CONVERT(VARCHAR(10), DATEADD(MONTH, 1, GETDATE()), 120), 1, 7) and t2.factory_model_id = #{factoryModelId} |
| | | </select> |
| | | |
| | | <select id="getNextNextMonthMaintenanceList" parameterType="String" resultType="Map"> |
| | | select count(0) from mom_eam_equipment t1 where t1.del_flag = '0' and SUBSTRING(CONVERT(VARCHAR(10), t1.next_third_maintenance_time, 120), 1, 7) = SUBSTRING(CONVERT(VARCHAR(10), DATEADD(MONTH,2 , GETDATE()), 120), 1, 7) and t2.factory_model_id = #{factoryModelId} |
| | | </select> |
| | | |
| | | |
| | | </mapper> |
| | |
| | | t1.audit_person as auditPerson, |
| | | t1.approval_person as approvalPerson, |
| | | t1.lose_efficacy_person as loseEfficacyPerson, |
| | | t1.dis_uda1 as disUda1 |
| | | t1.dis_uda1 as disUda1, |
| | | t1.dis_uda2 as disUda2, |
| | | t1.dis_uda3 as disUda3 |
| | | FROM |
| | | mom_eam_daily_inspection_standard t1 |
| | | LEFT JOIN mom_eam_equipment t2 ON t1.equipment_id = t2.id |
| | |
| | | t1.write_person as writePerson, |
| | | t1.audit_person as auditPerson, |
| | | t1.approval_person as approvalPerson, |
| | | t1.lose_efficacy_person as loseEfficacyPerson |
| | | t1.lose_efficacy_person as loseEfficacyPerson, |
| | | t1.maintenance_standard_uda1 as maintenanceStandardUda1, |
| | | t1.maintenance_standard_uda2 as maintenanceStandardUda2 |
| | | FROM |
| | | mom_eam_maintenance_standard t1 |
| | | LEFT JOIN mom_eam_equipment t2 ON t1.equipment_id = t2.id |
| | |
| | | */ |
| | | List<Map<String, Object>> getPrecisionParameterList(String equipmentId); |
| | | |
| | | |
| | | /** |
| | | *首页技术状态数量统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | List<Map<String, Object>> getEquipmentTechnologyStatusList(String factoryModelId); |
| | | |
| | | /** |
| | | *首页设备报修情况统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | List<Map<String, Object>> getReportRepairEquipmentList(String factoryModelId); |
| | | |
| | | /** |
| | | *首页本月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | List<Map<String, Object>> getThisMonthMaintenanceList(String factoryModelId); |
| | | |
| | | /** |
| | | *首页下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | List<Map<String, Object>> getNextMonthMaintenanceList(String factoryModelId); |
| | | |
| | | /** |
| | | *首页下下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | List<Map<String, Object>> getNextNextMonthMaintenanceList(String factoryModelId); |
| | | |
| | | } |
| | |
| | | public List<Map<String, Object>> getPrecisionParameterList(String equipmentId) { |
| | | return this.baseMapper.getPrecisionParameterList(equipmentId); |
| | | } |
| | | |
| | | /** |
| | | *首页技术状态数量统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getEquipmentTechnologyStatusList(String factoryModelId) { |
| | | return this.baseMapper.getEquipmentTechnologyStatusList(factoryModelId); |
| | | } |
| | | |
| | | /** |
| | | *首页设备报修情况统计 |
| | | * qsw 2024-3-13 |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getReportRepairEquipmentList(String factoryModelId) { |
| | | return this.baseMapper.getReportRepairEquipmentList(factoryModelId); |
| | | } |
| | | |
| | | /** |
| | | *首页本月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getThisMonthMaintenanceList(String factoryModelId) { |
| | | return this.baseMapper.getThisMonthMaintenanceList(factoryModelId); |
| | | } |
| | | |
| | | /** |
| | | *首页下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getNextMonthMaintenanceList(String factoryModelId) { |
| | | return this.baseMapper.getNextMonthMaintenanceList(factoryModelId); |
| | | } |
| | | |
| | | /** |
| | | *首页下下月三保计划 |
| | | * qsw 2024-3-14 |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getNextNextMonthMaintenanceList(String factoryModelId) { |
| | | return this.baseMapper.getNextNextMonthMaintenanceList(factoryModelId); |
| | | } |
| | | } |