Browse Source

fix:修改梦天的数据推送

dist.1.3.0
pref_mail@163.com 6 months ago
parent
commit
6f25935e24
  1. 7
      blade-service/logpm-factory/src/main/java/com/logpm/factory/mt/controller/MtFactoryDataController.java

7
blade-service/logpm-factory/src/main/java/com/logpm/factory/mt/controller/MtFactoryDataController.java

@ -108,7 +108,8 @@ public class MtFactoryDataController extends BladeController {
@PostMapping("/data")
@ApiOperationSupport(order = 1)
@ApiOperation(value = "通常数据推送", notes = "传入factoryOrderDTO")
public R data(@Validated @RequestBody MtFactoryDataDTO mtFactoryDataDTO, HttpServletRequest request) {
// public R data(@Validated @RequestBody MtFactoryDataDTO mtFactoryDataDTO, HttpServletRequest request) {
public R data(@Validated @RequestBody Map<String, Object> mtFactoryDataDTO, HttpServletRequest request) {
log.info("############data:{} ", mtFactoryDataDTO);
String corpId = request.getHeader("corpId");
@ -120,8 +121,10 @@ public class MtFactoryDataController extends BladeController {
orderStatusLog.setBrand("梦天");
orderStatusLogService.save(orderStatusLog);
try {
// 解析 map 为 MtFactoryDataDTO 对象
MtFactoryDataDTO dto = JSONObject.parseObject(JSONObject.toJSONString(mtFactoryDataDTO), MtFactoryDataDTO.class);
//数据存入数据库
R r = mtFactoryDataService.dealWithData(mtFactoryDataDTO);
R r = mtFactoryDataService.dealWithData(dto);
int code = r.getCode();
Map<String, Long> map = (Map<String, Long>) r.getData();

Loading…
Cancel
Save