mapListFromJson static method

Map<String, List<MonthlyInvoiceSummaryModel>> mapListFromJson(
  1. dynamic json
)

Implementation

static Map<String, List<MonthlyInvoiceSummaryModel>> mapListFromJson(
  dynamic json,
) {
  final map = <String, List<MonthlyInvoiceSummaryModel>>{};
  if (json is Map && json.isNotEmpty) {
    json.cast<String, dynamic>().forEach((key, dynamic value) {
      map[key] = MonthlyInvoiceSummaryModel.listFromJson(value);
    });
  }
  return map;
}