Removed error messages on lost focus events and instead just display the error on write operation.

This commit is contained in:
Infineon\StieberD
2025-10-22 12:39:26 -07:00
parent 374e5c2b51
commit 79cde8e098
2 changed files with 249 additions and 298 deletions

View File

@ -149,51 +149,53 @@ WRITE_RECORD_PRE:
// Req'd parameter checks
ItemType = {RI_TYPE}
If ItemType EQ '' then ErrMsg := 'Item Type was not specified. '
If ItemType EQ '' then ErrMsg := 'Item Type was not specified.':CRLF$
If (ItemType NE 'LE') AND (ItemType NE 'RE') then
SerialNo = Record<REACT_ITEM_SERIAL_NO$>
If SerialNo EQ '' then
ErrMsg := 'Serial No. is required for this Reactor Item type. '
ErrMsg := 'Serial No. is required for this Reactor Item type.':CRLF$
end
end
If ItemType EQ 'S' then
PocketQty = Record<REACT_ITEM_PKT_QTY$>
PartType = Record<REACT_ITEM_PART_TYPE$>
PocketQty = Record<REACT_ITEM_PKT_QTY$>
PocketSize = Record<REACT_ITEM_PKT_SIZE$>
If PartType EQ '' then
ErrMsg := 'Part Type is required for Susceptor Reactor Item type.':CRLF$
end
If PocketSize EQ '' then
ErrMsg := 'Pocket size is required for Susceptor Item Type. '
ErrMsg := 'Pocket size is required for Susceptor Item Type.':CRLF$
end
If PocketQty EQ '' then
ErrMsg := 'Pocket quantity is required for Susceptor Item Type. '
ErrMsg := 'Pocket quantity is required for Susceptor Item Type.':CRLF$
end
If ErrMsg = '' then
ExpectedQty = ''
Begin Case
Case Record<REACT_ITEM_PART_TYPE$> EQ 'ASM'
Case PartType EQ 'ASM'
If PocketSize EQ 6 OR PocketSize EQ 8 then
ExpectedQty = 1
end
Case Record<REACT_ITEM_PART_TYPE$> EQ 'HTR'
Case PartType EQ 'HTR'
If PocketSize EQ 8 then
ExpectedQty = 3
end else
If PocketSize EQ 6 then ExpectedQty = 5
end
Case Record<REACT_ITEM_PART_TYPE$> EQ 'EPP'
Case PartType EQ 'EPP'
If PocketSize EQ 8 then
ExpectedQty = 8
end else
If PocketSize EQ 6 then ExpectedQty = 18
end
Case Record<REACT_ITEM_PART_TYPE$> EQ ''
ErrMsg := 'Part Type. is required for Susceptor Reactor Item type. '
Case Otherwise$
ErrMsg := 'Invalid Part Type for Susceptor Reactor Item Type. '
ErrMsg := 'Invalid Part Type for Susceptor Reactor Item Type.':CRLF$
End Case
If ExpectedQty NE '' then
If PocketQty NE ExpectedQty then
ErrMsg := 'Invalid Pocket Quantity for Part Type/Pocket Size combination. '
ErrMsg := 'Invalid Pocket Quantity for Part Type/Pocket Size combination.':CRLF$
end
end
end
@ -201,8 +203,10 @@ WRITE_RECORD_PRE:
end
If ErrMsg NE '' then
Error_Services('Add', 'Error Saving Reactor Item: ' : ErrMsg)
OrigFileError = 104:': Error Saving Reactor Item: ' : ErrMsg
// Strip off last @FM
ErrMsg[-1, 2] = ''
Error_Services('Add', 'Error Saving Reactor Item:' : CRLF$ : ErrMsg)
OrigFileError = 104:': Error Saving Reactor Item:' : CRLF$ : ErrMsg
Status = 0
Record = ''
ActionFlow = ACTION_STOP$
@ -289,6 +293,3 @@ Restore_System_Variables:
return