migrated timetable integration from WebUntis to the MarianumConnect API, implementing a Dio-based client with bearer token authentication, background session validation, and auto-refresh logic.
This commit is contained in:
@@ -12,31 +12,33 @@ _TimetableState _$TimetableStateFromJson(Map<String, dynamic> json) =>
|
||||
(json['weekCache'] as Map<String, dynamic>?)?.map(
|
||||
(k, e) => MapEntry(
|
||||
k,
|
||||
GetTimetableResponse.fromJson(e as Map<String, dynamic>),
|
||||
TimetableGetWeekResponse.fromJson(e as Map<String, dynamic>),
|
||||
),
|
||||
) ??
|
||||
const <String, GetTimetableResponse>{},
|
||||
const <String, TimetableGetWeekResponse>{},
|
||||
rooms: json['rooms'] == null
|
||||
? null
|
||||
: GetRoomsResponse.fromJson(json['rooms'] as Map<String, dynamic>),
|
||||
: TimetableGetRoomsResponse.fromJson(
|
||||
json['rooms'] as Map<String, dynamic>,
|
||||
),
|
||||
subjects: json['subjects'] == null
|
||||
? null
|
||||
: GetSubjectsResponse.fromJson(
|
||||
: TimetableGetSubjectsResponse.fromJson(
|
||||
json['subjects'] as Map<String, dynamic>,
|
||||
),
|
||||
schoolHolidays: json['schoolHolidays'] == null
|
||||
? null
|
||||
: GetHolidaysResponse.fromJson(
|
||||
: TimetableGetHolidaysResponse.fromJson(
|
||||
json['schoolHolidays'] as Map<String, dynamic>,
|
||||
),
|
||||
schoolyear: json['schoolyear'] == null
|
||||
? null
|
||||
: GetCurrentSchoolyearResponse.fromJson(
|
||||
: TimetableGetSchoolyearResponse.fromJson(
|
||||
json['schoolyear'] as Map<String, dynamic>,
|
||||
),
|
||||
timegrid: json['timegrid'] == null
|
||||
? null
|
||||
: GetTimegridUnitsResponse.fromJson(
|
||||
: TimetableGetTimegridResponse.fromJson(
|
||||
json['timegrid'] as Map<String, dynamic>,
|
||||
),
|
||||
customEvents: json['customEvents'] == null
|
||||
|
||||
Reference in New Issue
Block a user