CartItem.fromMap constructor

CartItem.fromMap(
  1. Map<String, dynamic> json
)

Implementation

factory CartItem.fromMap(Map<String, dynamic> json) => CartItem(
      uuid: json["uuid"],
      productId: json["product_id"],
      productName: json["product_name"],
      unitPrice: json["unit_price"],
      subTotal: json["sub_total"],
      uniqueCheck: json["unique_check"],
      quantity: json["quantity"] == null ? null : json["quantity"],
      productDetails:
          json["product_details"] == null ? null : json["product_details"],
      itemCartIndex:
          json["item_cart_index"] == null ? null : json["item_cart_index"],
    );