[Taxes] Add extra decimal places, new API #38733
Conversation
|
I'm fixing the autofocus here. We need this PR merged soon, since the API changes are live and created this blocker already |
|
Added #38827 to the list of fixed issues here |
filip-solecki
left a comment
There was a problem hiding this comment.
LGTM, just one question
|
@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] |
|
@kosmydel Can you update your recordings to show 4 decimal limit? |
|
@kosmydel I am unable to put 012 as tax rate. Is this intentional? |
@kosmydel Why is tax categories missing in mobile device? Edit - Now, I am unable to see the default tax rates. |
I can do that tomorrow.
I think the limit here is 2 characters. I'm not sure if we want users to type more than 2 non-decimal digits? Cc @luacmartins |
I think we support this in other cases, e.g. request money and the resulting amount would just be 12. I think we shouldn't block on it though since the most important change in this PR is updating the API so it works correctly. |
luacmartins
left a comment
There was a problem hiding this comment.
Changes LGTM. We still need to decide on the number of decimals that we want to use for NewDot. Additionally, there are other small things we need to address:
- Zeros to the left should just be discarded, e.g. Users can enter 0012 and that should result in 12
- Users should be able to enter 100 as the max tax rate.
Reviewer Checklist
Screenshots/VideosAndroid: NativeScreen.Recording.2024-03-25.at.10.11.15.PM.movAndroid: mWeb ChromeScreen.Recording.2024-03-25.at.9.30.13.PM.moviOS: NativeScreen.Recording.2024-03-25.at.9.57.07.PM.moviOS: mWeb SafariScreen.Recording.2024-03-25.at.9.21.02.PM.movMacOS: Chrome / SafariScreen.Recording.2024-03-25.at.9.07.05.PM.movMacOS: DesktopScreen.Recording.2024-03-25.at.9.37.43.PM.mov |
shubham1206agra
left a comment
There was a problem hiding this comment.
This is looking good to me except minor comments made by @luacmartins
|
@luacmartins looks like this was merged without a test passing. Please add a note explaining why this was done and remove the |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
Should we set the max length then? Or should the user be able to enter something like I think letting the user enter 4 digits for the integer part, and 4 for the decimals, might be a good balance.
Right, going to change it. |
|
Users should be able to enter
Seems fine to me |


Details
This PR fixes two things:
Valuepage,UpdatePolicyTaxValueAPI calls to the new API.We've discussed on Slack, that for now, we want to support up to 4 decimal places.
Fixed Issues
$ #38499
$ #38208 (comment)
$ #38827
PROPOSAL: N/A
Tests
0.1234.11.1234.01.5,99.9999,Valuepage, and verify theValueinput is focused.Offline tests
N/A
QA Steps
TestssectionPR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))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.mov
Android: mWeb Chrome
mweb-android.mov
iOS: Native
ios.mp4
iOS: mWeb Safari
mweb-ios.mp4
MacOS: Chrome / Safari
web.mov
MacOS: Desktop
desktop.mov