country_detail_entity.dart 832 B

1234567891011121314151617181920212223242526272829
  1. import 'package:hengyi/generated/json/base/json_field.dart';
  2. import 'package:hengyi/generated/json/country_detail_entity.g.dart';
  3. import 'dart:convert';
  4. @JsonSerializable()
  5. class CountryDetailEntity {
  6. late int id;
  7. @JSONField(name: "country_name")
  8. late String countryName;
  9. @JSONField(name: "country_img_url")
  10. late String countryImgUrl;
  11. @JSONField(name: "country_visit_visa_url")
  12. late String countryVisitVisaUrl;
  13. @JSONField(name: "country_business_visa_url")
  14. late String countryBusinessVisaUrl;
  15. @JSONField(name: "country_content")
  16. late String countryContent;
  17. CountryDetailEntity();
  18. factory CountryDetailEntity.fromJson(Map<String, dynamic> json) => $CountryDetailEntityFromJson(json);
  19. Map<String, dynamic> toJson() => $CountryDetailEntityToJson(this);
  20. @override
  21. String toString() {
  22. return jsonEncode(this);
  23. }
  24. }