toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final json = <String, dynamic>{};
  json[r'id'] = this.id;
  json[r'project'] = this.project;
  json[r'name'] = this.name;
  if (this.nameDe != null) {
    json[r'name_de'] = this.nameDe;
  } else {
    json[r'name_de'] = null;
  }
  if (this.nameEn != null) {
    json[r'name_en'] = this.nameEn;
  } else {
    json[r'name_en'] = null;
  }
  if (this.nameFr != null) {
    json[r'name_fr'] = this.nameFr;
  } else {
    json[r'name_fr'] = null;
  }
  if (this.nameIt != null) {
    json[r'name_it'] = this.nameIt;
  } else {
    json[r'name_it'] = null;
  }
  if (this.slug != null) {
    json[r'slug'] = this.slug;
  } else {
    json[r'slug'] = null;
  }
  if (this.image != null) {
    json[r'image'] = this.image;
  } else {
    json[r'image'] = null;
  }
  json[r'image_thumb'] = this.imageThumb;
  json[r'image_preview'] = this.imagePreview;
  if (this.preview != null) {
    json[r'preview'] = this.preview;
  } else {
    json[r'preview'] = null;
  }
  if (this.status != null) {
    json[r'status'] = this.status;
  } else {
    json[r'status'] = null;
  }
  json[r'description'] = this.description;
  if (this.descriptionDe != null) {
    json[r'description_de'] = this.descriptionDe;
  } else {
    json[r'description_de'] = null;
  }
  if (this.descriptionEn != null) {
    json[r'description_en'] = this.descriptionEn;
  } else {
    json[r'description_en'] = null;
  }
  if (this.descriptionFr != null) {
    json[r'description_fr'] = this.descriptionFr;
  } else {
    json[r'description_fr'] = null;
  }
  if (this.descriptionIt != null) {
    json[r'description_it'] = this.descriptionIt;
  } else {
    json[r'description_it'] = null;
  }
  if (this.number != null) {
    json[r'number'] = this.number;
  } else {
    json[r'number'] = null;
  }
  json[r'site_url'] = this.siteUrl;
  if (this.siteUrlDe != null) {
    json[r'site_url_de'] = this.siteUrlDe;
  } else {
    json[r'site_url_de'] = null;
  }
  if (this.siteUrlEn != null) {
    json[r'site_url_en'] = this.siteUrlEn;
  } else {
    json[r'site_url_en'] = null;
  }
  if (this.siteUrlFr != null) {
    json[r'site_url_fr'] = this.siteUrlFr;
  } else {
    json[r'site_url_fr'] = null;
  }
  if (this.siteUrlIt != null) {
    json[r'site_url_it'] = this.siteUrlIt;
  } else {
    json[r'site_url_it'] = null;
  }
  if (this.sku != null) {
    json[r'sku'] = this.sku;
  } else {
    json[r'sku'] = null;
  }
  if (this.price != null) {
    json[r'price'] = this.price;
  } else {
    json[r'price'] = null;
  }
  json[r'price_currency'] = this.priceCurrency;
  if (this.scaleable != null) {
    json[r'scaleable'] = this.scaleable;
  } else {
    json[r'scaleable'] = null;
  }
  if (this.glb != null) {
    json[r'glb'] = this.glb;
  } else {
    json[r'glb'] = null;
  }
  if (this.usdz != null) {
    json[r'usdz'] = this.usdz;
  } else {
    json[r'usdz'] = null;
  }
  if (this.model != null) {
    json[r'model'] = this.model;
  } else {
    json[r'model'] = null;
  }
  json[r'arbutton_config'] = this.arbuttonConfig;
  json[r'created'] = this.created.toUtc().toIso8601String();
  json[r'modified'] = this.modified.toUtc().toIso8601String();
  if (this.verticalPlacement != null) {
    json[r'vertical_placement'] = this.verticalPlacement;
  } else {
    json[r'vertical_placement'] = null;
  }
  return json;
}