From 0de0a72329a77fbf20bc299c542e435a6d47256b Mon Sep 17 00:00:00 2001
From: LAPTOP-SNT8I5JK\Boounion <Chenluhua@qq.com>
Date: 星期六, 21 六月 2025 17:12:01 +0800
Subject: [PATCH] Merge branch 'liuyang' into clh
---
SourceCode/Bond/Servo/CLoadPort.cpp | 40 ++++++++++++++++++++++++++++++++++++++++
1 files changed, 40 insertions(+), 0 deletions(-)
diff --git a/SourceCode/Bond/Servo/CLoadPort.cpp b/SourceCode/Bond/Servo/CLoadPort.cpp
index cee42a2..d2366f1 100644
--- a/SourceCode/Bond/Servo/CLoadPort.cpp
+++ b/SourceCode/Bond/Servo/CLoadPort.cpp
@@ -1140,4 +1140,44 @@
return 0;
}
+ int CLoadPort::testGenerateGlassListFromConfig(const SERVO::PortConfig& config)
+ {
+ char szBuffer[64];
+ for (const auto& slot : config.vecSlot) {
+ if (!slot.isEnabled) continue;
+
+ int nSlotIndex = slot.nSlotID - 1;
+ if (nSlotIndex < 0 || nSlotIndex >= SLOT_MAX) {
+ continue;
+ }
+
+ m_slot[nSlotIndex].enable();
+
+ if (!m_slot[nSlotIndex].isEnable()) continue;
+
+ CJobDataS js;
+ js.setCassetteSequenceNo(getNextCassetteSequenceNo());
+ js.setJobSequenceNo(m_slot[nSlotIndex].getNo());
+
+ sprintf_s(szBuffer, 64, "%05d%05d", js.getCassetteSequenceNo(), js.getJobSequenceNo());
+ js.setJobType(1);
+ js.setMaterialsType(config.nMaterialType);
+
+ js.setLotId(config.strLotID.c_str());
+ js.setProductId(config.strProductID.c_str());
+ js.setOperationId(config.strOperationID.c_str());
+ js.setGlass1Id(szBuffer);
+
+ CGlass* pGlass = theApp.m_model.m_glassPool.allocaGlass();
+ pGlass->addPath(m_nID, 0);
+ pGlass->processEnd(m_nID, 0);
+ pGlass->setID(szBuffer);
+ pGlass->setType(static_cast<SERVO::MaterialsType>(config.nMaterialType));
+ pGlass->setJobDataS(&js);
+
+ m_slot[nSlotIndex].setContext(pGlass);
+ }
+
+ return 0;
+ }
}
--
Gitblit v1.9.3