@@ -2,11 +2,9 @@ import React, { useEffect } from 'react'
22import get from 'lodash/get'
33import { useRouter } from 'next/router'
44import Head from 'next/head'
5- import { useAuth } from '@open-condo/next/auth'
65import { useIntl } from '@open-condo/next/intl'
76import { useOrganization } from '@open-condo/next/organization'
87import { Typography } from '@open-condo/ui'
9- import LoadingOrErrorPage from '@condo/domains/common/components/containers/LoadingOrErrorPage'
108import { PageContent , PageWrapper , PageHeader } from '@condo/domains/common/components/containers/BaseLayout'
119import IFrame from '@condo/domains/common/components/IFrame'
1210import { BillingIntegrationOrganizationContext } from '@condo/domains/billing/utils/clientSchema'
@@ -20,12 +18,8 @@ type BillingAppPageProps = {
2018export const BillingAppPage : React . FC < BillingAppPageProps > = ( { id } ) => {
2119 const intl = useIntl ( )
2220 const FallbackPageTitle = intl . formatMessage ( { id : 'global.section.miniapps' } )
23- const NoPermissionMessage = intl . formatMessage ( { id : 'global.noPageViewPermission' } )
2421
2522 const router = useRouter ( )
26- const auth = useAuth ( )
27- const isSupport = get ( auth , [ 'user' , 'isSupport' ] , false )
28- const isAdmin = get ( auth , [ 'user' , 'isAdmin' ] , false )
2923 const userOrganization = useOrganization ( )
3024 const organizationId = get ( userOrganization , [ 'organization' , 'id' ] , null )
3125
@@ -46,9 +40,10 @@ export const BillingAppPage: React.FC<BillingAppPageProps> = ({ id }) => {
4640 }
4741 } , [ id , loading , error , context , appUrl , router ] )
4842
49- if ( isSupport || isAdmin ) {
50- return < LoadingOrErrorPage title = { FallbackPageTitle } error = { NoPermissionMessage } />
51- }
43+ // TODO(DOMA-5005): Return this restriction back till token scopes will be implemented
44+ // if (isSupport || isAdmin) {
45+ // return <LoadingOrErrorPage title={FallbackPageTitle} error={NoPermissionMessage}/>
46+ // }
5247
5348
5449 return (
0 commit comments