add toast for payments method save
This commit is contained in:
@@ -253,6 +253,7 @@ export type PayoutMethodFormState = {
|
||||
bankCard?: string | undefined;
|
||||
paymentsType?: 'bank-card' | 'bank-transfer' | 'on-account-balance';
|
||||
} | undefined,
|
||||
success?: boolean,
|
||||
error: Record<string, string | null> | null
|
||||
};
|
||||
|
||||
@@ -288,6 +289,7 @@ export async function addPayoutMethod(
|
||||
previousState: {
|
||||
bankCard
|
||||
},
|
||||
success: false,
|
||||
error: errors
|
||||
};
|
||||
}
|
||||
@@ -318,6 +320,7 @@ export async function addPayoutMethod(
|
||||
bankCard,
|
||||
paymentsType
|
||||
},
|
||||
success: true,
|
||||
error: null
|
||||
};
|
||||
} else {
|
||||
@@ -336,6 +339,7 @@ export async function addPayoutMethod(
|
||||
bankCard,
|
||||
paymentsType
|
||||
},
|
||||
success: false,
|
||||
error: errors
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user