|
|
@ -79,16 +79,21 @@ export default function Login() { |
|
|
|
dispatch({ |
|
|
|
dispatch({ |
|
|
|
type: TYPE_DISPATCH.RESET_AUTHENTICATION, |
|
|
|
type: TYPE_DISPATCH.RESET_AUTHENTICATION, |
|
|
|
}); |
|
|
|
}); |
|
|
|
persistor.purge(); |
|
|
|
dispatch( |
|
|
|
window.location.href = PATH.login; |
|
|
|
alertActions.error({ |
|
|
|
return false |
|
|
|
message: 'Bạn không có quyền truy cập', |
|
|
|
|
|
|
|
}), |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
return false |
|
|
|
|
|
|
|
// persistor.purge();
|
|
|
|
|
|
|
|
// window.location.href = PATH.login;
|
|
|
|
} |
|
|
|
} |
|
|
|
handleLoginSuccess(res); |
|
|
|
handleLoginSuccess(res); |
|
|
|
} |
|
|
|
} |
|
|
|
} catch (err) { |
|
|
|
} catch (err) { |
|
|
|
dispatch( |
|
|
|
dispatch( |
|
|
|
alertActions.error({ |
|
|
|
alertActions.error({ |
|
|
|
message: 'Bạn không có quyền truy cập', |
|
|
|
message: err.toString() |
|
|
|
}), |
|
|
|
}), |
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|