Skip to content

NetSuite Travel invoicing export crashes when opening Journal entries posting preference menu #91023

@blimpich

Description

@blimpich

Problem

When the user opens the "Journal entries posting preference" menu under a NetSuite workspace's Travel invoicing export settings, New Expensify crashes and renders the "Uh-oh, something went wrong!" fallback screen instead of showing the selection list.

Reproduction Steps

Reproduces on both staging and dev.

  1. Connect a workspace to NetSuite (NetSuite must be the active connection).
  2. Go to Workspace settings → Accounting → NetSuite → Export → Travel invoicing.
    • Direct URL: /workspaces/<policyID>/accounting/netsuite/export/travel-invoicing
  3. Tap Journal entries posting preference.

Expected behavior

A selection screen appears letting the admin pick between "Single entry for each expense" and the other posting preference values.

Actual behavior

The app renders the global error boundary ("Uh-oh, something went wrong!") with Refresh / Sign out buttons. The user must refresh to recover.

Solution

Add the missing import React from 'react'; statement at the top of src/pages/workspace/accounting/netsuite/export/NetSuiteTravelInvoicingJournalPostingPreferenceSelectPage.tsx. The file uses JSX, which compiles to React.createElement(...) under this project's classic JSX runtime, so React must be in scope at module level.

Extra context

Console error captured from the dev build:

ReferenceError: React is not defined
    at NetSuiteTravelInvoicingJournalPostingPreferenceSelectPage (.../NetSuiteTravelInvoicingJournalPostingPreferenceSelectPage.tsx)
    at react_stack_bottom_frame
    at renderWithHooks
    ...

The file is the only .tsx in src/pages/workspace/accounting/netsuite/export/ without an import React line — every sibling (including the very similar NetSuiteTravelInvoicingPayableAccountSelectPage.tsx and DynamicNetSuiteExportExpensesJournalPostingPreferenceSelectPage.tsx) imports React explicitly.

File introduced in #89968.

Metadata

Metadata

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions