react-native-timacare 3.3.45 → 3.3.47
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.
- package/lib/commonjs/assets/svgs/question.svg +1 -7
- package/lib/commonjs/components/ItemTimaOneV3.js +1 -1
- package/lib/commonjs/components/ItemTimaOneV3.js.flow +29 -29
- package/lib/commonjs/components/ItemTimaOneV3.js.map +1 -1
- package/lib/commonjs/components/SkeletonLoanCard.js +1 -1
- package/lib/commonjs/components/SkeletonLoanCard.js.flow +58 -0
- package/lib/commonjs/components/SkeletonLoanCard.js.map +1 -1
- package/lib/commonjs/navigation/navigationRef.js +1 -1
- package/lib/commonjs/navigation/navigationRef.js.flow +65 -33
- package/lib/commonjs/navigation/navigationRef.js.map +1 -1
- package/lib/commonjs/navigation/primary-navigator.js +1 -1
- package/lib/commonjs/navigation/primary-navigator.js.flow +46 -7
- package/lib/commonjs/navigation/primary-navigator.js.map +1 -1
- package/lib/commonjs/screens/detail-loan-tima/InforLoan.js +2 -0
- package/lib/commonjs/screens/detail-loan-tima/InforLoan.js.flow +199 -0
- package/lib/commonjs/screens/detail-loan-tima/InforLoan.js.map +1 -0
- package/lib/commonjs/screens/detail-loan-tima/PaymentSchedule.js +2 -0
- package/lib/commonjs/screens/{detail-loan/DetailLoanTima.js.flow → detail-loan-tima/PaymentSchedule.js.flow} +107 -118
- package/lib/commonjs/screens/detail-loan-tima/PaymentSchedule.js.map +1 -0
- package/lib/commonjs/screens/detail-loan-tima/index.js +2 -0
- package/lib/commonjs/screens/detail-loan-tima/index.js.flow +109 -0
- package/lib/commonjs/screens/detail-loan-tima/index.js.map +1 -0
- package/lib/commonjs/screens/home/DigitalTopupItem.js +1 -1
- package/lib/commonjs/screens/home/DigitalTopupItem.js.flow +2 -2
- package/lib/commonjs/screens/home/DigitalTopupItem.js.map +1 -1
- package/lib/commonjs/screens/home/ItemMotoBikeLoan.js +1 -1
- package/lib/commonjs/screens/home/ItemMotoBikeLoan.js.flow +2 -2
- package/lib/commonjs/services/api/api.js +1 -1
- package/lib/commonjs/services/api/api.js.flow +33 -7
- package/lib/commonjs/services/api/api.js.map +1 -1
- package/lib/module/assets/svgs/question.svg +1 -7
- package/lib/module/components/ItemTimaOneV3.js +1 -1
- package/lib/module/components/ItemTimaOneV3.js.map +1 -1
- package/lib/module/components/SkeletonLoanCard.js +1 -1
- package/lib/module/components/SkeletonLoanCard.js.map +1 -1
- package/lib/module/navigation/navigationRef.js +1 -1
- package/lib/module/navigation/navigationRef.js.map +1 -1
- package/lib/module/navigation/primary-navigator.js +1 -1
- package/lib/module/navigation/primary-navigator.js.map +1 -1
- package/lib/module/screens/detail-loan-tima/InforLoan.js +2 -0
- package/lib/module/screens/detail-loan-tima/InforLoan.js.map +1 -0
- package/lib/module/screens/detail-loan-tima/PaymentSchedule.js +2 -0
- package/lib/module/screens/detail-loan-tima/PaymentSchedule.js.map +1 -0
- package/lib/module/screens/detail-loan-tima/index.js +2 -0
- package/lib/module/screens/detail-loan-tima/index.js.map +1 -0
- package/lib/module/screens/home/DigitalTopupItem.js +1 -1
- package/lib/module/screens/home/DigitalTopupItem.js.map +1 -1
- package/lib/module/screens/home/ItemMotoBikeLoan.js +1 -1
- package/lib/module/services/api/api.js +1 -1
- package/lib/module/services/api/api.js.map +1 -1
- package/lib/typescript/components/SkeletonLoanCard.d.ts +3 -0
- package/lib/typescript/components/SkeletonLoanCard.d.ts.map +1 -1
- package/lib/typescript/navigation/navigationRef.d.ts +47 -8
- package/lib/typescript/navigation/navigationRef.d.ts.map +1 -1
- package/lib/typescript/navigation/primary-navigator.d.ts +9 -2
- package/lib/typescript/navigation/primary-navigator.d.ts.map +1 -1
- package/lib/typescript/screens/detail-loan-tima/InforLoan.d.ts +4 -0
- package/lib/typescript/screens/detail-loan-tima/InforLoan.d.ts.map +1 -0
- package/lib/typescript/screens/detail-loan-tima/PaymentSchedule.d.ts +2 -0
- package/lib/typescript/screens/detail-loan-tima/PaymentSchedule.d.ts.map +1 -0
- package/lib/typescript/screens/detail-loan-tima/index.d.ts +2 -0
- package/lib/typescript/screens/detail-loan-tima/index.d.ts.map +1 -0
- package/lib/typescript/services/api/api.d.ts +16 -0
- package/lib/typescript/services/api/api.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/assets/svgs/question.svg +1 -7
- package/src/components/ItemTimaOneV3.tsx +29 -29
- package/src/components/SkeletonLoanCard.tsx +58 -0
- package/src/navigation/navigationRef.ts +65 -33
- package/src/navigation/primary-navigator.tsx +46 -7
- package/src/screens/detail-loan-tima/InforLoan.tsx +199 -0
- package/src/screens/{detail-loan/DetailLoanTima.tsx → detail-loan-tima/PaymentSchedule.tsx} +107 -118
- package/src/screens/detail-loan-tima/index.tsx +109 -0
- package/src/screens/home/DigitalTopupItem.tsx +2 -2
- package/src/screens/home/ItemMotoBikeLoan.tsx +2 -2
- package/src/services/api/api.ts +33 -7
- package/lib/commonjs/screens/detail-loan/DetailLoanTima.js +0 -2
- package/lib/commonjs/screens/detail-loan/DetailLoanTima.js.map +0 -1
- package/lib/module/screens/detail-loan/DetailLoanTima.js +0 -2
- package/lib/module/screens/detail-loan/DetailLoanTima.js.map +0 -1
- package/lib/typescript/screens/detail-loan/DetailLoanTima.d.ts +0 -2
- package/lib/typescript/screens/detail-loan/DetailLoanTima.d.ts.map +0 -1
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.default=InforLoan;var _regenerator=_interopRequireDefault(require("@babel/runtime/regenerator"));var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _react=_interopRequireWildcard(require("react"));var _reactNative=require("react-native");var _MText=require("../../components/MText");var _icons=require("../../assets/icons");var _utils=require("../../utils");var _api=require("../../services/api");var _theme=require("../../theme");var _SkeletonLoanCard=require("../../components/SkeletonLoanCard");var _this=this,_jsxFileName="/Users/tima/Tima/react-native-timacare/src/screens/detail-loan-tima/InforLoan.tsx";function _interopRequireWildcard(e,t){if("function"==typeof WeakMap)var r=new WeakMap(),n=new WeakMap();return(_interopRequireWildcard=function _interopRequireWildcard(e,t){if(!t&&e&&e.__esModule)return e;var o,i,f={__proto__:null,default:e};if(null===e||"object"!=typeof e&&"function"!=typeof e)return f;if(o=t?n:r){if(o.has(e))return o.get(e);o.set(e,f);}for(var _t2 in e)"default"!==_t2&&{}.hasOwnProperty.call(e,_t2)&&((i=(o=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,_t2))&&(i.get||i.set)?o(f,_t2,i):f[_t2]=e[_t2]);return f;})(e,t);}var cardStyle={backgroundColor:'#FFFFFF',borderRadius:12,borderWidth:1,borderColor:'#E0E0E0',marginHorizontal:16,paddingHorizontal:16,paddingVertical:8};var InfoRow=function InfoRow(_ref){var label=_ref.label,value=_ref.value,_ref$valueColor=_ref.valueColor,valueColor=_ref$valueColor===void 0?'#1A1A1A':_ref$valueColor;return _react.default.createElement(_reactNative.View,{style:{flexDirection:'row',alignItems:'center',justifyContent:'space-between',paddingVertical:12},__self:_this,__source:{fileName:_jsxFileName,lineNumber:23,columnNumber:3}},_react.default.createElement(_MText.MText,{style:{fontSize:14,color:'#4F4F4F'},__self:_this,__source:{fileName:_jsxFileName,lineNumber:31,columnNumber:5}},label),_react.default.createElement(_MText.MText,{style:{fontSize:14,fontWeight:'600',fontFamily:'BeVietnamPro-SemiBold',color:valueColor},__self:_this,__source:{fileName:_jsxFileName,lineNumber:32,columnNumber:5}},value));};function InforLoan(_ref2){var _data$schedules,_this2=this;var id=_ref2.id;var _useState=(0,_react.useState)(false),_useState2=(0,_slicedToArray2.default)(_useState,2),isLoading=_useState2[0],setIsLoading=_useState2[1];var _useState3=(0,_react.useState)(),_useState4=(0,_slicedToArray2.default)(_useState3,2),data=_useState4[0],setData=_useState4[1];var _useState5=(0,_react.useState)(false),_useState6=(0,_slicedToArray2.default)(_useState5,2),expanded=_useState6[0],setExpanded=_useState6[1];var getData=function _callee(){var response,_response$data,_response$data$meta,_response$data2,_response$data3,_response$data3$meta,_t;return _regenerator.default.async(function(_context){while(1)switch(_context.prev=_context.next){case 0:_context.prev=0;setIsLoading(true);_context.next=1;return _regenerator.default.awrap(_api.Api.getInstance().get_detail_loan_tima(id));case 1:response=_context.sent;if(response.kind==='ok'){if(((_response$data=response.data)==null?void 0:(_response$data$meta=_response$data.meta)==null?void 0:_response$data$meta.errorCode)===200){setData((_response$data2=response.data)==null?void 0:_response$data2.data);}else{_reactNative.Alert.alert('Thông báo',response==null?void 0:(_response$data3=response.data)==null?void 0:(_response$data3$meta=_response$data3.meta)==null?void 0:_response$data3$meta.errorMessage);}}else{_reactNative.Alert.alert('Thông báo','Có lỗi xảy ra. Vui lòng thử lại sau');}_context.next=3;break;case 2:_context.prev=2;_t=_context["catch"](0);_reactNative.Alert.alert('Thông báo','Có lỗi xảy ra. Vui lòng thử lại sau');case 3:_context.prev=3;setIsLoading(false);return _context.finish(3);case 4:case"end":return _context.stop();}},null,null,[[0,2,3,4]],Promise);};(0,_react.useEffect)(function(){getData();},[]);if(isLoading&&!data){return _react.default.createElement(_reactNative.ScrollView,{style:{flex:1,paddingTop:16},__self:this,__source:{fileName:_jsxFileName,lineNumber:76,columnNumber:7}},_react.default.createElement(_SkeletonLoanCard.SkeletonDisbursedList,{count:2,__self:this,__source:{fileName:_jsxFileName,lineNumber:77,columnNumber:9}}));}return _react.default.createElement(_reactNative.ScrollView,{style:{flex:1},contentContainerStyle:{paddingVertical:16},__self:this,__source:{fileName:_jsxFileName,lineNumber:83,columnNumber:5}},_react.default.createElement(_reactNative.View,{style:cardStyle,__self:this,__source:{fileName:_jsxFileName,lineNumber:88,columnNumber:7}},_react.default.createElement(InfoRow,{label:"M\xE3 H\u0110 gi\u1EA3i ng\xE2n",value:(data==null?void 0:data.contractCode)||'',__self:this,__source:{fileName:_jsxFileName,lineNumber:89,columnNumber:9}}),_react.default.createElement(InfoRow,{label:"S\u1ED1 ti\u1EC1n gi\u1EA3i ng\xE2n",value:(0,_utils.formatMoney)((data==null?void 0:data.totalMoneyDisbursement)||0)+" \u0111",__self:this,__source:{fileName:_jsxFileName,lineNumber:90,columnNumber:9}}),_react.default.createElement(InfoRow,{label:"Th\u1EDDi h\u1EA1n",value:data!=null&&data.loanTime?(data==null?void 0:data.loanTime)+" th\xE1ng":'',__self:this,__source:{fileName:_jsxFileName,lineNumber:94,columnNumber:9}}),_react.default.createElement(InfoRow,{label:"Ng\xE0y gi\u1EA3i ng\xE2n",value:data!=null&&data.fromDate?(0,_utils.formatDDMMYYY)(data==null?void 0:data.fromDate):'',__self:this,__source:{fileName:_jsxFileName,lineNumber:98,columnNumber:9}}),_react.default.createElement(InfoRow,{label:"Ng\xE0y \u0111\u1EBFn h\u1EA1n ti\u1EBFp theo",value:data!=null&&data.nextDate?(0,_utils.formatDDMMYYY)(data==null?void 0:data.nextDate):'',__self:this,__source:{fileName:_jsxFileName,lineNumber:102,columnNumber:9}}),_react.default.createElement(InfoRow,{label:"Tr\u1EA1ng th\xE1i H\u1EE3p \u0111\u1ED3ng",value:(data==null?void 0:data.statusName)||'',__self:this,__source:{fileName:_jsxFileName,lineNumber:106,columnNumber:9}})),_react.default.createElement(_reactNative.View,{style:[{marginTop:16,marginHorizontal:16,paddingHorizontal:16,paddingVertical:8,borderRadius:12,borderWidth:1,borderColor:'#E0E0E0'}],__self:this,__source:{fileName:_jsxFileName,lineNumber:110,columnNumber:7}},_react.default.createElement(_reactNative.TouchableOpacity,{activeOpacity:0.8,onPress:function onPress(){return setExpanded(function(prev){return!prev;});},style:{flexDirection:'row',alignItems:'center',justifyContent:'space-between',paddingVertical:12},__self:this,__source:{fileName:_jsxFileName,lineNumber:123,columnNumber:9}},_react.default.createElement(_MText.MText,{style:{fontSize:14,color:'#4F4F4F'},__self:this,__source:{fileName:_jsxFileName,lineNumber:133,columnNumber:11}},"T\u1ED5ng ph\u1EA3i tr\u1EA3"),_react.default.createElement(_reactNative.View,{style:{flexDirection:'row',alignItems:'center'},__self:this,__source:{fileName:_jsxFileName,lineNumber:136,columnNumber:11}},_react.default.createElement(_MText.MText,{style:{fontSize:14,fontWeight:'600',fontFamily:'BeVietnamPro-SemiBold',color:_theme.color.primary,marginRight:8},__self:this,__source:{fileName:_jsxFileName,lineNumber:137,columnNumber:13}},(0,_utils.formatMoney)((data==null?void 0:data.totalMoneyNeedPay)||0)," \u0111"),_react.default.createElement(_reactNative.View,{style:{transform:[{rotate:expanded?'180deg':'0deg'}]},__self:this,__source:{fileName:_jsxFileName,lineNumber:148,columnNumber:13}},_react.default.createElement(_icons.IconArrowDown,{width:14,height:14,fill:"#828282",__self:this,__source:{fileName:_jsxFileName,lineNumber:153,columnNumber:15}})))),expanded&&(data==null?void 0:(_data$schedules=data.schedules)==null?void 0:_data$schedules.map(function(item,index){return _react.default.createElement(_reactNative.View,{key:(item==null?void 0:item.paymentScheduleID)||index,style:{flexDirection:'row',alignItems:'center',justifyContent:'space-between',paddingVertical:8,paddingHorizontal:24},__self:_this2,__source:{fileName:_jsxFileName,lineNumber:160,columnNumber:13}},_react.default.createElement(_MText.MText,{style:{fontSize:13,color:'#828282'},__self:_this2,__source:{fileName:_jsxFileName,lineNumber:170,columnNumber:15}},(0,_utils.formatDDMMYYY)(item==null?void 0:item.payDate)),_react.default.createElement(_MText.MText,{style:{fontSize:13,color:'#828282'},__self:_this2,__source:{fileName:_jsxFileName,lineNumber:173,columnNumber:15}},(0,_utils.formatMoney)((item==null?void 0:item.moneyNeedPay)||0)," \u0111"));})),expanded&&_react.default.createElement(_reactNative.View,{style:{height:1,backgroundColor:'#E0E0E0'},__self:this,__source:{fileName:_jsxFileName,lineNumber:184,columnNumber:11}}),_react.default.createElement(InfoRow,{label:"Tr\u1EA1ng th\xE1i",value:(data==null?void 0:data.paymentStatusName)||'',valueColor:data!=null&&data.isPaid?'#27AE60':_theme.color.primary,__self:this,__source:{fileName:_jsxFileName,lineNumber:191,columnNumber:9}})));}
|
|
2
|
+
//# sourceMappingURL=InforLoan.js.map
|
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
//@ts-nocheck
|
|
2
|
+
import React, { useEffect, useState } from 'react';
|
|
3
|
+
import { Alert, ScrollView, TouchableOpacity, View } from 'react-native';
|
|
4
|
+
import { MText } from '../../components/MText';
|
|
5
|
+
import { IconArrowDown } from '../../assets/icons';
|
|
6
|
+
import { formatDDMMYYY, formatMoney } from '../../utils';
|
|
7
|
+
import { Api } from '../../services/api';
|
|
8
|
+
import { color } from '../../theme';
|
|
9
|
+
import { SkeletonDisbursedList } from '../../components/SkeletonLoanCard';
|
|
10
|
+
|
|
11
|
+
const cardStyle = {
|
|
12
|
+
backgroundColor: '#FFFFFF',
|
|
13
|
+
borderRadius: 12,
|
|
14
|
+
borderWidth: 1,
|
|
15
|
+
borderColor: '#E0E0E0',
|
|
16
|
+
marginHorizontal: 16,
|
|
17
|
+
paddingHorizontal: 16,
|
|
18
|
+
paddingVertical: 8,
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
// Một dòng "Nhãn ... Giá trị" trong thẻ thông tin
|
|
22
|
+
const InfoRow = ({ label, value, valueColor = '#1A1A1A' }) => (
|
|
23
|
+
<View
|
|
24
|
+
style={{
|
|
25
|
+
flexDirection: 'row',
|
|
26
|
+
alignItems: 'center',
|
|
27
|
+
justifyContent: 'space-between',
|
|
28
|
+
paddingVertical: 12,
|
|
29
|
+
}}
|
|
30
|
+
>
|
|
31
|
+
<MText style={{ fontSize: 14, color: '#4F4F4F' }}>{label}</MText>
|
|
32
|
+
<MText
|
|
33
|
+
style={{
|
|
34
|
+
fontSize: 14,
|
|
35
|
+
fontWeight: '600',
|
|
36
|
+
fontFamily: 'BeVietnamPro-SemiBold',
|
|
37
|
+
color: valueColor,
|
|
38
|
+
}}
|
|
39
|
+
>
|
|
40
|
+
{value}
|
|
41
|
+
</MText>
|
|
42
|
+
</View>
|
|
43
|
+
);
|
|
44
|
+
|
|
45
|
+
export default function InforLoan({ id }: { id: number }) {
|
|
46
|
+
const [isLoading, setIsLoading] = useState(false);
|
|
47
|
+
const [data, setData] = useState<any>();
|
|
48
|
+
const [expanded, setExpanded] = useState(false);
|
|
49
|
+
|
|
50
|
+
const getData = async () => {
|
|
51
|
+
try {
|
|
52
|
+
setIsLoading(true);
|
|
53
|
+
const response = await Api.getInstance().get_detail_loan_tima(id);
|
|
54
|
+
if (response.kind === 'ok') {
|
|
55
|
+
if (response.data?.meta?.errorCode === 200) {
|
|
56
|
+
setData(response.data?.data);
|
|
57
|
+
} else {
|
|
58
|
+
Alert.alert('Thông báo', response?.data?.meta?.errorMessage);
|
|
59
|
+
}
|
|
60
|
+
} else {
|
|
61
|
+
Alert.alert('Thông báo', 'Có lỗi xảy ra. Vui lòng thử lại sau');
|
|
62
|
+
}
|
|
63
|
+
} catch (error) {
|
|
64
|
+
Alert.alert('Thông báo', 'Có lỗi xảy ra. Vui lòng thử lại sau');
|
|
65
|
+
} finally {
|
|
66
|
+
setIsLoading(false);
|
|
67
|
+
}
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
useEffect(() => {
|
|
71
|
+
getData();
|
|
72
|
+
}, []);
|
|
73
|
+
|
|
74
|
+
if (isLoading && !data) {
|
|
75
|
+
return (
|
|
76
|
+
<ScrollView style={{ flex: 1, paddingTop: 16 }}>
|
|
77
|
+
<SkeletonDisbursedList count={2} />
|
|
78
|
+
</ScrollView>
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
return (
|
|
83
|
+
<ScrollView
|
|
84
|
+
style={{ flex: 1 }}
|
|
85
|
+
contentContainerStyle={{ paddingVertical: 16 }}
|
|
86
|
+
>
|
|
87
|
+
{/* Thẻ thông tin hợp đồng giải ngân */}
|
|
88
|
+
<View style={cardStyle}>
|
|
89
|
+
<InfoRow label="Mã HĐ giải ngân" value={data?.contractCode || ''} />
|
|
90
|
+
<InfoRow
|
|
91
|
+
label="Số tiền giải ngân"
|
|
92
|
+
value={`${formatMoney(data?.totalMoneyDisbursement || 0)} đ`}
|
|
93
|
+
/>
|
|
94
|
+
<InfoRow
|
|
95
|
+
label="Thời hạn"
|
|
96
|
+
value={data?.loanTime ? `${data?.loanTime} tháng` : ''}
|
|
97
|
+
/>
|
|
98
|
+
<InfoRow
|
|
99
|
+
label="Ngày giải ngân"
|
|
100
|
+
value={data?.fromDate ? formatDDMMYYY(data?.fromDate) : ''}
|
|
101
|
+
/>
|
|
102
|
+
<InfoRow
|
|
103
|
+
label="Ngày đến hạn tiếp theo"
|
|
104
|
+
value={data?.nextDate ? formatDDMMYYY(data?.nextDate) : ''}
|
|
105
|
+
/>
|
|
106
|
+
<InfoRow label="Trạng thái Hợp đồng" value={data?.statusName || ''} />
|
|
107
|
+
</View>
|
|
108
|
+
|
|
109
|
+
{/* Thẻ tổng phải trả + trạng thái thanh toán */}
|
|
110
|
+
<View
|
|
111
|
+
style={[
|
|
112
|
+
{
|
|
113
|
+
marginTop: 16,
|
|
114
|
+
marginHorizontal: 16,
|
|
115
|
+
paddingHorizontal: 16,
|
|
116
|
+
paddingVertical: 8,
|
|
117
|
+
borderRadius: 12,
|
|
118
|
+
borderWidth: 1,
|
|
119
|
+
borderColor: '#E0E0E0',
|
|
120
|
+
},
|
|
121
|
+
]}
|
|
122
|
+
>
|
|
123
|
+
<TouchableOpacity
|
|
124
|
+
activeOpacity={0.8}
|
|
125
|
+
onPress={() => setExpanded((prev) => !prev)}
|
|
126
|
+
style={{
|
|
127
|
+
flexDirection: 'row',
|
|
128
|
+
alignItems: 'center',
|
|
129
|
+
justifyContent: 'space-between',
|
|
130
|
+
paddingVertical: 12,
|
|
131
|
+
}}
|
|
132
|
+
>
|
|
133
|
+
<MText style={{ fontSize: 14, color: '#4F4F4F' }}>
|
|
134
|
+
Tổng phải trả
|
|
135
|
+
</MText>
|
|
136
|
+
<View style={{ flexDirection: 'row', alignItems: 'center' }}>
|
|
137
|
+
<MText
|
|
138
|
+
style={{
|
|
139
|
+
fontSize: 14,
|
|
140
|
+
fontWeight: '600',
|
|
141
|
+
fontFamily: 'BeVietnamPro-SemiBold',
|
|
142
|
+
color: color.primary,
|
|
143
|
+
marginRight: 8,
|
|
144
|
+
}}
|
|
145
|
+
>
|
|
146
|
+
{formatMoney(data?.totalMoneyNeedPay || 0)} đ
|
|
147
|
+
</MText>
|
|
148
|
+
<View
|
|
149
|
+
style={{
|
|
150
|
+
transform: [{ rotate: expanded ? '180deg' : '0deg' }],
|
|
151
|
+
}}
|
|
152
|
+
>
|
|
153
|
+
<IconArrowDown width={14} height={14} fill="#828282" />
|
|
154
|
+
</View>
|
|
155
|
+
</View>
|
|
156
|
+
</TouchableOpacity>
|
|
157
|
+
{/* Chi tiết kỳ thanh toán khi mở rộng */}
|
|
158
|
+
{expanded &&
|
|
159
|
+
data?.schedules?.map((item, index) => (
|
|
160
|
+
<View
|
|
161
|
+
key={item?.paymentScheduleID || index}
|
|
162
|
+
style={{
|
|
163
|
+
flexDirection: 'row',
|
|
164
|
+
alignItems: 'center',
|
|
165
|
+
justifyContent: 'space-between',
|
|
166
|
+
paddingVertical: 8,
|
|
167
|
+
paddingHorizontal: 24,
|
|
168
|
+
}}
|
|
169
|
+
>
|
|
170
|
+
<MText style={{ fontSize: 13, color: '#828282' }}>
|
|
171
|
+
{formatDDMMYYY(item?.payDate)}
|
|
172
|
+
</MText>
|
|
173
|
+
<MText
|
|
174
|
+
style={{
|
|
175
|
+
fontSize: 13,
|
|
176
|
+
color: '#828282',
|
|
177
|
+
}}
|
|
178
|
+
>
|
|
179
|
+
{formatMoney(item?.moneyNeedPay || 0)} đ
|
|
180
|
+
</MText>
|
|
181
|
+
</View>
|
|
182
|
+
))}
|
|
183
|
+
{expanded && (
|
|
184
|
+
<View
|
|
185
|
+
style={{
|
|
186
|
+
height: 1,
|
|
187
|
+
backgroundColor: '#E0E0E0',
|
|
188
|
+
}}
|
|
189
|
+
/>
|
|
190
|
+
)}
|
|
191
|
+
<InfoRow
|
|
192
|
+
label="Trạng thái"
|
|
193
|
+
value={data?.paymentStatusName || ''}
|
|
194
|
+
valueColor={data?.isPaid ? '#27AE60' : color.primary}
|
|
195
|
+
/>
|
|
196
|
+
</View>
|
|
197
|
+
</ScrollView>
|
|
198
|
+
);
|
|
199
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_MText","_icons","_utils","_api","_theme","_SkeletonLoanCard","_this","_jsxFileName","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","_t2","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","cardStyle","backgroundColor","borderRadius","borderWidth","borderColor","marginHorizontal","paddingHorizontal","paddingVertical","InfoRow","_ref","label","value","_ref$valueColor","valueColor","createElement","View","style","flexDirection","alignItems","justifyContent","__self","__source","fileName","lineNumber","columnNumber","MText","fontSize","color","fontWeight","fontFamily","InforLoan","_ref2","_data$schedules","_this2","id","_useState","useState","_useState2","_slicedToArray2","isLoading","setIsLoading","_useState3","_useState4","data","setData","_useState5","_useState6","expanded","setExpanded","getData","_callee","response","_response$data","_response$data$meta","_response$data2","_response$data3","_response$data3$meta","_t","_regenerator","async","_context","prev","next","awrap","Api","getInstance","get_detail_loan_tima","sent","kind","meta","errorCode","Alert","alert","errorMessage","finish","stop","Promise","useEffect","ScrollView","flex","paddingTop","SkeletonDisbursedList","count","contentContainerStyle","contractCode","formatMoney","totalMoneyDisbursement","loanTime","fromDate","formatDDMMYYY","nextDate","statusName","marginTop","TouchableOpacity","activeOpacity","onPress","primary","marginRight","totalMoneyNeedPay","transform","rotate","IconArrowDown","width","height","fill","schedules","map","item","index","key","paymentScheduleID","payDate","moneyNeedPay","paymentStatusName","isPaid"],"sourceRoot":"../../../../src","sources":["screens/detail-loan-tima/InforLoan.tsx"],"mappings":"iVACA,IAAAA,MAAA,CAAAC,uBAAA,CAAAC,OAAA,WACA,IAAAC,YAAA,CAAAD,OAAA,iBACA,IAAAE,MAAA,CAAAF,OAAA,2BACA,IAAAG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E,MAAM,CAAG,SAAS,CAAGvF,YAAK,CAACqE,OAAQ,CAAA5E,MAAA,MAAAC,QAAA,EAAAC,QAAA,CAAA3C,YAAA,CAAA4C,UAAA,KAAAC,YAAA,IACtD,CACG,CACI,CAAC,CAEjB","ignoreList":[]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.PaymentSchedule=void 0;var _regenerator=_interopRequireDefault(require("@babel/runtime/regenerator"));var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _react=_interopRequireWildcard(require("react"));var _mobxReactLite=require("mobx-react-lite");var _native=require("@react-navigation/native");var _reactNative=require("react-native");var _MText=require("../../components/MText");var _utils=require("../../utils");var _api=require("../../services/api");var _theme=require("../../theme");var _SkeletonLoanCard=require("../../components/SkeletonLoanCard");var _reactNativeSafeAreaContext=require("react-native-safe-area-context");var _jsxFileName="/Users/tima/Tima/react-native-timacare/src/screens/detail-loan-tima/PaymentSchedule.tsx";function _interopRequireWildcard(e,t){if("function"==typeof WeakMap)var r=new WeakMap(),n=new WeakMap();return(_interopRequireWildcard=function _interopRequireWildcard(e,t){if(!t&&e&&e.__esModule)return e;var o,i,f={__proto__:null,default:e};if(null===e||"object"!=typeof e&&"function"!=typeof e)return f;if(o=t?n:r){if(o.has(e))return o.get(e);o.set(e,f);}for(var _t2 in e)"default"!==_t2&&{}.hasOwnProperty.call(e,_t2)&&((i=(o=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,_t2))&&(i.get||i.set)?o(f,_t2,i):f[_t2]=e[_t2]);return f;})(e,t);}var PaymentSchedule=exports.PaymentSchedule=(0,_mobxReactLite.observer)(function PaymentSchedule(_ref){var _data$paymentSchedule,_this=this;var id=_ref.id;var insets=(0,_reactNativeSafeAreaContext.useSafeAreaInsets)();var navigation=(0,_native.useNavigation)();var _useState=(0,_react.useState)(false),_useState2=(0,_slicedToArray2.default)(_useState,2),isLoading=_useState2[0],setIsLoading=_useState2[1];var _useState3=(0,_react.useState)(),_useState4=(0,_slicedToArray2.default)(_useState3,2),data=_useState4[0],setData=_useState4[1];var _useState5=(0,_react.useState)(0),_useState6=(0,_slicedToArray2.default)(_useState5,2),moneyCloseLoan=_useState6[0],setMoneyCloseLoan=_useState6[1];var getData=function _callee(){return _regenerator.default.async(function(_context){while(1)switch(_context.prev=_context.next){case 0:setIsLoading(true);_api.Api.getInstance().getPaymentScheduleTima(id).then(function(response){setIsLoading(false);if(response.kind==='ok'){if(response.data.meta.errorCode===200){var _response$data;setData((_response$data=response.data)==null?void 0:_response$data.data);}else{var _response$data2,_response$data2$meta;_reactNative.Alert.alert('Thông báo',response==null?void 0:(_response$data2=response.data)==null?void 0:(_response$data2$meta=_response$data2.meta)==null?void 0:_response$data2$meta.errorMessage);}}else{_reactNative.Alert.alert('Thông báo','Có lỗi xảy ra. Vui lòng thử lại sau');}}).catch(function(err){setIsLoading(false);_reactNative.Alert.alert('Thông báo','Có lỗi xảy ra. Vui lòng thử lại sau');});case 1:case"end":return _context.stop();}},null,null,null,Promise);};var getMoneyCloseLoan=function _callee2(){var response,_response$data3,_response$data3$data,_t;return _regenerator.default.async(function(_context2){while(1)switch(_context2.prev=_context2.next){case 0:_context2.prev=0;setIsLoading(true);_context2.next=1;return _regenerator.default.awrap(_api.Api.getInstance().getMoneyCloseLoan(id));case 1:response=_context2.sent;if(response.kind==='ok'&&response.data.meta.errorCode===200){setMoneyCloseLoan((_response$data3=response.data)==null?void 0:(_response$data3$data=_response$data3.data)==null?void 0:_response$data3$data.totalMoneyCloseLoan);}else{}_context2.next=3;break;case 2:_context2.prev=2;_t=_context2["catch"](0);case 3:_context2.prev=3;setIsLoading(false);return _context2.finish(3);case 4:case"end":return _context2.stop();}},null,null,[[0,2,3,4]],Promise);};(0,_react.useEffect)(function(){getData();getMoneyCloseLoan();},[]);return _react.default.createElement(_reactNative.View,{style:{flex:1,backgroundColor:'#FDFDFD'},__self:this,__source:{fileName:_jsxFileName,lineNumber:75,columnNumber:5}},_react.default.createElement(_reactNative.View,{style:{flex:1},__self:this,__source:{fileName:_jsxFileName,lineNumber:76,columnNumber:7}},_react.default.createElement(_reactNative.View,{style:{backgroundColor:'#ECFFE8',flexDirection:'row',alignItems:'center',paddingHorizontal:16,paddingVertical:8,justifyContent:'space-between',marginTop:16},__self:this,__source:{fileName:_jsxFileName,lineNumber:77,columnNumber:9}},_react.default.createElement(_MText.MText,{style:{fontSize:12},__self:this,__source:{fileName:_jsxFileName,lineNumber:88,columnNumber:11}},"M\xE3 H\u0110 gi\u1EA3i ng\xE2n"),_react.default.createElement(_MText.MText,{style:{fontSize:12,fontWeight:'600',fontFamily:'BeVietnamPro-SemiBold'},__self:this,__source:{fileName:_jsxFileName,lineNumber:95,columnNumber:11}},"TC-",data==null?void 0:data.codeId)),_react.default.createElement(_reactNative.View,{style:{flexDirection:'row',alignItems:'center',paddingHorizontal:16,backgroundColor:'#FFF3E9',paddingVertical:16},__self:this,__source:{fileName:_jsxFileName,lineNumber:105,columnNumber:9}},_react.default.createElement(_MText.MText,{style:{color:'black',fontWeight:'600',width:'35%',fontFamily:'BeVietnamPro-SemiBold'},__self:this,__source:{fileName:_jsxFileName,lineNumber:114,columnNumber:11}},"Ng\xE0y thanh to\xE1n"),_react.default.createElement(_MText.MText,{style:{color:'black',fontWeight:'600',width:'40%',textAlign:'center',fontFamily:'BeVietnamPro-SemiBold'},__self:this,__source:{fileName:_jsxFileName,lineNumber:124,columnNumber:11}},"S\u1ED1 ti\u1EC1n thanh to\xE1n")),isLoading&&!data?_react.default.createElement(_SkeletonLoanCard.SkeletonPaymentScheduleList,{__self:this,__source:{fileName:_jsxFileName,lineNumber:137,columnNumber:11}}):_react.default.createElement(_reactNative.ScrollView,{style:{flex:1,paddingHorizontal:16},__self:this,__source:{fileName:_jsxFileName,lineNumber:139,columnNumber:11}},data==null?void 0:(_data$paymentSchedule=data.paymentSchedule)==null?void 0:_data$paymentSchedule.map(function(item,index){return _react.default.createElement(_reactNative.View,{key:index,style:{flexDirection:'row',paddingVertical:16,borderBottomWidth:1,borderColor:_theme.color.border},__self:_this,__source:{fileName:_jsxFileName,lineNumber:141,columnNumber:15}},_react.default.createElement(_MText.MText,{style:[{width:'35%'}],__self:_this,__source:{fileName:_jsxFileName,lineNumber:150,columnNumber:17}},item!=null&&item.daysPayable?(0,_utils.formatDDMMYYY)(item==null?void 0:item.daysPayable):''),_react.default.createElement(_reactNative.View,{style:{width:'40%',alignItems:'center'},__self:_this,__source:{fileName:_jsxFileName,lineNumber:159,columnNumber:17}},_react.default.createElement(_MText.MText,{__self:_this,__source:{fileName:_jsxFileName,lineNumber:165,columnNumber:19}},(0,_utils.formatMoney)(item==null?void 0:item.payMoney)," \u0111"),_react.default.createElement(_MText.MText,{style:[{color:!(item!=null&&item.done)?'#EB5757':'#27AE60',marginTop:4,fontSize:12}],__self:_this,__source:{fileName:_jsxFileName,lineNumber:166,columnNumber:19}},!(item!=null&&item.done)?'Chưa thanh toán':'Đã thanh toán')),_react.default.createElement(_reactNative.View,{style:{flexDirection:'row',justifyContent:'flex-end'},__self:_this,__source:{fileName:_jsxFileName,lineNumber:179,columnNumber:17}},!(item!=null&&item.done)&&_react.default.createElement(_reactNative.TouchableOpacity,{disabled:item==null?void 0:item.done,style:{borderRadius:24,height:30,paddingHorizontal:8,alignItems:'center',justifyContent:'center',borderWidth:1,borderColor:!(item!=null&&item.done)?_theme.color.primary:'#333333'},onPress:function onPress(){return navigation.navigate('ShowQrCode',{item:item,data:data,id:id});},__self:_this,__source:{fileName:_jsxFileName,lineNumber:186,columnNumber:21}},_react.default.createElement(_MText.MText,{style:{color:!(item!=null&&item.done)?_theme.color.primary:'#333333',fontSize:12},__self:_this,__source:{fileName:_jsxFileName,lineNumber:205,columnNumber:23}},"Thanh to\xE1n"))));}),_react.default.createElement(_reactNative.TouchableOpacity,{onPress:function onPress(){return navigation.navigate('ShowQrCode',{data:data,id:id,isFullPayment:true,totalMoney:moneyCloseLoan});},style:{backgroundColor:'#FFEAD8',marginTop:24,borderRadius:24,height:40,alignItems:'center',justifyContent:'center',borderWidth:1,borderColor:'#F05123',marginBottom:insets.bottom+24},__self:this,__source:{fileName:_jsxFileName,lineNumber:218,columnNumber:13}},_react.default.createElement(_MText.MText,{style:{color:'#F05123',fontWeight:'500',fontFamily:'BeVietnamPro-Medium'},__self:this,__source:{fileName:_jsxFileName,lineNumber:239,columnNumber:15}},"Xem th\xF4ng tin t\u1EA5t to\xE1n")))));});var $backButton={position:'absolute',left:16};var $header={flexDirection:'row',alignItems:'center',paddingVertical:16,justifyContent:'center'};
|
|
2
|
+
//# sourceMappingURL=PaymentSchedule.js.map
|
|
@@ -15,11 +15,15 @@ import { formatDDMMYYY, formatMoney } from '../../utils';
|
|
|
15
15
|
import { Api } from '../../services/api';
|
|
16
16
|
import { color } from '../../theme';
|
|
17
17
|
import { commonStyles } from '../CommonStyles';
|
|
18
|
-
import
|
|
18
|
+
import { SkeletonPaymentScheduleList } from '../../components/SkeletonLoanCard';
|
|
19
19
|
import MHeader from '../../components/MHeader';
|
|
20
20
|
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
21
21
|
|
|
22
|
-
export const
|
|
22
|
+
export const PaymentSchedule = observer(function PaymentSchedule({
|
|
23
|
+
id,
|
|
24
|
+
}: {
|
|
25
|
+
id: number;
|
|
26
|
+
}) {
|
|
23
27
|
const insets = useSafeAreaInsets();
|
|
24
28
|
const navigation = useNavigation();
|
|
25
29
|
const [isLoading, setIsLoading] = useState(false);
|
|
@@ -29,7 +33,7 @@ export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
|
|
|
29
33
|
const getData = async () => {
|
|
30
34
|
setIsLoading(true);
|
|
31
35
|
Api.getInstance()
|
|
32
|
-
.getPaymentScheduleTima(
|
|
36
|
+
.getPaymentScheduleTima(id)
|
|
33
37
|
.then((response) => {
|
|
34
38
|
setIsLoading(false);
|
|
35
39
|
if (response.kind === 'ok') {
|
|
@@ -51,9 +55,7 @@ export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
|
|
|
51
55
|
const getMoneyCloseLoan = async () => {
|
|
52
56
|
try {
|
|
53
57
|
setIsLoading(true);
|
|
54
|
-
const response = await Api.getInstance().getMoneyCloseLoan(
|
|
55
|
-
props.route?.params?.loan?.id
|
|
56
|
-
);
|
|
58
|
+
const response = await Api.getInstance().getMoneyCloseLoan(id);
|
|
57
59
|
if (response.kind === 'ok' && response.data.meta.errorCode === 200) {
|
|
58
60
|
setMoneyCloseLoan(response.data?.data?.totalMoneyCloseLoan);
|
|
59
61
|
} else {
|
|
@@ -71,25 +73,7 @@ export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
|
|
|
71
73
|
|
|
72
74
|
return (
|
|
73
75
|
<View style={{ flex: 1, backgroundColor: '#FDFDFD' }}>
|
|
74
|
-
<MHeader title={`Vay trực tuyến 24/7`} />
|
|
75
76
|
<View style={{ flex: 1 }}>
|
|
76
|
-
<View style={$header}>
|
|
77
|
-
<TouchableOpacity
|
|
78
|
-
style={$backButton}
|
|
79
|
-
onPress={() => navigation.goBack()}
|
|
80
|
-
>
|
|
81
|
-
<IconBack />
|
|
82
|
-
</TouchableOpacity>
|
|
83
|
-
<MText
|
|
84
|
-
style={{
|
|
85
|
-
fontSize: 16,
|
|
86
|
-
fontWeight: '600',
|
|
87
|
-
fontFamily: 'BeVietnamPro-SemiBold',
|
|
88
|
-
}}
|
|
89
|
-
>
|
|
90
|
-
HD-{props.route?.params?.loan?.id}
|
|
91
|
-
</MText>
|
|
92
|
-
</View>
|
|
93
77
|
<View
|
|
94
78
|
style={{
|
|
95
79
|
backgroundColor: '#ECFFE8',
|
|
@@ -98,6 +82,7 @@ export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
|
|
|
98
82
|
paddingHorizontal: 16,
|
|
99
83
|
paddingVertical: 8,
|
|
100
84
|
justifyContent: 'space-between',
|
|
85
|
+
marginTop: 16,
|
|
101
86
|
}}
|
|
102
87
|
>
|
|
103
88
|
<MText
|
|
@@ -122,7 +107,8 @@ export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
|
|
|
122
107
|
flexDirection: 'row',
|
|
123
108
|
alignItems: 'center',
|
|
124
109
|
paddingHorizontal: 16,
|
|
125
|
-
|
|
110
|
+
backgroundColor: '#FFF3E9',
|
|
111
|
+
paddingVertical: 16,
|
|
126
112
|
}}
|
|
127
113
|
>
|
|
128
114
|
<MText
|
|
@@ -147,118 +133,121 @@ export const DetailLoanTima = observer(function DetailLoanTima(props: any) {
|
|
|
147
133
|
Số tiền thanh toán
|
|
148
134
|
</MText>
|
|
149
135
|
</View>
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
flexDirection: 'row',
|
|
156
|
-
paddingVertical: 16,
|
|
157
|
-
borderBottomWidth: 1,
|
|
158
|
-
borderColor: color.border,
|
|
159
|
-
}}
|
|
160
|
-
>
|
|
161
|
-
<MText
|
|
162
|
-
style={[
|
|
163
|
-
{
|
|
164
|
-
width: '35%',
|
|
165
|
-
},
|
|
166
|
-
]}
|
|
167
|
-
>
|
|
168
|
-
{item?.daysPayable ? formatDDMMYYY(item?.daysPayable) : ''}
|
|
169
|
-
</MText>
|
|
136
|
+
{isLoading && !data ? (
|
|
137
|
+
<SkeletonPaymentScheduleList />
|
|
138
|
+
) : (
|
|
139
|
+
<ScrollView style={{ flex: 1, paddingHorizontal: 16 }}>
|
|
140
|
+
{data?.paymentSchedule?.map((item, index) => (
|
|
170
141
|
<View
|
|
142
|
+
key={index}
|
|
171
143
|
style={{
|
|
172
|
-
|
|
173
|
-
|
|
144
|
+
flexDirection: 'row',
|
|
145
|
+
paddingVertical: 16,
|
|
146
|
+
borderBottomWidth: 1,
|
|
147
|
+
borderColor: color.border,
|
|
174
148
|
}}
|
|
175
149
|
>
|
|
176
|
-
<MText>{formatMoney(item?.payMoney)} VNĐ</MText>
|
|
177
150
|
<MText
|
|
178
151
|
style={[
|
|
179
152
|
{
|
|
180
|
-
|
|
181
|
-
marginTop: 4,
|
|
182
|
-
fontSize: 12,
|
|
153
|
+
width: '35%',
|
|
183
154
|
},
|
|
184
155
|
]}
|
|
185
156
|
>
|
|
186
|
-
{
|
|
157
|
+
{item?.daysPayable ? formatDDMMYYY(item?.daysPayable) : ''}
|
|
187
158
|
</MText>
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
alignItems: 'center',
|
|
204
|
-
justifyContent: 'center',
|
|
205
|
-
borderWidth: 1,
|
|
206
|
-
borderColor: !item?.done ? color.primary : '#333333',
|
|
207
|
-
}}
|
|
208
|
-
onPress={() =>
|
|
209
|
-
navigation.navigate('ShowQrCode', {
|
|
210
|
-
item,
|
|
211
|
-
data,
|
|
212
|
-
id: props.route?.params?.loan?.id,
|
|
213
|
-
})
|
|
214
|
-
}
|
|
159
|
+
<View
|
|
160
|
+
style={{
|
|
161
|
+
width: '40%',
|
|
162
|
+
alignItems: 'center',
|
|
163
|
+
}}
|
|
164
|
+
>
|
|
165
|
+
<MText>{formatMoney(item?.payMoney)} đ</MText>
|
|
166
|
+
<MText
|
|
167
|
+
style={[
|
|
168
|
+
{
|
|
169
|
+
color: !item?.done ? '#EB5757' : '#27AE60',
|
|
170
|
+
marginTop: 4,
|
|
171
|
+
fontSize: 12,
|
|
172
|
+
},
|
|
173
|
+
]}
|
|
215
174
|
>
|
|
216
|
-
|
|
175
|
+
{!item?.done ? 'Chưa thanh toán' : 'Đã thanh toán'}
|
|
176
|
+
</MText>
|
|
177
|
+
</View>
|
|
178
|
+
|
|
179
|
+
<View
|
|
180
|
+
style={{
|
|
181
|
+
flexDirection: 'row',
|
|
182
|
+
justifyContent: 'flex-end',
|
|
183
|
+
}}
|
|
184
|
+
>
|
|
185
|
+
{!item?.done && (
|
|
186
|
+
<TouchableOpacity
|
|
187
|
+
disabled={item?.done}
|
|
217
188
|
style={{
|
|
218
|
-
|
|
219
|
-
|
|
189
|
+
borderRadius: 24,
|
|
190
|
+
height: 30,
|
|
191
|
+
paddingHorizontal: 8,
|
|
192
|
+
alignItems: 'center',
|
|
193
|
+
justifyContent: 'center',
|
|
194
|
+
borderWidth: 1,
|
|
195
|
+
borderColor: !item?.done ? color.primary : '#333333',
|
|
220
196
|
}}
|
|
197
|
+
onPress={() =>
|
|
198
|
+
navigation.navigate('ShowQrCode', {
|
|
199
|
+
item,
|
|
200
|
+
data,
|
|
201
|
+
id: id,
|
|
202
|
+
})
|
|
203
|
+
}
|
|
221
204
|
>
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
205
|
+
<MText
|
|
206
|
+
style={{
|
|
207
|
+
color: !item?.done ? color.primary : '#333333',
|
|
208
|
+
fontSize: 12,
|
|
209
|
+
}}
|
|
210
|
+
>
|
|
211
|
+
Thanh toán
|
|
212
|
+
</MText>
|
|
213
|
+
</TouchableOpacity>
|
|
214
|
+
)}
|
|
215
|
+
</View>
|
|
226
216
|
</View>
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
}
|
|
237
|
-
}
|
|
238
|
-
style={{
|
|
239
|
-
backgroundColor: '#FFEAD8',
|
|
240
|
-
marginTop: 24,
|
|
241
|
-
borderRadius: 24,
|
|
242
|
-
height: 40,
|
|
243
|
-
alignItems: 'center',
|
|
244
|
-
justifyContent: 'center',
|
|
245
|
-
borderWidth: 1,
|
|
246
|
-
borderColor: '#F05123',
|
|
247
|
-
marginBottom: insets.bottom + 24,
|
|
248
|
-
}}
|
|
249
|
-
>
|
|
250
|
-
<MText
|
|
217
|
+
))}
|
|
218
|
+
<TouchableOpacity
|
|
219
|
+
onPress={() =>
|
|
220
|
+
navigation.navigate('ShowQrCode', {
|
|
221
|
+
data,
|
|
222
|
+
id: id,
|
|
223
|
+
isFullPayment: true,
|
|
224
|
+
totalMoney: moneyCloseLoan,
|
|
225
|
+
})
|
|
226
|
+
}
|
|
251
227
|
style={{
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
228
|
+
backgroundColor: '#FFEAD8',
|
|
229
|
+
marginTop: 24,
|
|
230
|
+
borderRadius: 24,
|
|
231
|
+
height: 40,
|
|
232
|
+
alignItems: 'center',
|
|
233
|
+
justifyContent: 'center',
|
|
234
|
+
borderWidth: 1,
|
|
235
|
+
borderColor: '#F05123',
|
|
236
|
+
marginBottom: insets.bottom + 24,
|
|
255
237
|
}}
|
|
256
238
|
>
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
239
|
+
<MText
|
|
240
|
+
style={{
|
|
241
|
+
color: '#F05123',
|
|
242
|
+
fontWeight: '500',
|
|
243
|
+
fontFamily: 'BeVietnamPro-Medium',
|
|
244
|
+
}}
|
|
245
|
+
>
|
|
246
|
+
Xem thông tin tất toán
|
|
247
|
+
</MText>
|
|
248
|
+
</TouchableOpacity>
|
|
249
|
+
</ScrollView>
|
|
250
|
+
)}
|
|
262
251
|
</View>
|
|
263
252
|
</View>
|
|
264
253
|
);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_mobxReactLite","_native","_reactNative","_MText","_utils","_api","_theme","_SkeletonLoanCard","_reactNativeSafeAreaContext","_jsxFileName","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","_t2","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","PaymentSchedule","exports","observer","_ref","_data$paymentSchedule","_this","id","insets","useSafeAreaInsets","navigation","useNavigation","_useState","useState","_useState2","_slicedToArray2","isLoading","setIsLoading","_useState3","_useState4","data","setData","_useState5","_useState6","moneyCloseLoan","setMoneyCloseLoan","getData","_callee","_regenerator","async","_context","prev","next","Api","getInstance","getPaymentScheduleTima","then","response","kind","meta","errorCode","_response$data","_response$data2","_response$data2$meta","Alert","alert","errorMessage","catch","err","stop","Promise","getMoneyCloseLoan","_callee2","_response$data3","_response$data3$data","_t","_context2","awrap","sent","totalMoneyCloseLoan","finish","useEffect","createElement","View","style","flex","backgroundColor","__self","__source","fileName","lineNumber","columnNumber","flexDirection","alignItems","paddingHorizontal","paddingVertical","justifyContent","marginTop","MText","fontSize","fontWeight","fontFamily","codeId","color","width","textAlign","SkeletonPaymentScheduleList","ScrollView","paymentSchedule","map","item","index","key","borderBottomWidth","borderColor","border","daysPayable","formatDDMMYYY","formatMoney","payMoney","done","TouchableOpacity","disabled","borderRadius","height","borderWidth","primary","onPress","navigate","isFullPayment","totalMoney","marginBottom","bottom","$backButton","position","left","$header"],"sourceRoot":"../../../../src","sources":["screens/detail-loan-tima/PaymentSchedule.tsx"],"mappings":"sVACA,IAAAA,MAAA,CAAAC,uBAAA,CAAAC,OAAA,WACA,IAAAC,cAAA,CAAAD,OAAA,oBACA,IAAAE,OAAA,CAAAF,OAAA,6BACA,IAAAG,YAAA,CAAAH,OAAA,iBAQA,IAAAI,MAAA,CAAAJ,OAAA,2BACA,IAAAK,MAAA,CAAAL,OAAA,gBACA,IAAAM,IAAA,CAAAN,OAAA,uBACA,IAAAO,MAAA,CAAAP,OAAA,gBAEA,IAAAQ,iBAAA,CAAAR,OAAA,sCAEA,IAAAS,2BAAA,CAAAT,OAAA,mCAAmE,IAAAU,YAAA,oGAAAX,wBAAAY,CAAA,CAAAC,CAAA,wBAAAC,OAAA,KAAAC,CAAA,KAAAD,OAAA,GAAAE,CAAA,KAAAF,OAAA,UAAAd,uBAAA,UAAAA,wBAAAY,CAAA,CAAAC,CAAA,MAAAA,CAAA,EAAAD,CAAA,EAAAA,CAAA,CAAAK,UAAA,QAAAL,CAAA,KAAAM,CAAA,CAAAC,CA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AE,EAAE,CACV/B,UAAU,CAAE,QAAQ,CACpBG,cAAc,CAAE,QAAQ,CACxB6B,WAAW,CAAE,CAAC,CACdX,WAAW,CAAE,SAAS,CACtBiB,YAAY,CAAEvG,MAAM,CAACwG,MAAM,CAAG,EAChC,CAAE,CAAA7C,MAAA,MAAAC,QAAA,EAAAC,QAAA,CAAAzF,YAAA,CAAA0F,UAAA,KAAAC,YAAA,MAEFvG,MAAA,CAAAuB,OAAA,CAAAuE,aAAA,CAACxF,MAAA,CAAAwG,KAAK,EACJd,KAAK,CAAE,CACLmB,KAAK,CAAE,SAAS,CAChBH,UAAU,CAAE,KAAK,CACjBC,UAAU,CAAE,qBACd,CAAE,CAAAd,MAAA,MAAAC,QAAA,EAAAC,QAAA,CAAAzF,YAAA,CAAA0F,UAAA,KAAAC,YAAA,MACH,mCAEM,CACS,CACR,CAEV,CACF,CAAC,CAEX,CAAC,CAAC,CACF,GAAM,CAAA0C,WAAsB,CAAG,CAC7BC,QAAQ,CAAE,UAAU,CACpBC,IAAI,CAAE,EACR,CAAC,CAED,GAAM,CAAAC,OAAkB,CAAG,CACzB5C,aAAa,CAAE,KAAK,CACpBC,UAAU,CAAE,QAAQ,CACpBE,eAAe,CAAE,EAAE,CACnBC,cAAc,CAAE,QAClB,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.DetailLoanTima=void 0;var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _react=_interopRequireWildcard(require("react"));var _mobxReactLite=require("mobx-react-lite");var _reactNative=require("react-native");var _MHeader=_interopRequireDefault(require("../../components/MHeader"));var _icons=require("../../assets/icons");var _MText=require("../../components/MText");var _InforLoan=_interopRequireDefault(require("./InforLoan"));var _PaymentSchedule=require("./PaymentSchedule");var _native=require("@react-navigation/native");var _jsxFileName="/Users/tima/Tima/react-native-timacare/src/screens/detail-loan-tima/index.tsx";function _interopRequireWildcard(e,t){if("function"==typeof WeakMap)var r=new WeakMap(),n=new WeakMap();return(_interopRequireWildcard=function _interopRequireWildcard(e,t){if(!t&&e&&e.__esModule)return e;var o,i,f={__proto__:null,default:e};if(null===e||"object"!=typeof e&&"function"!=typeof e)return f;if(o=t?n:r){if(o.has(e))return o.get(e);o.set(e,f);}for(var _t in e)"default"!==_t&&{}.hasOwnProperty.call(e,_t)&&((i=(o=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,_t))&&(i.get||i.set)?o(f,_t,i):f[_t]=e[_t]);return f;})(e,t);}var DetailLoanTima=exports.DetailLoanTima=(0,_mobxReactLite.observer)(function DetailLoanTima(props){var _props$route,_props$route$params,_props$route$params$l,_props$route2,_props$route2$params,_props$route2$params$,_props$route3,_props$route3$params,_props$route3$params$;var navigation=(0,_native.useNavigation)();var _useState=(0,_react.useState)(1),_useState2=(0,_slicedToArray2.default)(_useState,2),tab=_useState2[0],setTab=_useState2[1];return _react.default.createElement(_reactNative.View,{style:{flex:1,backgroundColor:'#FFFFFF'},__self:this,__source:{fileName:_jsxFileName,lineNumber:16,columnNumber:5}},_react.default.createElement(_MHeader.default,{title:"Vay Online 24/7",__self:this,__source:{fileName:_jsxFileName,lineNumber:17,columnNumber:7}}),_react.default.createElement(_reactNative.View,{style:$header,__self:this,__source:{fileName:_jsxFileName,lineNumber:18,columnNumber:7}},_react.default.createElement(_reactNative.TouchableOpacity,{style:$backButton,onPress:function onPress(){return navigation.goBack();},__self:this,__source:{fileName:_jsxFileName,lineNumber:19,columnNumber:9}},_react.default.createElement(_icons.IconBack,{__self:this,__source:{fileName:_jsxFileName,lineNumber:23,columnNumber:11}})),_react.default.createElement(_MText.MText,{style:{fontSize:16,fontWeight:'600',fontFamily:'BeVietnamPro-SemiBold'},__self:this,__source:{fileName:_jsxFileName,lineNumber:25,columnNumber:9}},"HD-",(_props$route=props.route)==null?void 0:(_props$route$params=_props$route.params)==null?void 0:(_props$route$params$l=_props$route$params.loan)==null?void 0:_props$route$params$l.id)),_react.default.createElement(_reactNative.View,{style:{flexDirection:'row',backgroundColor:'#F2F2F2',borderRadius:30,marginHorizontal:16},__self:this,__source:{fileName:_jsxFileName,lineNumber:35,columnNumber:7}},_react.default.createElement(_reactNative.TouchableOpacity,{onPress:function onPress(){return setTab(1);},style:{flex:1},__self:this,__source:{fileName:_jsxFileName,lineNumber:43,columnNumber:9}},_react.default.createElement(_reactNative.View,{style:{alignItems:'center',borderRadius:30,paddingVertical:10,borderWidth:1,borderColor:tab===1?'#EF4123':'#F2F2F2',backgroundColor:tab===1?'#FFFFFF':'#F2F2F2'},__self:this,__source:{fileName:_jsxFileName,lineNumber:44,columnNumber:11}},_react.default.createElement(_MText.MText,{style:{color:tab===1?'#EF4123':'#333333',fontWeight:tab===1?'bold':'400'},__self:this,__source:{fileName:_jsxFileName,lineNumber:54,columnNumber:13}},"Th\xF4ng tin \u0111\u01A1n"))),_react.default.createElement(_reactNative.TouchableOpacity,{onPress:function onPress(){return setTab(2);},style:{flex:1},__self:this,__source:{fileName:_jsxFileName,lineNumber:64,columnNumber:9}},_react.default.createElement(_reactNative.View,{style:{alignItems:'center',borderRadius:30,paddingVertical:10,borderWidth:1,borderColor:tab===2?'#EF4123':'#F2F2F2',backgroundColor:tab===2?'#FFFFFF':'#F2F2F2'},__self:this,__source:{fileName:_jsxFileName,lineNumber:70,columnNumber:11}},_react.default.createElement(_MText.MText,{style:{color:tab===2?'#EF4123':'#333333',fontWeight:tab===2?'bold':'400'},__self:this,__source:{fileName:_jsxFileName,lineNumber:80,columnNumber:13}},"L\u1ECBch thanh to\xE1n")))),tab===1?_react.default.createElement(_InforLoan.default,{id:(_props$route2=props.route)==null?void 0:(_props$route2$params=_props$route2.params)==null?void 0:(_props$route2$params$=_props$route2$params.loan)==null?void 0:_props$route2$params$.id,__self:this,__source:{fileName:_jsxFileName,lineNumber:92,columnNumber:9}}):_react.default.createElement(_PaymentSchedule.PaymentSchedule,{id:(_props$route3=props.route)==null?void 0:(_props$route3$params=_props$route3.params)==null?void 0:(_props$route3$params$=_props$route3$params.loan)==null?void 0:_props$route3$params$.id,__self:this,__source:{fileName:_jsxFileName,lineNumber:94,columnNumber:9}}));});var $backButton={position:'absolute',left:16};var $header={flexDirection:'row',alignItems:'center',paddingVertical:16,justifyContent:'center'};
|
|
2
|
+
//# sourceMappingURL=index.js.map
|