Closed marcaaron closed 6 months ago
@s77rt offer for $250 sent via upwork!
Actually there were many regressions / missed cases: https://github.com/Expensify/App/issues/39247 https://github.com/Expensify/App/issues/39295 https://github.com/Expensify/App/issues/39254 https://github.com/Expensify/App/issues/39323 https://github.com/Expensify/App/issues/39560
Interesting. Curious if @marcaaron you agree that all of these were regressions?
Reason I ask is each regression typically reduces bounty by 50%. So if there were 6 regressions here, the bounty would be reduced from $500 > $8. So want to be super sure that each of them was in fact a regression.
Noting that @marcaaron and I discussed this 1:1 and decided that there should be no regression penalties here. Marc flagged that @s77rt has gone above and beyond to do a great job working on this project, and any missed cases are not indicative of mistakes or anything like that.
So we're going to pay out the full $500 to @s77rt for this one via Upwork.
Thank you! I have accepted the Upwork offer
@s77rt $500 sent and contract ended!
Upwork job closed.
All set. TY!
⚠️ Looks like this issue was linked to a Deploy Blocker here
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.
If a regression has occurred and you are the assigned CM follow the instructions here.
If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.
Holding on:
Group Chats Design Doc
Changes described in detail here.
Goals
Current UI:
New UI (with differences noted):
API call:
chatType
togroup
when callingOpenReport
so the backend will know we are creating a "Group Chat" and add a constant for this.%firstName%
,%firstName%
, …. one for each member, with the first member alphabetically appearing first (leftmost)Group
chat contains only one member because everyone else has left, then the default name will be%firstName%’s group chat
groupChatAdminLogins
. For now, it will include the creator of the chat only.Migration notes:
reportID
(as this won't ever change) similar to how the default avatars are generated.This will all need to be performed in one App PR. We will hard deprecate older versions after it is deployed to production by updating the minimum app version so there is a hard dependency on this PR getting approved and merged:
Other things to note:
'hidden'
until a comment is left. We must ensure this behavior is preserved.Implementation notes:
Our existing screen for this flow is: NewChatSelectorPage, but the Chat tab section is the NewChatPage. Its Modal stack navigator is here.
We need to: Modify the “Create group” button so that it says “Next”. Add an additional page to the NewChatSelectorPage stack navigator. Create a new page which we will call NewChatConfrmPage Add the appropriate routes for this page at /new/chat/confirm
Switching the button to “Next” here when we have tapped the “Add to group” option. Navigating to the new page
We need to add logic to navigate the user to the confirm page when they have selected “Add to group” here and have some staging participants.
We’ll also need some way for this new page to access those participants. The selectedOptions are currently stored here and house the members being added to the group. We will move them to a new Onyx key called newGroupChat that will be exclusively used to hold the state for a Group chat that is in the process of being created. This will allow the user to refresh the page and pick up where they left off (which is not possible today) and also allow us to share this state between all pages in the flow.
Start group button By this point, the newGroupChat Onyx state should have the following required data for the OpenReport API call: optimisticReportID optimistic accountIDs for any participants groupChatAdminLogins - should only contain the creator reportName - empty string (for now)
onPress we will navigate to the report just like we do already for Group DMs.
To do this, we will modify the navigateAndOpenReport() method here to handle the: memberRoles (if any) reportName
It already handles the logins. So, we need to add arguments for roles and reportName to that method. We must also modify the logic here when we have the group chat case since we won’t ever need to get an existing chat and will always be creating one.
The optimisticReport returned from ReportUtils.buildOptimisticChatReport() must be modified to update the participants field (see refactor plan here) with the corresponding role for each participant. Finally, the optimistic report is passed here to be created in the server. We must also pass the memberRoles as it will contain the link between any optimistic accountID and the login/email.
Group chat avatars will also need to display correctly in the Search function, Report header, details page, etc. We must modify the methods that get the avatars from personal details or workspace and first check for the report.avatarUrl. We can modify the existing ReportUtils.getIcons() method to first check the report.avatarUrl when we have a “Group chat” and fallback to a default avatar based off of the reportID.
Upwork Automation - Do Not Edit