This commit is contained in:
Samandar Turgunboyev
2025-09-04 18:38:08 +05:00
parent 9d317290ef
commit f41451c6b8
98 changed files with 1717 additions and 2118 deletions

View File

@@ -1,9 +1,10 @@
import { useNavigation } from '@react-navigation/native';
import { NativeStackNavigationProp } from '@react-navigation/native-stack';
import { PacketsData } from 'api/packets';
import AppText from 'components/AppText';
import React, { useCallback, useMemo } from 'react';
import { useTranslation } from 'react-i18next';
import { Text, TouchableOpacity, View } from 'react-native';
import { TouchableOpacity, View } from 'react-native';
import { PaymentStyle } from './style';
type WalletStackParamList = {
@@ -66,39 +67,43 @@ const Payment = ({ packets }: Props) => {
<View style={cardContainerStyle}>
<View style={cardStyle}>
<View style={PaymentStyle.cardHeader}>
<Text style={PaymentStyle.title}>{item.packetName}</Text>
<AppText style={PaymentStyle.title}>{item.packetName}</AppText>
{isPaid ? (
<Text style={PaymentStyle.badge}>{t("To'langan")}</Text>
<AppText style={PaymentStyle.badge}>{t("To'langan")}</AppText>
) : (
<Text style={badgeStyle}>{t("To'lanmagan")}</Text>
<AppText style={badgeStyle}>{t("To'lanmagan")}</AppText>
)}
</View>
<View style={PaymentStyle.row}>
<Text style={PaymentStyle.infoTitle}>{t('Reys raqami')}</Text>
<Text
<AppText style={PaymentStyle.infoTitle}>
{t('Reys raqami')}
</AppText>
<AppText
style={[
PaymentStyle.text,
{ width: '60%', textAlign: 'right' },
]}
>
{item.packetName}
</Text>
</AppText>
</View>
<View style={PaymentStyle.row}>
<Text style={PaymentStyle.infoTitle}>
<AppText style={PaymentStyle.infoTitle}>
{t("Mahsulotlar og'irligi")}
</Text>
<Text style={PaymentStyle.text}>{item.weight}</Text>
</AppText>
<AppText style={PaymentStyle.text}>{item.weight}</AppText>
</View>
<View style={PaymentStyle.row}>
<Text style={PaymentStyle.infoTitle}>
<AppText style={PaymentStyle.infoTitle}>
{t('Mahsulotlar soni')}
</Text>
<Text style={PaymentStyle.text}>{item.items.length}</Text>
</AppText>
<AppText style={PaymentStyle.text}>{item.items.length}</AppText>
</View>
<View style={PaymentStyle.row}>
<Text style={PaymentStyle.infoTitle}>{t('Umumiy narxi')}</Text>
<Text style={PaymentStyle.text}>{item.totalPrice}</Text>
<AppText style={PaymentStyle.infoTitle}>
{t('Umumiy narxi')}
</AppText>
<AppText style={PaymentStyle.text}>{item.totalPrice}</AppText>
</View>
</View>
</View>