Inline pctypeId logic to fix production Object required error
This commit is contained in:
28
api.asp
28
api.asp
@@ -250,9 +250,31 @@ Sub UpdateCompleteAsset()
|
|||||||
machineTypeId = 33
|
machineTypeId = 33
|
||||||
debugMsg = debugMsg & "7-machineTypeId=" & machineTypeId & ","
|
debugMsg = debugMsg & "7-machineTypeId=" & machineTypeId & ","
|
||||||
|
|
||||||
' Get PC type ID from pcType string
|
' Get PC type ID from pcType string (inlined to avoid function call issues)
|
||||||
Dim pctypeId
|
Dim pctypeId, pcTypeClean
|
||||||
pctypeId = GetPCTypeIdFromPCType(pcType)
|
pcTypeClean = Trim(UCase(pcType))
|
||||||
|
Select Case pcTypeClean
|
||||||
|
Case "ENGINEER", "ENGINEERING"
|
||||||
|
pctypeId = 2
|
||||||
|
Case "SHOPFLOOR", "SHOP FLOOR"
|
||||||
|
pctypeId = 3
|
||||||
|
Case "CMM"
|
||||||
|
pctypeId = 5
|
||||||
|
Case "WAX TRACE", "WAXTRACE", "WAX", "WAX / TRACE"
|
||||||
|
pctypeId = 6
|
||||||
|
Case "KEYENCE"
|
||||||
|
pctypeId = 7
|
||||||
|
Case "GENSPECT", "EAS1000"
|
||||||
|
pctypeId = 8
|
||||||
|
Case "HEAT TREAT", "HEATTTREAT", "HEATTEAT", "HEAT_TREAT", "HEATTREAT"
|
||||||
|
pctypeId = 9
|
||||||
|
Case "PART MARKER", "PARTMARKER"
|
||||||
|
pctypeId = 10
|
||||||
|
Case "MEASURING", "MEASURING TOOL"
|
||||||
|
pctypeId = 7
|
||||||
|
Case Else
|
||||||
|
pctypeId = 1
|
||||||
|
End Select
|
||||||
debugMsg = debugMsg & "7b-pctypeId=" & pctypeId & ","
|
debugMsg = debugMsg & "7b-pctypeId=" & pctypeId & ","
|
||||||
|
|
||||||
' Check if PC exists
|
' Check if PC exists
|
||||||
|
|||||||
Reference in New Issue
Block a user