feat(EleEpdPqd): 添加根据告警码获取数据功能
- 在控制器中新增 findListByCode 方法实现告警码查询 - 在 Feign 客户端接口中添加对应的远程调用方法 - 在降级工厂中实现相应的异常处理逻辑 - 添加了参数验证注解支持 - 集成了 Swagger 文档注解便于接口文档生成
This commit is contained in:
@@ -234,5 +234,15 @@ public class EleEpdPqdController extends BaseController {
|
||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, po, methodDescribe);
|
||||
}
|
||||
|
||||
@PostMapping("/findListByCode")
|
||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||
@ApiOperation("根据告警码获取数据")
|
||||
@ApiImplicitParam(name = "code", value = "告警码", required = true)
|
||||
public HttpResult<List<EleEpdPqd>> findListByCode(@RequestParam("code") @Validated String code){
|
||||
String methodDescribe = getMethodDescribe("findListByCode");
|
||||
List<EleEpdPqd> po = eleEpdPqdService.lambdaQuery().like(EleEpdPqd::getDefaultValue,code).list();
|
||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, po, methodDescribe);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user