Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
rezkiy37 committed Oct 1, 2024
1 parent 9f053a5 commit acde545
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/pages/workspace/invoices/WorkspaceInvoicesPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import WorkspaceInvoicesVBAView from './WorkspaceInvoicesVBAView';
import WorkspaceInvoiceVBASection from './WorkspaceInvoiceVBASection';

type WorkspaceInvoicesPageProps = StackScreenProps<FullScreenNavigatorParamList, typeof SCREENS.WORKSPACE.INVOICES>;

function WorkspaceInvoicesPage({route}: WorkspaceInvoicesPageProps) {
const {translate} = useLocalize();
const styles = useThemeStyles();
Expand All @@ -33,11 +32,13 @@ function WorkspaceInvoicesPage({route}: WorkspaceInvoicesPageProps) {
shouldSkipVBBACall={false}
route={route}
>
<View style={[styles.mt3, shouldUseNarrowLayout ? styles.workspaceSectionMobile : styles.workspaceSection]}>
{policyID && <WorkspaceInvoiceVBASection policyID={policyID} />}
{!hasVBA && policyID && <WorkspaceInvoicesNoVBAView policyID={policyID} />}
{hasVBA && policyID && <WorkspaceInvoicesVBAView policyID={policyID} />}
</View>
{(hasVBA?: boolean, policyID?: string) => (
<View style={[styles.mt3, shouldUseNarrowLayout ? styles.workspaceSectionMobile : styles.workspaceSection]}>
{policyID && <WorkspaceInvoiceVBASection policyID={policyID} />}
{!hasVBA && policyID && <WorkspaceInvoicesNoVBAView policyID={policyID} />}
{hasVBA && policyID && <WorkspaceInvoicesVBAView policyID={policyID} />}
</View>
)}
</WorkspacePageWithSections>
</AccessOrNotFoundWrapper>
);
Expand Down

0 comments on commit acde545

Please sign in to comment.