You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

113 lines
2.9KB

  1. class Account {
  2. num? id;
  3. String? login;
  4. String? firstName;
  5. String? lastName;
  6. String? midleName;
  7. String? fullName;
  8. String? phone;
  9. String? address;
  10. String? avartar;
  11. num? vaiTroId;
  12. String? tenVaiTro;
  13. num? donViCanhTacId;
  14. String? tenDonVi;
  15. String? email;
  16. String? imageUrl;
  17. bool? activated;
  18. num? countryId;
  19. String? countryName;
  20. num? cityId;
  21. String? cityName;
  22. num? districtId;
  23. String? districtName;
  24. num? wardId;
  25. String? wardName;
  26. List<String>? authorities;
  27. Account(
  28. {this.id,
  29. this.login,
  30. this.firstName,
  31. this.lastName,
  32. this.midleName,
  33. this.fullName,
  34. this.phone,
  35. this.address,
  36. this.avartar,
  37. this.vaiTroId,
  38. this.tenVaiTro,
  39. this.donViCanhTacId,
  40. this.tenDonVi,
  41. this.email,
  42. this.imageUrl,
  43. this.activated,
  44. this.countryId,
  45. this.countryName,
  46. this.cityId,
  47. this.cityName,
  48. this.districtId,
  49. this.districtName,
  50. this.wardId,
  51. this.wardName,
  52. this.authorities});
  53. Account.fromJson(Map<String, dynamic> json) {
  54. id = json['id'];
  55. login = json['login'];
  56. firstName = json['firstName'];
  57. lastName = json['lastName'];
  58. midleName = json['midleName'];
  59. fullName = json['fullName'];
  60. phone = json['phone'];
  61. address = json['address'];
  62. avartar = json['avartar'];
  63. vaiTroId = json['vaiTroId'];
  64. tenVaiTro = json['tenVaiTro'];
  65. donViCanhTacId = json['donViCanhTacId'];
  66. tenDonVi = json['tenDonVi'];
  67. email = json['email'];
  68. imageUrl = json['imageUrl'];
  69. activated = json['activated'];
  70. countryId = json['countryId'];
  71. countryName = json['countryName'];
  72. cityId = json['cityId'];
  73. cityName = json['cityName'];
  74. districtId = json['districtId'];
  75. districtName = json['districtName'];
  76. wardId = json['wardId'];
  77. wardName = json['wardName'];
  78. authorities = json['authorities'].cast<String>();
  79. }
  80. Map<String, dynamic> toJson() {
  81. final Map<String, dynamic> data = new Map<String, dynamic>();
  82. data['id'] = this.id;
  83. data['login'] = this.login;
  84. data['firstName'] = this.firstName;
  85. data['lastName'] = this.lastName;
  86. data['midleName'] = this.midleName;
  87. data['fullName'] = this.fullName;
  88. data['phone'] = this.phone;
  89. data['address'] = this.address;
  90. data['avartar'] = this.avartar;
  91. data['vaiTroId'] = this.vaiTroId;
  92. data['tenVaiTro'] = this.tenVaiTro;
  93. data['donViCanhTacId'] = this.donViCanhTacId;
  94. data['tenDonVi'] = this.tenDonVi;
  95. data['email'] = this.email;
  96. data['imageUrl'] = this.imageUrl;
  97. data['activated'] = this.activated;
  98. data['countryId'] = this.countryId;
  99. data['countryName'] = this.countryName;
  100. data['cityId'] = this.cityId;
  101. data['cityName'] = this.cityName;
  102. data['districtId'] = this.districtId;
  103. data['districtName'] = this.districtName;
  104. data['wardId'] = this.wardId;
  105. data['wardName'] = this.wardName;
  106. data['authorities'] = this.authorities;
  107. return data;
  108. }
  109. }