toJson method

Map<String, dynamic> toJson()

Implementation

core.Map<core.String, core.dynamic> toJson() => {
      if (cartId != null) 'cartId': cartId!,
      if (listId != null) 'listId': listId!,
      if (pageCategories != null)
        'pageCategories':
            pageCategories!.map((value) => value.toJson()).toList(),
      if (productDetails != null)
        'productDetails':
            productDetails!.map((value) => value.toJson()).toList(),
      if (purchaseTransaction != null)
        'purchaseTransaction': purchaseTransaction!.toJson(),
      if (searchQuery != null) 'searchQuery': searchQuery!,
    };