// GENERATED CODE - DO NOT MODIFY BY HAND

part of 'training_workout.model.dart';

// **************************************************************************
// JsonSerializableGenerator
// **************************************************************************

TrainingWorkout _$TrainingWorkoutFromJson(Map<String, dynamic> json) {
  return TrainingWorkout()
    ..id = json['id'] as int
    ..box_id = json['box_id'] as int
    ..name = json['name'] as String
    ..description = json['description'] as String
    ..category = json['category'] as String
    ..created_at = json['created_at'] == null
        ? null
        : DateTime.parse(json['created_at'] as String)
    ..updated_at = json['updated_at'] == null
        ? null
        : DateTime.parse(json['updated_at'] as String)
    ..training_workout_sections = (json['training_workout_sections'] as List)
        ?.map((e) => e == null
            ? null
            : TrainingWorkoutSection.fromJson(e as Map<String, dynamic>))
        ?.toList();
}

Map<String, dynamic> _$TrainingWorkoutToJson(TrainingWorkout instance) =>
    <String, dynamic>{
      'id': instance.id,
      'box_id': instance.box_id,
      'name': instance.name,
      'description': instance.description,
      'category': instance.category,
      'created_at': instance.created_at?.toIso8601String(),
      'updated_at': instance.updated_at?.toIso8601String(),
      'sections': instance.training_workout_sections,
    };
