|
|
@@ -412,7 +412,7 @@ public class PlanNewCommonOutController {
|
|
|
* @return {@link Mono}<{@link RStatus}<{@link PlanNewCommonMaterialRes}>>
|
|
|
*/
|
|
|
@PostMapping("getCommonMaterial")
|
|
|
- public Mono<RStatus<byte[]>> getCommonMaterial(@RequestBody PlanNewCommonMaterialReq request) {
|
|
|
+ public Mono<RStatus<PlanNewCommonMaterialRes>> getCommonMaterial(@RequestBody PlanNewCommonMaterialReq request) {
|
|
|
Mono<PlanNewCommon> planNewCommonMono = template.selectOne(Query.query(Criteria.where("code").is(request.getCode())), PlanNewCommon.class)
|
|
|
.switchIfEmpty(Mono.error(new BaseException("计划code异常 返回结果为空")))
|
|
|
.onErrorResume(throwable -> Mono.error(new Exception(throwable.getMessage())));
|
|
|
@@ -453,8 +453,8 @@ public class PlanNewCommonOutController {
|
|
|
});
|
|
|
});
|
|
|
// GZIP压缩
|
|
|
- Mono<byte[]> res = materialResMono.flatMap(f -> Mono.just(Objects.requireNonNull(this.compressData(JSONUtil.toJsonStr(f)))));
|
|
|
- return RStatus.success(res);
|
|
|
+ // Mono<byte[]> res = materialResMono.flatMap(f -> Mono.just(Objects.requireNonNull(this.compressData(JSONUtil.toJsonStr(f)))));
|
|
|
+ return RStatus.success(materialResMono);
|
|
|
}
|
|
|
|
|
|
/**
|