Found that the location of the cassettes being added were first being sorted in an ascending order within a LOCATE loop.
This commit is contained in:
@ -16,7 +16,7 @@ COMPILE FUNCTION obj_WO_React(Method,Parms)
|
||||
|
||||
|
||||
DECLARE FUNCTION Get_Status, Msg, Utility, obj_Tables, NextKey, obj_Prod_Spec, obj_WO_Mat_QA, GetTickCount
|
||||
Declare function Environment_Services
|
||||
Declare function Environment_Services, Database_Services
|
||||
DECLARE SUBROUTINE Set_Status, Msg, obj_Tables, RList, ErrMsg, Btree.Extract, obj_WO_Mat_QA, Mona_Services
|
||||
|
||||
$INSERT MSG_EQUATES
|
||||
@ -90,7 +90,6 @@ WOReactKey = WONo:'*':StepNo:'*':ReactNo
|
||||
otParms = 'WO_REACT':@RM:WOReactKey
|
||||
|
||||
WOReactRec = obj_Tables('ReadOnlyRec',otParms)
|
||||
|
||||
RDSNos = WOReactRec<WO_REACT_RDS_NO$>
|
||||
CassNos = WOReactRec<WO_REACT_CASS_NO$>
|
||||
|
||||
@ -105,13 +104,11 @@ Start = QAMetData<COL$QA_MET_START>
|
||||
Interval = QAMetData<COL$QA_MET_INTERVAL>
|
||||
Stage = QAMetData<COL$QA_MET_STAGE>
|
||||
MetPropCd = QAMetData<COL$QA_MET_PROP>
|
||||
|
||||
GOSUB BuildAllTestPos ;* Set RDSNos, Start and Interval -> returns AllTestPos
|
||||
|
||||
|
||||
* * * Find where the the RDS being added will be in the list. * * *
|
||||
|
||||
LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> BY 'AR' USING @VM SETTING InsPos THEN
|
||||
LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> USING @VM SETTING InsPos THEN
|
||||
|
||||
otParms = 'WO_REACT':@RM:WOReactKey
|
||||
WOReactRec = obj_Tables('UnlockRec',otParms)
|
||||
@ -120,10 +117,9 @@ LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> BY 'AR' USING @VM SETTING InsPos TH
|
||||
|
||||
END ELSE
|
||||
|
||||
LOCATE InsPos IN AllTestPos BY 'AR' USING @VM SETTING TrimPos ELSE Null
|
||||
LOCATE InsPos IN AllTestPos USING @VM SETTING TrimPos ELSE Null
|
||||
|
||||
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
|
||||
|
||||
GOSUB RemSchedQA ;* Removes unsigned QAMet from cassettes scheduled past the box being removed
|
||||
|
||||
END
|
||||
@ -135,13 +131,12 @@ RDSNos = WOReactRec<WO_REACT_RDS_NO$> ;* List after insert
|
||||
CassNos = WOReactRec<WO_REACT_CASS_NO$> ;* List after insert
|
||||
|
||||
* * * Now build list for cassette
|
||||
|
||||
GOSUB BuildAllTestPos
|
||||
|
||||
GOSUB BuildAllTestPos
|
||||
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
|
||||
|
||||
GOSUB AddSchedQA ;* Add QAMet spec data to cassettes now associated with the test positions after removing the RDS & Cassno from the lists
|
||||
|
||||
|
||||
otParms = FIELDSTORE(otParms,@RM,4,0,WOReactRec)
|
||||
obj_Tables('WriteOnlyRec',otParms) ;* Done with updates to the WO_REACT record
|
||||
|
||||
@ -194,19 +189,17 @@ MetPropCd = QAMetData<COL$QA_MET_PROP>
|
||||
|
||||
GOSUB BuildAllTestPos ;* Set RDSNos, Start and Interval -> returns AllTestPos
|
||||
|
||||
|
||||
IF AllTestPos NE '' THEN
|
||||
|
||||
* * * Find where the the RDS being removed is in the list. * * *
|
||||
|
||||
LOCATE RDSNo IN WOReactRec<WO_REACT_RDS_NO$> USING @VM SETTING RemPos THEN
|
||||
|
||||
LOCATE RemPos IN AllTestPos BY 'AR' USING @VM SETTING TrimPos ELSE Null
|
||||
LOCATE RemPos IN AllTestPos USING @VM SETTING TrimPos ELSE Null
|
||||
|
||||
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
|
||||
|
||||
GOSUB RemSchedQA ;* Removes unsigned QAMet from cassettes scheduled past the box being removed
|
||||
|
||||
END ELSE
|
||||
|
||||
otParms = 'WO_REACT':@RM:WOReactKey
|
||||
@ -225,11 +218,9 @@ CassNos = WOReactRec<WO_REACT_CASS_NO$> ;* List after removal
|
||||
* * * Now build list for cassette
|
||||
|
||||
GOSUB BuildAllTestPos
|
||||
|
||||
ChangePosList = FIELD(AllTestPos,@VM,TrimPos,SeqCnt)
|
||||
|
||||
GOSUB AddSchedQA ;* Add QAMet spec data to cassettes now associated with the test positions after removing the RDS & Cassno from the lists
|
||||
|
||||
otParms = FIELDSTORE(otParms,@RM,4,0,WOReactRec)
|
||||
// 10/12/18 Changed to WriteOnlyRec as per Francois' instructions. - djs
|
||||
obj_Tables('WriteOnlyRec',otParms) ;* Done with updates to the WO_REACT record
|
||||
@ -346,3 +337,4 @@ FOR I = 1 TO chgCnt
|
||||
NEXT I
|
||||
|
||||
RETURN
|
||||
|
||||
|
Reference in New Issue
Block a user