Bypass validation for REACT_ITEMs being retired.

This commit is contained in:
Infineon\Mitchem
2025-09-03 13:15:58 -07:00
parent 7ec010b03f
commit 981840fd95
2 changed files with 63 additions and 51 deletions

View File

@ -503,6 +503,7 @@ RETURN
LUPktSize: LUPktSize:
* * * * * * * * * * * * * *
Retired = Get_Property(@Window: '.RETIRE_DT', 'TEXT')
RIType = Get_Property(@Window:'.RI_TYPE', 'TEXT') RIType = Get_Property(@Window:'.RI_TYPE', 'TEXT')
If RIType EQ 'S' then If RIType EQ 'S' then
PocketQty = '' PocketQty = ''
@ -533,7 +534,7 @@ If RIType EQ 'S' then
Set_Property(@Window:'.PKT_QTY', 'TEXT', PocketQty) Set_Property(@Window:'.PKT_QTY', 'TEXT', PocketQty)
END END
end else end else
ErrMsg('A valid Part Type (EPP, ASM, HTR) must be selected before selecting Pocket Size.') If Retired EQ '' then ErrMsg('A valid Part Type (EPP, ASM, HTR) must be selected before selecting Pocket Size.')
end end
end end
@ -597,6 +598,7 @@ RETURN
PktSizeChange: PktSizeChange:
Retired = Get_Property(@Window: '.RETIRE_DT', 'TEXT')
RIType = Get_Property(@Window:'.RI_TYPE', 'TEXT') RIType = Get_Property(@Window:'.RI_TYPE', 'TEXT')
If RIType EQ 'S' then If RIType EQ 'S' then
PocketQty = '' PocketQty = ''
@ -624,12 +626,13 @@ PktSizeChange:
End Case End Case
Set_Property(@Window:'.PKT_QTY', 'TEXT', PocketQty) Set_Property(@Window:'.PKT_QTY', 'TEXT', PocketQty)
end else end else
ErrMsg('A valid Pocket Size (6 or 8 in.) is required.') If Retired EQ '' then ErrMsg('A valid Pocket Size (6 or 8 in.) is required.')
end end
end else end else
ErrMsg('A valid Part Type (EPP, ASM, HTR) must be selected before selecting Pocket Size.') If Retired EQ '' then ErrMsg('A valid Part Type (EPP, ASM, HTR) must be selected before selecting Pocket Size.')
end end
end end
return return

View File

@ -136,7 +136,16 @@ return
WRITE_RECORD_PRE: WRITE_RECORD_PRE:
ErrMsg = '' ErrMsg = ''
OrigRetireDt = OrigRecord<REACT_ITEM_RETIRE_DT$>
NewRetireDt = Record<REACT_ITEM_RETIRE_DT$>
If OrigRetireDt EQ '' AND NewRetireDt NE '' then
RetireBypass = True$
end else
RetireBypass = False$
end
If RetireBypass EQ False$ then
// Req'd parameter checks // Req'd parameter checks
ItemType = {RI_TYPE} ItemType = {RI_TYPE}
@ -189,6 +198,7 @@ WRITE_RECORD_PRE:
end end
end end
end end
end
If ErrMsg NE '' then If ErrMsg NE '' then
Error_Services('Add', 'Error Saving Reactor Item: ' : ErrMsg) Error_Services('Add', 'Error Saving Reactor Item: ' : ErrMsg)
@ -197,8 +207,6 @@ WRITE_RECORD_PRE:
Record = '' Record = ''
ActionFlow = ACTION_STOP$ ActionFlow = ACTION_STOP$
end else end else
OrigRetireDt = OrigRecord<REACT_ITEM_RETIRE_DT$>
NewRetireDt = Record<REACT_ITEM_RETIRE_DT$>
OrigNotes = OrigRecord<REACT_ITEM_NOTES$> OrigNotes = OrigRecord<REACT_ITEM_NOTES$>
NewNotes = Record<REACT_ITEM_NOTES$> NewNotes = Record<REACT_ITEM_NOTES$>
If ( (OrigRetireDt NE NewRetireDt) or (OrigNotes NE NewNotes) ) then If ( (OrigRetireDt NE NewRetireDt) or (OrigNotes NE NewNotes) ) then
@ -283,3 +291,4 @@ return