///
/// Code generated by jsonToDartModel https://ashamp.github.io/jsonToDartModel/
///
class TagHomeData {
/*
{
  "id": 1,
  "title": "",
  "color": ""
}
*/

  int? id;
  String? title;
  String? color;

  TagHomeData({
    this.id,
    this.title,
    this.color,
  });
  TagHomeData.fromJson(Map<String, dynamic> json) {
    id = json["id"]?.toInt();
    title = json["title"]?.toString();
    color = json["color"]?.toString();
  }
  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = Map<String, dynamic>();
    data["id"] = id;
    data["title"] = title;
    data["color"] = color;
    return data;
  }
}

class TagHomeResponse {
/*
{
  "totalRecord": 9,
  "isSuccess": true,
  "errorMesssage": null,
  "Data": [
    {
      "id": 1,
      "title": "",
      "color": ""
    }
  ],
  "message": null
}
*/

  int? totalRecord;
  bool? isSuccess;
  String? errorMesssage;
  List<TagHomeData>? Data;
  String? message;

  TagHomeResponse({
    this.totalRecord,
    this.isSuccess,
    this.errorMesssage,
    this.Data,
    this.message,
  });
  TagHomeResponse.fromJson(Map<String, dynamic> json) {
    totalRecord = json["totalRecord"]?.toInt();
    isSuccess = json["isSuccess"];
    errorMesssage = json["errorMesssage"]?.toString();
    if (json["Data"] != null) {
      final v = json["Data"];
      final arr0 = <TagHomeData>[];
      v.forEach((v) {
        arr0.add(TagHomeData.fromJson(v));
      });
      Data = arr0;
    }
    message = json["message"]?.toString();
  }
  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = Map<String, dynamic>();
    data["totalRecord"] = totalRecord;
    data["isSuccess"] = isSuccess;
    data["errorMesssage"] = errorMesssage;
    if (Data != null) {
      final v = Data;
      final arr0 = [];
      v!.forEach((v) {
        arr0.add(v.toJson());
      });
      data["Data"] = arr0;
    }
    data["message"] = message;
    return data;
  }
}
