react-native-timacare 2.0.14 → 2.0.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (203) hide show
  1. package/lib/commonjs/components/MHeader.js +2 -0
  2. package/lib/commonjs/components/MHeader.js.flow +101 -0
  3. package/lib/commonjs/components/MHeader.js.map +1 -0
  4. package/lib/commonjs/navigation/primary-navigator.js +1 -1
  5. package/lib/commonjs/navigation/primary-navigator.js.flow +1 -1
  6. package/lib/commonjs/navigation/primary-navigator.js.map +1 -1
  7. package/lib/commonjs/screens/cimb-sign/index.js +1 -1
  8. package/lib/commonjs/screens/cimb-sign/index.js.flow +34 -50
  9. package/lib/commonjs/screens/cimb-sign/index.js.map +1 -1
  10. package/lib/commonjs/screens/detail-loan/DetailLoanTima.js +1 -1
  11. package/lib/commonjs/screens/detail-loan/DetailLoanTima.js.flow +6 -29
  12. package/lib/commonjs/screens/detail-loan/DetailLoanTima.js.map +1 -1
  13. package/lib/commonjs/screens/detail-loan/PaymentInfo.js +1 -1
  14. package/lib/commonjs/screens/detail-loan/PaymentInfo.js.flow +8 -31
  15. package/lib/commonjs/screens/detail-loan/PaymentInfo.js.map +1 -1
  16. package/lib/commonjs/screens/detail-loan/index.js +1 -1
  17. package/lib/commonjs/screens/detail-loan/index.js.flow +13 -36
  18. package/lib/commonjs/screens/detail-loan/index.js.map +1 -1
  19. package/lib/commonjs/screens/digital-lending/index.js +1 -1
  20. package/lib/commonjs/screens/digital-lending/index.js.flow +16 -45
  21. package/lib/commonjs/screens/digital-lending/index.js.map +1 -1
  22. package/lib/commonjs/screens/eSign/PreviewContract.js +1 -1
  23. package/lib/commonjs/screens/eSign/PreviewContract.js.flow +7 -34
  24. package/lib/commonjs/screens/eSign/PreviewContract.js.map +1 -1
  25. package/lib/commonjs/screens/eSign/index.js +1 -1
  26. package/lib/commonjs/screens/eSign/index.js.flow +7 -38
  27. package/lib/commonjs/screens/eSign/index.js.map +1 -1
  28. package/lib/commonjs/screens/full-submit/index.js +1 -1
  29. package/lib/commonjs/screens/full-submit/index.js.flow +9 -31
  30. package/lib/commonjs/screens/full-submit/index.js.map +1 -1
  31. package/lib/commonjs/screens/full-submit/selfie.js +1 -1
  32. package/lib/commonjs/screens/full-submit/selfie.js.flow +2 -28
  33. package/lib/commonjs/screens/full-submit/selfie.js.map +1 -1
  34. package/lib/commonjs/screens/guide-transfer-bank/TransferDetail.js +1 -1
  35. package/lib/commonjs/screens/guide-transfer-bank/TransferDetail.js.flow +7 -33
  36. package/lib/commonjs/screens/guide-transfer-bank/TransferDetail.js.map +1 -1
  37. package/lib/commonjs/screens/guide-transfer-bank/index.js +1 -1
  38. package/lib/commonjs/screens/guide-transfer-bank/index.js.flow +8 -31
  39. package/lib/commonjs/screens/guide-transfer-bank/index.js.map +1 -1
  40. package/lib/commonjs/screens/home/CIMBxTima.js +1 -1
  41. package/lib/commonjs/screens/home/CIMBxTima.js.flow +2 -20
  42. package/lib/commonjs/screens/home/CIMBxTima.js.map +1 -1
  43. package/lib/commonjs/screens/home/index.js +1 -1
  44. package/lib/commonjs/screens/home/index.js.flow +37 -45
  45. package/lib/commonjs/screens/home/index.js.map +1 -1
  46. package/lib/commonjs/screens/introduction/index.js +1 -1
  47. package/lib/commonjs/screens/introduction/index.js.flow +2 -29
  48. package/lib/commonjs/screens/introduction/index.js.map +1 -1
  49. package/lib/commonjs/screens/nationalID/index.js +1 -1
  50. package/lib/commonjs/screens/nationalID/index.js.flow +7 -29
  51. package/lib/commonjs/screens/nationalID/index.js.map +1 -1
  52. package/lib/commonjs/screens/nationalIDBack/index.js +1 -1
  53. package/lib/commonjs/screens/nationalIDBack/index.js.flow +7 -30
  54. package/lib/commonjs/screens/nationalIDBack/index.js.map +1 -1
  55. package/lib/commonjs/screens/notification/index.js +1 -1
  56. package/lib/commonjs/screens/notification/index.js.flow +2 -29
  57. package/lib/commonjs/screens/notification/index.js.map +1 -1
  58. package/lib/commonjs/screens/payment-evidence/index.js +1 -1
  59. package/lib/commonjs/screens/payment-evidence/index.js.flow +3 -57
  60. package/lib/commonjs/screens/payment-evidence/index.js.map +1 -1
  61. package/lib/commonjs/screens/quick-submit/index.js +1 -1
  62. package/lib/commonjs/screens/quick-submit/index.js.flow +13 -36
  63. package/lib/commonjs/screens/quick-submit/index.js.map +1 -1
  64. package/lib/commonjs/screens/schedule-payment/index.js +1 -1
  65. package/lib/commonjs/screens/schedule-payment/index.js.flow +6 -31
  66. package/lib/commonjs/screens/schedule-payment/index.js.map +1 -1
  67. package/lib/commonjs/screens/selfie/index.js +1 -1
  68. package/lib/commonjs/screens/selfie/index.js.flow +2 -22
  69. package/lib/commonjs/screens/selfie/index.js.map +1 -1
  70. package/lib/commonjs/screens/sign-tima/ConfirmContract.js +1 -1
  71. package/lib/commonjs/screens/sign-tima/ConfirmContract.js.flow +2 -29
  72. package/lib/commonjs/screens/sign-tima/ConfirmContract.js.map +1 -1
  73. package/lib/commonjs/screens/sign-tima/ViewContract.js +1 -1
  74. package/lib/commonjs/screens/sign-tima/ViewContract.js.flow +12 -36
  75. package/lib/commonjs/screens/sign-tima/ViewContract.js.map +1 -1
  76. package/lib/commonjs/screens/terms/QuickTerm.js +1 -1
  77. package/lib/commonjs/screens/terms/QuickTerm.js.flow +7 -24
  78. package/lib/commonjs/screens/terms/QuickTerm.js.map +1 -1
  79. package/lib/commonjs/screens/terms/TermScreen.js +1 -1
  80. package/lib/commonjs/screens/terms/TermScreen.js.flow +8 -39
  81. package/lib/commonjs/screens/terms/TermScreen.js.map +1 -1
  82. package/lib/commonjs/screens/uploadVideo/index.js +1 -1
  83. package/lib/commonjs/screens/uploadVideo/index.js.flow +89 -90
  84. package/lib/commonjs/screens/uploadVideo/index.js.map +1 -1
  85. package/lib/commonjs/services/api/api-config.js +1 -1
  86. package/lib/commonjs/services/api/api-config.js.flow +2 -2
  87. package/lib/commonjs/services/api/api-config.js.map +1 -1
  88. package/lib/module/components/MHeader.js +2 -0
  89. package/lib/module/components/MHeader.js.map +1 -0
  90. package/lib/module/navigation/primary-navigator.js +1 -1
  91. package/lib/module/navigation/primary-navigator.js.map +1 -1
  92. package/lib/module/screens/cimb-sign/index.js +1 -1
  93. package/lib/module/screens/cimb-sign/index.js.map +1 -1
  94. package/lib/module/screens/detail-loan/DetailLoanTima.js +1 -1
  95. package/lib/module/screens/detail-loan/DetailLoanTima.js.map +1 -1
  96. package/lib/module/screens/detail-loan/PaymentInfo.js +1 -1
  97. package/lib/module/screens/detail-loan/PaymentInfo.js.map +1 -1
  98. package/lib/module/screens/detail-loan/index.js +1 -1
  99. package/lib/module/screens/detail-loan/index.js.map +1 -1
  100. package/lib/module/screens/digital-lending/index.js +1 -1
  101. package/lib/module/screens/digital-lending/index.js.map +1 -1
  102. package/lib/module/screens/eSign/PreviewContract.js +1 -1
  103. package/lib/module/screens/eSign/PreviewContract.js.map +1 -1
  104. package/lib/module/screens/eSign/index.js +1 -1
  105. package/lib/module/screens/eSign/index.js.map +1 -1
  106. package/lib/module/screens/full-submit/index.js +1 -1
  107. package/lib/module/screens/full-submit/index.js.map +1 -1
  108. package/lib/module/screens/full-submit/selfie.js +1 -1
  109. package/lib/module/screens/full-submit/selfie.js.map +1 -1
  110. package/lib/module/screens/guide-transfer-bank/TransferDetail.js +1 -1
  111. package/lib/module/screens/guide-transfer-bank/TransferDetail.js.map +1 -1
  112. package/lib/module/screens/guide-transfer-bank/index.js +1 -1
  113. package/lib/module/screens/guide-transfer-bank/index.js.map +1 -1
  114. package/lib/module/screens/home/CIMBxTima.js +1 -1
  115. package/lib/module/screens/home/CIMBxTima.js.map +1 -1
  116. package/lib/module/screens/home/index.js +1 -1
  117. package/lib/module/screens/home/index.js.map +1 -1
  118. package/lib/module/screens/introduction/index.js +1 -1
  119. package/lib/module/screens/introduction/index.js.map +1 -1
  120. package/lib/module/screens/nationalID/index.js +1 -1
  121. package/lib/module/screens/nationalID/index.js.map +1 -1
  122. package/lib/module/screens/nationalIDBack/index.js +1 -1
  123. package/lib/module/screens/nationalIDBack/index.js.map +1 -1
  124. package/lib/module/screens/notification/index.js +1 -1
  125. package/lib/module/screens/notification/index.js.map +1 -1
  126. package/lib/module/screens/payment-evidence/index.js +1 -1
  127. package/lib/module/screens/payment-evidence/index.js.map +1 -1
  128. package/lib/module/screens/quick-submit/index.js +1 -1
  129. package/lib/module/screens/quick-submit/index.js.map +1 -1
  130. package/lib/module/screens/schedule-payment/index.js +1 -1
  131. package/lib/module/screens/schedule-payment/index.js.map +1 -1
  132. package/lib/module/screens/selfie/index.js +1 -1
  133. package/lib/module/screens/selfie/index.js.map +1 -1
  134. package/lib/module/screens/sign-tima/ConfirmContract.js +1 -1
  135. package/lib/module/screens/sign-tima/ConfirmContract.js.map +1 -1
  136. package/lib/module/screens/sign-tima/ViewContract.js +1 -1
  137. package/lib/module/screens/sign-tima/ViewContract.js.map +1 -1
  138. package/lib/module/screens/terms/QuickTerm.js +1 -1
  139. package/lib/module/screens/terms/QuickTerm.js.map +1 -1
  140. package/lib/module/screens/terms/TermScreen.js +1 -1
  141. package/lib/module/screens/terms/TermScreen.js.map +1 -1
  142. package/lib/module/screens/uploadVideo/index.js +1 -1
  143. package/lib/module/screens/uploadVideo/index.js.map +1 -1
  144. package/lib/module/services/api/api-config.js +1 -1
  145. package/lib/module/services/api/api-config.js.map +1 -1
  146. package/lib/typescript/components/MHeader.d.ts +7 -0
  147. package/lib/typescript/components/MHeader.d.ts.map +1 -0
  148. package/lib/typescript/screens/cimb-sign/index.d.ts.map +1 -1
  149. package/lib/typescript/screens/detail-loan/DetailLoanTima.d.ts.map +1 -1
  150. package/lib/typescript/screens/detail-loan/PaymentInfo.d.ts.map +1 -1
  151. package/lib/typescript/screens/detail-loan/index.d.ts.map +1 -1
  152. package/lib/typescript/screens/digital-lending/index.d.ts.map +1 -1
  153. package/lib/typescript/screens/eSign/PreviewContract.d.ts.map +1 -1
  154. package/lib/typescript/screens/eSign/index.d.ts.map +1 -1
  155. package/lib/typescript/screens/full-submit/index.d.ts.map +1 -1
  156. package/lib/typescript/screens/full-submit/selfie.d.ts.map +1 -1
  157. package/lib/typescript/screens/guide-transfer-bank/TransferDetail.d.ts.map +1 -1
  158. package/lib/typescript/screens/guide-transfer-bank/index.d.ts.map +1 -1
  159. package/lib/typescript/screens/home/CIMBxTima.d.ts.map +1 -1
  160. package/lib/typescript/screens/home/index.d.ts.map +1 -1
  161. package/lib/typescript/screens/introduction/index.d.ts.map +1 -1
  162. package/lib/typescript/screens/nationalID/index.d.ts.map +1 -1
  163. package/lib/typescript/screens/nationalIDBack/index.d.ts.map +1 -1
  164. package/lib/typescript/screens/notification/index.d.ts.map +1 -1
  165. package/lib/typescript/screens/payment-evidence/index.d.ts.map +1 -1
  166. package/lib/typescript/screens/quick-submit/index.d.ts.map +1 -1
  167. package/lib/typescript/screens/schedule-payment/index.d.ts.map +1 -1
  168. package/lib/typescript/screens/selfie/index.d.ts.map +1 -1
  169. package/lib/typescript/screens/sign-tima/ConfirmContract.d.ts.map +1 -1
  170. package/lib/typescript/screens/sign-tima/ViewContract.d.ts.map +1 -1
  171. package/lib/typescript/screens/terms/QuickTerm.d.ts.map +1 -1
  172. package/lib/typescript/screens/terms/TermScreen.d.ts.map +1 -1
  173. package/lib/typescript/screens/uploadVideo/index.d.ts.map +1 -1
  174. package/package.json +1 -1
  175. package/src/components/MHeader.tsx +101 -0
  176. package/src/navigation/primary-navigator.tsx +1 -1
  177. package/src/screens/cimb-sign/index.tsx +34 -50
  178. package/src/screens/detail-loan/DetailLoanTima.tsx +6 -29
  179. package/src/screens/detail-loan/PaymentInfo.tsx +8 -31
  180. package/src/screens/detail-loan/index.tsx +13 -36
  181. package/src/screens/digital-lending/index.tsx +16 -45
  182. package/src/screens/eSign/PreviewContract.tsx +7 -34
  183. package/src/screens/eSign/index.tsx +7 -38
  184. package/src/screens/full-submit/index.tsx +9 -31
  185. package/src/screens/full-submit/selfie.tsx +2 -28
  186. package/src/screens/guide-transfer-bank/TransferDetail.tsx +7 -33
  187. package/src/screens/guide-transfer-bank/index.tsx +8 -31
  188. package/src/screens/home/CIMBxTima.tsx +2 -20
  189. package/src/screens/home/index.tsx +37 -45
  190. package/src/screens/introduction/index.tsx +2 -29
  191. package/src/screens/nationalID/index.tsx +7 -29
  192. package/src/screens/nationalIDBack/index.tsx +7 -30
  193. package/src/screens/notification/index.tsx +2 -29
  194. package/src/screens/payment-evidence/index.tsx +3 -57
  195. package/src/screens/quick-submit/index.tsx +13 -36
  196. package/src/screens/schedule-payment/index.tsx +6 -31
  197. package/src/screens/selfie/index.tsx +2 -22
  198. package/src/screens/sign-tima/ConfirmContract.tsx +2 -29
  199. package/src/screens/sign-tima/ViewContract.tsx +12 -36
  200. package/src/screens/terms/QuickTerm.tsx +7 -24
  201. package/src/screens/terms/TermScreen.tsx +8 -39
  202. package/src/screens/uploadVideo/index.tsx +89 -90
  203. package/src/services/api/api-config.ts +2 -2
@@ -0,0 +1,101 @@
1
+ //@ts-nocheck
2
+ import React from 'react';
3
+ import { Linking, TouchableOpacity, View } from 'react-native';
4
+ import { Call, CloseIcon, IconBackWhite } from '../assets/icons';
5
+ import { MText } from './MText';
6
+ import LinearGradient from 'react-native-linear-gradient';
7
+ import {
8
+ useNavigation,
9
+ StackActions,
10
+ CommonActions,
11
+ } from '@react-navigation/native';
12
+ import DeviceInfo from 'react-native-device-info';
13
+
14
+ interface IProps {
15
+ title?: string;
16
+ onBack?: () => void;
17
+ }
18
+ export default function MHeader({ title, onBack }: IProps) {
19
+ const navigation = useNavigation();
20
+ return (
21
+ <LinearGradient colors={['#FF8E4F', '#EF592E']}>
22
+ <View
23
+ style={{
24
+ flexDirection: 'row',
25
+ alignItems: 'center',
26
+ paddingTop: DeviceInfo.hasNotch() ? 60 : 24,
27
+ paddingBottom: 12,
28
+ justifyContent: 'space-between',
29
+ paddingHorizontal: 24,
30
+ }}
31
+ >
32
+ <View
33
+ style={{
34
+ display: 'flex',
35
+ flexDirection: 'row',
36
+ alignItems: 'center',
37
+ }}
38
+ >
39
+ <TouchableOpacity
40
+ onPress={() => {
41
+ if (onBack) onBack();
42
+ }}
43
+ style={{
44
+ width: 32,
45
+ height: 32,
46
+ justifyContent: 'center',
47
+ }}
48
+ >
49
+ <IconBackWhite />
50
+ </TouchableOpacity>
51
+ <MText
52
+ style={{
53
+ fontWeight: 'bold',
54
+ color: 'white',
55
+ fontSize: 16,
56
+ }}
57
+ >
58
+ {title}
59
+ </MText>
60
+ </View>
61
+ <View
62
+ style={{
63
+ borderWidth: 1,
64
+ borderColor: 'white',
65
+ flexDirection: 'row',
66
+ borderRadius: 16,
67
+ height: 30,
68
+ alignItems: 'center',
69
+ }}
70
+ >
71
+ <TouchableOpacity
72
+ style={{
73
+ paddingHorizontal: 10,
74
+ }}
75
+ onPress={() => {
76
+ Linking.openURL(`tel:1900633688`);
77
+ }}
78
+ >
79
+ <Call />
80
+ </TouchableOpacity>
81
+ <View style={{ width: 1, height: 30, backgroundColor: 'white' }} />
82
+ <TouchableOpacity
83
+ style={{
84
+ paddingHorizontal: 10,
85
+ }}
86
+ onPress={() => {
87
+ navigation.dispatch(
88
+ CommonActions.reset({
89
+ index: 1,
90
+ routes: [{ name: 'Main' }],
91
+ })
92
+ );
93
+ }}
94
+ >
95
+ <CloseIcon />
96
+ </TouchableOpacity>
97
+ </View>
98
+ </View>
99
+ </LinearGradient>
100
+ );
101
+ }
@@ -54,7 +54,7 @@ import PreviewContract from '../screens/eSign/PreviewContract';
54
54
 
55
55
  export const ScreenNames = {
56
56
  Splash: 'Splash',
57
- Main: 'Main',
57
+ Main: 'HomeTimaCare',
58
58
  Support: 'Support',
59
59
  Compare: 'Compare',
60
60
  OTP: 'OTP',
@@ -8,6 +8,7 @@ import { IconBack } from '../../assets/icons';
8
8
  import { MText } from '../../components/MText';
9
9
  import { color } from '../../theme';
10
10
  import { commonStyles } from '../CommonStyles';
11
+ import MHeader from '../../components/MHeader';
11
12
 
12
13
  export const CIMBSign = observer(function CIMBSign(props: any) {
13
14
  const navigation = useNavigation();
@@ -15,57 +16,40 @@ export const CIMBSign = observer(function CIMBSign(props: any) {
15
16
 
16
17
  return (
17
18
  <View style={{ flex: 1, backgroundColor: '#FFFFFF' }}>
19
+ <MHeader
20
+ title="Ký hợp đồng"
21
+ onBack={() => {
22
+ if (
23
+ stateWebView &&
24
+ stateWebView?.url.includes('contract-status-approval')
25
+ ) {
26
+ navigation.goBack();
27
+ } else {
28
+ Alert.alert(
29
+ 'Cảnh báo',
30
+ 'Bạn có chắc chắn muốn rời khỏi màn hình ký hợp đồng?',
31
+ [
32
+ {
33
+ text: 'Đồng ý',
34
+ onPress: () => navigation.goBack(),
35
+ },
36
+ {
37
+ text: 'Huỷ',
38
+ },
39
+ ]
40
+ );
41
+ }
42
+ }}
43
+ style={{
44
+ width: 40,
45
+ height: 40,
46
+ position: 'absolute',
47
+ left: 8,
48
+ alignItems: 'center',
49
+ justifyContent: 'center',
50
+ }}
51
+ />
18
52
  <SafeAreaView style={{ flex: 1 }}>
19
- <View
20
- style={[
21
- commonStyles.alignCenter,
22
- { alignItems: 'center', height: 50, justifyContent: 'center' },
23
- ]}
24
- >
25
- <TouchableOpacity
26
- onPress={() => {
27
- if (
28
- stateWebView &&
29
- stateWebView?.url.includes('contract-status-approval')
30
- ) {
31
- navigation.goBack();
32
- } else {
33
- Alert.alert(
34
- 'Cảnh báo',
35
- 'Bạn có chắc chắn muốn rời khỏi màn hình ký hợp đồng?',
36
- [
37
- {
38
- text: 'Đồng ý',
39
- onPress: () => navigation.goBack(),
40
- },
41
- {
42
- text: 'Huỷ',
43
- },
44
- ]
45
- );
46
- }
47
- }}
48
- style={{
49
- width: 40,
50
- height: 40,
51
- position: 'absolute',
52
- left: 8,
53
- alignItems: 'center',
54
- justifyContent: 'center',
55
- }}
56
- >
57
- <IconBack fill={color.textHeader} />
58
- </TouchableOpacity>
59
-
60
- <MText
61
- style={[
62
- commonStyles.textNormalBold,
63
- { color: color.textHeader, fontSize: 16 },
64
- ]}
65
- >
66
- Ký hợp đồng
67
- </MText>
68
- </View>
69
53
  <View style={{ flex: 1, marginBottom: 16 }}>
70
54
  <WebView
71
55
  source={{
@@ -16,6 +16,7 @@ import { Api } from '../../services/api';
16
16
  import { color } from '../../theme';
17
17
  import { commonStyles } from '../CommonStyles';
18
18
  import Loading from '../../components/Loading';
19
+ import MHeader from '../../components/MHeader';
19
20
 
20
21
  export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
21
22
  const navigation = useNavigation();
@@ -50,36 +51,12 @@ export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
50
51
 
51
52
  return (
52
53
  <View style={{ flex: 1, backgroundColor: '#FDFDFD' }}>
54
+ <MHeader
55
+ title={`Đơn vay ${props.route?.params?.loan?.id}`}
56
+ onBack={() => navigation.goBack()}
57
+ />
53
58
  <SafeAreaView style={{ flex: 1 }}>
54
- <View
55
- style={[
56
- commonStyles.alignCenter,
57
- { alignItems: 'center', height: 50, justifyContent: 'center' },
58
- ]}
59
- >
60
- <TouchableOpacity
61
- onPress={() => navigation.goBack()}
62
- style={{
63
- width: 40,
64
- height: 40,
65
- position: 'absolute',
66
- left: 8,
67
- alignItems: 'center',
68
- justifyContent: 'center',
69
- }}
70
- >
71
- <IconBack fill={color.textHeader} />
72
- </TouchableOpacity>
73
- <MText
74
- style={[
75
- commonStyles.textNormalBold,
76
- { color: color.textHeader, fontSize: 16 },
77
- ]}
78
- >
79
- Đơn vay {props.route?.params?.loan?.id}
80
- </MText>
81
- </View>
82
- <ScrollView style={{ flex: 1, paddingHorizontal: 16 }}>
59
+ <ScrollView style={{ flex: 1, paddingHorizontal: 16, marginTop: 16 }}>
83
60
  {data.map((item, index) => (
84
61
  <View
85
62
  key={index}
@@ -20,6 +20,7 @@ import { color } from '../../theme';
20
20
  import { formatMoney } from '../../utils';
21
21
  import { commonStyles } from '../CommonStyles';
22
22
  import DetailLoanStore from './store';
23
+ import MHeader from '../../components/MHeader';
23
24
 
24
25
  const logoView: ImageStyle = {
25
26
  position: 'absolute',
@@ -57,38 +58,14 @@ export const PaymentInfo = observer(function PaymentInfo(props: any) {
57
58
  return (
58
59
  <View style={{ flex: 1 }}>
59
60
  <Image source={require('../../assets/img/home.png')} style={logoView} />
61
+ <MHeader
62
+ title="Thông tin chuyển khoản"
63
+ onBack={() => {
64
+ navigation.goBack();
65
+ }}
66
+ />
60
67
  <SafeAreaView style={{ flex: 1 }}>
61
- <View
62
- style={[
63
- commonStyles.alignCenter,
64
- { alignItems: 'center', height: 50, justifyContent: 'center' },
65
- ]}
66
- >
67
- <TouchableOpacity
68
- onPress={() => navigation.goBack()}
69
- style={{
70
- width: 40,
71
- height: 40,
72
- position: 'absolute',
73
- left: 8,
74
- alignItems: 'center',
75
- justifyContent: 'center',
76
- }}
77
- >
78
- <IconBack fill={color.textHeader} />
79
- </TouchableOpacity>
80
-
81
- <MText
82
- style={[
83
- commonStyles.textNormalBold,
84
- { color: color.textHeader, fontSize: 16 },
85
- ]}
86
- >
87
- Thông tin chuyển khoản
88
- </MText>
89
- </View>
90
-
91
- <ScrollView style={{ flex: 1 }}>
68
+ <ScrollView style={{ flex: 1, marginTop: 16 }}>
92
69
  <View
93
70
  style={{
94
71
  marginHorizontal: 16,
@@ -18,6 +18,7 @@ import { color } from '../../theme';
18
18
  import { commonStyles } from '../CommonStyles';
19
19
  import { Info } from './Info';
20
20
  import { Payment } from './Payment';
21
+ import MHeader from '../../components/MHeader';
21
22
  const logoView: ImageStyle = {
22
23
  position: 'absolute',
23
24
  width: '100%',
@@ -31,49 +32,25 @@ export const DetailLoan = observer(function DetailLoan(props: any) {
31
32
 
32
33
  return (
33
34
  <View style={{ flex: 1, backgroundColor: '#FDFDFD' }}>
35
+ <MHeader
36
+ title={`Đơn vay ${props.route?.params?.loan?.id}`}
37
+ onBack={() =>
38
+ navigation.dispatch(
39
+ CommonActions.reset({
40
+ index: 1,
41
+ routes: [{ name: ScreenNames.Main }],
42
+ })
43
+ )
44
+ }
45
+ />
34
46
  <SafeAreaView style={{ flex: 1 }}>
35
- <View
36
- style={[
37
- commonStyles.alignCenter,
38
- { alignItems: 'center', height: 50, justifyContent: 'center' },
39
- ]}
40
- >
41
- <TouchableOpacity
42
- onPress={() =>
43
- navigation.dispatch(
44
- CommonActions.reset({
45
- index: 1,
46
- routes: [{ name: ScreenNames.Main }],
47
- })
48
- )
49
- }
50
- style={{
51
- width: 40,
52
- height: 40,
53
- position: 'absolute',
54
- left: 8,
55
- alignItems: 'center',
56
- justifyContent: 'center',
57
- }}
58
- >
59
- <IconBack fill={color.textHeader} />
60
- </TouchableOpacity>
61
-
62
- <MText
63
- style={[
64
- commonStyles.textNormalBold,
65
- { color: color.textHeader, fontSize: 16 },
66
- ]}
67
- >
68
- Đơn vay {props.route?.params?.loan?.id}
69
- </MText>
70
- </View>
71
47
  <View
72
48
  style={{
73
49
  flexDirection: 'row',
74
50
  backgroundColor: '#F2F2F2',
75
51
  borderRadius: 30,
76
52
  marginHorizontal: 16,
53
+ marginTop: 16,
77
54
  }}
78
55
  >
79
56
  <TouchableOpacity onPress={() => setTab(1)} style={{ flex: 1 }}>
@@ -27,6 +27,7 @@ import { Step4 } from './Step4';
27
27
  import { Step5 } from './Step5';
28
28
  import { Step6 } from './Step6';
29
29
  import Loading from '../../components/Loading';
30
+ import MHeader from '../../components/MHeader';
30
31
 
31
32
  export const DigitalLending = observer(function DigitalLending(props: any) {
32
33
  const navigation = useNavigation();
@@ -61,51 +62,21 @@ export const DigitalLending = observer(function DigitalLending(props: any) {
61
62
 
62
63
  return (
63
64
  <View style={[commonStyles.fill, { zIndex: 1, backgroundColor: 'white' }]}>
64
- <LinearGradient colors={['#FF8E4F', '#EF592E']}>
65
- <SafeAreaView style={{}}>
66
- <View
67
- style={{
68
- flexDirection: 'row',
69
- justifyContent: 'center',
70
- paddingHorizontal: 16,
71
- alignItems: 'center',
72
- height: 60,
73
- }}
74
- >
75
- {digitalLendingStore.step === 1 && (
76
- <MButton
77
- style={{
78
- height: 32,
79
- width: 32,
80
- borderRadius: 30,
81
- alignItems: 'center',
82
- justifyContent: 'center',
83
- position: 'absolute',
84
- left: 16,
85
- }}
86
- onPress={() => {
87
- navigation.pop();
88
- digitalLendingStore.clear();
89
- digitalLendingStore.data = {};
90
- }}
91
- >
92
- <IconBackWhite />
93
- </MButton>
94
- )}
95
- <MText
96
- style={{
97
- fontWeight: 'bold',
98
- color: 'white',
99
- fontSize: 16,
100
- }}
101
- >
102
- Thông tin cá nhân
103
- </MText>
104
- </View>
105
- </SafeAreaView>
106
- </LinearGradient>
107
-
108
- <Observer>{() => renderView(digitalLendingStore.step)}</Observer>
65
+ <MHeader
66
+ title="Thông tin cá nhân"
67
+ onBack={() => {
68
+ navigation.pop();
69
+ digitalLendingStore.clear();
70
+ digitalLendingStore.data = {};
71
+ }}
72
+ />
73
+ <SafeAreaView
74
+ style={{
75
+ flex: 1,
76
+ }}
77
+ >
78
+ <Observer>{() => renderView(digitalLendingStore.step)}</Observer>
79
+ </SafeAreaView>
109
80
  </View>
110
81
  );
111
82
  });
@@ -8,47 +8,20 @@ import { commonStyles } from '../CommonStyles';
8
8
  import MButton from '../../components/MButton';
9
9
  import { useNavigation } from '@react-navigation/native';
10
10
  import Pdf from 'react-native-pdf';
11
+ import MHeader from '../../components/MHeader';
11
12
 
12
13
  export default function PreviewContract(props: any) {
13
14
  const navigation = useNavigation();
14
15
  const source = props?.route?.params;
15
16
  return (
16
17
  <View style={{ flex: 1, backgroundColor: 'white' }}>
18
+ <MHeader
19
+ title="Hợp đồng"
20
+ onBack={() => {
21
+ navigation.goBack();
22
+ }}
23
+ />
17
24
  <SafeAreaView style={{ flex: 1 }}>
18
- <View
19
- style={[
20
- commonStyles.row,
21
- commonStyles.alignCenter,
22
- { paddingHorizontal: 16, height: 55 },
23
- ]}
24
- >
25
- <MButton
26
- //@ts-ignore
27
- onPress={() => {
28
- navigation.goBack();
29
- }}
30
- style={{
31
- width: 30,
32
- height: 55,
33
- justifyContent: 'center',
34
- alignItems: 'center',
35
- }}
36
- >
37
- <IconBack width={18} height={18} fill={'black'} />
38
- </MButton>
39
-
40
- <MText
41
- style={{
42
- marginRight: 30,
43
- fontSize: 16,
44
- paddingHorizontal: 4,
45
- color: color.headerColor,
46
- fontWeight: 'bold',
47
- textAlign: 'center',
48
- flex: 1,
49
- }}
50
- ></MText>
51
- </View>
52
25
  <View style={{ backgroundColor: color.border }} />
53
26
  <View style={{ flex: 1 }}>
54
27
  <Pdf
@@ -34,6 +34,7 @@ import Pdf from 'react-native-pdf';
34
34
  import Modal from 'react-native-modal';
35
35
  import KeyboardSpacer from '../../components/keyboardspace';
36
36
  import Loading from '../../components/Loading';
37
+ import MHeader from '../../components/MHeader';
37
38
 
38
39
  const webHookURL =
39
40
  'https://hooks.slack.com/services/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';
@@ -154,46 +155,14 @@ export const ESign = observer(function ESign(props: any) {
154
155
 
155
156
  return (
156
157
  <View style={{ flex: 1, backgroundColor: 'white' }}>
158
+ <MHeader
159
+ title="Ký hợp đồng"
160
+ onBack={() => {
161
+ back();
162
+ }}
163
+ />
157
164
  <SafeAreaView style={{ flex: 1 }}>
158
165
  <View style={{ flex: 1 }}>
159
- <View
160
- style={[
161
- commonStyles.row,
162
- commonStyles.alignCenter,
163
- { paddingHorizontal: 16, height: 55 },
164
- ]}
165
- >
166
- <MButton
167
- //@ts-ignore
168
- onPress={() => {
169
- back();
170
- }}
171
- style={{
172
- width: 30,
173
- height: 55,
174
- justifyContent: 'center',
175
- alignItems: 'center',
176
- }}
177
- >
178
- <IconBack width={18} height={18} fill={'black'} />
179
- </MButton>
180
-
181
- <MText
182
- style={{
183
- marginRight: 30,
184
- fontSize: 16,
185
- paddingHorizontal: 4,
186
- color: color.headerColor,
187
- fontWeight: 'bold',
188
- textAlign: 'center',
189
- flex: 1,
190
- }}
191
- >
192
- Ký hợp đồng
193
- </MText>
194
- </View>
195
- <View style={{ backgroundColor: color.border }} />
196
-
197
166
  <View style={{ flex: 1 }}>
198
167
  <Pdf
199
168
  source={{
@@ -12,6 +12,7 @@ import { commonStyles } from '../CommonStyles';
12
12
  import FullSubmitStore from './store';
13
13
  import { UpdateDocument } from './update-document';
14
14
  import { UpdateInfo } from './update-info';
15
+ import MHeader from '../../components/MHeader';
15
16
 
16
17
  export const FullSubmit = observer(function FullSubmit(props: any) {
17
18
  const navigation = useNavigation();
@@ -20,38 +21,14 @@ export const FullSubmit = observer(function FullSubmit(props: any) {
20
21
 
21
22
  return (
22
23
  <View style={{ flex: 1, backgroundColor: '#FFFFFF' }}>
24
+ <MHeader
25
+ title="Hoàn thiện hồ sơ"
26
+ onBack={() => {
27
+ navigation.goBack();
28
+ FullSubmitStore.tab = 1;
29
+ }}
30
+ />
23
31
  <SafeAreaView style={{ flex: 1 }}>
24
- <View
25
- style={[
26
- commonStyles.alignCenter,
27
- { alignItems: 'center', height: 50, justifyContent: 'center' },
28
- ]}
29
- >
30
- <TouchableOpacity
31
- onPress={() => {
32
- navigation.goBack();
33
- FullSubmitStore.tab = 1;
34
- }}
35
- style={{
36
- width: 40,
37
- height: 40,
38
- position: 'absolute',
39
- left: 8,
40
- alignItems: 'center',
41
- justifyContent: 'center',
42
- }}
43
- >
44
- <IconBack fill={color.textHeader} />
45
- </TouchableOpacity>
46
- <MText
47
- style={[
48
- commonStyles.textNormalBold,
49
- { color: color.textHeader, fontSize: 16 },
50
- ]}
51
- >
52
- Hoàn thiện hồ sơ
53
- </MText>
54
- </View>
55
32
  <View
56
33
  style={{
57
34
  flexDirection: 'row',
@@ -59,6 +36,7 @@ export const FullSubmit = observer(function FullSubmit(props: any) {
59
36
  borderColor: '#EF4123',
60
37
  borderRadius: 30,
61
38
  marginHorizontal: 16,
39
+ marginTop: 16,
62
40
  }}
63
41
  >
64
42
  <View
@@ -21,6 +21,7 @@ import { MText } from '../../components/MText';
21
21
  import { ScreenNames } from '../../navigation';
22
22
  import { commonStyles } from '../CommonStyles';
23
23
  import FullSubmitStore from './store';
24
+ import MHeader from '../../components/MHeader';
24
25
 
25
26
  const logoView: ImageStyle = {
26
27
  position: 'absolute',
@@ -75,35 +76,8 @@ export const CimbSelfie = observer(function CimbSelfie(props: any) {
75
76
  return (
76
77
  <View style={{ flex: 1 }}>
77
78
  <Image source={require('../../assets/img/EKYC.png')} style={logoView} />
79
+ <MHeader title="Xác thực khuôn mặt" onBack={() => navigation.goBack()} />
78
80
  <SafeAreaView style={commonStyles.fill}>
79
- <View
80
- style={[
81
- commonStyles.alignCenter,
82
- { alignItems: 'center', height: 50, justifyContent: 'center' },
83
- ]}
84
- >
85
- <TouchableOpacity
86
- onPress={() => navigation.goBack()}
87
- style={{
88
- width: 40,
89
- height: 40,
90
- position: 'absolute',
91
- left: 8,
92
- alignItems: 'center',
93
- justifyContent: 'center',
94
- }}
95
- >
96
- <IconBackWhite fill={'#FFFFFF'} />
97
- </TouchableOpacity>
98
- <MText
99
- style={[
100
- commonStyles.textNormalBold,
101
- { color: '#FFFFFF', fontSize: 16 },
102
- ]}
103
- >
104
- Xác thực khuôn mặt
105
- </MText>
106
- </View>
107
81
  <ScrollView style={commonStyles.fill}>
108
82
  <View style={{ paddingHorizontal: 16, paddingBottom: 16 }}>
109
83
  <Image