toJson method Null safety

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() => {
      "maxQty": maxQty,
      "imageID": imageId,
      "freeBOGO": freeBogo,
      "discountBOGOID": discountBogoid,
      "addedForDiscountBOGO": addedForDiscountBogo,
      "stock": stock,
      "qty": qty,
      "minDeliveryPeriod": minDeliveryPeriod,
      "maxDeliveryPeriod": maxDeliveryPeriod,
      "periodName": periodName,
      "deliveryNote": deliveryNote,
      "preOrder": preOrder,
      "availabilityDate": availabilityDate,
      "id": id,
      "productID": productId,
      "productCode": productCode,
      "imageUrl": imageUrl,
      "imageThumbUrl": imageThumbUrl,
      "title": title,
      "seoTitle": seoTitle,
      "isOutOfStock": isOutOfStock,
      "price": price,
      "finalPrice": finalPrice,
      "hasDiscount": hasDiscount,
      "discountValue": discountValue,
      "discountType": discountType,
      "promoText": promoText,
      "bogoPromoText": bogoPromoText,
      "croppedImageURL": croppedImageUrl,
      "enableCropping": enableCropping,
      "size": size,
      "sizeID": sizeId,
      "colorHexaCode": colorHexaCode,
      "color": color,
      "colorID": colorId,
    };