class Section {
  final String id;
  final String name;
  final String description;
  final String? thumbnail;
  final DateTime timeSection;

  Section({
    required this.id,
    required this.name,
    required this.description,
    this.thumbnail,
    required this.timeSection,
  });

  factory Section.fromJson(Map<String, dynamic> json) {
    return Section(
      id: json['ID_SECTION'],
      name: json['NAME_SECTION'],
      description: json['DESCRIPTION_SECTION'],
      thumbnail: json['THUMBNAIL'],
      timeSection: DateTime.parse(json['TIME_SECTION']),
    );
  }
}
