order_model.dart 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342
  1. class OrderModel {
  2. List<OrerDetailModel> records;
  3. int total;
  4. int size;
  5. int current;
  6. bool searchCount;
  7. int pages;
  8. OrderModel(
  9. {this.records,
  10. this.total,
  11. this.size,
  12. this.current,
  13. this.searchCount,
  14. this.pages});
  15. OrderModel.fromJson(Map<String, dynamic> json) {
  16. if (json['records'] != null) {
  17. records = new List<OrerDetailModel>();
  18. json['records'].forEach((v) {
  19. records.add(new OrerDetailModel.fromJson(v));
  20. });
  21. }
  22. total = json['total'];
  23. size = json['size'];
  24. current = json['current'];
  25. searchCount = json['searchCount'];
  26. pages = json['pages'];
  27. }
  28. Map<String, dynamic> toJson() {
  29. final Map<String, dynamic> data = new Map<String, dynamic>();
  30. if (this.records != null) {
  31. data['records'] = this.records.map((v) => v.toJson()).toList();
  32. }
  33. data['total'] = this.total;
  34. data['size'] = this.size;
  35. data['current'] = this.current;
  36. data['searchCount'] = this.searchCount;
  37. data['pages'] = this.pages;
  38. return data;
  39. }
  40. }
  41. class OrerDetailModel {
  42. int id;
  43. int createTime;
  44. String createBy;
  45. int updateTime;
  46. String updateBy;
  47. int dataId;
  48. int dataTable;
  49. int userId;
  50. int isInvoice;
  51. dynamic redEnvelopeDeduction;
  52. int redEnvelopeId;
  53. dynamic couponDeduction;
  54. int couponId;
  55. dynamic totalCost;
  56. dynamic payCost;
  57. String orderNo;
  58. int payType;
  59. int orderStatus;
  60. String orderSerialNumber;
  61. LiftCaseEntity liftCaseEntity;
  62. LiftCaseAppealEntity liftCaseAppealEntity;
  63. OrerDetailModel(
  64. {this.id,
  65. this.createTime,
  66. this.createBy,
  67. this.updateTime,
  68. this.updateBy,
  69. this.dataId,
  70. this.dataTable,
  71. this.userId,
  72. this.isInvoice,
  73. this.redEnvelopeDeduction,
  74. this.redEnvelopeId,
  75. this.couponDeduction,
  76. this.couponId,
  77. this.totalCost,
  78. this.payCost,
  79. this.orderNo,
  80. this.payType,
  81. this.orderStatus,
  82. this.orderSerialNumber,
  83. this.liftCaseEntity,
  84. this.liftCaseAppealEntity});
  85. OrerDetailModel.fromJson(Map<String, dynamic> json) {
  86. id = json['id'];
  87. createTime = json['createTime'];
  88. createBy = json['createBy'];
  89. updateTime = json['updateTime'];
  90. updateBy = json['updateBy'];
  91. dataId = json['dataId'];
  92. dataTable = json['dataTable'];
  93. userId = json['userId'];
  94. isInvoice = json['isInvoice'];
  95. redEnvelopeDeduction = json['redEnvelopeDeduction'];
  96. redEnvelopeId = json['redEnvelopeId'];
  97. couponDeduction = json['couponDeduction'];
  98. couponId = json['couponId'];
  99. totalCost = json['totalCost'];
  100. payCost = json['payCost'];
  101. orderNo = json['orderNo'];
  102. payType = json['payType'];
  103. orderStatus = json['orderStatus'];
  104. orderSerialNumber = json['orderSerialNumber'];
  105. liftCaseEntity = json['liftCaseEntity'] != null
  106. ? new LiftCaseEntity.fromJson(json['liftCaseEntity'])
  107. : null;
  108. liftCaseAppealEntity = json['liftCaseAppealEntity'] != null
  109. ? new LiftCaseAppealEntity.fromJson(json['liftCaseAppealEntity'])
  110. : null;
  111. }
  112. Map<String, dynamic> toJson() {
  113. final Map<String, dynamic> data = new Map<String, dynamic>();
  114. data['id'] = this.id;
  115. data['createTime'] = this.createTime;
  116. data['createBy'] = this.createBy;
  117. data['updateTime'] = this.updateTime;
  118. data['updateBy'] = this.updateBy;
  119. data['dataId'] = this.dataId;
  120. data['dataTable'] = this.dataTable;
  121. data['userId'] = this.userId;
  122. data['isInvoice'] = this.isInvoice;
  123. data['redEnvelopeDeduction'] = this.redEnvelopeDeduction;
  124. data['redEnvelopeId'] = this.redEnvelopeId;
  125. data['couponDeduction'] = this.couponDeduction;
  126. data['couponId'] = this.couponId;
  127. data['totalCost'] = this.totalCost;
  128. data['payCost'] = this.payCost;
  129. data['orderNo'] = this.orderNo;
  130. data['payType'] = this.payType;
  131. data['orderStatus'] = this.orderStatus;
  132. data['orderSerialNumber'] = this.orderSerialNumber;
  133. if (this.liftCaseEntity != null) {
  134. data['liftCaseEntity'] = this.liftCaseEntity.toJson();
  135. }
  136. if (this.liftCaseAppealEntity != null) {
  137. data['liftCaseAppealEntity'] = this.liftCaseAppealEntity.toJson();
  138. }
  139. return data;
  140. }
  141. }
  142. class LiftCaseEntity {
  143. int id;
  144. int createTime;
  145. String createBy;
  146. int updateTime;
  147. String updateBy;
  148. String expression;
  149. String usedMethods;
  150. String imgs;
  151. int brandId;
  152. String sessionId;
  153. String address;
  154. String chargerId;
  155. dynamic travelCost;
  156. dynamic serviceCost;
  157. dynamic totalCost;
  158. int arrivedTime;
  159. int statuz;
  160. int acceptStatus;
  161. int arrivedFlag;
  162. String arrivedAddress;
  163. int dataTable;
  164. String createUserId;
  165. int customerServiceId;
  166. String name;
  167. String avatarUrl;
  168. String brandName;
  169. LiftCaseEntity(
  170. {this.id,
  171. this.createTime,
  172. this.createBy,
  173. this.updateTime,
  174. this.updateBy,
  175. this.expression,
  176. this.usedMethods,
  177. this.imgs,
  178. this.brandId,
  179. this.sessionId,
  180. this.address,
  181. this.chargerId,
  182. this.travelCost,
  183. this.serviceCost,
  184. this.totalCost,
  185. this.arrivedTime,
  186. this.statuz,
  187. this.acceptStatus,
  188. this.arrivedFlag,
  189. this.arrivedAddress,
  190. this.dataTable,
  191. this.createUserId,
  192. this.customerServiceId,
  193. this.name,
  194. this.avatarUrl,
  195. this.brandName});
  196. LiftCaseEntity.fromJson(Map<String, dynamic> json) {
  197. id = json['id'];
  198. createTime = json['createTime'];
  199. createBy = json['createBy'];
  200. updateTime = json['updateTime'];
  201. updateBy = json['updateBy'];
  202. expression = json['expression'];
  203. usedMethods = json['usedMethods'];
  204. imgs = json['imgs'];
  205. brandId = json['brandId'];
  206. sessionId = json['sessionId'];
  207. address = json['address'];
  208. chargerId = json['chargerId'];
  209. travelCost = json['travelCost'];
  210. serviceCost = json['serviceCost'];
  211. totalCost = json['totalCost'];
  212. arrivedTime = json['arrivedTime'];
  213. statuz = json['statuz'];
  214. acceptStatus = json['acceptStatus'];
  215. arrivedFlag = json['arrivedFlag'];
  216. arrivedAddress = json['arrivedAddress'];
  217. dataTable = json['dataTable'];
  218. createUserId = json['createUserId'];
  219. customerServiceId = json['customerServiceId'];
  220. name = json['name'];
  221. avatarUrl = json['avatarUrl'];
  222. brandName = json['brandName'];
  223. }
  224. Map<String, dynamic> toJson() {
  225. final Map<String, dynamic> data = new Map<String, dynamic>();
  226. data['id'] = this.id;
  227. data['createTime'] = this.createTime;
  228. data['createBy'] = this.createBy;
  229. data['updateTime'] = this.updateTime;
  230. data['updateBy'] = this.updateBy;
  231. data['expression'] = this.expression;
  232. data['usedMethods'] = this.usedMethods;
  233. data['imgs'] = this.imgs;
  234. data['brandId'] = this.brandId;
  235. data['sessionId'] = this.sessionId;
  236. data['address'] = this.address;
  237. data['chargerId'] = this.chargerId;
  238. data['travelCost'] = this.travelCost;
  239. data['serviceCost'] = this.serviceCost;
  240. data['totalCost'] = this.totalCost;
  241. data['arrivedTime'] = this.arrivedTime;
  242. data['statuz'] = this.statuz;
  243. data['acceptStatus'] = this.acceptStatus;
  244. data['arrivedFlag'] = this.arrivedFlag;
  245. data['arrivedAddress'] = this.arrivedAddress;
  246. data['dataTable'] = this.dataTable;
  247. data['createUserId'] = this.createUserId;
  248. data['customerServiceId'] = this.customerServiceId;
  249. data['name'] = this.name;
  250. data['avatarUrl'] = this.avatarUrl;
  251. data['brandName'] = this.brandName;
  252. return data;
  253. }
  254. }
  255. class LiftCaseAppealEntity {
  256. String appealerId;
  257. String cancelSeason;
  258. int caseId;
  259. String content;
  260. String createBy;
  261. int createTime;
  262. int dataId;
  263. String expertName;
  264. String expression;
  265. int id;
  266. String imgs;
  267. String sessionid;
  268. int statuz;
  269. String updateBy;
  270. int updateTime;
  271. String userName;
  272. LiftCaseAppealEntity(
  273. {this.appealerId,
  274. this.cancelSeason,
  275. this.caseId,
  276. this.content,
  277. this.createBy,
  278. this.createTime,
  279. this.dataId,
  280. this.expertName,
  281. this.expression,
  282. this.id,
  283. this.imgs,
  284. this.sessionid,
  285. this.statuz,
  286. this.updateBy,
  287. this.updateTime,
  288. this.userName});
  289. LiftCaseAppealEntity.fromJson(Map<String, dynamic> json) {
  290. appealerId = json['appealerId'];
  291. cancelSeason = json['cancelSeason'];
  292. caseId = json['caseId'];
  293. content = json['content'];
  294. createBy = json['createBy'];
  295. createTime = json['createTime'];
  296. dataId = json['dataId'];
  297. expertName = json['expertName'];
  298. expression = json['expression'];
  299. id = json['id'];
  300. imgs = json['imgs'];
  301. sessionid = json['sessionid'];
  302. statuz = json['statuz'];
  303. updateBy = json['updateBy'];
  304. updateTime = json['updateTime'];
  305. userName = json['userName'];
  306. }
  307. Map<String, dynamic> toJson() {
  308. final Map<String, dynamic> data = new Map<String, dynamic>();
  309. data['appealerId'] = this.appealerId;
  310. data['cancelSeason'] = this.cancelSeason;
  311. data['caseId'] = this.caseId;
  312. data['content'] = this.content;
  313. data['createBy'] = this.createBy;
  314. data['createTime'] = this.createTime;
  315. data['dataId'] = this.dataId;
  316. data['expertName'] = this.expertName;
  317. data['expression'] = this.expression;
  318. data['id'] = this.id;
  319. data['imgs'] = this.imgs;
  320. data['sessionid'] = this.sessionid;
  321. data['statuz'] = this.statuz;
  322. data['updateBy'] = this.updateBy;
  323. data['updateTime'] = this.updateTime;
  324. data['userName'] = this.userName;
  325. return data;
  326. }
  327. }