diff --git a/src/front/Components/DesignSystem/Header/Navigation/index.tsx b/src/front/Components/DesignSystem/Header/Navigation/index.tsx
index f51975a1..6134b4a8 100644
--- a/src/front/Components/DesignSystem/Header/Navigation/index.tsx
+++ b/src/front/Components/DesignSystem/Header/Navigation/index.tsx
@@ -34,7 +34,7 @@ export default function Navigation() {
}, []);
const getNotifications = useCallback(async () => {
- await getAnchoringStatus();
+ //await getAnchoringStatus();
const notifications = await Notifications.getInstance().get({
where: {
read: false,
@@ -47,11 +47,12 @@ export default function Navigation() {
redirectUrl: notification.notification.redirection_url,
});
});
- }, [getAnchoringStatus]);
+ }, []);
useEffect(() => {
+ getAnchoringStatus();
getNotifications();
- }, [pathname, getNotifications]);
+ }, [pathname, getNotifications, getAnchoringStatus]);
return (
diff --git a/src/front/Components/DesignSystem/Toasts/ToastsContainer/ToastElement/index.tsx b/src/front/Components/DesignSystem/Toasts/ToastsContainer/ToastElement/index.tsx
index 1a5661c0..8474ef5e 100644
--- a/src/front/Components/DesignSystem/Toasts/ToastsContainer/ToastElement/index.tsx
+++ b/src/front/Components/DesignSystem/Toasts/ToastsContainer/ToastElement/index.tsx
@@ -108,10 +108,12 @@ class ToastElementClass extends React.Component
{
}, 200);
}
- private handleClick(e: React.MouseEvent) {
+ private async handleClick(e: React.MouseEvent) {
+ console.log('redirectUrl', this.props.toast.redirectUrl);
if (this.props.toast.redirectUrl) {
- this.props.router.push(this.props.toast.redirectUrl);
this.onClose(e);
+ await this.props.router.push(this.props.toast.redirectUrl);
+ this.props.router.reload();
}
}
}
diff --git a/src/front/Components/DesignSystem/Toasts/ToastsContainer/index.tsx b/src/front/Components/DesignSystem/Toasts/ToastsContainer/index.tsx
index dc5edd46..f323974a 100644
--- a/src/front/Components/DesignSystem/Toasts/ToastsContainer/index.tsx
+++ b/src/front/Components/DesignSystem/Toasts/ToastsContainer/index.tsx
@@ -8,7 +8,7 @@ type IProps = {};
type IState = {
toastList: IToast[];
};
-export default class ToastsContainer extends React.Component {
+export class ToastsContainerClass extends React.Component {
private removeOnChange = () => {};
public constructor(props: IProps) {
@@ -25,7 +25,7 @@ export default class ToastsContainer extends React.Component {
0 && classes["open"])}>
<>
{this.state.toastList.map((toast) => {
- return ;
+ return ;
})}
>
@@ -44,3 +44,7 @@ export default class ToastsContainer extends React.Component {
this.setState({ toastList });
}
}
+
+export default function ToastsContainer(props: IProps) {
+ return ;
+};