home_search_content_users_model.dart 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. /// code : "OK"
  2. /// data : {"total":3,"pageIndex":1,"pageSize":20,"list":[{"userId":"162116510154752","userName":"66纪念","userNo":"10811379","niceNo":null,"userAvatar":"http://user.qn.timichat.net/avatar/162116510154752/1631951244395.png","isLive":0,"userLatitude":30.287458,"userLongitude":120.15358,"userDistance":1.2866731490746794E7,"wealthLevel":49,"charmLevel":1,"starLevel":16,"followStatus":false},{"userId":"170852968562689","userName":"小星芽66","userNo":"10829581","niceNo":null,"userAvatar":"http://user.qn.timichat.com/avatar/default_male.png","isLive":0,"userLatitude":null,"userLongitude":null,"userDistance":null,"wealthLevel":3,"charmLevel":1,"starLevel":2,"followStatus":false},{"userId":"551615425675280","userName":"龙丘志泽66","userNo":"10411382","niceNo":null,"userAvatar":"http://user.qn.timichat.com/avatar/default_male.png","isLive":0,"userLatitude":null,"userLongitude":null,"userDistance":null,"wealthLevel":1,"charmLevel":1,"starLevel":1,"followStatus":false}],"pageCursor":0}
  3. /// msg : ""
  4. /// success : true
  5. class HomeSearchContentUsersModel {
  6. HomeSearchContentUsersModel({
  7. String? code,
  8. Data? data,
  9. String? msg,
  10. bool? success,}){
  11. _code = code;
  12. _data = data;
  13. _msg = msg;
  14. _success = success;
  15. }
  16. HomeSearchContentUsersModel.fromJson(dynamic json) {
  17. _code = json['code'];
  18. _data = json['data'] != null ? Data.fromJson(json['data']) : null;
  19. _msg = json['msg'];
  20. _success = json['success'];
  21. }
  22. String? _code;
  23. Data? _data;
  24. String? _msg;
  25. bool? _success;
  26. String? get code => _code;
  27. Data? get data => _data;
  28. String? get msg => _msg;
  29. bool? get success => _success;
  30. Map<String, dynamic> toJson() {
  31. final map = <String, dynamic>{};
  32. map['code'] = _code;
  33. if (_data != null) {
  34. map['data'] = _data?.toJson();
  35. }
  36. map['msg'] = _msg;
  37. map['success'] = _success;
  38. return map;
  39. }
  40. }
  41. /// total : 3
  42. /// pageIndex : 1
  43. /// pageSize : 20
  44. /// list : [{"userId":"162116510154752","userName":"66纪念","userNo":"10811379","niceNo":null,"userAvatar":"http://user.qn.timichat.net/avatar/162116510154752/1631951244395.png","isLive":0,"userLatitude":30.287458,"userLongitude":120.15358,"userDistance":1.2866731490746794E7,"wealthLevel":49,"charmLevel":1,"starLevel":16,"followStatus":false},{"userId":"170852968562689","userName":"小星芽66","userNo":"10829581","niceNo":null,"userAvatar":"http://user.qn.timichat.com/avatar/default_male.png","isLive":0,"userLatitude":null,"userLongitude":null,"userDistance":null,"wealthLevel":3,"charmLevel":1,"starLevel":2,"followStatus":false},{"userId":"551615425675280","userName":"龙丘志泽66","userNo":"10411382","niceNo":null,"userAvatar":"http://user.qn.timichat.com/avatar/default_male.png","isLive":0,"userLatitude":null,"userLongitude":null,"userDistance":null,"wealthLevel":1,"charmLevel":1,"starLevel":1,"followStatus":false}]
  45. /// pageCursor : 0
  46. class Data {
  47. Data({
  48. int? total,
  49. int? pageIndex,
  50. int? pageSize,
  51. List<SearchContentUser>? list,
  52. int? pageCursor,}){
  53. _total = total;
  54. _pageIndex = pageIndex;
  55. _pageSize = pageSize;
  56. _list = list;
  57. _pageCursor = pageCursor;
  58. }
  59. Data.fromJson(dynamic json) {
  60. _total = json['total'];
  61. _pageIndex = json['pageIndex'];
  62. _pageSize = json['pageSize'];
  63. if (json['list'] != null) {
  64. _list = [];
  65. json['list'].forEach((v) {
  66. _list?.add(SearchContentUser.fromJson(v));
  67. });
  68. }
  69. _pageCursor = json['pageCursor'];
  70. }
  71. int? _total;
  72. int? _pageIndex;
  73. int? _pageSize;
  74. List<SearchContentUser>? _list;
  75. int? _pageCursor;
  76. int? get total => _total;
  77. int? get pageIndex => _pageIndex;
  78. int? get pageSize => _pageSize;
  79. List<SearchContentUser>? get list => _list;
  80. int? get pageCursor => _pageCursor;
  81. Map<String, dynamic> toJson() {
  82. final map = <String, dynamic>{};
  83. map['total'] = _total;
  84. map['pageIndex'] = _pageIndex;
  85. map['pageSize'] = _pageSize;
  86. if (_list != null) {
  87. map['list'] = _list?.map((v) => v.toJson()).toList();
  88. }
  89. map['pageCursor'] = _pageCursor;
  90. return map;
  91. }
  92. }
  93. /// userId : "162116510154752"
  94. /// userName : "66纪念"
  95. /// userNo : "10811379"
  96. /// niceNo : null
  97. /// userAvatar : "http://user.qn.timichat.net/avatar/162116510154752/1631951244395.png"
  98. /// isLive : 0
  99. /// userLatitude : 30.287458
  100. /// userLongitude : 120.15358
  101. /// userDistance : 1.2866731490746794E7
  102. /// wealthLevel : 49
  103. /// charmLevel : 1
  104. /// starLevel : 16
  105. /// followStatus : false
  106. class SearchContentUser {
  107. SearchContentUser({
  108. String? userId,
  109. String? userName,
  110. String? userNo,
  111. dynamic niceNo,
  112. String? userAvatar,
  113. int? isLive,
  114. double? userLatitude,
  115. double? userLongitude,
  116. double? userDistance,
  117. int? wealthLevel,
  118. int? charmLevel,
  119. int? starLevel,
  120. bool? followStatus,}){
  121. _userId = userId;
  122. _userName = userName;
  123. _userNo = userNo;
  124. _niceNo = niceNo;
  125. _userAvatar = userAvatar;
  126. _isLive = isLive;
  127. _userLatitude = userLatitude;
  128. _userLongitude = userLongitude;
  129. _userDistance = userDistance;
  130. _wealthLevel = wealthLevel;
  131. _charmLevel = charmLevel;
  132. _starLevel = starLevel;
  133. followStatus = followStatus;
  134. }
  135. SearchContentUser.fromJson(dynamic json) {
  136. _userId = json['userId'];
  137. _userName = json['userName'];
  138. _userNo = json['userNo'];
  139. _niceNo = json['niceNo'];
  140. _userAvatar = json['userAvatar'];
  141. _isLive = json['isLive'];
  142. _userLatitude = json['userLatitude'];
  143. _userLongitude = json['userLongitude'];
  144. _userDistance = json['userDistance'];
  145. _wealthLevel = json['wealthLevel'];
  146. _charmLevel = json['charmLevel'];
  147. _starLevel = json['starLevel'];
  148. followStatus = json['followStatus'];
  149. }
  150. String? _userId;
  151. String? _userName;
  152. String? _userNo;
  153. dynamic _niceNo;
  154. String? _userAvatar;
  155. int? _isLive;
  156. double? _userLatitude;
  157. double? _userLongitude;
  158. double? _userDistance;
  159. int? _wealthLevel;
  160. int? _charmLevel;
  161. int? _starLevel;
  162. bool? followStatus;
  163. String? get userId => _userId;
  164. String? get userName => _userName;
  165. String? get userNo => _userNo;
  166. dynamic get niceNo => _niceNo;
  167. String? get userAvatar => _userAvatar;
  168. int? get isLive => _isLive;
  169. double? get userLatitude => _userLatitude;
  170. double? get userLongitude => _userLongitude;
  171. double? get userDistance => _userDistance;
  172. int? get wealthLevel => _wealthLevel;
  173. int? get charmLevel => _charmLevel;
  174. int? get starLevel => _starLevel;
  175. Map<String, dynamic> toJson() {
  176. final map = <String, dynamic>{};
  177. map['userId'] = _userId;
  178. map['userName'] = _userName;
  179. map['userNo'] = _userNo;
  180. map['niceNo'] = _niceNo;
  181. map['userAvatar'] = _userAvatar;
  182. map['isLive'] = _isLive;
  183. map['userLatitude'] = _userLatitude;
  184. map['userLongitude'] = _userLongitude;
  185. map['userDistance'] = _userDistance;
  186. map['wealthLevel'] = _wealthLevel;
  187. map['charmLevel'] = _charmLevel;
  188. map['starLevel'] = _starLevel;
  189. map['followStatus'] = followStatus;
  190. return map;
  191. }
  192. }