核心信息提取
This commit is contained in:
@@ -1,11 +1,16 @@
|
||||
package com.njcn.supervision.api;
|
||||
|
||||
import com.njcn.bpm.pojo.dto.BpmInstanceInfo;
|
||||
import com.njcn.common.pojo.annotation.OperateInfo;
|
||||
import com.njcn.common.pojo.constant.ServerInfo;
|
||||
import com.njcn.common.pojo.enums.common.LogEnum;
|
||||
import com.njcn.common.pojo.response.HttpResult;
|
||||
import com.njcn.supervision.api.fallback.BusinessCommonFeignClientFallbackFactory;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
|
||||
/**
|
||||
@@ -25,4 +30,12 @@ public interface BusinessCommonFeignClient {
|
||||
@GetMapping("/updateProcessStatus")
|
||||
HttpResult<Object> updateProcessStatus(@RequestParam("processKey") String processKey,@RequestParam("businessId") String businessId, @RequestParam("status")Integer status);
|
||||
|
||||
|
||||
/**
|
||||
* 根据流程key,业务id去实时更新流程状态
|
||||
* @param processKey 流程定义key
|
||||
* @param businessId 业务id
|
||||
*/
|
||||
@GetMapping("/getInstanceInfo")
|
||||
HttpResult<BpmInstanceInfo> getInstanceInfo(@RequestParam("processKey") String processKey, @RequestParam("businessId")String businessId);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.njcn.supervision.api.fallback;
|
||||
|
||||
import com.njcn.bpm.pojo.dto.BpmInstanceInfo;
|
||||
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
||||
import com.njcn.common.pojo.exception.BusinessException;
|
||||
import com.njcn.common.pojo.response.HttpResult;
|
||||
@@ -28,6 +29,12 @@ public class BusinessCommonFeignClientFallbackFactory implements FallbackFactory
|
||||
log.error("{}异常,降级处理,异常为:{}", "更新流程状态", throwable.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HttpResult<BpmInstanceInfo> getInstanceInfo(String processKey, String businessId) {
|
||||
log.error("{}异常,降级处理,异常为:{}", "获取流程额外信息", throwable.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,8 @@ package com.njcn.supervision.enums;
|
||||
|
||||
import lombok.Getter;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
@Getter
|
||||
public enum ProblemTypeEnum {
|
||||
|
||||
@@ -18,4 +20,12 @@ public enum ProblemTypeEnum {
|
||||
this.code = code;
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public static String getNameByCode(Integer code) {
|
||||
ProblemTypeEnum problemTypeEnumTemp = Arrays.stream(ProblemTypeEnum.values())
|
||||
.filter(problemTypeEnum -> problemTypeEnum.getCode().equals(code))
|
||||
.findAny()
|
||||
.orElse(PLAN);
|
||||
return problemTypeEnumTemp.getName();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,6 +38,11 @@ public class WarningLeaflet extends BaseEntity implements Serializable{
|
||||
*/
|
||||
private String leafletNo;
|
||||
|
||||
/**
|
||||
* 负责单位id
|
||||
*/
|
||||
private String deptId;
|
||||
|
||||
/**
|
||||
* 1:技术监督管理;2:在线监测超标问题;3:用户投诉;4:现场测试超标
|
||||
*/
|
||||
|
||||
@@ -33,6 +33,16 @@ public class WarningLeafletVO extends BaseEntity implements Serializable{
|
||||
*/
|
||||
private String leafletNo;
|
||||
|
||||
/**
|
||||
* 负责单位id
|
||||
*/
|
||||
private String deptId;
|
||||
|
||||
/**
|
||||
* 负责单位
|
||||
*/
|
||||
private String deptName;
|
||||
|
||||
/**
|
||||
* 1:技术监督管理;2:在线监测超标问题;3:用户投诉;4:现场测试超标
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user