/LoanPaidOffLetterOrder ready
This commit is contained in:
@@ -70,16 +70,56 @@ const LoanPaidOffLetterOrderDetailsScreen = () => {
|
|||||||
<Ionicons name="close" size={28} color={COLORS.textPrimary} />
|
<Ionicons name="close" size={28} color={COLORS.textPrimary} />
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
|
|
||||||
<ScrollView contentContainerStyle={{ paddingBottom: 40 }}>
|
<ScrollView contentContainerStyle={{ paddingBottom: 40, paddingHorizontal: 24 }}>
|
||||||
<Text style={styles.title}>Güwanama detallary</Text>
|
<Text style={styles.title}>Güwanama {order.id}</Text>
|
||||||
|
|
||||||
<View style={styles.detailCard}>
|
<View style={styles.detailCard}>
|
||||||
{Object.entries(order).map(([key, value]) => (
|
{[
|
||||||
<View key={key} style={styles.detailRow}>
|
'id',
|
||||||
<Text style={styles.detailKey}>{key}</Text>
|
'region',
|
||||||
<Text style={styles.detailValue}>{String(value)}</Text>
|
'branch_id',
|
||||||
</View>
|
'customer_name',
|
||||||
))}
|
'customer_surname',
|
||||||
|
'customer_patronic_name',
|
||||||
|
'born_at',
|
||||||
|
'phone',
|
||||||
|
'passport_serie',
|
||||||
|
'passport_id',
|
||||||
|
'status',
|
||||||
|
'notes',
|
||||||
|
'loan_contract_number',
|
||||||
|
'loan_contract_date',
|
||||||
|
'loan_amount',
|
||||||
|
'loan_reason',
|
||||||
|
].filter((k) => order[k] !== undefined && order[k] !== null).map((key, idx, arr) => {
|
||||||
|
const titles = {
|
||||||
|
id: 'ID',
|
||||||
|
region: 'Welaýat',
|
||||||
|
branch_id: 'Şahamça',
|
||||||
|
customer_name: 'Ady',
|
||||||
|
customer_surname: 'Familiýasy',
|
||||||
|
customer_patronic_name: 'Atasynyň ady',
|
||||||
|
born_at: 'Doglan senesi',
|
||||||
|
phone: 'Telefon',
|
||||||
|
passport_serie: 'Passport seriýa',
|
||||||
|
passport_id: 'Passport nomer',
|
||||||
|
status: 'Status',
|
||||||
|
notes: 'Bellikler',
|
||||||
|
loan_contract_number: 'Karz şertnamanyň belgisi',
|
||||||
|
loan_contract_date: 'Karz şertnamanyň senesi',
|
||||||
|
loan_amount: 'Karzyň möçberi',
|
||||||
|
loan_reason: 'Karzyň maksady',
|
||||||
|
};
|
||||||
|
return (
|
||||||
|
<View
|
||||||
|
key={key}
|
||||||
|
style={[styles.detailRow, idx !== arr.length - 1 && styles.detailRowBorder]}
|
||||||
|
>
|
||||||
|
<Text style={styles.detailKey}>{titles[key]}</Text>
|
||||||
|
<Text style={styles.detailValue}>{String(order[key])}</Text>
|
||||||
|
</View>
|
||||||
|
);
|
||||||
|
})}
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
<TouchableOpacity style={styles.deleteBtn} onPress={handleDelete}>
|
<TouchableOpacity style={styles.deleteBtn} onPress={handleDelete}>
|
||||||
@@ -105,6 +145,7 @@ const styles = StyleSheet.create({
|
|||||||
backBtn: {
|
backBtn: {
|
||||||
alignSelf: 'flex-end',
|
alignSelf: 'flex-end',
|
||||||
marginBottom: 16,
|
marginBottom: 16,
|
||||||
|
marginRight: 24,
|
||||||
},
|
},
|
||||||
title: {
|
title: {
|
||||||
fontSize: 24,
|
fontSize: 24,
|
||||||
@@ -121,7 +162,11 @@ const styles = StyleSheet.create({
|
|||||||
detailRow: {
|
detailRow: {
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
justifyContent: 'space-between',
|
justifyContent: 'space-between',
|
||||||
marginBottom: 12,
|
paddingVertical: 12,
|
||||||
|
},
|
||||||
|
detailRowBorder: {
|
||||||
|
borderBottomWidth: 1,
|
||||||
|
borderBottomColor: COLORS.border,
|
||||||
},
|
},
|
||||||
detailKey: {
|
detailKey: {
|
||||||
fontWeight: '600',
|
fontWeight: '600',
|
||||||
|
|||||||
Reference in New Issue
Block a user