Enhanced Error Checking
This commit is contained in:
committed by
Ouellette Jonathan (CSC FI SPS MESLEO)
parent
09d2d13e63
commit
a8dff61cfa
@ -3577,8 +3577,9 @@ end service
|
||||
Service GetReactorsWithDownLLByDtm(DtmToCheck, ReactType)
|
||||
|
||||
ErrMsg = ''
|
||||
AllReactors = Reactor_Services('GetReactorNumbers', ReactType)
|
||||
SLLReactors = ''
|
||||
If DtmToCheck NE '' then
|
||||
AllReactors = Reactor_Services('GetReactorNumbers', ReactType)
|
||||
If AllReactors NE '' then
|
||||
for each ReactNo in AllReactors using @FM
|
||||
PickPlaceFlag = XLATE('REACTOR', ReactNo, REACTOR_PICK_PLACE$, 'X')
|
||||
@ -3609,6 +3610,13 @@ Service GetReactorsWithDownLLByDtm(DtmToCheck, ReactType)
|
||||
end else
|
||||
ErrMsg = 'No Reactor IDs found!'
|
||||
end
|
||||
end else
|
||||
ErrMsg = 'Datetime to check variable was null.'
|
||||
end
|
||||
|
||||
If ErrMsg NE '' then
|
||||
Error_Services('Add', ErrMsg)
|
||||
end
|
||||
|
||||
Response = SLLReactors
|
||||
|
||||
|
@ -141,7 +141,12 @@ CreateHALItem:
|
||||
//Single Load Lock Report from Metrology Services
|
||||
ReportStartDtm = Http_Services('GetQueryField', 'StartDate')
|
||||
ReportEndDtm = Http_Services('GetQueryField', 'EndDate')
|
||||
If ReportStartDtm NE '' AND ReportEndDtm NE '' then
|
||||
RepJson = Report_Services('GetSLLReportJson', ReportStartDtm, ReportEndDtm)
|
||||
end else
|
||||
Error_Services('Add', 'Missing parameters for report.')
|
||||
end
|
||||
|
||||
Case Otherwise$
|
||||
Error_Services('Add', 'Unsupported report')
|
||||
End Case
|
||||
|
@ -2379,7 +2379,7 @@ Service GetSLLReportJson(FromDt, ToDt)
|
||||
ErrorMessage = ''
|
||||
SLLReportJson = ''
|
||||
objSLLReportJson = ''
|
||||
|
||||
If FromDt NE '' OR ToDt NE '' then
|
||||
If SRP_Json(objSLLReportJson, 'New', 'Array') then
|
||||
For StartDt = FromDt to ToDt
|
||||
ThisDate = Date_Services('ConvertDateTimeToISO8601', StartDt)
|
||||
@ -2399,6 +2399,15 @@ Service GetSLLReportJson(FromDt, ToDt)
|
||||
Next StartDt
|
||||
SLLReportJson = SRP_Json(objSLLReportJson, 'Stringify', 'Fast')
|
||||
SRP_Json(objSLLReportJson, 'Release')
|
||||
end else
|
||||
ErrorMessage = 'Error creating the root JSON for the report.'
|
||||
end
|
||||
end else
|
||||
ErrorMessage = 'From Date or To Date was null.'
|
||||
end
|
||||
|
||||
If ErrorMessage NE '' then
|
||||
Error_Services('Add', ErrorMessage)
|
||||
end
|
||||
|
||||
Response = SLLReportJson
|
||||
|
Reference in New Issue
Block a user