diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/offlinesn/MesWuhanOfflinePrintController.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/offlinesn/MesWuhanOfflinePrintController.java index 9602d3a..e9db51e 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/offlinesn/MesWuhanOfflinePrintController.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/offlinesn/MesWuhanOfflinePrintController.java @@ -1,15 +1,13 @@ package cn.estsh.i3plus.ext.mes.pcn.apiservice.controller.busi.offlinesn; +import cn.estsh.i3plus.ext.mes.pcn.apiservice.model.MesCustSnOfflineModel; import cn.estsh.i3plus.ext.mes.pcn.apiservice.serviceimpl.offlineprint.MesOfflinePrintServiceImpl; import cn.estsh.i3plus.ext.mes.pcn.pojo.constant.MesCommonConstant; import cn.estsh.impp.framework.boot.util.ResultBean; import io.swagger.annotations.Api; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.web.bind.annotation.GetMapping; -import org.springframework.web.bind.annotation.PathVariable; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.*; import java.util.Map; @@ -21,12 +19,12 @@ public class MesWuhanOfflinePrintController { @Autowired private MesOfflinePrintServiceImpl mesOfflinePrintService; - @GetMapping("/cust-sn/{custSn}/{templateCode}/{organizeCode}") - public ResultBean custSn(@PathVariable("custSn") String custSn,@PathVariable("templateCode") String templateCode,@PathVariable("organizeCode") String organizeCode) { + @PostMapping("/cust-sn") + public ResultBean custSn(@RequestBody MesCustSnOfflineModel model) { Map custSnOfflineInfo = null; try { - custSnOfflineInfo = mesOfflinePrintService.getCustSnOfflineInfo(custSn, templateCode, organizeCode); + custSnOfflineInfo = mesOfflinePrintService.getCustSnOfflineInfo(model.getCustSn(), model.getTemplateCode(), model.getOrganizeCode()); } catch (Exception e) { ResultBean.fail().setErrorMsg(e.getMessage()); } diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/model/MesCustSnOfflineModel.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/model/MesCustSnOfflineModel.java new file mode 100644 index 0000000..9a9b3a2 --- /dev/null +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/model/MesCustSnOfflineModel.java @@ -0,0 +1,12 @@ +package cn.estsh.i3plus.ext.mes.pcn.apiservice.model; + +import lombok.Data; + +@Data +public class MesCustSnOfflineModel { + private String custSn; + + private String templateCode; + + private String organizeCode; +}