Explorar el Código

导出excel表格添加任务判断

tags/V1.0.1^2
chengwang hace 1 año
padre
commit
152df1047e
Se han modificado 2 ficheros con 5 adiciones y 1 borrados
  1. +2
    -1
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/enums/AirDataEnum.java
  2. +3
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/airData/query/QueryAirDataListService.java

+ 2
- 1
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/enums/AirDataEnum.java Ver fichero

@@ -10,7 +10,8 @@ public enum AirDataEnum {

//任务状态1待执行 2执行中
INSPECTION_ID_IS_NULL(10001,"任务id为空"),
AIR_DATA_IS_NOT_EXIST(10002,"大气数据为空");
INSPECTION_IS_NOT_EXIST(10002,"任务不存在"),
AIR_DATA_IS_NOT_EXIST(10003,"大气数据为空");

AirDataEnum(int code, String msg){
this.code = code;

+ 3
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/airData/query/QueryAirDataListService.java Ver fichero

@@ -82,6 +82,9 @@ public class QueryAirDataListService {
}
//获取任务名称
Inspection inspection = inspectionMapper.selectById(id);
if(ObjectUtil.isNull(inspection)){
return JsonResult.error(AirDataEnum.INSPECTION_IS_NOT_EXIST.getCode(),AirDataEnum.INSPECTION_IS_NOT_EXIST.getMsg());
}
String name = inspection.getName();
if(StringUtils.isEmpty(name)){
log.info("对应的任务名称为空");

Cargando…
Cancelar
Guardar