Merge remote-tracking branch 'origin/dev-temp-xw-202501160000-44858' into uat

tags/yfai-pcn-ext-v2.81
王杰 4 months ago
commit f241329b41

@ -2,8 +2,11 @@ package cn.estsh.i3plus.ext.mes.pcn.apiservice.controller.busi;
import cn.estsh.i3plus.ext.mes.pcn.api.base.IMesPartService;
import cn.estsh.i3plus.ext.mes.pcn.pojo.constant.MesCommonConstant;
import cn.estsh.i3plus.pojo.base.bean.ListPager;
import cn.estsh.i3plus.pojo.base.common.Pager;
import cn.estsh.i3plus.pojo.mes.bean.MesPart;
import cn.estsh.i3plus.pojo.mes.bean.MesPartSap;
import cn.estsh.i3plus.pojo.mes.bean.MesPartType;
import cn.estsh.impp.framework.boot.exception.ImppBusiException;
import cn.estsh.impp.framework.boot.exception.ImppExceptionBuilder;
import cn.estsh.impp.framework.boot.util.ResultBean;
@ -14,6 +17,8 @@ import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* @Description :
* @Reference :
@ -33,7 +38,17 @@ public class MesPartController {
@ApiOperation(value = "查询信息")
public ResultBean queryMesPart(MesPart mesPart, Pager pager) {
try {
return ResultBean.success("查询成功").setListPager(mesPartService.queryMesPart(mesPart, pager));
ListPager<MesPart> mesPartListPager = mesPartService.queryMesPart(mesPart, pager);
List<MesPart> partList = mesPartListPager.getObjectList();
for (MesPart part : partList) {
MesPartSap partSap = mesPartService.getMesPartSapByPartNo(part.getPartNo(), part.getOrganizeCode());
if (partSap != null) {
part.setUnit(partSap.getUnit());
}
}
mesPartListPager.setObjectList(partList);
return ResultBean.success("查询成功").setListPager(mesPartListPager);
} catch (ImppBusiException imppException) {
return ResultBean.fail(imppException);
} catch (Exception e) {

@ -127,6 +127,7 @@ public class MesProductResultErrorHandleStepService extends BaseStepService {
//mesDefectType.setDefectType(MesExtEnumUtil.MES_DEFECT_TYPE);
model.setSn(mesProduceSn.getProductSn());
model.setPerson(mesDefectType);
model.setUserName(reqBean.getUserInfo());
MesPartInspection partInspection = new MesPartInspection();
@ -160,10 +161,10 @@ public class MesProductResultErrorHandleStepService extends BaseStepService {
mesPartInspectionDetail.setDefectTypeCode(mesDefectType.getDefectTypeCode());
mesPartInspectionDetail.setDefectTypeName(mesDefectType.getDefectTypeName());
model.setPartInspection(partInspection);
model.setType(partInspection.getSourceType());
model.setType(MesExtEnumUtil.EQUIP_VARIABLE_CFG_CATEGORY.PRODUCT_SUSPICIOUS.getCode());
model.setProductVersion(productVersion);
if (Objects.equal(MesExtEnumUtil.EQUIP_VARIABLE_CFG_CATEGORY.PRODUCT_SCRAP.getValue(), productResult)) {
if (Objects.equal(MesExtEnumUtil.EQUIP_VARIABLE_CFG_CATEGORY.PRODUCT_SCRAP.getCode(), productResult)) {
model.setType(MesExtEnumUtil.NC_TYPE.SCRAP.getValue());
}
MesPartSap mesPartSap = new MesPartSap();

Loading…
Cancel
Save