From 7aed7b068d63204ac50dd45ca8d26b8372714348 Mon Sep 17 00:00:00 2001 From: Reza_ashrafi Date: Sat, 9 Apr 2022 12:52:06 +0430 Subject: [PATCH] reza fixed strings on Cart --- .../ShoppingCart/components/Product.js | 43 ++++++++++++------- src/screens/ShoppingCart/index.js | 6 +-- 2 files changed, 31 insertions(+), 18 deletions(-) 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({ >