import 'package:domain/generated/json/base/json_field.dart'; import 'package:domain/generated/json/facility_page_entity.g.dart'; import 'dart:convert'; export 'package:domain/generated/json/facility_page_entity.g.dart'; @JsonSerializable() class FacilityPageEntity { int count = 0; int page = 0; int limit = 0; @JSONField(name: "count_page") int countPage = 0; @JSONField(name: "total_deposit") String? totalDeposit; List? list = []; FacilityPageEntity(); factory FacilityPageEntity.fromJson(Map json) => $FacilityPageEntityFromJson(json); Map toJson() => $FacilityPageEntityToJson(this); @override String toString() { return jsonEncode(this); } } @JsonSerializable() class FacilityDetail { FacilityPageListBooking? booking; FacilityPageListFacility? facility; @JSONField(name: "time_period") FacilityPageListTimePeriod? timePeriod; FacilityPageListAccount? account; FacilityDetail(); factory FacilityDetail.fromJson(Map json) => $FacilityDetailFromJson(json); Map toJson() => $FacilityDetailToJson(this); @override String toString() { return jsonEncode(this); } } @JsonSerializable() class FacilityPageListBooking { String? id; String? date; String? start; String? end; @JSONField(name: "deposit_paid") String? depositPaid; @JSONField(name: "deposit_refund") String? depositRefund; @JSONField(name: "deposit_refund_at") String? depositRefundAt; FacilityPageListBooking(); factory FacilityPageListBooking.fromJson(Map json) => $FacilityPageListBookingFromJson(json); Map toJson() => $FacilityPageListBookingToJson(this); @override String toString() { return jsonEncode(this); } } @JsonSerializable() class FacilityPageListFacility { String? id; String? name; FacilityPageListFacilityType? type; FacilityPageListFacility(); factory FacilityPageListFacility.fromJson(Map json) => $FacilityPageListFacilityFromJson(json); Map toJson() => $FacilityPageListFacilityToJson(this); @override String toString() { return jsonEncode(this); } } @JsonSerializable() class FacilityPageListFacilityType { String? id; String? name; FacilityPageListFacilityType(); factory FacilityPageListFacilityType.fromJson(Map json) => $FacilityPageListFacilityTypeFromJson(json); Map toJson() => $FacilityPageListFacilityTypeToJson(this); @override String toString() { return jsonEncode(this); } } @JsonSerializable() class FacilityPageListTimePeriod { String? price; String? deposit; FacilityPageListTimePeriod(); factory FacilityPageListTimePeriod.fromJson(Map json) => $FacilityPageListTimePeriodFromJson(json); Map toJson() => $FacilityPageListTimePeriodToJson(this); @override String toString() { return jsonEncode(this); } } @JsonSerializable() class FacilityPageListAccount { String? id; String? name; FacilityPageListAccount(); factory FacilityPageListAccount.fromJson(Map json) => $FacilityPageListAccountFromJson(json); Map toJson() => $FacilityPageListAccountToJson(this); @override String toString() { return jsonEncode(this); } }