fix: customer route
This commit is contained in:
parent
910f996db6
commit
a3dc450497
2 changed files with 5 additions and 2 deletions
|
|
@ -285,7 +285,6 @@ const CHECK_AGAINST_SANCTIONS = gql`
|
|||
|
||||
const CustomerProfile = memo(() => {
|
||||
const [, navigate] = useLocation()
|
||||
|
||||
const [showCompliance, setShowCompliance] = useState(false)
|
||||
const [wizard, setWizard] = useState(false)
|
||||
const [error, setError] = useState(null)
|
||||
|
|
@ -298,6 +297,7 @@ const CustomerProfile = memo(() => {
|
|||
loading: customerLoading,
|
||||
} = useQuery(GET_CUSTOMER, {
|
||||
variables: { customerId },
|
||||
skip: !customerId,
|
||||
})
|
||||
|
||||
const { data: configResponse, loading: configLoading } = useQuery(GET_DATA)
|
||||
|
|
|
|||
|
|
@ -105,7 +105,10 @@ const Routes = () => {
|
|||
<Transition
|
||||
className={wrapperClasses}
|
||||
{...transitionProps}
|
||||
in={location === route}
|
||||
in={
|
||||
location === route ||
|
||||
(route.includes(':') && location.startsWith(route.split(':')[0]))
|
||||
}
|
||||
mountOnEnter
|
||||
unmountOnExit>
|
||||
<div className={wrapperClasses}>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue