Skip to content

Commit

Permalink
Fix bug in InspectionFindingService to include plants
Browse files Browse the repository at this point in the history
  • Loading branch information
MuhammadUsama-afk-equinor committed Nov 29, 2023
1 parent 392d94e commit 8a237e8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/api/Services/InspectionFindingService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public async Task<List<InspectionFinding>> RetrieveInspectionFindings(DateTime l
public async Task<MissionRun?> GetMissionRunByIsarStepId(InspectionFinding inspectionFinding)
{
return await context.MissionRuns
.Include(mr => mr.Area)
.Include(mr => mr.Area).ThenInclude(area => area != null ? area.Plant : null)
.Include(mr => mr.Robot)
.Where(mr => mr.Tasks.Any(mt => mt.Inspections.Any(i => i.IsarStepId == inspectionFinding.IsarStepId)))
.FirstOrDefaultAsync()
Expand Down

0 comments on commit 8a237e8

Please sign in to comment.