ScheduleDto typedef

ScheduleDto = ({List<LocalizedRefDto>? classes, LocalizedRefDto? course, double? credits, int? hours, String? language, String? number, int? phase, String? remarks, List<({ReferenceDto? classroom, DayOfWeek day, Period period})>? schedule, String? status, String? syllabusId, LocalizedRefDto? teacher, String? type})

Course schedule entry from the course selection system.

Implementation

typedef ScheduleDto = ({
  /// Course offering number (e.g., "313146", "352902").
  String? number,

  /// Reference to the course with bilingual name.
  LocalizedRefDto? course,

  /// Course sequence phase/stage number (階段, e.g., "1", "2").
  int? phase,

  /// Number of credits for this course.
  double? credits,

  /// Number of hours per week.
  int? hours,

  /// Type of course (e.g., "必", "選", "通", "輔").
  String? type,

  /// Reference to the instructor with bilingual name.
  LocalizedRefDto? teacher,

  /// List of class/program references with bilingual names.
  List<LocalizedRefDto>? classes,

  /// Weekly schedule as list of (day, period, classroom) entries.
  ///
  /// Each entry includes the classroom for that specific timeslot, as some
  /// courses use different rooms for different sessions.
  List<({DayOfWeek day, Period period, ReferenceDto? classroom})>? schedule,

  /// Enrollment status for special cases (e.g., "撤選" for withdrawal).
  ///
  /// Normally null for regular enrolled courses.
  String? status,

  /// Language of instruction.
  String? language,

  /// Syllabus identifier for fetching course syllabus.
  String? syllabusId,

  /// Additional remarks or notes about the course.
  String? remarks,
});