Repository navigation
[HOLD for payment 2024-12-05] [$250] Invoices - App opens workspace description settings when clicking on invoice description text #51976
Description
Activity
- addedDailyKSv2KSv2BugSomething is broken. Auto assigns a BugZero manager.Something is broken. Auto assigns a BugZero manager.
on Nov 4, 2024 Triggered auto assignment to @zanyrenney (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.Edited by proposal-police: This proposal was edited at 2024-11-04 18:00:25 UTC.
Proposal
Please re-state the problem that we are trying to solve in this issue.
App opens workspace description settings when clicking on invoice description text
What is the root cause of that problem?
We navigate to WORKSPACE_PROFILE_DESCRIPTION here
App/src/components/ReportWelcomeText.tsx
Lines 126 to 129 in fcb4a5b
if (!canEditPolicyDescription) { return; } Navigation.navigate(ROUTES.WORKSPACE_PROFILE_DESCRIPTION.getRoute(policy?.id ?? '-1')); What changes do you think we should make in order to solve the problem?
Change to the following
const activeRoute = Navigation.getReportRHPActiveRoute(); if (ReportUtils.canEditReportDescription(report, policy)) { Navigation.navigate(ROUTES.REPORT_DESCRIPTION.getRoute(report?.reportID ?? '-1', activeRoute)); return; } Navigation.navigate(ROUTES.REPORT_WITH_ID_DETAILS.getRoute(report?.reportID ?? '-1', activeRoute));What alternative solutions did you explore? (Optional)
Proposal
Please re-state the problem that we are trying to solve in this issue.
App opens workspace description settings when clicking on the invoice description text.
What is the root cause of that problem?
When we click to this description, we'll navigate to workspace description here
App/src/components/ReportWelcomeText.tsx
Line 129 in fcb4a5b
Navigation.navigate(ROUTES.WORKSPACE_PROFILE_DESCRIPTION.getRoute(policy?.id ?? '-1')); What changes do you think we should make in order to solve the problem?
We should navigate to the report description when it is Invoice room
ReportUtils.isInvoiceRoom(report) ? Navigation.navigate(ROUTES.REPORT_DESCRIPTION.getRoute(report?.reportID ?? '-1')) : Navigation.navigate(ROUTES.WORKSPACE_PROFILE_DESCRIPTION.getRoute(policy?.id ?? '-1'));What alternative solutions did you explore? (Optional)
NA
Proposal
Please re-state the problem that we are trying to solve in this issue.
App opens workspace description settings when clicking on invoice description text
What is the root cause of that problem?
Here we are navigating to workspace profile description page instead of report description page
App/src/components/ReportWelcomeText.tsx
Line 129 in fcb4a5b
Navigation.navigate(ROUTES.WORKSPACE_PROFILE_DESCRIPTION.getRoute(policy?.id ?? '-1')); What changes do you think we should make in order to solve the problem?
We don't need the
canEditPolicyDescriptionas we are not navigating to policy description page anymore
App/src/components/ReportWelcomeText.tsx
Lines 126 to 128 in fcb4a5b
if (!canEditPolicyDescription) { return; } and instead of navigating to policy description page here, let's change this to
const activeRoute = Navigation.getReportRHPActiveRoute(); Navigation.navigate(ROUTES.REPORT_DESCRIPTION.getRoute(report?.reportID ?? '-1', activeRoute));Note
We don’t need the
canEditReportDescriptioncheck here since it’s already handled inRoomDescriptionPage.tsx, where users see a different view if they can’t edit the description(not the policy admin). Removing this check allows users to click on the description and navigate to the invoice room description, ensuring consistency with the behavior when accessing the room description from the header.Screen.Recording.2024-11-05.at.12.02.58.AM.mov
We should also remove these styles
canEditPolicyDescription ? styles.cursorPointer : styles.cursorTextApp/src/components/ReportWelcomeText.tsx
Line 131 in fcb4a5b
style={[styles.renderHTML, canEditPolicyDescription ? styles.cursorPointer : styles.cursorText]} What alternative solutions did you explore? (Optional)
If we want to prevent users from navigating to the description page when they can't edit it, we can implement the following solution:
Let's add a new check, we use the same check on
RoomDescriptionPage.tsxconst canEdit = ReportUtils.canEditReportDescription(report, policy);then we can change these
canEditPolicyDescriptiontocanEdit
App/src/components/ReportWelcomeText.tsx
Line 131 in fcb4a5b
style={[styles.renderHTML, canEditPolicyDescription ? styles.cursorPointer : styles.cursorText]}
App/src/components/ReportWelcomeText.tsx
Line 126 in fcb4a5b
if (!canEditPolicyDescription) { and at last let's change this link
const activeRoute = Navigation.getReportRHPActiveRoute(); Navigation.navigate(ROUTES.REPORT_DESCRIPTION.getRoute(report?.reportID ?? '-1', activeRoute));With this solution, users who cannot edit the report description will see the text cursor when hovering over it, indicating it's not editable.
adding external!
- addedExternalAdded to denote the issue can be worked on by a contributorAdded to denote the issue can be worked on by a contributor
on Nov 7, 2024 - changed the title
[-]Invoices - App opens workspace description settings when clicking on invoice description text[/-][+][$250] Invoices - App opens workspace description settings when clicking on invoice description text[/+]on Nov 7, 2024 Job added to Upwork: https://www.upwork.com/jobs/~021854589048868933801
- addedHelp WantedApply this label when an issue is open to proposals by contributorsApply this label when an issue is open to proposals by contributors
on Nov 7, 2024 Triggered auto assignment to Contributor-plus team member for initial proposal review - @alitoshmatov (
External)@zanyrenney, @alitoshmatov Whoops! This issue is 2 days overdue. Let's get this updated quick!
18 remaining items
- addedWeeklyKSv2KSv2Awaiting PaymentAuto-added when associated PR is deployed to productionAuto-added when associated PR is deployed to productionand removedWeeklyKSv2KSv2
on Nov 28, 2024 - changed the title
[-][$250] Invoices - App opens workspace description settings when clicking on invoice description text[/-][+][HOLD for payment 2024-12-05] [$250] Invoices - App opens workspace description settings when clicking on invoice description text[/+]on Nov 28, 2024 Reviewinglabel has been removed, please complete the "BugZero Checklist".The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.67-9 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 2024-12-05. 🎊
For reference, here are some details about the assignees on this issue:
- @alitoshmatov requires payment through NewDot Manual Requests
- @Nodebrute requires payment automatic offer (Contributor)
@alitoshmatov @zanyrenney @alitoshmatov The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]
BugZero Checklist:
- [Contributor] Classify the bug:
Bug classification
Source of bug:
- 1a. Result of the original design (eg. a case wasn't considered)
- 1b. Mistake during implementation
- 1c. Backend bug
- 1z. Other:
Where bug was reported:
- 2a. Reported on production (eg. bug slipped through the normal regression and PR testing process on staging)
- 2b. Reported on staging (eg. found during regression or PR testing)
- 2d. Reported on a PR
- 2z. Other:
Who reported the bug:
- 3a. Expensify user
- 3b. Expensify employee
- 3c. Contributor
- 3d. QA
- 3z. Other:
-
[Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to comment: https://github.com/Expensify/App/pull/49919/files#r1870335962
-
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: No discussion started
-
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
Regression Test Proposal Template
-
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Link to issue:
Regression Test Proposal
Precondition:
Test:
- Go to FAB > Send Invoice.
- Send an invoice to any recipient.
- Navigate to the Invoice Chat.
- Click on the Invoice Chat Header.
- Select Room Description.
- Enter a description and save it.
- Return to the Invoice Chat.
- Click on the room description text displayed under "Say hello!".
- Verify that the app opens the Invoice Room Description.
Do we agree 👍 or 👎
Reacted by Zany RenneyNice, thanks for doing this @alitoshmatov
payment summary
@alitoshmatov requires payment through NewDot Manual Requests - please request $250 on ND.
@Nodebrute requires payment automatic offer (Contributor) - paid $250 in Upwork.$250 approved for @alitoshmatov
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number: 9.0.57-0
Reproducible in staging?: Y
Reproducible in production?: Y
Email or phone of affected tester (no customers): applausetester+kh25100005@applause.expensifail.com
Issue reported by: Applause Internal Team
Action Performed:
Expected Result:
App will open invoice room description settings.
Actual Result:
App opens workspace description settings when clicking on the invoice description text.
This issue only happens in invoice room.
Workaround:
Unknown
Platforms:
Screenshots/Videos
Bug6654526_1730740619973.20241105_011217.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @zanyrenney