#2 - Get the billing grace end period collection with useOnyx#83033
Conversation
|
@shubham1206agra Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
No product review needed |
Reviewer Checklist
Screenshots/VideosScreen.Recording.2026-02-22.at.11.23.51.PM.mov |
…ng-grace-period-subscription-utils-2
|
@tgolen Please review this PR |
tgolen
left a comment
There was a problem hiding this comment.
Can you please update or add some basic unit tests for shouldRestrictUserBillableActions() to ensure this parameter is covered?
| const [activePolicy] = useOnyx(`${ONYXKEYS.COLLECTION.POLICY}${activePolicyID}`); | ||
| const [session] = useOnyx(ONYXKEYS.SESSION, {selector: sessionSelector}); | ||
| const [allTransactionDrafts] = useOnyx(ONYXKEYS.COLLECTION.TRANSACTION_DRAFT); | ||
| const [userBillingGraceEndPeriodCollection] = useOnyx(ONYXKEYS.COLLECTION.SHARED_NVP_PRIVATE_USER_BILLING_GRACE_PERIOD_END); |
There was a problem hiding this comment.
| const [userBillingGraceEndPeriodCollection] = useOnyx(ONYXKEYS.COLLECTION.SHARED_NVP_PRIVATE_USER_BILLING_GRACE_PERIOD_END); | |
| const [userBillingGraceEndPeriods] = useOnyx(ONYXKEYS.COLLECTION.SHARED_NVP_PRIVATE_USER_BILLING_GRACE_PERIOD_END); |
Would you be OK to rename this? "collection" is redundant.
There was a problem hiding this comment.
Yeah, it'd be consistent with the other collections, such as reports, reportActions, etc. Updated!
…ng-grace-period-subscription-utils-2
|
@tgolen we already have the test for it App/tests/unit/SubscriptionUtilsTest.ts Lines 255 to 283 in a152afa |
tgolen
left a comment
There was a problem hiding this comment.
Cool, thanks! This looks good.
|
Ah... @bernhardoj looks like prettier is failing. Can you fix that please? |
…ng-grace-period-subscription-utils-2
|
@tgolen fixed |
|
🚧 @tgolen has triggered a test Expensify/App build. You can view the workflow run here. |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/tgolen in version: 9.3.28-0 🚀
|
|
Hi @bernhardoj. Can you please check if the script is correct? QA team can not see the restricted modal when clicking 83033W.1.mp4 |
|
@bernhardoj @tgolen @danieldoglas Is this one requires DEW enabled account to test? |
|
@IuliiaHerets you need to replace the @m-natarajan it's not needed |
|
🚀 Deployed to staging by https://github.com/tgolen in version: 9.3.30-0 🚀
|
|
🚀 Deployed to production by https://github.com/blimpich in version: 9.3.30-3 🚀
|
Explanation of Change
Fixed Issues
$ #66456
PROPOSAL:
Tests
Same as QA Steps
Offline tests
Same as QA Steps
QA Steps
Onyx.merge('sharedNVP_private_billingGracePeriodEnd_[replaceWithYourACcountID]', {value: 1});in consolePR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand 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
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
ewb.mp4