Skip to content

[main] Add $changes->getBefore() to event in reorder#7124

Merged
grnd-alt merged 1 commit into
nextcloud:mainfrom
stpronk:patch-1
Jul 31, 2025
Merged

[main] Add $changes->getBefore() to event in reorder#7124
grnd-alt merged 1 commit into
nextcloud:mainfrom
stpronk:patch-1

Conversation

@stpronk

@stpronk stpronk commented Jul 21, 2025

Copy link
Copy Markdown
Contributor
  • Resolves: N/A
  • Target version: main

Summary

Added $changes->getBefore() to dispatched event to be able to see the before status when reordering. Now able to hook into the event and the the changes that have been made to be able to react properly to the given changes.

TODO

  • Review and resolve any conflicts

Checklist

  • Code is properly formatted
  • Sign-off message is added to all commits
  • Tests (unit, integration, api and/or acceptance) are included
  • Documentation (manuals or wiki) has been updated or is not required

@stpronk stpronk changed the title [FEATUER] Add $changes->getBefore() to event in reorder [main] Add $changes->getBefore() to event in reorder Jul 21, 2025

@grnd-alt grnd-alt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution, I can see how it would be useful to have these changes.
Would you mind sharing the app you mentioned in #7147, would be interesting to see how you are planning to use the events.

Comment thread lib/Service/CardService.php
if ($resetDuedateNotification) {
$this->notificationHelper->markDuedateAsRead($card);
}
$this->changeHelper->cardChanged($card->getId(), true);

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"true" is default here, redundant argument

@grnd-alt grnd-alt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code changes look good, great thanks🔥
You can pick out more places where the before attribute would be useful if you want, but I think we'd be ready to merge this right now as well.

Do you mind rebasing and squashing the 3 commits into 1 before merging?

@stpronk

stpronk commented Jul 30, 2025

Copy link
Copy Markdown
Contributor Author

@grnd-alt Awesome to hear! 🔥 I will take a look at the other services what can be done & will squash the commits afterwards. thanks for the feedback!

…ate where possible

Signed-off-by: StPronk <stpronk@gmail.com>
@stpronk

stpronk commented Jul 31, 2025

Copy link
Copy Markdown
Contributor Author

@grnd-alt Squashed the commits and rebased the branch!

Looked into the other services as well, yet I see more work there then initial thought. To keep the PR's clean, I will continue with it in separate branches!

@grnd-alt grnd-alt enabled auto-merge July 31, 2025 08:34
@grnd-alt grnd-alt self-requested a review July 31, 2025 08:34

@grnd-alt grnd-alt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great Thanks, and congratulations on your first contribution 🔥

@grnd-alt grnd-alt merged commit 58027c8 into nextcloud:main Jul 31, 2025
36 checks passed
@github-actions

github-actions Bot commented Aug 5, 2025

Copy link
Copy Markdown
Contributor

Hello there,
Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

(If you believe you should not receive this message, you can add yourself to the blocklist.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants