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.

64 lines
1.7KB

  1. class Packing {
  2. int id;
  3. int cropId;
  4. int activityId;
  5. int harvestId;
  6. String executeDate;
  7. String description;
  8. String executeBy;
  9. String media;
  10. List<String> mediaDel;
  11. num quantityLv1;
  12. num quantityLv2;
  13. num quantityLv3;
  14. num removedQuantity;
  15. Packing(
  16. {this.id,
  17. this.cropId,
  18. this.activityId,
  19. this.harvestId,
  20. this.executeDate,
  21. this.description,
  22. this.executeBy,
  23. this.media,
  24. this.mediaDel,
  25. this.quantityLv1,
  26. this.quantityLv2,
  27. this.quantityLv3,
  28. this.removedQuantity});
  29. Packing.fromJson(Map<String, dynamic> json) {
  30. id = json['id'];
  31. cropId = json['cropId'];
  32. activityId = json['activityId'];
  33. harvestId = json['harvestId'];
  34. executeDate = json['executeDate'];
  35. description = json['description'];
  36. executeBy = json['executeBy'];
  37. media = json['media'];
  38. quantityLv1 = json['quantityLv1'];
  39. quantityLv2 = json['quantityLv2'];
  40. quantityLv3 = json['quantityLv3'];
  41. removedQuantity = json['removedQuantity'];
  42. }
  43. Map<String, dynamic> toJson() {
  44. final Map<String, dynamic> data = new Map<String, dynamic>();
  45. data['id'] = this.id;
  46. data['cropId'] = this.cropId;
  47. data['activityId'] = this.activityId;
  48. data['harvestId'] = this.harvestId;
  49. data['executeDate'] = this.executeDate;
  50. data['description'] = this.description;
  51. data['executeBy'] = this.executeBy;
  52. data['media'] = this.media;
  53. data['media_del'] = this.mediaDel;
  54. data['quantityLv1'] = this.quantityLv1;
  55. data['quantityLv2'] = this.quantityLv2;
  56. data['quantityLv3'] = this.quantityLv3;
  57. data['removedQuantity'] = this.removedQuantity;
  58. return data;
  59. }
  60. }