class NotificationDTO {
  int? id;
  String? subject;
  String? message;
  int? tbCropId;
  int? tbEntityId;
  String? contents;
  String? createdDate;
  String? sendDate;
  int? isRead;
  String? type;

  NotificationDTO({
    this.id,
    this.subject,
    this.message,
    this.tbCropId,
    this.tbEntityId,
    this.contents,
    this.createdDate,
    this.sendDate,
    this.type,
    this.isRead,
  });
  NotificationDTO.clone(NotificationDTO noti) {
    this.id = noti.id;
    this.contents = noti.contents;
    this.tbCropId = noti.tbCropId;
    this.tbEntityId = noti.tbEntityId;
    this.subject = noti.subject;
    this.message = noti.message;
    this.createdDate = noti.createdDate;
    this.sendDate = noti.sendDate;
    this.type = noti.type;
    this.isRead = noti.isRead;
  }
  NotificationDTO.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    subject = json['subject'];
    message = json['message'];
    tbCropId = json['tbCropId'];
    tbEntityId = json['tbEntityId'];
    contents = json['contents'];
    createdDate = json['createdDate'];
    sendDate = json['sendDate'];
    type = json['type'];
    isRead = json['isRead'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['subject'] = this.subject;
    data['message'] = this.message;
    data['tbCropId'] = this.tbCropId;
    data['tbEntityId'] = this.tbEntityId;
    data['contents'] = this.contents;
    data['createdDate'] = this.createdDate;
    data['sendDate'] = this.sendDate;
    data['type'] = this.type;
    data['isRead'] = this.isRead;
    return data;
  }
}
