From c35bf617dbc931d4ef89c84fdd3b8726cf43863e Mon Sep 17 00:00:00 2001 From: Reza_ashrafi Date: Sat, 12 Feb 2022 00:36:24 +0330 Subject: [PATCH] reza added something --- src/components/Button/index.js | 2 +- src/components/CourseChapter/index.js | 4 ++-- src/components/ProductStatusCard/index.js | 4 ++-- src/views/ShoppingCart/Code/index.js | 6 +++--- src/views/ShoppingCart/Product/index.js | 22 ++++++++++++++++------ src/views/ShoppingCart/index.js | 11 +++++++---- src/views/Video/index.js | 4 ++-- 7 files changed, 33 insertions(+), 20 deletions(-) diff --git a/src/components/Button/index.js b/src/components/Button/index.js index 5c9d36a..b38944c 100644 --- a/src/components/Button/index.js +++ b/src/components/Button/index.js @@ -34,7 +34,7 @@ export default function Button({ }} onClick={() => onClick()} > - {loading ? : title} + {loading ? : title} ); } diff --git a/src/components/CourseChapter/index.js b/src/components/CourseChapter/index.js index a1d20f9..e70bf5e 100644 --- a/src/components/CourseChapter/index.js +++ b/src/components/CourseChapter/index.js @@ -47,7 +47,7 @@ const CourseChapter = ({
-
+

{seasons?.length > 0 && playList?.length > 0 && @@ -92,7 +92,7 @@ const CourseChapter = ({ className={`w-full bg-white flex flex-col transition duration-400 hover:scale-95 shadow-md transform rounded-md ${ selectedVideo?.id === video?.id - ? "bg-blueC0 text-white" + ? "bg-green-600 text-white" : "text-blueC0" } `} diff --git a/src/components/ProductStatusCard/index.js b/src/components/ProductStatusCard/index.js index 3fb29f5..4c513be 100644 --- a/src/components/ProductStatusCard/index.js +++ b/src/components/ProductStatusCard/index.js @@ -53,9 +53,9 @@ const ProductStatusCard = ({

))}
-

+

{separate(price)} - تومان + تومان

با خرید این کالا diff --git a/src/views/ShoppingCart/Code/index.js b/src/views/ShoppingCart/Code/index.js index 5f2f487..023d236 100644 --- a/src/views/ShoppingCart/Code/index.js +++ b/src/views/ShoppingCart/Code/index.js @@ -10,13 +10,13 @@ function Code({ codeId, setCodeId, userId, factorId }) { } return ( -

+ - +
); } diff --git a/src/views/ShoppingCart/Product/index.js b/src/views/ShoppingCart/Product/index.js index eedf5b2..3ea3028 100644 --- a/src/views/ShoppingCart/Product/index.js +++ b/src/views/ShoppingCart/Product/index.js @@ -1,4 +1,4 @@ -import React, {useState} from "react"; +import React, { useState } from "react"; import { connect } from "react-redux"; import { userProduct } from "../../../redux/actions"; import separate from "../../../utils/separate"; @@ -10,6 +10,7 @@ import exitIcon from "../../../assets/icons/exit.svg"; import deleteIcon from "../../../assets/icons/delete.svg"; function Product({ product, grades, pushToCart, isMobile, loading }) { + let id; return isMobile ? (
@@ -89,7 +90,12 @@ function Product({ product, grades, pushToCart, isMobile, loading }) {
) : ( -
+
{ + id = product?.id; + }} + >
- - {loading ? : product.count} + + {loading ? ( + + ) : ( + product.count + )} { <> @@ -154,7 +164,7 @@ function Product({ product, grades, pushToCart, isMobile, loading }) { /> ) : (
); }; @@ -191,18 +194,18 @@ function ShoppingCart({
@@ -212,7 +215,7 @@ function ShoppingCart({ جمع کل سبد خرید

- {separate(productsLength ? factorInfo?.payPrice : 384000)} + {separate(productsLength ? factorInfo?.payPrice : '')} تومان diff --git a/src/views/Video/index.js b/src/views/Video/index.js index 01f90bf..7e34a34 100644 --- a/src/views/Video/index.js +++ b/src/views/Video/index.js @@ -152,7 +152,7 @@ function Video({ /> )}

-
+

{"دوره ویدئویی" + " " + book?.name} @@ -209,7 +209,7 @@ function Video({

مشاهده کتاب این محصول