From fb75dfbcb7bbe82b85801f6135d5c2c8a36fd664 Mon Sep 17 00:00:00 2001 From: wangh <123456> Date: Tue, 21 Nov 2023 17:58:07 +0800 Subject: [PATCH] =?UTF-8?q?add=20-=20=E8=B4=A8=E6=A3=80=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=E5=88=B0=E8=AE=B0=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/controller/PdaBindingController.java | 29 +++-- .../aucma/api/domain/dto/CheckInfoDto.java | 101 ++++++++++++++++++ .../base/mapper/BaseMaterialinfoMapper.java | 2 +- .../impl/BaseMaterialInfoServiceImpl.java | 4 +- .../mapper/base/BaseMaterialinfoMapper.xml | 2 +- 5 files changed, 125 insertions(+), 13 deletions(-) create mode 100644 aucma-api/src/main/java/com/aucma/api/domain/dto/CheckInfoDto.java diff --git a/aucma-api/src/main/java/com/aucma/api/controller/PdaBindingController.java b/aucma-api/src/main/java/com/aucma/api/controller/PdaBindingController.java index 8be1c44..58c42fc 100644 --- a/aucma-api/src/main/java/com/aucma/api/controller/PdaBindingController.java +++ b/aucma-api/src/main/java/com/aucma/api/controller/PdaBindingController.java @@ -1,12 +1,11 @@ package com.aucma.api.controller; +import com.aucma.api.domain.dto.CheckInfoDto; import com.aucma.api.service.IPdaBindingService; import com.aucma.common.core.domain.AjaxResult; import com.aucma.common.utils.StringUtils; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.web.bind.annotation.PostMapping; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.*; import java.util.Optional; @@ -26,13 +25,25 @@ public class PdaBindingController { //壳胆绑定-提交 @PostMapping("/boxBanding") - public AjaxResult binding(String boxCode,String innerCode,String loginName){ - String boxName = service.selectBoxNameByCode(boxCode); - if (StringUtils.isNotNull(boxName)){ - service.insertBindingInfo(boxCode,boxName,innerCode); - return success() ; - } + public AjaxResult binding(String boxCode, String innerCode, String loginName) { + String boxName = service.selectBoxNameByCode(boxCode); + if (StringUtils.isNotNull(boxName)) { + service.insertBindingInfo(boxCode, boxName, innerCode); + return success(); + } return error("箱壳条码扫描错误"); } //条码绑定 + + // 质检提交 + @PostMapping("/checkSubmit") + public AjaxResult checkSubmit(@RequestBody CheckInfoDto checkInfo/*, + @RequestParam("processCode") String processCode, + @RequestParam("userName") String userName*/) { + System.out.println(checkInfo.toString()); +// System.out.println(processCode); +// System.out.println(userName); + return success(); + } + } diff --git a/aucma-api/src/main/java/com/aucma/api/domain/dto/CheckInfoDto.java b/aucma-api/src/main/java/com/aucma/api/domain/dto/CheckInfoDto.java new file mode 100644 index 0000000..f1ddcb8 --- /dev/null +++ b/aucma-api/src/main/java/com/aucma/api/domain/dto/CheckInfoDto.java @@ -0,0 +1,101 @@ +package com.aucma.api.domain.dto; + +import java.util.List; + +/** + * @author wanghao + * @date 2023/11/21 16:44 + */ +public class CheckInfoDto { + private String code;//产品条码 + private String defect; + private List list;//缺陷列表 + private String measure;//处理措施TREATMENT_MEASURE + private String offline; + + + + public String getCode() { + return code; + } + + public void setCode(String code) { + this.code = code; + } + + public String getDefect() { + return defect; + } + + public void setDefect(String defect) { + this.defect = defect; + } + + public List getList() { + return list; + } + + public void setList(List list) { + this.list = list; + } + + public String getMeasure() { + return measure; + } + + public void setMeasure(String measure) { + this.measure = measure; + } + + public String getOffline() { + return offline; + } + + public void setOffline(String offline) { + this.offline = offline; + } + + @Override + public String toString() { + return "CheckInfoDto{" + "code='" + code + '\'' + ", defect='" + defect + '\'' + ", list=" + list + ", measure='" + measure + '\'' + ", offline='" + offline + '\'' + '}'; + } + + public static class DefectBeen { + private String qualityDefectCode; + private String qualityDefectName; + + private String itemCode; + + public DefectBeen() { + } + + public String getQualityDefectCode() { + return qualityDefectCode; + } + + public void setQualityDefectCode(String qualityDefectCode) { + this.qualityDefectCode = qualityDefectCode; + } + + public String getQualityDefectName() { + return qualityDefectName; + } + + public void setQualityDefectName(String qualityDefectName) { + this.qualityDefectName = qualityDefectName; + } + + public String getItemCode() { + return itemCode; + } + + public void setItemCode(String itemCode) { + this.itemCode = itemCode; + } + + @Override + public String toString() { + return "DefectBeen{" + "qualityDefectCode='" + qualityDefectCode + '\'' + ", qualityDefectName='" + qualityDefectName + '\'' + ", itemCode='" + itemCode + '\'' + '}'; + } + } +} diff --git a/aucma-base/src/main/java/com/aucma/base/mapper/BaseMaterialinfoMapper.java b/aucma-base/src/main/java/com/aucma/base/mapper/BaseMaterialinfoMapper.java index 1ae17a3..30939d6 100644 --- a/aucma-base/src/main/java/com/aucma/base/mapper/BaseMaterialinfoMapper.java +++ b/aucma-base/src/main/java/com/aucma/base/mapper/BaseMaterialinfoMapper.java @@ -9,7 +9,7 @@ import com.aucma.base.domain.BaseMaterialInfo; * @author Yinq * @date 2023-09-19 */ -public interface BaseMaterialInfoMapper +public interface BaseMaterialinfoMapper { /** * 查询物料信息 diff --git a/aucma-base/src/main/java/com/aucma/base/service/impl/BaseMaterialInfoServiceImpl.java b/aucma-base/src/main/java/com/aucma/base/service/impl/BaseMaterialInfoServiceImpl.java index 32ec8e6..869cc15 100644 --- a/aucma-base/src/main/java/com/aucma/base/service/impl/BaseMaterialInfoServiceImpl.java +++ b/aucma-base/src/main/java/com/aucma/base/service/impl/BaseMaterialInfoServiceImpl.java @@ -5,7 +5,7 @@ import java.util.List; import com.aucma.common.utils.DateUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; -import com.aucma.base.mapper.BaseMaterialInfoMapper; +import com.aucma.base.mapper.BaseMaterialinfoMapper; import com.aucma.base.domain.BaseMaterialInfo; import com.aucma.base.service.IBaseMaterialInfoService; @@ -19,7 +19,7 @@ import com.aucma.base.service.IBaseMaterialInfoService; public class BaseMaterialInfoServiceImpl implements IBaseMaterialInfoService { @Autowired - private BaseMaterialInfoMapper baseMaterialInfoMapper; + private BaseMaterialinfoMapper baseMaterialInfoMapper; /** * 查询物料信息 diff --git a/aucma-base/src/main/resources/mapper/base/BaseMaterialinfoMapper.xml b/aucma-base/src/main/resources/mapper/base/BaseMaterialinfoMapper.xml index f4fea57..ee79716 100644 --- a/aucma-base/src/main/resources/mapper/base/BaseMaterialinfoMapper.xml +++ b/aucma-base/src/main/resources/mapper/base/BaseMaterialinfoMapper.xml @@ -2,7 +2,7 @@ - +