-
Notifications
You must be signed in to change notification settings - Fork 13k
regression(Contact Center): Empty contextual bar when creating a new contact from the omnichannel admin #38033
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
Conversation
…contact from the omnichannel admin
|
Looks like this PR is not ready to merge, because of the following issues:
Please fix the issues and try again If you have any trouble, please check the PR guidelines |
|
WalkthroughExpanded the contact-route hook's early-return condition to also treat Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Suggested reviewers
Poem
Pre-merge checks and finishing touches✅ Passed checks (5 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## release-8.0.0 #38033 +/- ##
=================================================
- Coverage 70.68% 70.65% -0.04%
=================================================
Files 3145 3145
Lines 108720 108726 +6
Branches 19501 19546 +45
=================================================
- Hits 76852 76821 -31
- Misses 29874 29904 +30
- Partials 1994 2001 +7
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No issues found across 1 file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
apps/meteor/client/views/omnichannel/hooks/useContactRoute.ts (1)
16-17: Addition ofomnichannel-current-chatsroute looks correct for the regression fix.The expanded condition properly handles navigation from the current chats view to ensure the contacts tab is selected. However, the TODO indicates this is a partial solution.
Would you like me to help identify other routes that might need similar handling, or create an issue to track the comprehensive route mapping mentioned in the TODO?
📜 Review details
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Disabled knowledge base sources:
- Jira integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
apps/meteor/client/views/omnichannel/hooks/useContactRoute.ts
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{ts,tsx,js}
📄 CodeRabbit inference engine (.cursor/rules/playwright.mdc)
**/*.{ts,tsx,js}: Write concise, technical TypeScript/JavaScript with accurate typing in Playwright tests
Avoid code comments in the implementation
Files:
apps/meteor/client/views/omnichannel/hooks/useContactRoute.ts
🧠 Learnings (2)
📚 Learning: 2025-12-18T15:18:31.688Z
Learnt from: gabriellsh
Repo: RocketChat/Rocket.Chat PR: 37773
File: apps/meteor/client/views/mediaCallHistory/MediaCallHistoryInternal.tsx:24-34
Timestamp: 2025-12-18T15:18:31.688Z
Learning: In apps/meteor/client/views/mediaCallHistory/MediaCallHistoryInternal.tsx, for internal call history items, the item.contactId is guaranteed to always match either the caller.id or callee.id in the call data, so the contact resolution in getContact will never result in undefined.
Applied to files:
apps/meteor/client/views/omnichannel/hooks/useContactRoute.ts
📚 Learning: 2025-11-24T17:08:17.065Z
Learnt from: CR
Repo: RocketChat/Rocket.Chat PR: 0
File: .cursor/rules/playwright.mdc:0-0
Timestamp: 2025-11-24T17:08:17.065Z
Learning: Applies to apps/meteor/tests/e2e/page-objects/**/*.ts : Utilize existing page objects pattern from `apps/meteor/tests/e2e/page-objects/`
Applied to files:
apps/meteor/client/views/omnichannel/hooks/useContactRoute.ts
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
- GitHub Check: 📦 Build Packages
- GitHub Check: cubic · AI code reviewer
- GitHub Check: CodeQL-Build
- GitHub Check: CodeQL-Build
🔇 Additional comments (1)
apps/meteor/client/views/omnichannel/hooks/useContactRoute.ts (1)
18-26: The code already passes the new contact's id tohandleNavigateafter creation.The contact creation flow in
useCreateContact.tsexplicitly passes the newly created contact'sid(returned ascontactIdfrom the API response) when callinghandleNavigate({ context: 'details', id: contactId })in theonSuccesscallback (line 18). The fallback logic inuseContactRoute.tsline 23 (id || currentParams.id) is a defensive measure for other scenarios but is not relied upon for newly created contacts. The implementation correctly ensures the new contact id is always provided during navigation after creation.Likely an incorrect or invalid review comment.
Proposed changes (including videos or screenshots)
Issue(s)
CORE-1599
Steps to test or reproduce
Further comments
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.