From 4f6b52eb18aa9d254068dbb083891d00dc015289 Mon Sep 17 00:00:00 2001 From: Hazem Krimi Date: Thu, 17 Jun 2021 03:28:10 +0100 Subject: [PATCH] Update project page --- src/pages/Project/index.tsx | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/src/pages/Project/index.tsx b/src/pages/Project/index.tsx index f17f96c..4ce5993 100644 --- a/src/pages/Project/index.tsx +++ b/src/pages/Project/index.tsx @@ -11,6 +11,7 @@ import { Empty, FullBuild, MVP, + Payment, Settings, Specification, } from '../../assets'; @@ -83,7 +84,7 @@ const Project = () => { id: currentUser?.id!, }, onCompleted({ getAllProjectsByClientId }) { - setProject(getAllProjectsByClientId[0]); + history.push(`/project/${getAllProjectsByClientId[0].id}`); }, fetchPolicy: 'network-only', }); @@ -93,7 +94,7 @@ const Project = () => { GetAllUsersQueryVariables >(GET_ALL_PROJECTS, { onCompleted({ getAllProjects }) { - setProject(getAllProjects[0]); + history.push(`/project/${getAllProjects[0].id}`); }, fetchPolicy: 'network-only', }); @@ -417,6 +418,20 @@ const Project = () => { } /> + {role === 'client' && ( + +