| | |
| | | private MiloService miloService; |
| | | |
| | | /** |
| | | * 未做完工序回复plc信号 |
| | | */ |
| | | @GetMapping("/unfinishedProcess") |
| | | public AjaxResult unfinishedProcess(BsFormulaChildInfo bsFormulaChildInfo) |
| | | { |
| | | try { |
| | | String str = "MOZU1."+bsFormulaChildInfo.getProcessesCode()+".RecordDataDone"; |
| | | miloService.writeToOpcShort(ReadWriteEntity.builder().identifier(str).value(bsFormulaChildInfo.getRecordDataDone()).build()); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return AjaxResult.success(); |
| | | } |
| | | |
| | | /** |
| | | * 扫码确认 |
| | | */ |
| | | @GetMapping("/initializedData") |
| | |
| | | { |
| | | String productNum = ""; |
| | | try { |
| | | String str = "MOZU1."+bsFormulaChildInfo.getProcessesCode()+".MES_ModuleCode"; |
| | | String str = "MOZU1."+bsFormulaChildInfo.getLocationCode()+".ModuleCode"; |
| | | Object productNumObject = miloService.readFromOpcUa(str).getValue(); |
| | | if(ObjectUtil.isNotNull(productNumObject)){ |
| | | productNum = productNumObject.toString(); |