From 89a147565ca9e95816fe8dd9b7d6885ae69ffd10 Mon Sep 17 00:00:00 2001 From: William Petit Date: Mon, 5 Oct 2020 16:36:00 +0200 Subject: [PATCH 1/2] Correction DOM invalide --- client/src/components/DashboardPage/Dashboard.tsx | 4 ++-- .../src/components/DecisionSupportFilePage/TimelinePanel.tsx | 4 ++-- client/src/components/WorkgroupPage/TimelinePanel.tsx | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/client/src/components/DashboardPage/Dashboard.tsx b/client/src/components/DashboardPage/Dashboard.tsx index 8ffeabf..861f721 100644 --- a/client/src/components/DashboardPage/Dashboard.tsx +++ b/client/src/components/DashboardPage/Dashboard.tsx @@ -26,7 +26,7 @@ export function Dashboard() {
-

+

Ces 7 derniers jours @@ -37,7 +37,7 @@ export function Dashboard() {
-

+
diff --git a/client/src/components/DecisionSupportFilePage/TimelinePanel.tsx b/client/src/components/DecisionSupportFilePage/TimelinePanel.tsx index a537abf..5f8b202 100644 --- a/client/src/components/DecisionSupportFilePage/TimelinePanel.tsx +++ b/client/src/components/DecisionSupportFilePage/TimelinePanel.tsx @@ -19,7 +19,7 @@ export const TimelinePanel: FunctionComponent = ({ dsf }) => return (
-

+

Suivi des opérations @@ -27,7 +27,7 @@ export const TimelinePanel: FunctionComponent = ({ dsf }) =>
-

+
diff --git a/client/src/components/WorkgroupPage/TimelinePanel.tsx b/client/src/components/WorkgroupPage/TimelinePanel.tsx index 0f52f62..4de95d7 100644 --- a/client/src/components/WorkgroupPage/TimelinePanel.tsx +++ b/client/src/components/WorkgroupPage/TimelinePanel.tsx @@ -20,7 +20,7 @@ export const TimelinePanel: FunctionComponent = ({ workgroup return (
-

+

Suivi des opérations @@ -28,7 +28,7 @@ export const TimelinePanel: FunctionComponent = ({ workgroup
-

+
From 7a6eedab9d0fc322c1d55d4dbc6c8b9c869cf64f Mon Sep 17 00:00:00 2001 From: William Petit Date: Mon, 5 Oct 2020 17:03:01 +0200 Subject: [PATCH 2/2] =?UTF-8?q?Forcer=20l'utilisation=20du=20r=C3=A9seau?= =?UTF-8?q?=20pour=20les=20requ=C3=AAtes=20d'autorisation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/gql/queries/authorization.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/client/src/gql/queries/authorization.tsx b/client/src/gql/queries/authorization.tsx index 31293ee..52ecc65 100644 --- a/client/src/gql/queries/authorization.tsx +++ b/client/src/gql/queries/authorization.tsx @@ -8,10 +8,16 @@ export const QUERY_IS_AUTHORIZED = gql` `; export function useIsAuthorizedQuery>(options: QueryHookOptions = {}) { + options = Object.assign({ + fetchPolicy: 'cache-and-network' + }, options); return useQuery(QUERY_IS_AUTHORIZED, options); } export function useIsAuthorized>(options: QueryHookOptions = {}, defaultValue = false) { + options = Object.assign({ + fetchPolicy: 'cache-and-network' + }, options); const { data, loading, error } = useGraphQLData( QUERY_IS_AUTHORIZED, 'isAuthorized', defaultValue, options );