feat(material): 新增材料结果完整数据
This commit is contained in:
@@ -56,4 +56,20 @@ public class MaterialResultController {
|
||||
var result = materialResultService.getTrend(data, year, month, type);
|
||||
return FuHttpResponse.Builder().dataResponse(result).build();
|
||||
}
|
||||
|
||||
@ApiOperation("获取材料结果完整数据")
|
||||
@GetMapping("/{id}/full-data")
|
||||
public HttpResponse getFullData (
|
||||
@PathVariable String id,
|
||||
@ApiParam("类型") @RequestParam("type") Integer type,
|
||||
@ApiParam("年份") @RequestParam("year") Integer year,
|
||||
@ApiParam("月份") @RequestParam(value="month") Integer month
|
||||
) throws Exception{
|
||||
var data = materialResultService.getById(id, type);
|
||||
if (data == null) {
|
||||
throw new NcHttpException(HttpErrorResponseEnum.MATERIAL_RESULT_NOT_FOUND);
|
||||
}
|
||||
var result = materialResultService.getTrend(data, year, month, type);
|
||||
return FuHttpResponse.Builder().dataResponse(result).build();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user