-
Notifications
You must be signed in to change notification settings - Fork 3k
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
[Due for payment 2025-02-25] Per diem - RHP shows offline view when deleted, fields are not grayed out when edited offline #54488
Comments
Triggered auto assignment to @marcaaron ( |
💬 A slack conversation has been started in #expensify-open-source |
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
|
Edited by proposal-police: This proposal was edited at 2024-12-24 04:46:36 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.In Step 6, after deleting the rate, RHP shows offline view while dismissing What is the root cause of that problem?This new feature comes from: #53625
The navigation take time to dismiss modal, and after deleting the subRate we're removing it in optimistic data App/src/libs/actions/Policy/PerDiem.ts Lines 233 to 237 in 8b7096f
that causes
We didn't update pendingAction and pendingFields in edit action App/src/libs/actions/Policy/PerDiem.ts Lines 284 to 286 in 8b7096f
... and didn't wrap so we don't see the gray out option What changes do you think we should make in order to solve the problem?
Here is the sample code
then wrap every menu item inside For example:
to
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?What alternative solutions did you explore? (Optional)Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job. ResultScreen.Recording.2024-12-24.at.11.41.42.mov |
@marcaaron What do you think about my proposal. I can create the quick PR for this DB |
Proposal looks good to me. But does this needs to be implemented as part of original PR #53625 given that we are still in regression period. |
@parasharrajat It's the new feature and I think it's hard to cover all cases. By the way, offline mode is quite complex to implement so it can be handle in the separate PR. cc @marcaaron |
Not sure about that. Let's wait for Marc's reply. There are a few issues poping up from per diem implementation. May be there are pending things from the design doc. |
Step 7 is intentional since we are using Pattern A here. |
Yeah, lets please implement this as part of the original PR, it's definitely a regression that should be fixed. @parasharrajat @daledah |
I'm going to remove the blocker label since this is pretty edge-casey, and it seems we need to sort out which pattern is intended here. |
In that case, I am going to tag the original Author/C+. @shubham1206agra Can you please look into this as it is a regression from your PR? |
@jasperhuangg I think the only bug is in step 6. Step 7 is intentional. Please update the issue to reflect that. |
@marcaaron Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
@marcaaron Huh... This is 4 days overdue. Who can take care of this? |
@marcaaron 6 days overdue. This is scarier than being forced to listen to Vogon poetry! |
@shubham1206agra Have you created the fix yet? |
Not yet, but planning to do so today itself. |
@marcaaron 10 days overdue. I'm getting more depressed than Marvin. |
@marcaaron I can help to create the PR fix to speed it up cc @parasharrajat |
And I can review asap. |
@daledah Thanks for the help, but I don't think your proposal is correct. |
ProposalPlease re-state the problem that we are trying to solve in this issue.RHP shows offline view when deleted, fields are not grayed out when edited offline What is the root cause of that problem?When deleting a Per Diem rate in offline mode, the deleted rate is removed from Onyx, causing
So we will briefly show the offline page before closing the modal
What changes do you think we should make in order to solve the problem?To resolve this issue, we should update the condition for displaying the offline page to ensure that it is not displayed unnecessarily after navigating back Update to const [hasNavigatedBack, setHasNavigatedBack] = useState(false);
let FullPageBlockingView;
if (hasNavigatedBack) {
FullPageBlockingView = View;
} else if (isEmptyObject(selectedSubRate)) {
FullPageBlockingView = FullPageOfflineBlockingView;
} else {
FullPageBlockingView = View;
}
Update to const handleDeletePerDiemRate = () => {
...
setHasNavigatedBack(true);
...
}; What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?This is a UI bug and does not require a unit test What alternative solutions did you explore? (Optional)Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job. |
@marcaaron 12 days overdue now... This issue's end is nigh! |
This issue has not been updated in over 14 days. @marcaaron eroding to Weekly issue. |
This'll be fixed by @shubham1206agra as part of the per diem project |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.99-2 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue: If no regressions arise, payment will be issued on 2025-02-25. 🎊 |
@Gonals No payment required here. Please close this issue. |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 9.0.78-0
Reproducible in staging?: Y
Reproducible in production?: N
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: N/A
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause - Internal Team
Action Performed:
Expected Result:
In Step 6, after deleting the rate, RHP will not show offline view
Actual Result:
In Step 6, after deleting the rate, RHP shows offline view while dismissing
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
Bug6701539_1734998541203.20241224_075747.mp4
Bug6701539_1734998541202!German_Per_Diem_-Dependent_Tags___2.csv
View all open jobs on GitHub
The text was updated successfully, but these errors were encountered: