|
@@ -50,16 +50,19 @@ public class ProductController {
|
|
|
|
|
|
@Operation(summary = "根据报告id查询产品数据信息")
|
|
@Operation(summary = "根据报告id查询产品数据信息")
|
|
@GetMapping("/getProduct")
|
|
@GetMapping("/getProduct")
|
|
- public JsonResult getProduct(Integer reportId) {
|
|
|
|
|
|
+ public String getProduct(Integer reportId) {
|
|
log.info("开始处理【根据报告id查询产品数据信息】的请求,参数为:{}", reportId);
|
|
log.info("开始处理【根据报告id查询产品数据信息】的请求,参数为:{}", reportId);
|
|
if (reportId != null) {
|
|
if (reportId != null) {
|
|
ProductStandardVO queryResult = productService.getProduct(reportId);
|
|
ProductStandardVO queryResult = productService.getProduct(reportId);
|
|
if (queryResult == null) {
|
|
if (queryResult == null) {
|
|
- return JsonResult.fail(ServiceCode.ERROR_NOT_FOUND, "产品不存在");
|
|
|
|
|
|
+ //return JsonResult.fail(ServiceCode.ERROR_NOT_FOUND, "产品不存在");
|
|
|
|
+ return Response.error("报告id对应产品不存在");
|
|
}
|
|
}
|
|
- return JsonResult.ok(queryResult);
|
|
|
|
|
|
+ //return JsonResult.ok(queryResult);
|
|
|
|
+ return Response.success(queryResult);
|
|
} else {
|
|
} else {
|
|
- return JsonResult.fail(ServiceCode.ERROR_BAD_REQUEST, "报告id不能为空");
|
|
|
|
|
|
+ //return JsonResult.fail(ServiceCode.ERROR_BAD_REQUEST, "报告id不能为空");
|
|
|
|
+ return Response.error("报告id不能为空");
|
|
}
|
|
}
|
|
|
|
|
|
}
|
|
}
|