toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final Map<String, dynamic> _data = <String, dynamic>{};
  _data["id"] = id;
  _data["reference"] = reference;
  _data["pictureUrl"] = pictureUrl;
  _data["categoryId"] = categoryId;
  _data["purchaseType"] = purchaseType;
  _data["warrantyDuration"] = warrantyDuration;
  _data["planDuration"] = planDuration;
  _data["workDuration"] = workDuration;
  _data["numberOfItems"] = numberOfItems;
  _data["label"] = label;
  _data["languageCode"] = languageCode;
  _data["subtitleLabel"] = subtitleLabel;
  _data["description"] = description;
  if (jsonDescription != null) {
    _data["jsonDescription"] = jsonDescription?.toJson();
  }
  _data["countryCode"] = countryCode;
  _data["price"] = price;
  _data["priceFormat"] = priceFormat;
  _data["priceMonthly"] = priceMonthly;
  _data["priceMonthlyFormat"] = priceMonthlyFormat;
  _data["priceYearly"] = priceYearly;
  _data["priceYearlyFormat"] = priceYearlyFormat;
  _data["priceByAdIfMonthlyFormat"] = priceByAdIfMonthlyFormat;
  _data["priceByAdIfYearlyFormat"] = priceByAdIfYearlyFormat;
  _data["pricePercentageDiscountIfYearly"] = pricePercentageDiscountIfYearly;
  _data["currency"] = currency;
  _data["currentDiscountActive"] = currentDiscountActive;
  _data["currentDiscountInPercent"] = currentDiscountInPercent;
  _data["discountBetweenYearAndMonth"] = discountBetweenYearAndMonth;
  _data["convertedPricing"] = convertedPricing;
  return _data;
}