class GoodsShareTempDataModel {
  String shareContent;
  List<GoodsShareTempAddModel> shareTemplate;
  String shareTip;
  String appUrl;
  String miniAppUrl;

  GoodsShareTempDataModel(
      {this.shareContent,
      this.shareTemplate,
      this.shareTip,
      this.appUrl,
      this.miniAppUrl});

  GoodsShareTempDataModel.fromJson(Map<String, dynamic> json) {
    shareContent = json['share_content'];
    if (json['share_template'] != null) {
      shareTemplate = new List<GoodsShareTempAddModel>();
      json['share_template'].forEach((v) {
        shareTemplate.add(new GoodsShareTempAddModel.fromJson(v));
      });
    }
    shareTip = json['share_tip'];
    appUrl = json['app_url'];
    miniAppUrl = json['mini_app_url'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['share_content'] = this.shareContent;
    if (this.shareTemplate != null) {
      data['share_template'] =
          this.shareTemplate.map((v) => v.toJson()).toList();
    }
    data['share_tip'] = this.shareTip;
    data['app_url'] = this.appUrl;
    data['mini_app_url'] = this.miniAppUrl;
    return data;
  }
}

class GoodsShareTempAddModel {
  String name;
  String val;
  String temp;

  GoodsShareTempAddModel({this.name, this.val, this.temp});

  GoodsShareTempAddModel.fromJson(Map<String, dynamic> json) {
    name = json['name'];
    val = json['val'];
    temp = json['temp'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['name'] = this.name;
    data['val'] = this.val;
    data['temp'] = this.temp;
    return data;
  }
}
