-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
T15098 Mvc\Model delete cascade relations with params #15126
T15098 Mvc\Model delete cascade relations with params #15126
Conversation
Altered fixtures to use params in relation
Added test for Mvc\Model::delete() with related items
I have a fix for this (#15098) for the 4.0.x branch as well, you can find it here: https://github.com/zsilbi/cphalcon/tree/T15098-related-cascade-delete |
…appen for hasOne relations)
419bc02
to
354ed04
Compare
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.
Looks good to me. Giving the rest team a day or two to review as well otherwise I'll merge this for the 4.1 release.
Hello!
In raising this pull request, I confirm the following:
Small description of change:
Modified
Mvc\Model::_checkForeignKeysReverseCascade()
to useModels\Manager::getRelationRecords()
when deleting related records.Added tests for:
Mvc\Model::getRelated()
andMvc\Model::delete()
to ensure theparams
option is used properly when accessing and deleting related models.Thanks,
zsilbi