fix: error CS1061
All checks were successful
.NET Test Pipeline / build-and-test (pull_request) Successful in 2m7s
All checks were successful
.NET Test Pipeline / build-and-test (pull_request) Successful in 2m7s
This commit is contained in:
parent
ca18804a33
commit
d8f2f51cd7
@ -11,13 +11,15 @@ public class GetScheduleListQueryHandler(ILessonDbContext dbContext) : IRequestH
|
||||
{
|
||||
public async Task<ScheduleListVm> Handle(GetScheduleListQuery request, CancellationToken cancellationToken)
|
||||
{
|
||||
var query = dbContext.Lessons.Include(l => l.LessonAssociations)
|
||||
var query = dbContext.Lessons
|
||||
.Include(l => l.LessonAssociations)
|
||||
.ThenInclude(la => la.LectureHall)
|
||||
.ThenInclude(lh => lh!.Campus)
|
||||
.Include(l => l.LessonAssociations)
|
||||
.ThenInclude(la => la.Professor)
|
||||
.Include(l => l.LessonAssociations)
|
||||
.ThenInclude(la => la.TypeOfOccupation)
|
||||
.Include(l => l.Group)
|
||||
.Include(l => l.TypeOfOccupation)
|
||||
.Include(l => l.Discipline)
|
||||
.AsQueryable();
|
||||
|
||||
@ -46,7 +48,9 @@ public class GetScheduleListQueryHandler(ILessonDbContext dbContext) : IRequestH
|
||||
DayOfWeek = l.DayOfWeek,
|
||||
PairNumber = l.PairNumber,
|
||||
IsEven = l.IsEven,
|
||||
TypeOfOccupation = l.TypeOfOccupation!.ShortName,
|
||||
TypeOfOccupations = l.LessonAssociations!
|
||||
.Where(la => !string.IsNullOrEmpty(la.TypeOfOccupation?.ShortName))
|
||||
.Select(la => la.TypeOfOccupation!.ShortName),
|
||||
|
||||
Discipline = l.Discipline!.Name,
|
||||
DisciplineId = l.DisciplineId,
|
||||
|
@ -33,11 +33,6 @@ public class ScheduleLookupDto
|
||||
/// </summary>
|
||||
public required int DisciplineId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the type of occupation.
|
||||
/// </summary>
|
||||
public required string TypeOfOccupation { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the name of the group.
|
||||
/// </summary>
|
||||
@ -48,6 +43,11 @@ public class ScheduleLookupDto
|
||||
/// </summary>
|
||||
public required int GroupId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the type of occupation.
|
||||
/// </summary>
|
||||
public required IEnumerable<string> TypeOfOccupations { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the names of the lecture halls.
|
||||
/// </summary>
|
||||
|
Loading…
Reference in New Issue
Block a user