import 'package:hmg_patient_app_new/core/utils/date_util.dart';

class WeekDiabeticResultAverage {
  dynamic dailyAverageResult;
  DateTime? dateChart;

  WeekDiabeticResultAverage({this.dailyAverageResult, this.dateChart});

  WeekDiabeticResultAverage.fromJson(Map<String, dynamic> json) {
    dailyAverageResult = json['DailyAverageResult'];
    dateChart = DateUtil.convertStringToDate(json['DateChart']);
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = <String, dynamic>{};
    data['DailyAverageResult'] = dailyAverageResult;
    data['DateChart'] = DateUtil.convertDateToString(dateChart!);
    return data;
  }
}

