This commit is contained in:
parent
11ebd9e1fb
commit
9f40388c57
|
|
@ -112,32 +112,18 @@ const ProcessStepOne = () => {
|
|||
name: `${recipient.firstName} ${recipient.lastName}`
|
||||
}));
|
||||
|
||||
console.log(recipientsData, "printing Recipient Data Line 114");
|
||||
|
||||
// await api.post(`/api/accounts/${accountId}/transactions/${transactionId}/recipients`, recipientsData).then((res) => {
|
||||
// console.log(res, "Response Line 117")
|
||||
// }).catch((err) => {
|
||||
// console.log(err)
|
||||
// })
|
||||
|
||||
dispatch(addRecipientAsync({recipientsData, accountId, transactionId}));
|
||||
|
||||
dispatch(hideLoader());
|
||||
|
||||
if (isSendNow) {
|
||||
dispatch(updateTransactionStatus(TRANSACTION_STATUS_ENUMS.TRANSACTION_SEND_SUCCESS));
|
||||
setTimeout(() => {
|
||||
navigate("/");
|
||||
}, 1000);
|
||||
} else {
|
||||
// Preview & Tag
|
||||
// Assuming you'd fetch or pass doc/recipients response here
|
||||
// dispatch(setImages(...));
|
||||
// dispatch(updateRecipientIds(...));
|
||||
// dispatch(setTransactionId(...));
|
||||
setTimeout(() => {
|
||||
dispatch(resetDocuments())
|
||||
dispatch(resetRecipients())
|
||||
setTimeout(() => {
|
||||
dispatch(hideLoader());
|
||||
navigate(`/process-step-two/${accountId}/${transactionId}`);
|
||||
}, 1000);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ api.interceptors.response.use(
|
|||
async error => {
|
||||
const originalRequest = error.config;
|
||||
// Prevent multiple refresh attempts
|
||||
if (error.response?.status === 401) {
|
||||
if (error.response?.status === 401 || error.response?.status === 500) {
|
||||
originalRequest._retry = true;
|
||||
try {
|
||||
if (!isRefreshing) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue