mirror of
https://github.com/SyncrowIOT/web.git
synced 2025-07-09 22:57:21 +00:00
27 lines
617 B
Dart
27 lines
617 B
Dart
class Schedule {
|
|
final String effectiveTime;
|
|
final String invalidTime;
|
|
final List<String> workingDay;
|
|
|
|
Schedule({
|
|
required this.effectiveTime,
|
|
required this.invalidTime,
|
|
required this.workingDay,
|
|
});
|
|
|
|
factory Schedule.fromJson(Map<String, dynamic> json) {
|
|
return Schedule(
|
|
effectiveTime: json['effectiveTime'],
|
|
invalidTime: json['invalidTime'],
|
|
workingDay: List<String>.from(json['workingDay']),
|
|
);
|
|
}
|
|
|
|
Map<String, dynamic> toJson() {
|
|
return {
|
|
'effectiveTime': effectiveTime,
|
|
'invalidTime': invalidTime,
|
|
'workingDay': workingDay,
|
|
};
|
|
}
|
|
} |