bug fixed

This commit is contained in:
Samandar Turgunboyev
2026-03-02 13:22:55 +05:00
parent bdc205b538
commit ab363ca3b9
44 changed files with 424 additions and 130 deletions

View File

@@ -12,9 +12,9 @@ import {
Switch,
Text,
TextInput,
ToastAndroid,
View,
View
} from 'react-native';
import { Toast } from 'toastify-react-native';
import { user_api } from '../lib/api';
type FormType = {
@@ -44,12 +44,12 @@ export default function CreateReferrals() {
is_agent: boolean;
}) => user_api.create_referral(body),
onSuccess: () => {
ToastAndroid.show(t('Referral yaratildi'), ToastAndroid.SHORT);
Toast.success(t('Referral yaratildi'));
queryClient.refetchQueries({ queryKey: ['my_referrals'] });
router.back();
},
onError: () => {
ToastAndroid.show(t('Xatolik yuz berdi'), ToastAndroid.SHORT);
Toast.error(t('Xatolik yuz berdi'));
},
});