2024-07-16 15:12:27 +08:00
|
|
|
package com.wms.controller.others;
|
2024-07-04 07:43:04 +08:00
|
|
|
|
2024-07-04 15:54:50 +08:00
|
|
|
import com.wms.controller.BaseController;
|
|
|
|
|
import com.wms.entity.app.mes.CheckNoticeRequest;
|
|
|
|
|
import com.wms.entity.app.mes.MesApiLocalResponse;
|
|
|
|
|
import com.wms.entity.app.mes.OutNoticeRequest;
|
|
|
|
|
import com.wms.entity.app.mes.ReceiptInRequest;
|
|
|
|
|
import com.wms.service.MesService;
|
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
|
import org.springframework.validation.annotation.Validated;
|
|
|
|
|
import org.springframework.web.bind.annotation.*;
|
2024-07-04 07:43:04 +08:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 和 mes 交互使用的 controller
|
|
|
|
|
* @author icewint
|
|
|
|
|
*/
|
2024-07-04 15:54:50 +08:00
|
|
|
@RestController
|
2024-07-04 07:43:04 +08:00
|
|
|
@CrossOrigin
|
2024-07-04 15:54:50 +08:00
|
|
|
@RequestMapping(value = "/api/mes")
|
|
|
|
|
@RequiredArgsConstructor(onConstructor = @__(@Autowired))
|
|
|
|
|
public class MesController extends BaseController {
|
|
|
|
|
|
|
|
|
|
private final MesService mesService;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* mes 入库之前用此接口推送信息 IF201
|
|
|
|
|
* @param request 请求信息
|
|
|
|
|
* @return 返回信息
|
|
|
|
|
*/
|
|
|
|
|
@PostMapping("/ReceiptIn")
|
|
|
|
|
public MesApiLocalResponse receiptIn(@RequestBody @Validated ReceiptInRequest request) {
|
|
|
|
|
return mesService.receiptIn(request);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* mes 出库 IF205(IF203)
|
|
|
|
|
* @param request 请求信息
|
|
|
|
|
* @return 返回信息
|
|
|
|
|
*/
|
|
|
|
|
@PostMapping("/OutNotice")
|
|
|
|
|
public MesApiLocalResponse outNotice(@RequestBody @Validated OutNoticeRequest request) {
|
|
|
|
|
return mesService.outNotice(request);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* mes 盘点通知单 IF206
|
|
|
|
|
* @return 返回信息
|
|
|
|
|
*/
|
|
|
|
|
@PostMapping("/CheckNotice")
|
|
|
|
|
public MesApiLocalResponse checkNotice(@RequestBody @Validated CheckNoticeRequest request) {
|
|
|
|
|
return mesService.checkNotice(request);
|
|
|
|
|
}
|
2024-07-04 07:43:04 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|