-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[#Wave-Control: Add NetSuite]: Top-level Subsidiary selection #44038
[#Wave-Control: Add NetSuite]: Top-level Subsidiary selection #44038
Conversation
…edit-last-message" This reverts commit 747fe19.
netsuite: { | ||
options: { | ||
config: { | ||
subsidiary, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need this as this will be redundant.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will keep this, and replace once your PR is merged for the common method.
netsuite: { | ||
options: { | ||
config: { | ||
subsidiary, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
subsidiary, |
The console error seems unrelated to changes in this one and exists already. I'll first fix the SelectionScreen as I am at the airport. If time permits I'll try to fix the console.error. |
src/pages/workspace/accounting/netsuite/NetSuiteSubsidiarySelector.tsx
Outdated
Show resolved
Hide resolved
import type SCREENS from '@src/SCREENS'; | ||
import type {NetSuiteSubsidiary} from '@src/types/onyx/Policy'; | ||
|
||
type NetSuiteSubsidiarySelectorProps = WithPolicyConnectionsProps & StackScreenProps<SettingsNavigatorParamList, typeof SCREENS.WORKSPACE.ACCOUNTING.NETSUITE_SUBSIDIARY_SELECTOR>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel this is unecessary.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed.
Reviewer Checklist
Screenshots/VideosAndroid: NativeAndroid: mWeb ChromeScreen.Recording.2024-06-25.at.5.51.33.PM.moviOS: NativeScreen.Recording.2024-06-25.at.6.57.13.PM.moviOS: mWeb SafariScreen.Recording.2024-06-25.at.5.46.08.PM.movMacOS: Chrome / SafariScreen.Recording.2024-06-25.at.5.44.15.PM.movMacOS: DesktopScreen.Recording.2024-06-25.at.6.46.28.PM.mov |
Revised screencasts with Web Also contains empty screen screenshot. web-updated-screencast_jd4dYEG5.mp4iOS: Doesn't have the console.error so I removed the SelectionList prop that I added for nested view. ios-updated-screencast.mov |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to production by https://github.com/jasperhuangg in version: 9.0.3-7 🚀
|
🚀 Deployed to production by https://github.com/Julesssss in version: 9.0.5-13 🚀
|
...(policyConnectedToNetSuite && !shouldShowSynchronizationError | ||
? [ | ||
{ | ||
description: translate('workspace.netsuite.subsidiary'), | ||
iconRight: Expensicons.ArrowRight, | ||
title: netSuiteSelectedSubsidiary, | ||
wrapperStyle: [styles.sectionMenuItemTopDescription], | ||
titleStyle: styles.fontWeightNormal, | ||
shouldShowRightIcon: netSuiteSubsidiaryList.length > 1, | ||
shouldShowDescriptionOnTop: true, | ||
pendingAction: policy?.connections?.netsuite?.options?.config?.pendingFields?.subsidiary, | ||
brickRoadIndicator: policy?.connections?.netsuite?.options?.config?.errorFields?.subsidiary ? CONST.BRICK_ROAD_INDICATOR_STATUS.ERROR : undefined, | ||
onPress: () => { | ||
if (!(netSuiteSubsidiaryList.length > 1)) { | ||
return; | ||
} | ||
Navigation.navigate(ROUTES.POLICY_ACCOUNTING_NETSUITE_SUBSIDIARY_SELECTOR.getRoute(policyID)); | ||
}, | ||
}, | ||
] | ||
: []), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like this part of the logic led to the following issue:
Which we solved by returning empty object when there's no value for subsidiary, more details in issue proposal.
Details
Covers the implementation of Top-level subsidiary config page.
This is one of the first FE PRs for NetSuite without the proper auth flow integrated. Hence, to get this working we'll need to have a few pre-requisites:
NetSuite
beta enabled for the user. You can return true in the canUseNetSuiteIntegration method.connections: {netsuite: <linkedjson>}
.Fixed Issues
$ #43435
PROPOSAL:
Tests
Accounting
from the LHSNet Suite
in the active connections along with theOracle NetSuite
logo.Subsidiary
list item below NetSuite title along with the subsidiary listed asHoneycomb Mfg.
(based on the test data imported)Offline tests
Accounting
from the LHSNet Suite
in the active connections along with theOracle NetSuite
logo.Subsidiary
list item below NetSuite title along with the subsidiary listed asHoneycomb Mfg.
(based on the test data imported)QA Steps
Same as Test Steps. Additionally do a sanity on list pages such as
Report
,Search
that the list and scroll behavior is not impacted.PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
android-net-suite-subsidiary.mov
Android: mWeb Chrome
mweb-chrome-net-suite-subsidiary.mov
iOS: Native
ios-net-suite-subsidiary.mov
iOS: mWeb Safari
mweb-safari-net-suite-subsidiary.mov
MacOS: Chrome / Safari
Basic Test
web-net-suite-subsidiary.mp4
Offline Behavior
web-net-suite-subsidiary-offline_gylZqRMq.mp4
Web Spanish Translation
Error handling
web-net-suite-subsidiary-error.mov
MacOS: Desktop
desktop-net-suite-subsidiary.mov