|
@@ -1,5 +1,6 @@
|
|
|
package com.hr.controller;
|
|
package com.hr.controller;
|
|
|
|
|
|
|
|
|
|
+import com.alibaba.fastjson2.JSON;
|
|
|
import com.hr.dto.AggregateQueryDTO;
|
|
import com.hr.dto.AggregateQueryDTO;
|
|
|
import com.hr.externelSystem.BizHandlerFactory;
|
|
import com.hr.externelSystem.BizHandlerFactory;
|
|
|
import com.hr.param.AggregateRequest;
|
|
import com.hr.param.AggregateRequest;
|
|
@@ -11,6 +12,7 @@ import com.hr.service.IpInterfaceService;
|
|
|
import com.hr.vo.IpAccountVO;
|
|
import com.hr.vo.IpAccountVO;
|
|
|
import com.hr.vo.IpInterfaceVO;
|
|
import com.hr.vo.IpInterfaceVO;
|
|
|
import com.yy.basedevelop.common.data.BaseReturnDto;
|
|
import com.yy.basedevelop.common.data.BaseReturnDto;
|
|
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
import org.apache.poi.ss.formula.functions.T;
|
|
import org.apache.poi.ss.formula.functions.T;
|
|
|
import org.springframework.beans.BeanUtils;
|
|
import org.springframework.beans.BeanUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
@@ -25,6 +27,7 @@ import reactor.core.publisher.Mono;
|
|
|
*/
|
|
*/
|
|
|
@RestController
|
|
@RestController
|
|
|
@RequestMapping("/aggregate")
|
|
@RequestMapping("/aggregate")
|
|
|
|
|
+@Slf4j
|
|
|
public class AggregateController {
|
|
public class AggregateController {
|
|
|
|
|
|
|
|
@Autowired
|
|
@Autowired
|
|
@@ -41,6 +44,7 @@ public class AggregateController {
|
|
|
|
|
|
|
|
@PostMapping("/openApi")
|
|
@PostMapping("/openApi")
|
|
|
public Mono<BaseReturnDto<Object>> aggregate(@RequestBody AggregateRequest req) {
|
|
public Mono<BaseReturnDto<Object>> aggregate(@RequestBody AggregateRequest req) {
|
|
|
|
|
+ log.info("openApi调用{}", req);
|
|
|
String accountNo = req.getAccountNo();
|
|
String accountNo = req.getAccountNo();
|
|
|
String interfaceCode = req.getInterfaceCode();
|
|
String interfaceCode = req.getInterfaceCode();
|
|
|
IpAccountVO ipAccount = ipAccountService.queryByAccountNo(accountNo);
|
|
IpAccountVO ipAccount = ipAccountService.queryByAccountNo(accountNo);
|
|
@@ -65,6 +69,8 @@ public class AggregateController {
|
|
|
IpInterfacePO ipInterfacePO = new IpInterfacePO();
|
|
IpInterfacePO ipInterfacePO = new IpInterfacePO();
|
|
|
BeanUtils.copyProperties(ipInterfaceVO, ipInterfacePO);
|
|
BeanUtils.copyProperties(ipInterfaceVO, ipInterfacePO);
|
|
|
dto.setIpInterfacePO(ipInterfacePO);
|
|
dto.setIpInterfacePO(ipInterfacePO);
|
|
|
- return Mono.just(bizHandlerFactory.dispatch(req,dto));
|
|
|
|
|
|
|
+ BaseReturnDto<Object> response = bizHandlerFactory.dispatch(req, dto);
|
|
|
|
|
+ log.info("openApi返回:{}", JSON.toJSONString(response));
|
|
|
|
|
+ return Mono.just(response);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|