import 'package:domain/generated/json/base/json_field.dart';
import 'package:domain/generated/json/notification_page_entity.g.dart';
import 'dart:convert';
export 'package:domain/generated/json/notification_page_entity.g.dart';

@JsonSerializable()
class NotificationPageEntity {
	int count = 0;
	int page = 0;
	int limit = 0;
	@JSONField(name: "count_page")
	int countPage = 0;
	List<NotificationPageList>? list = [];

	NotificationPageEntity();

	factory NotificationPageEntity.fromJson(Map<String, dynamic> json) => $NotificationPageEntityFromJson(json);

	Map<String, dynamic> toJson() => $NotificationPageEntityToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class NotificationPageList {
	String? id;
	@JSONField(name: "estate_id")
	String? estateId;
	String? type;
	String? title;
	String? body;
	NotificationPageListData? data;
	bool read = false;
	@JSONField(name: "created_at")
	String? createdAt;

	NotificationPageList();

	factory NotificationPageList.fromJson(Map<String, dynamic> json) => $NotificationPageListFromJson(json);

	Map<String, dynamic> toJson() => $NotificationPageListToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class NotificationPageListData {
	String? id;
	@JSONField(name: "estate_online_form_id")
	String? estateOnlineFormId;
	@JSONField(name: "online_form_type_id")
	String? onlineFormTypeId;
	String? type;

	NotificationPageListData();

	factory NotificationPageListData.fromJson(Map<String, dynamic> json) => $NotificationPageListDataFromJson(json);

	Map<String, dynamic> toJson() => $NotificationPageListDataToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}