property_news_detail_entity.dart 814 B

1234567891011121314151617181920212223242526272829
  1. import 'package:domain/generated/json/base/json_field.dart';
  2. import 'package:domain/generated/json/property_news_detail_entity.g.dart';
  3. import 'dart:convert';
  4. export 'package:domain/generated/json/property_news_detail_entity.g.dart';
  5. @JsonSerializable()
  6. class PropertyNewsDetailEntity {
  7. int? id;
  8. String? title;
  9. @JSONField(name: "cover_image")
  10. String? coverImage;
  11. String? content;
  12. @JSONField(name: "created_at")
  13. String? createdAt;
  14. @JSONField(name: "likes_count")
  15. int? likesCount;
  16. bool? liked;
  17. PropertyNewsDetailEntity();
  18. factory PropertyNewsDetailEntity.fromJson(Map<String, dynamic> json) => $PropertyNewsDetailEntityFromJson(json);
  19. Map<String, dynamic> toJson() => $PropertyNewsDetailEntityToJson(this);
  20. @override
  21. String toString() {
  22. return jsonEncode(this);
  23. }
  24. }