fix/scan #80
@ -99,7 +99,11 @@ namespace InternshipSystem.Api.Controllers
|
|||||||
.Include(i => i.Documentation)
|
.Include(i => i.Documentation)
|
||||||
.FirstAsync(i => i.Student.Id == user.PersonNumber, cancellationToken);
|
.FirstAsync(i => i.Student.Id == user.PersonNumber, cancellationToken);
|
||||||
|
|
||||||
var document = internship.Documentation.First(d => d.Id == documentId);
|
var document = await _context.Entry(internship)
|
||||||
|
.Collection(i => i.Documentation)
|
||||||
|
.Query()
|
||||||
|
.Include(d => d.Scan)
|
||||||
|
.FirstAsync(d => d.Id == documentId, cancellationToken);
|
||||||
|
|
||||||
document.Scan ??= new DocumentScan();
|
document.Scan ??= new DocumentScan();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user