Fix notification card links to use redirect URL#7665
Fix notification card links to use redirect URL#7665jacksbox-cassandra wants to merge 3 commits intonextcloud:mainfrom
Conversation
| $this->assertEquals($notification, $actualNotification); | ||
| } | ||
|
|
||
| public function testPrepareCardAssigned() { |
There was a problem hiding this comment.
This function is duplicated.
There was a problem hiding this comment.
Fixed! Renamed to testPrepareCardAssignedUsesRedirectUrl in commit b56448b. Thanks for the review!
|
Thanks for catching that @luka-nextcloud! 🙏 I've renamed the duplicate test method to Commit: b56448b |
b56448b to
0ad1255
Compare
jacksbox-cassandra
left a comment
There was a problem hiding this comment.
Hi @luka-nextcloud, thank you for the review! I've fixed the duplicate function issue. The second 'testPrepareCardAssigned' function has been renamed to 'testPrepareCardAssignedUsesRedirectUrl' to clarify its purpose (it specifically tests that card assignment notifications use the redirect URL pattern). The duplicate function names that were causing the issue have been resolved.
- Change card notifications to use redirectToCard route instead of direct board/card URL - This ensures notifications properly open the card modal regardless of current state - Add getCardRedirectUrl method to Notifier class - Update tests to verify redirect URL functionality - Fixes issue nextcloud#2469: Notifications should open card Signed-off-by: jacksbox_cassandra <jacksbot2026@gmail.com>
…ectUrl Addresses review feedback: the added test method had the same name as an existing method with a data provider, causing a duplicate function declaration. Renamed to testPrepareCardAssignedUsesRedirectUrl to clarify its purpose (verifying that card-assigned notifications use the redirect URL pattern). Signed-off-by: jacksbox_cassandra <jacksbot2026@gmail.com>
0ad1255 to
b62e6b3
Compare
Summary
This PR fixes issue #2469 where notifications for cards (due dates, assignments, comments) do not properly open the card when clicked.
Problem
Currently, card notifications use direct board/card URLs, which may not properly open the card modal if the user doesn't have the board loaded in their session or if there are routing issues.
Solution
Changed card notifications to use the redirect URL instead, which:
Changes
Testing
Fixes #2469