tags/yfai-pcn-ext-v1.0
王杰 12 months ago
parent d53f56800e
commit 4b76393bfd

@ -100,7 +100,7 @@ public class MesFirstMouldNoReadStepService extends BaseStepService {
productionProcessContextStepService.doCacheContext(reqBean, productionProcessContext);
if (!stepResult.isCompleted()) threadSleep(stepParamMap, MesPcnExtConstWords.READ_FAILURE_SLEEP, 1000L);
if (!stepResult.isCompleted()) threadSleep(stepParamMap, MesPcnExtConstWords.READ_FAILURE_SLEEP, MesPcnExtConstWords.READ_FAILURE_SLEEP_DEFAULT_TIME);
return stepResult;

@ -101,7 +101,7 @@ public class MesMouldNoReadStepService extends BaseStepService {
productionProcessContextStepService.doCacheContext(reqBean, productionProcessContext);
if (!stepResult.isCompleted()) threadSleep(stepParamMap, MesPcnExtConstWords.READ_FAILURE_SLEEP, 1000L);
if (!stepResult.isCompleted()) threadSleep(stepParamMap, MesPcnExtConstWords.READ_FAILURE_SLEEP, MesPcnExtConstWords.READ_FAILURE_SLEEP_DEFAULT_TIME);
return stepResult;

@ -93,7 +93,7 @@ public class MesProductResultReadStepService extends BaseStepService {
productionProcessContextStepService.doCacheContext(reqBean, productionProcessContext);
if (!stepResult.isCompleted()) threadSleep(stepParamMap, MesPcnExtConstWords.READ_FAILURE_SLEEP, 1000L);
if (!stepResult.isCompleted()) threadSleep(stepParamMap, MesPcnExtConstWords.READ_FAILURE_SLEEP, MesPcnExtConstWords.READ_FAILURE_SLEEP_DEFAULT_TIME);
return stepResult;

@ -58,7 +58,11 @@ public class MesProductionProcessContext {
@ApiParam("设备变量集合信息([Json]List<MesEquipmentVariable>)")
private String equipVariableJson;
@ApiParam("腔组明细信息")
private String cavityGroupDetailJson;
@ApiParam("腔组明细加工参数信息")
private String cavityGroupProdParamJson;
//-----------------根据业务执行情况必要时清理-----------------
@ -75,25 +79,37 @@ public class MesProductionProcessContext {
@ApiParam("一模多腔信息")
private String mouldCavityJson;
//--------------------------------------------------------
@ApiParam("零件信息")
private String partJson;
@ApiParam("腔组明细信息")
private String cavityGroupDetailJson;
@ApiParam("扫描信息:生产工单号")
private String workOrderNoJson;
@ApiParam("设备加工参数信息")
private String equipProdParamJson;
@ApiParam("扫描信息:主条码")
private String productSnJson;
@ApiParam("扫描信息:装配件条码")
private String assemblySnJson;
@ApiParam("零件条码信息")
private String produceSnDataJson;
@ApiParam("生产工单信息")
private String workOrderDataJson;
@ApiParam("装配件信息(非排序/排序线排产装配目视项)")
private String assemblyDataJson;
@ApiParam("非排序加工规则信息")
private String unSortRuleJson;
@ApiParam("装配件信息(非排序/排序线排产装配目视项)")
private String assemblyJson;
@ApiParam("设备加工参数信息")
private String equipProdParamJson;
@ApiParam("时效性信息")
private String timeEfficientJson;
@ApiParam("零件条码信息")
private String produceSnJson;
//--------------------------------------------------------
public MesProductionProcessContext() {}
@ -308,4 +324,38 @@ public class MesProductionProcessContext {
return this;
}
//从上下文中取出零件信息集合
public List<MesPart> getPartList() {
return StringUtils.isEmpty(this.partJson) ? null : JSONObject.parseArray(this.partJson, MesPart.class);
}
//上下文赋值零件信息集合
public MesProductionProcessContext partJson(List<MesPart> partList) {
this.partJson = !CollectionUtils.isEmpty(partList) ? JSONObject.toJSONString(partList) : null;
return this;
}
//上下文清除零件信息
public MesProductionProcessContext partJsonClear() {
this.partJson = null;
return this;
}
//从上下文中取出零件条码信息集合
public List<MesProduceSn> getProduceSnDataList() {
return StringUtils.isEmpty(this.produceSnDataJson) ? null : JSONObject.parseArray(this.produceSnDataJson, MesProduceSn.class);
}
//上下文赋值零件条码信息集合
public MesProductionProcessContext produceSnDataJson(List<MesProduceSn> produceSnList) {
this.produceSnDataJson = !CollectionUtils.isEmpty(produceSnList) ? JSONObject.toJSONString(produceSnList) : null;
return this;
}
//上下文清除零件条码信息
public MesProductionProcessContext produceSnDataJsonClear() {
this.produceSnDataJson = null;
return this;
}
}

@ -70,6 +70,8 @@ public class MesPcnExtConstWords {
public static final String EQUIPMENT_CODE_UC = "EQUIPMENT_CODE";
// 读取失败睡眠毫秒数[工步参数]
public static final String READ_FAILURE_SLEEP = "READ_FAILURE_SLEEP";
// 0
public static final Long READ_FAILURE_SLEEP_DEFAULT_TIME = 1000L;

Loading…
Cancel
Save