diff --git a/src/screens/ShoppingCart/components/Product.js b/src/screens/ShoppingCart/components/Product.js index 20e9632..494e4e1 100644 --- a/src/screens/ShoppingCart/components/Product.js +++ b/src/screens/ShoppingCart/components/Product.js @@ -51,9 +51,7 @@ function Product({ product, grades, pushToCart, loading, mobile }) { ]} /> - {product.product.book.name} + {product?.product?.book?.name || " "} - {"پایه" + " " + grades[product.product.book.gradeId]} + {"پایه" + " " + grades[product?.product?.book?.gradeId] || " "} - {product.productType === 2 ? "نسخه فیزیکی" : "نسخه دیجیتال"} + {product?.productType || 1 === 2 ? "نسخه فیزیکی" : "نسخه دیجیتال"} - {separate(product?.product?.price)} + {separate(product?.product?.price) || ' '} - + {" " + "تومان"} - - {separate(product.product.price * product.count)} + + {separate(product?.product?.price * product?.count) || ' '} diff --git a/src/screens/ShoppingCart/index.js b/src/screens/ShoppingCart/index.js index 258ec9c..439f7a7 100644 --- a/src/screens/ShoppingCart/index.js +++ b/src/screens/ShoppingCart/index.js @@ -157,18 +157,18 @@ function ShoppingCart({ >