Commit 6d942be1 by Giang Tran

checkout

parent 94aecd32
...@@ -13,33 +13,6 @@ export const OTP_TYPE = { ...@@ -13,33 +13,6 @@ export const OTP_TYPE = {
}; };
export const RSA_KEY = { export const RSA_KEY = {
privateKey: `-----BEGIN RSA PRIVATE KEY-----
MIIEpQIBAAKCAQEAriPaOfp9zSDIsde2OJPU3GKlV2EXqhEGxnmO6NHnz3SCJiTA
cTMIbckGKYsmsPoZyAmdP4irA+zMUA16vixXc1+R4whR1qVcXRQ2ZL/QOAtlgBUu
9rF3/+dexv3PW/2Di1uBdGn7khj3Mrs1PKWY9FEtb+NdgTF61RKWnhE6ktoKgukI
1XN5Xvt+5QqwOpPnDcByWyrw7J5N8Jc9bsP+GC7SzURE00nuw1uazrBvVpgcgyiA
yHj3SFJIF89MZYuulJxi9GYjv6ov3kcW5o14kNPExNEgPtlTVyoe1qub/xknSm12
GOTd5V8yvjgJ8ipjHxC7CvEEhG7AT5sJ/3pOywIDAQABAoIBAQCFQT4u+7XkkF/D
Z1Qzezx54KqxcMTRCPJsUny/QFDo+TjWw2zXsruSdy/V/nt/FgNAhcrk4UosWLoH
0CjK+dd5m/phBu7JGATT3TG6auWE3YOwPYWQlUFEe+KU14gj1p0guMcZNDikFaKk
GYmlfPrMiooAgrX8tMZP4keLcZem4xvclhOF49NOaQgbeydBGf33vFUN86qMG5V8
dUy80HkZ55TNXvY6GWpfKw7nOT7LjY1dNSGykNyMVoiLIQ7rMupzXVsu40Y6jajK
7S/pWZnDLPhMMepakFVzgy/D0ixwfrfRQN1PMFAS84r1n8CpA0rjm9xLyc7sLpEp
PEGbY9GxAoGBANUlhfK2e+kpoE40q3F1o2dwAglC+ombj8+VhJc7jnf8YLYcp4mG
+8RSqLueobR4UnFInkFRuN8VklkMISMHD+YuUhamzBkGnllA6THsgafqWOi1vO1A
9sm/UhHPnONm7tp5Ogxh3LZHSLStl8CaYazHkTt6IoHIkdwCWG/BJChXAoGBANEm
sh3ZgXxe0zBB7kuPcjk5VUU3oVjpkERYjBAsOD1vtmRgD74Ev+qMCDjIosalUo8B
jxpatmup+CHB3lwbvEmTy1y1Vjm85U++9KmDvhCjgVhh97uPYAqMapmTKTkoWKYm
OzCKzoltVHGAX9AXrfwRM+Nfz7Y1pJHvAACildStAoGBAJba5+LQpQJxI7Q2MuEq
kWw0KjzD2u5p227gM+eVj0/8n7ZEsY70qlxY5HNl4q0IO9FRxDAW1vGNIvdDTnCs
HuSbBB5kDy/nL0ucVW+wJFPj2OlbN0v0HrbLYhqZBkEsKQEXq6331W5tJVg7RJxc
p6TR2khuON4CRrmgL1dpK14hAoGBAJvb4EQKQEo0R+DgYPoB7bbjGL46FIyzkQS9
j7LFoSt3Qk5On6yU0YexzrayHUs3C+zx1nhnPSXCRdyyIkg1ivyxnIx7vcPNFn10
6dIhENRJZCw+5WPqFkIGHbJQThoADP/T4avs5LjYtmLWrY/e9ZKwJyC714gLNZZi
qnfOsSUJAoGAX9CAHHCz/X3GJ+HGYm5mu3ks2hCw9umJZkabpKxnWWhpgPrqysHF
wkSh32IW6zQqgN/H7Q2sndqb5NM88rHowxPyIL1sSnmpXPNmjUhjxP74stu0EcSM
KYdYznyvql2HvuWSfOHzOdbA2umFaL09lNSDBdGiaK4ji8oleyhlWPU=
-----END RSA PRIVATE KEY-----`,
publicKey: `-----BEGIN PUBLIC KEY----- publicKey: `-----BEGIN PUBLIC KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAriPaOfp9zSDIsde2OJPU MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAriPaOfp9zSDIsde2OJPU
3GKlV2EXqhEGxnmO6NHnz3SCJiTAcTMIbckGKYsmsPoZyAmdP4irA+zMUA16vixX 3GKlV2EXqhEGxnmO6NHnz3SCJiTAcTMIbckGKYsmsPoZyAmdP4irA+zMUA16vixX
......
{
"folders": [
{
"path": "../../.."
}
],
"settings": {}
}
import React from 'react'; import React, {Component, useState} from 'react';
import {View, Text} from 'react-native'; import {View, Text, StatusBar, SafeAreaView} from 'react-native';
import {getFontXD} from '../../../Config/Functions'; import {getFontXD, HEIGHT, WIDTHXD} from '../../../Config/Functions';
import HeaderBack from '../../../components/Header/HeaderBack'; import Level1 from './Tabs/Level1';
import {WebView} from 'react-native-webview';
import {connect} from 'react-redux'; import I18n from '../../../helper/i18/i18n';
import {createMaterialTopTabNavigator} from '@react-navigation/material-top-tabs';
const Tab = createMaterialTopTabNavigator();
import HeaderPartner from '../../../components/Header/HeaderPartner';
import SearchModal from './SearchModal';
const ListTabs = [
{
type: 'level1',
},
{
type: 'level2',
},
{
type: 'level3',
},
];
const MyGroup = (props) => { const MyGroup = (props) => {
const [isModalVisible, setModalVisible] = useState(true);
const toggleModal = () => {
setModalVisible(!isModalVisible);
};
return ( return (
<View style={{flex: 1}}> <View style={{flex: 1}}>
<HeaderBack isWhite={true} title={'MyPartner'} /> <HeaderPartner
<WebView onOpenSearch={toggleModal}
androidHardwareAccelerationDisabled={true} title={'MyPartner'}
source={{ isWhite={true}
uri:
'http://api.dcvinvest.com/webview/partners/show/' + props.user.uid,
}}
/> />
<View style={{flex: 1, backgroundColor: 'white'}}>
<Tab.Navigator
initialRouteName="Tab1"
swipeEnabled={false}
tabBarOptions={{
inactiveTintColor: '#929292',
activeTintColor: '#1473E6',
labelStyle: {fontSize: getFontXD(36)},
style: {backgroundColor: 'white'},
}}>
{ListTabs.map((e) => (
<Tab.Screen
name={e.type}
children={() => <Level1 type={e.type} />}
options={{tabBarLabel: I18n.t(e.type)}}
/>
))}
</Tab.Navigator>
<SearchModal
toggleModal={toggleModal}
isModalVisible={isModalVisible}
/>
</View>
</View> </View>
); );
}; };
const mapStateToProps = (state) => { export default MyGroup;
return {
user: state.userReducer,
};
};
export default connect(mapStateToProps, {})(MyGroup);
import React, {useEffect, useState} from 'react';
import {
View,
Text,
Image,
StyleSheet,
TouchableOpacity,
TouchableWithoutFeedback,
Platform,
DeviceEventEmitter,
} from 'react-native';
import R from '../../../assets/R';
import {
HEIGHTXD,
WIDTHXD,
getFontXD,
getWidth,
} from '../../../Config/Functions';
import Modal from 'react-native-modal';
import I18n from '../.././../helper/i18/i18n';
import AppText from '../../../components/AppText';
import PickerItem from '../../../components/Picker/PickerItem';
import PickerMonth from '../../../components/Picker/PickerMonth';
import {SEARCHPARTNER} from '../../../routers/ScreenNames';
import {showAlert, TYPE} from '../../../components/DropdownAlert';
import {useNavigation} from '@react-navigation/native';
import TextField from '../../../components/Input/TextField';
import IconClose from 'react-native-vector-icons/AntDesign';
const SearchProductCodeModal = (props) => {
const navigate = useNavigation();
const [product, setProduct] = useState(null);
const [period, setPeriod] = useState(new Date());
const [dataProduct, setDataProduct] = useState([]);
const [dataProductFilter, setDataProductFilter] = useState([]);
return (
<Modal
isVisible={props.isModalVisible}
style={{margin: 0, justifyContent: 'flex-end'}}>
<View style={{flex: 1, justifyContent: 'flex-end'}}>
<TouchableOpacity
style={styles.opacity}
activeOpacity={1}
onPressOut={() => {
props.toggleModal();
}}>
<TouchableWithoutFeedback>
<View style={styles.container}>
<View style={styles.viewTitle}>
<Text
style={[
styles.txt,
{
color: R.colors.black,
textAlign: 'center',
flex: 10,
},
]}>
{I18n.t('SearchProductCode')}
</Text>
<TouchableOpacity
onPress={() => {
props.toggleModal();
}}
style={styles.btClose}>
<IconClose
name="close"
size={WIDTHXD(48)}
color={R.colors.black}
/>
</TouchableOpacity>
</View>
<TextField title={I18n.t('NamePartner')} />
<AppText
style={[styles.txtTitle, {marginTop: HEIGHTXD(40)}]}
i18nKey={'level'}
/>
<AppText
style={[styles.txtTitle, {marginTop: HEIGHTXD(40)}]}
i18nKey={'OpenAccountCQG'}
/>
<View
style={{
marginTop: HEIGHTXD(80),
justifyContent: 'center',
alignItems: 'center',
}}>
<TouchableOpacity
onPress={() => {
props.toggleModal();
navigate.navigate(SEARCHPARTNER);
}}
style={styles.btnSend}>
<Text style={styles.txtSend}>{I18n.t('Search')}</Text>
</TouchableOpacity>
</View>
</View>
</TouchableWithoutFeedback>
</TouchableOpacity>
</View>
</Modal>
);
};
const styles = StyleSheet.create({
container: {
backgroundColor: R.colors.white,
borderRadius: 10,
borderWidth: 2,
borderColor: '#DBDBDB',
paddingTop: HEIGHTXD(50),
paddingBottom: HEIGHTXD(300),
paddingHorizontal: WIDTHXD(40),
},
viewTitle: {
flexDirection: 'row',
width: getWidth() - WIDTHXD(40),
marginLeft: WIDTHXD(40),
},
btClose: {
flex: 1,
justifyContent: 'center',
alignItems: 'flex-start',
marginRight: WIDTHXD(40),
},
txt: {
fontSize: getFontXD(42),
color: R.colors.color777,
marginBottom: 5,
paddingLeft: 10,
},
txtTitle: {
fontSize: getFontXD(42),
color: R.colors.color777,
},
selectionImg: {
padding: 10,
justifyContent: 'center',
alignItems: 'center',
},
containerSelect: {
height: HEIGHTXD(520),
backgroundColor: 'white',
paddingTop: 10,
borderTopLeftRadius: 20,
borderTopRightRadius: 20,
},
line: {
height: 1,
backgroundColor: '#929292',
width: '100%',
marginTop: 5,
},
imgIcon: {
width: 40,
height: 40,
},
txtTitleBtn: {
fontSize: getFontXD(42),
color: '#1473E6',
},
btnSend: {
width: WIDTHXD(500),
height: HEIGHTXD(120),
backgroundColor: R.colors.main,
borderRadius: 8,
justifyContent: 'center',
alignItems: 'center',
},
txtSend: {
fontSize: getFontXD(42),
color: R.colors.white,
paddingHorizontal: WIDTHXD(60),
fontWeight: 'bold',
},
});
export default SearchProductCodeModal;
import React, {Component} from 'react';
import {View, Text} from 'react-native';
import HeaderBack from '../../../components/Header/HeaderBack';
const SearchPartner = (props) => {
return (
<View style={{flex: 1}}>
<HeaderBack title="SearchPartner" />
<Text>List partner</Text>
</View>
);
};
export default SearchPartner;
import React, {Component} from 'react';
import {View, Text} from 'react-native';
const Level1 = (props) => {
return (
<View>
<Text>{props.type}</Text>
</View>
);
};
export default Level1;
import React, {useState} from 'react';
import {
View,
Text,
Image,
StatusBar,
StyleSheet,
SafeAreaView,
ImageBackground,
TouchableOpacity,
Platform,
Button,
TouchableWithoutFeedback,
} from 'react-native';
import R from '../../assets/R';
import {getFontXD, HEIGHT, WIDTHXD} from '../../Config/Functions';
import LinearGradient from 'react-native-linear-gradient';
import {connect} from 'react-redux';
import Modal from 'react-native-modal';
import Drawer from './Drawer';
import SnackBar from '../SnackBar';
import AppText from '../AppText';
import Icon from 'react-native-vector-icons/Ionicons';
import {useNavigation} from '@react-navigation/native';
const HeaderDrawer = (props) => {
const {title, isWhite} = props;
const navigate = useNavigation();
return (
<ImageBackground
imageStyle={{resizeMode: 'stretch'}}
style={[styles.img, isWhite ? {backgroundColor: 'white'} : {}]}
source={R.images.bgHeader}>
<SnackBar />
<StatusBar backgroundColor="transparent" translucent={true} />
<View style={styles.headerContainer}>
<TouchableOpacity
onPress={() => navigate.goBack()}
style={{width: 35, height: 30}}>
<Image source={R.images.iconBack} style={styles.imgIcon} />
</TouchableOpacity>
<AppText i18nKey={title} style={styles.txtTitle}></AppText>
<TouchableOpacity
style={{width: 35, height: 35}}
onPress={props.onOpenSearch}>
<Icon name={'search-sharp'} size={25} color={R.colors.white} />
</TouchableOpacity>
</View>
</ImageBackground>
);
};
const mapStateToProps = (state) => {
return {
user: state.userReducer,
};
};
export default connect(mapStateToProps, {})(HeaderDrawer);
const styles = StyleSheet.create({
img: {
height: 95,
width: '100%',
paddingTop: 30,
},
headerContainer: {
height: 40,
paddingTop: 10,
width: '100%',
alignItems: 'center',
flexDirection: 'row',
paddingHorizontal: 20,
justifyContent: 'space-between',
},
imgIcon: {
width: 25,
height: 20,
},
txtTitle: {
fontSize: getFontXD(52),
color: R.colors.white,
fontWeight: 'bold',
},
container: {
backgroundColor: 'white',
height: '100%',
width: WIDTHXD(780),
borderRadius: 20,
},
});
...@@ -329,7 +329,8 @@ export default { ...@@ -329,7 +329,8 @@ export default {
YouHaveNotSettingSmartOTP: 'You have not installed Smart OTP', YouHaveNotSettingSmartOTP: 'You have not installed Smart OTP',
OTP: 'Enter OTP', OTP: 'Enter OTP',
HaveIssue: 'Have an issue, try again!', HaveIssue: 'Have an issue, try again!',
HaveNotCredential: 'Can not login by %{type}, please return on login by %{type}', HaveNotCredential:
'Can not login by %{type}, please return on login by %{type}',
LoginBy: 'Login by %{type}', LoginBy: 'Login by %{type}',
Fingerprint: 'Fingerprint', Fingerprint: 'Fingerprint',
FaceId: 'FaceId', FaceId: 'FaceId',
...@@ -338,5 +339,10 @@ export default { ...@@ -338,5 +339,10 @@ export default {
Period: 'Period', Period: 'Period',
YouNotSettingBiometry: 'You not setting %{type}, please setting it', YouNotSettingBiometry: 'You not setting %{type}, please setting it',
EnterPasswordTitle: 'Enter password login', EnterPasswordTitle: 'Enter password login',
level1: 'Level 1',
level2: 'Level 2',
level3: 'Level 3',
SearchPartner: 'Search partner',
level: 'Level',
NamePartner: 'Name partner',
}; };
...@@ -326,13 +326,21 @@ export default { ...@@ -326,13 +326,21 @@ export default {
YouHaveNotSettingSmartOTP: 'Bạn chưa cài đặt Smart OTP', YouHaveNotSettingSmartOTP: 'Bạn chưa cài đặt Smart OTP',
OTP: 'Nhập OTP', OTP: 'Nhập OTP',
HaveIssue: 'Có lỗi xảy ra, vui lòng thử lại', HaveIssue: 'Có lỗi xảy ra, vui lòng thử lại',
HaveNotCredential: 'Không thể đăng nhập được bằng %{type}, vui lòng bật lại chức năng đăng nhập bằng %{type}', HaveNotCredential:
'Không thể đăng nhập được bằng %{type}, vui lòng bật lại chức năng đăng nhập bằng %{type}',
LoginBy: 'Đăng nhập bằng %{type}', LoginBy: 'Đăng nhập bằng %{type}',
Fingerprint: 'vân tay', Fingerprint: 'vân tay',
FaceId: 'nhận diện khuôn mặt', FaceId: 'nhận diện khuôn mặt',
SearchProductCode: 'Tìm kiếm mã sản phẩm', SearchProductCode: 'Tìm kiếm mã sản phẩm',
IndustryGroup: 'Nhóm ngành', IndustryGroup: 'Nhóm ngành',
Period: 'Kỳ hạn', Period: 'Kỳ hạn',
YouNotSettingBiometry: 'Bạn chưa thiết lập %{type}, vui lòng thiết lập %{type}', YouNotSettingBiometry:
'Bạn chưa thiết lập %{type}, vui lòng thiết lập %{type}',
EnterPasswordTitle: 'Nhập mật khẩu đăng nhập', EnterPasswordTitle: 'Nhập mật khẩu đăng nhập',
level1: 'Cấp 1',
level2: 'Cấp 2',
level3: 'Cấp 3',
SearchPartner: 'Tìm kiếm đối tác',
level: 'Cấp',
NamePartner: 'Tên đối tác',
}; };
...@@ -95,3 +95,4 @@ export const RULESSMARTOTP = 'RULESSMARTOTP'; ...@@ -95,3 +95,4 @@ export const RULESSMARTOTP = 'RULESSMARTOTP';
export const FAQSSMARTOTP = 'FAQSSMARTOTP'; export const FAQSSMARTOTP = 'FAQSSMARTOTP';
export const CONFIRMCREATEOTP = 'CONFIRMCREATEOTP'; export const CONFIRMCREATEOTP = 'CONFIRMCREATEOTP';
export const SEARCHPARTNER = 'SEARCHPARTNER';
...@@ -68,6 +68,7 @@ import ConfirmChangeSmartOTP from '../Screens/SmartOTP/ChangeSmartOTP/ConfirmCha ...@@ -68,6 +68,7 @@ import ConfirmChangeSmartOTP from '../Screens/SmartOTP/ChangeSmartOTP/ConfirmCha
import FAQs from '../Screens/SmartOTP/WebView/FAQs'; import FAQs from '../Screens/SmartOTP/WebView/FAQs';
import RulesSmartOTP from '../Screens/SmartOTP/WebView/RulesSmartOTP'; import RulesSmartOTP from '../Screens/SmartOTP/WebView/RulesSmartOTP';
import ConfirmCreate from '../Screens/SmartOTP/ConfirmCreate/ConfirmCreate'; import ConfirmCreate from '../Screens/SmartOTP/ConfirmCreate/ConfirmCreate';
import SearchPartner from '../Screens/Menu/MyGroup/SearchPartner';
import * as ScreenName from './ScreenNames'; import * as ScreenName from './ScreenNames';
...@@ -208,6 +209,8 @@ function MyStack(props) { ...@@ -208,6 +209,8 @@ function MyStack(props) {
name={ScreenName.CONFIRMCHANGESMARTOTP} name={ScreenName.CONFIRMCHANGESMARTOTP}
component={ConfirmChangeSmartOTP} component={ConfirmChangeSmartOTP}
/> />
<Stack.Screen name={ScreenName.SEARCHPARTNER} component={SearchPartner} />
</Stack.Navigator> </Stack.Navigator>
); );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment