|
@@ -136,7 +136,7 @@ public class MesController extends SuperController<MesNoticeService, Long, MesNo
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "接受质检任务下发通知接口", notes = "接受质检任务下发通知接口")
|
|
|
- @PostMapping("/externalApi/quality/measuringTaskReceive")
|
|
|
+ @PostMapping("/externalApi/measuringTaskReceive")
|
|
|
public R addQualityToNotice(@RequestBody String data) {
|
|
|
log.info("==============接受质检任务下发通知接口开始=================");
|
|
|
ThreeCoordinateDto threeCoordinateDto = JSONObject.parseObject(data, ThreeCoordinateDto.class);
|
|
@@ -155,7 +155,7 @@ public class MesController extends SuperController<MesNoticeService, Long, MesNo
|
|
|
}
|
|
|
|
|
|
@ApiOperation(value = "质检结果上报", notes = "质检结果上报")
|
|
|
- @PostMapping("/externalApi/quality/qualityResultReport")
|
|
|
+ @PostMapping("/externalApi/qualityResultReport")
|
|
|
public R QualityResultReport(@RequestBody String data){
|
|
|
log.info("定时================质检结果上报开始================");
|
|
|
// 根据代办的质量任务,查询是否已经检测完成,是,进行上报
|
|
@@ -174,7 +174,7 @@ public class MesController extends SuperController<MesNoticeService, Long, MesNo
|
|
|
}
|
|
|
|
|
|
@ApiOperation(value = "刀具需求下发给EOP", notes = "刀具需求下发给EOP")
|
|
|
- @PostMapping("/externalApi/cutter/sendCutterNeedToEop")
|
|
|
+ @PostMapping("/externalApi/sendCutterNeedToEop")
|
|
|
public R sendCutterNeedToEop(@RequestBody String data){
|
|
|
log.info("定时================发送刀具需求给Eop系统开始================");
|
|
|
CutterNeedDto cutterNeedDto = JSONObject.parseObject(data, CutterNeedDto.class);
|
|
@@ -191,7 +191,7 @@ public class MesController extends SuperController<MesNoticeService, Long, MesNo
|
|
|
}
|
|
|
|
|
|
@ApiOperation(value = "接受刀具分拣结果", notes = "接受刀具分拣结果")
|
|
|
- @PostMapping("/externalApi/cutter/acceptSortingResult")
|
|
|
+ @PostMapping("/externalApi/acceptSortingResult")
|
|
|
public R acceptSortingResult(@RequestBody CutterNeedDto data){
|
|
|
log.info("定时================质检结果上报开始================");
|
|
|
// 根据代办的质量任务,查询是否已经检测完成,是,进行上报
|
|
@@ -209,7 +209,27 @@ public class MesController extends SuperController<MesNoticeService, Long, MesNo
|
|
|
|
|
|
}
|
|
|
|
|
|
+ @ApiOperation(value = "任务下发通知接口", notes = "任务下发通知接口")
|
|
|
+ @PostMapping("/externalApi/order/addMes")
|
|
|
+ public R addNotice(@RequestBody String data) {
|
|
|
+ log.info("================接受上游系统的任务================");
|
|
|
+
|
|
|
+ log.info("任务数据{}", JSONObject.toJSONString(data));
|
|
|
+ try {
|
|
|
+ JSONObject jsonObject = JSONObject.parseObject(data);
|
|
|
+
|
|
|
+ MesNotice mesNotice = MesNotice.builder().orderNo(jsonObject.getString("workOrderNo")).
|
|
|
+ buType("TASKDISTRIBUTE").lineCode("11111").status("1").source("QUALITY").apiType("TASKDISTRIBUTE")
|
|
|
+ .targetSource("PRODUCTION_LINE").acceptPar(data).build();
|
|
|
+ boolean b = baseService.addNotice(mesNotice);
|
|
|
+ } catch (Exception e) {
|
|
|
+ e.printStackTrace();
|
|
|
+ return R.fail(e.getMessage());
|
|
|
+ }
|
|
|
|
|
|
+ log.info("================接受上游系统的任务结束================");
|
|
|
+ return R.success();
|
|
|
+ }
|
|
|
|
|
|
|
|
|
|