BT - Migrate CATEGORIES_IMPORT#87273
Conversation
Codecov Report❌ Looks like you've decreased code coverage for some files. Please write tests to increase, or at least maintain, the existing level of code coverage. See our documentation here for how to interpret this table.
|
…te-workspace-categories-import
…te-workspace-categories-import
| backTo={backTo} | ||
| goTo={isQuickSettingsFlow ? ROUTES.SETTINGS_CATEGORIES_IMPORTED.getRoute(policyID, backTo) : ROUTES.WORKSPACE_CATEGORIES_IMPORTED.getRoute(policyID)} | ||
| backTo={isQuickSettingsFlow ? backTo : workspaceCategoriesListBackPath} | ||
| goTo={isQuickSettingsFlow ? ROUTES.SETTINGS_CATEGORIES_IMPORTED.getRoute(policyID, backTo) : workspaceGoToImportedPath} |
There was a problem hiding this comment.
@collectioneur I needed this append logic to ensure goTo works well. Let me know if appendDynamicRouteSuffixToBasePath works okay or requires any changes.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 09bf3a0e6e
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| onBackButtonPress={() => | ||
| Navigation.goBack(isQuickSettingsFlow ? ROUTES.SETTINGS_CATEGORIES_IMPORT.getRoute(policyID, backTo) : ROUTES.WORKSPACE_CATEGORIES_IMPORT.getRoute(policyID)) | ||
| } | ||
| onBackButtonPress={() => Navigation.goBack(isQuickSettingsFlow ? ROUTES.SETTINGS_CATEGORIES_IMPORT.getRoute(policyID, backTo) : backPath)} |
There was a problem hiding this comment.
Preserve back target to import screen in workspace flow
In the workspace categories flow, this back handler now sends users from .../categories/imported to backPath (the categories list), because useDynamicBackPath('imported') strips the suffix to .../categories. Previously, back from Imported Categories returned to the Import Categories screen, which lets users revise mapping/re-upload without restarting the flow. Repro: workspace categories → Import spreadsheet → upload CSV → on Imported Categories press Back; it now skips the import step.
Useful? React with 👍 / 👎.
Explanation of Change
Fixed Issues
$ #83832
PROPOSAL:
Tests
Preconditions
Offline tests
Same as Test steps
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
Same as Test steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
mweb-chrome-bt-category-import.mov
iOS: Native
ios-bt-category-imported.mov
ios-bt-category-import.mov
iOS: mWeb Safari
mweb-safari-bt-category-import.mov
MacOS: Chrome / Safari
web-bt-category-import.mov