基础组件库
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.
 
 
 
 
 

58 lines
1.6 KiB

  1. import 'package:zhiying_base_widget/widgets/share/models/share_icon_model.dart';
  2. class ShareAlertModel {
  3. List<ShareIconModel> icons;
  4. String selectIcon;
  5. String selectImg;
  6. String selectTextImg;
  7. String successImg;
  8. String sucText;
  9. String sucTips;
  10. String selectText1;
  11. String selectText2;
  12. ShareAlertModel(
  13. {this.icons,
  14. this.selectIcon,
  15. this.selectImg,
  16. this.selectTextImg,
  17. this.successImg,
  18. this.sucText,
  19. this.sucTips,
  20. this.selectText1,
  21. this.selectText2});
  22. ShareAlertModel.fromJson(Map<String, dynamic> json) {
  23. if (json['list'] != null) {
  24. icons = new List<ShareIconModel>();
  25. json['list'].forEach((v) {
  26. icons.add(new ShareIconModel.fromJson(v));
  27. });
  28. }
  29. selectIcon = json['select_icon'];
  30. selectImg = json['select_img'];
  31. selectTextImg = json['select_text_img'];
  32. successImg = json['success_img'];
  33. sucText = json['suc_text'];
  34. sucTips = json['suc_tips'];
  35. selectText1 = json['select_text1'];
  36. selectText2 = json['select_text2'];
  37. }
  38. Map<String, dynamic> toJson() {
  39. final Map<String, dynamic> data = new Map<String, dynamic>();
  40. if (this.icons != null) {
  41. data['list'] = this.icons.map((v) => v.toJson()).toList();
  42. }
  43. data['select_icon'] = this.selectIcon;
  44. data['select_img'] = this.selectImg;
  45. data['select_text_img'] = this.selectTextImg;
  46. data['success_img'] = this.successImg;
  47. data['suc_text'] = this.sucText;
  48. data['suc_tips'] = this.sucTips;
  49. data['select_text1'] = this.selectText1;
  50. data['select_text2'] = this.selectText2;
  51. return data;
  52. }
  53. }