Closed izarutskaya closed 11 months ago
Job added to Upwork: https://www.upwork.com/jobs/~017cd1e2909d9808bd
Triggered auto assignment to @mallenexpensify (Bug
), see https://stackoverflow.com/c/expensify/questions/14418 for more details.
Platforms
in OP are ✅)Triggered auto assignment to Contributor-plus team member for initial proposal review - @thesahindia (External
)
:wave: 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:
Triggered auto assignment to @mountiny (Engineering
), see https://stackoverflow.com/c/expensify/questions/4319 for more details.
I'm available for a fix immediately.
Custom invitation message is still preserved after sending an invitation
After sending the message, the savedWelcomeMessage
onyx key is not cleared.
To fix this issue, we need to clear the onyx key in the sendInvitation
method.
Onyx.set(`${ONYXKEYS.FORMS.WORKSPACE_INVITE_MESSAGE_FORM}Draft`, message);
Another logical issue in this implementation is that custom message is the same across all workspaces, even if we do not invite any user. We need to implement the Onyx Key using policy ID and then proceed accordingly.
Seems like a regression from https://github.com/Expensify/App/issues/27902
As per https://github.com/Expensify/App/issues/27902#issuecomment-1781394926, this is the expected behaviour.
This seems to be intended behaviour now.
Just wondering about a feature request - What if I want to reset to the default welcome message? There is no way to do that with the current workflow I think
We will discuss if we want to change anything about this flow or not.
Upwork job price has been updated to $250
Current assignee @mallenexpensify is eligible for the NewFeature assigner, not assigning anyone new.
Based on the internal discussion this is not a bug but a new feature which is desired, however as such I am making this weekly and lower value issue as we dont have to focus on this so much https://expensify.slack.com/archives/C03U7DCU4/p1699364509319509
@mountiny Thank you for the update, can you please share the latest expected results?
I have updated the OP, let me know if its not clear, thanks!
This is a feature request.
The simplest way to implement the change would be via these 2 changes:
key: ({route}) => `${ONYXKEYS.FORMS.WORKSPACE_INVITE_MESSAGE_FORM}_${route.params.policyID.toString()}Draft`,
formID={`${ONYXKEYS.FORMS.WORKSPACE_INVITE_MESSAGE_FORM}_${this.props.route.params.policyID.toString()}`}
@GItGudRatio, please follow the proposal guidelines correctly. You
What is the root cause of that problem?
This is a feature request.
You have to add some info about the code that is responsible for the current behaviour.
What changes do you think we should make in order to solve the problem?
The simplest way to implement the change would be via these 2 changes:
You need to use simple english to explain your solution. You have to describe what your solution is and how it will work.
workspaceInviteMessageFormDraft
to store the invite message draft. Here is an example value:
{welcomeMessage: "You have been invited to ws! Download the Expensify mobile app at use.expensify.com/download to start tracking your expenses. "}
the welcomeMessage
. The workspaceInviteMessageFormDraft
value is shared between the workspaces.invitedEmailsToAccountIDsDraft
)
https://github.com/Expensify/App/blob/82ee5775e9beecaf3163d13199ffd91d7b521527/src/pages/workspace/WorkspaceInviteMessagePage.js#L252-L254 Do it by these below steps:
WORKSPACE_INVITE_MESSAGE_DRAFT
function setWorkspaceInviteMessageDraft(policyID, message) {
Onyx.set(`${ONYXKEYS.COLLECTION.WORKSPACE_INVITE_MESSAGE_DRAFT}${policyID}`, message)
}
ONYXKEYS.COLLECTION.WORKSPACE_INVITE_MESSAGE_DRAFT
by updating:
https://github.com/Expensify/App/blob/82ee5775e9beecaf3163d13199ffd91d7b521527/src/pages/workspace/WorkspaceInviteMessagePage.js#L255-L258
to:
workspaceInviteMessageDraft: {
key: `${ONYXKEYS.COLLECTION.WORKSPACE_INVITE_MESSAGE_DRAFT}`,
},
shouldSaveDraft: false
because we do not need to use the form draft feature anymore:
https://github.com/Expensify/App/blob/82ee5775e9beecaf3163d13199ffd91d7b521527/src/pages/workspace/WorkspaceInviteMessagePage.js#L231workspaceInviteMessageDraft
by updating:
https://github.com/Expensify/App/blob/82ee5775e9beecaf3163d13199ffd91d7b521527/src/pages/workspace/WorkspaceInviteMessagePage.js#L79
to:
welcomeNote: this.props.workspaceInviteMessageDraft || this.getDefaultWelcomeNote(),
onChangeText={(text) => {
Policy.setWorkspaceInviteMessageDraft(this.props.route.params.policyID, text);
this.setState({welcomeNote: text});
}}
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸
@thesahindia can you please review @DylanDylann 's proposal above?
@mallenexpensify, @mountiny, @thesahindia Eep! 4 days overdue now. Issues have feelings too...
Bumped for proposal review in Slack
Sorry for the delay. I missed the notifications and, unfortunately, I will need to unassign myself. I'm not in a good shape.
📣 @akinwale 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!
Offer link Upwork job Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑💻 Keep in mind: Code of Conduct | Contributing 📖
Taking over as C+ here.
@DylanDylann's proposed solution follows an existing pattern of storing relevant data on a per-workspace basis using Onyx, so I recommend we move forward with the proposal.
🎀 👀 🎀 C+ reviewed.
Triggered auto assignment to @thienlnam, see https://stackoverflow.com/c/expensify/questions/7972 for more details.
Looks like @mountiny is already assigned and has the context so will leave to him
📣 @DylanDylann 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!
Offer link Upwork job Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑💻 Keep in mind: Code of Conduct | Contributing 📖
@akinwale PR https://github.com/Expensify/App/pull/31770 is ready to review
Reviewing
label has been removed, please complete the "BugZero Checklist".
The solution for this issue has been :rocket: deployed to production :rocket: in version 1.4.4-3 and is now subject to a 7-day regression period :calendar:. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2023-12-06. :confetti_ball:
After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
For reference, here are some details about the assignees on this issue:
BugZero Checklist: The PR adding this new feature has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
Contributor: @DylanDylann paid $250 via Upwork Contributor+: @akinwale paid $250 via Upwork
@akinwale can you please propose the regression test steps to add for the new feature? Thx
@akinwale, @mallenexpensify, @mountiny, @DylanDylann Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
@akinwale bump please
@akinwale bump please
Missed the initial notification. I'll get to it within an hour.
BugZero Checklist: The PR adding this new feature has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
- [x] [@akinwale] Please propose regression test steps to ensure the new feature will work correctly on production in further releases.
Do we agree 👍 or 👎?
@akinwale I would update this to make it clear that the custom message should stay same on the particular workspace, ie its different across workspaces but remains unchanged on the same workspace
@mountiny Updated.
Thanks, @mallenexpensify all yours!
Thanbks @akinwale !
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Found when executing PR : https://github.com/Expensify/App/pull/30562
Version Number: v1.3.96-0 Reproducible in staging?: Y Reproducible in production?: N If this was caught during regression testing, add the test name, ID and link from TestRail: Email or phone of affected tester (no customers): Logs: https://stackoverflow.com/c/expensify/questions/4856 Expensify/Expensify Issue URL: Issue reported by: Applause-Internal Team Slack conversation: @
Action Performed:
Expected Result:
The invitation messages are saved per workspace basis. They are reset after signout out and sign back in but while user is signed in, we keep the welcome message saved per workspace
Actual Result:
The custom invitation message is preserved across policies
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
https://github.com/Expensify/App/assets/115492554/71e3857f-198c-4f74-ae13-228a958e618b
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @mallenexpensify