reza added some feature

master
Reza_ashrafi 3 years ago
parent 41b2a6c154
commit 6f57df14bd
  1. 6
      navigation/index.js
  2. BIN
      planning 4-2-1401.xlsx
  3. 42
      src/screens/Product/components/Book.js
  4. 2
      src/screens/Video/index.js

@ -444,7 +444,6 @@ const HomeStackScreen = ({ theme }) => {
<HomeStack.Screen name="Home" component={Home} /> <HomeStack.Screen name="Home" component={Home} />
<HomeStack.Screen name="VOD" component={Videos} /> <HomeStack.Screen name="VOD" component={Videos} />
<HomeStack.Screen name="Video" component={Video} unmountOnExit={true} /> <HomeStack.Screen name="Video" component={Video} unmountOnExit={true} />
<HomeStack.Screen name="ShoppingCart" component={ShoppingCart} />
<HomeStack.Screen name="VideoDisplay" component={VideoDisplay} /> <HomeStack.Screen name="VideoDisplay" component={VideoDisplay} />
<HomeStack.Screen name="Products" component={Products} /> <HomeStack.Screen name="Products" component={Products} />
<HomeStack.Screen name="Product" component={Product} /> <HomeStack.Screen name="Product" component={Product} />
@ -471,7 +470,6 @@ const ProductsStackScreen = ({ theme }) => {
> >
<ProductsStack.Screen name="Products" component={Products} /> <ProductsStack.Screen name="Products" component={Products} />
<ProductsStack.Screen name="Product" component={Product} /> <ProductsStack.Screen name="Product" component={Product} />
<ProductsStack.Screen name="ShoppingCart" component={ShoppingCart} />
<ProductsStack.Screen name="Sample" component={Sample} /> <ProductsStack.Screen name="Sample" component={Sample} />
<ProductsStack.Screen name="Info" component={Info} /> <ProductsStack.Screen name="Info" component={Info} />
</ProductsStack.Navigator> </ProductsStack.Navigator>
@ -489,10 +487,11 @@ const VODStackScreen = ({ theme }) => {
theme === "light" ? Colors.theme1.white : Colors.theme1.dark, theme === "light" ? Colors.theme1.white : Colors.theme1.dark,
}, },
}} }}
initialRouteName="VOD"
> >
<VODStack.Screen name="VOD" component={Videos} /> <VODStack.Screen name="VOD" component={Videos} />
<VODStack.Screen name="Video" component={Video} unmountOnExit={true} /> <VODStack.Screen name="Video" component={Video} unmountOnExit={true} />
<VODStack.Screen name="ShoppingCart" component={ShoppingCart} />
<VODStack.Screen name="VideoDisplay" component={VideoDisplay} /> <VODStack.Screen name="VideoDisplay" component={VideoDisplay} />
</VODStack.Navigator> </VODStack.Navigator>
); );
@ -509,6 +508,7 @@ const CARTStackScreen = ({ theme }) => {
theme === "light" ? Colors.theme1.white : Colors.theme1.dark, theme === "light" ? Colors.theme1.white : Colors.theme1.dark,
}, },
}} }}
initialRouteName="ShoppingCart"
> >
<CARTStack.Screen name="ShoppingCart" component={ShoppingCart} /> <CARTStack.Screen name="ShoppingCart" component={ShoppingCart} />
<CARTStack.Screen name="DeliveryForm" component={DeliveryForm} /> <CARTStack.Screen name="DeliveryForm" component={DeliveryForm} />

Binary file not shown.

@ -87,21 +87,30 @@ function Book({
if (whichTypeAdded === "video" && videoAvailabileInCart) { if (whichTypeAdded === "video" && videoAvailabileInCart) {
asyncAwesomeAlert("", "به سبد خرید اضافه شد", { asyncAwesomeAlert("", "به سبد خرید اضافه شد", {
showCancelButton: true, showCancelButton: true,
onConfirm: () => navigation.push("ShoppingCart"), onConfirm: () =>
navigation.navigate("ShoppingCartTab", {
screen: "ShoppingCart",
}),
confirmText: "مشاهده سبد خرید", confirmText: "مشاهده سبد خرید",
cancelText: "ادامه خرید", cancelText: "ادامه خرید",
}); });
} else if (whichTypeAdded === "physical" && physicalAvailabileInCart) { } else if (whichTypeAdded === "physical" && physicalAvailabileInCart) {
asyncAwesomeAlert("", "به سبد خرید اضافه شد", { asyncAwesomeAlert("", "به سبد خرید اضافه شد", {
showCancelButton: true, showCancelButton: true,
onConfirm: () => navigation.push("ShoppingCart"), onConfirm: () =>
navigation.navigate("ShoppingCartTab", {
screen: "ShoppingCart",
}),
confirmText: "مشاهده سبد خرید", confirmText: "مشاهده سبد خرید",
cancelText: "ادامه خرید", cancelText: "ادامه خرید",
}); });
} else if (whichTypeAdded === "digital" && digitalAvailabileInCart) { } else if (whichTypeAdded === "digital" && digitalAvailabileInCart) {
asyncAwesomeAlert("", "به سبد خرید اضافه شد", { asyncAwesomeAlert("", "به سبد خرید اضافه شد", {
showCancelButton: true, showCancelButton: true,
onConfirm: () => navigation.push("ShoppingCart"), onConfirm: () =>
navigation.navigate("ShoppingCartTab", {
screen: "ShoppingCart",
}),
confirmText: "مشاهده سبد خرید", confirmText: "مشاهده سبد خرید",
cancelText: "ادامه خرید", cancelText: "ادامه خرید",
}); });
@ -271,7 +280,8 @@ function Book({
{ {
borderWidth: 1, borderWidth: 1,
borderColor: Colors.theme1.greenCF, borderColor: Colors.theme1.greenCF,
backgroundColor: theme === 'light' ? Colors.theme1.greenFF + "0a" : null, backgroundColor:
theme === "light" ? Colors.theme1.greenFF + "0a" : null,
}, },
]} ]}
onPress={() => onPress={() =>
@ -340,8 +350,9 @@ function Book({
tw("flex flex-row-reverse justify-between px-2 py-3 mb-4"), tw("flex flex-row-reverse justify-between px-2 py-3 mb-4"),
{ {
borderWidth: 1, borderWidth: 1,
borderColor: Colors.theme1.greenCF, borderColor: Colors.theme1.greenCF,
backgroundColor: theme === 'light' ? Colors.theme1.greenFF + "0a" : null, backgroundColor:
theme === "light" ? Colors.theme1.greenFF + "0a" : null,
width: width - 32 - 8 - (fontSize.sm * 6 + 18), width: width - 32 - 8 - (fontSize.sm * 6 + 18),
}, },
]} ]}
@ -411,7 +422,8 @@ function Book({
{ {
borderWidth: 1, borderWidth: 1,
borderColor: Colors.theme1.greenCF, borderColor: Colors.theme1.greenCF,
backgroundColor: theme === 'light' ? Colors.theme1.greenFF + "0a" : null, backgroundColor:
theme === "light" ? Colors.theme1.greenFF + "0a" : null,
width: fontSize.sm * 6 + 18, width: fontSize.sm * 6 + 18,
}, },
]} ]}
@ -422,7 +434,9 @@ function Book({
fontFamily: "bold", fontFamily: "bold",
fontSize: fontSize.xs, fontSize: fontSize.xs,
color: color:
theme === "light" ? Colors.theme1.green79 : Colors.theme1.greenCF, theme === "light"
? Colors.theme1.green79
: Colors.theme1.greenCF,
paddingVertical: 4, paddingVertical: 4,
}} }}
@ -437,7 +451,8 @@ function Book({
{ {
borderWidth: 1, borderWidth: 1,
borderColor: Colors.theme1.greenCF, borderColor: Colors.theme1.greenCF,
backgroundColor: theme === 'light' ? Colors.theme1.greenFF + "0a" : null, backgroundColor:
theme === "light" ? Colors.theme1.greenFF + "0a" : null,
width: width - 32 - 8 - (fontSize.sm * 6 + 18), width: width - 32 - 8 - (fontSize.sm * 6 + 18),
}, },
]} ]}
@ -506,7 +521,8 @@ function Book({
{ {
borderWidth: 1, borderWidth: 1,
borderColor: Colors.theme1.greenCF, borderColor: Colors.theme1.greenCF,
backgroundColor: theme === 'light' ? Colors.theme1.greenFF + "0a" : null, backgroundColor:
theme === "light" ? Colors.theme1.greenFF + "0a" : null,
width: fontSize.sm * 6 + 18, width: fontSize.sm * 6 + 18,
}, },
]} ]}
@ -517,7 +533,9 @@ function Book({
fontFamily: "bold", fontFamily: "bold",
fontSize: fontSize.xs, fontSize: fontSize.xs,
color: color:
theme === "light" ? Colors.theme1.green79 : Colors.theme1.greenCF, theme === "light"
? Colors.theme1.green79
: Colors.theme1.greenCF,
paddingVertical: 4, paddingVertical: 4,
}} }}
@ -567,7 +585,7 @@ function Book({
style={[ style={[
{ {
fontSize: fontSize.tiny, fontSize: fontSize.tiny,
color: theme === 'light' ? "#275077" : Colors.theme1.white, color: theme === "light" ? "#275077" : Colors.theme1.white,
fontFamily: "regular", fontFamily: "regular",
}, },
tw(""), tw(""),

@ -197,7 +197,7 @@ function Product({
} }
/> />
</View> </View>
<View style={tw("flex ")}> <View style={tw("flex")}>
{seasons {seasons
?.sort((a, b) => a[0]?.categoryId - b[0]?.categoryId) ?.sort((a, b) => a[0]?.categoryId - b[0]?.categoryId)
?.map((season, index) => ( ?.map((season, index) => (

Loading…
Cancel
Save