Modified full box reject logic within NCR_ACTIONS to not execute if the associated WO_MAT record already has a batch number. If it does, the scrapped quantity will be accounted for in SAP against the SAP batch using the SCRAP_IN transaction logic within NCR_ACTIONS.

This commit is contained in:
Infineon\StieberD
2025-11-04 15:10:04 -07:00
parent b4922b45ea
commit fe0ebca16a

View File

@ -147,6 +147,7 @@ READ_RECORD_PRE:
// ActionFlow = ACTION_STOP$
return
READ_RECORD:
// In order to stop a record from being read in this action these lines of code must be used:
//
@ -174,6 +175,7 @@ READ_RECORD:
return
READONLY_RECORD_PRE:
// In order to stop a record from being read in this action these lines of code must be used:
//
@ -183,6 +185,7 @@ READONLY_RECORD_PRE:
// ActionFlow = ACTION_STOP$
return
READONLY_RECORD:
// In order to stop a record from being read in this action these lines of code must be used:
//
@ -210,6 +213,7 @@ READONLY_RECORD:
return
WRITE_RECORD_PRE:
WorkOrderNo = {WO_NO}
@ -260,6 +264,7 @@ WRITE_RECORD_PRE:
return
WRITE_RECORD:
NCRNo = @ID
@ -286,6 +291,7 @@ WRITE_RECORD:
WoMatRec = Database_Services('ReadDataRow', 'WO_MAT', WoMatKey)
WMIKey = WoMatRec<WO_MAT_WMI_KEY$>
WMOKey = WoMatRec<WO_MAT_WMO_KEY$>
If WMIKey NE '' then
WMIRec = Database_Services('ReadDataRow', 'WM_IN', WMIKey)
Database_Services('WriteDataRow', 'WM_IN', WMIKey, WMIRec, True$, True$, False$)
@ -369,7 +375,10 @@ WRITE_RECORD:
end
end
// NCR has been closed. Check if it is a full box reject.
SAPBatchNo = WoMatRec<WO_MAT_SAP_BATCH_NO$>
If (SAPBatchNo EQ '') then
// NCR has been closed and SAPBatchNo is null. Check if it is a full box reject. If it is send a cassette
// complete transaction (with zero GR wafers!) to record the scrap quantity in SAP.
WONo = {WO_NO}
CassNo = {WO_MAT_CASS_NO}
WOStep = {WO_STEP}
@ -664,9 +673,11 @@ WRITE_RECORD:
end
end
end
end
return
DELETE_RECORD_PRE:
WorkOrderNo = {WO_NO}