-
-
Notifications
You must be signed in to change notification settings - Fork 315
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
Disallow deleting pages if still attached to menu node #2338
Conversation
Unfortunately, I was not able to fix the new tests that I've added.
|
…e if a page is still linked to nodes, AlchemyCMS#2301
This pull request has not seen any activiy in a long time. |
This pull request has not seen any activiy in a long time. |
Still valid |
I've fixed the tests, but I don't understand why I had to apply that changes. |
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.
Thanks!
Add foreign key on nodes to restrict on delete page_id and add a warning on delete if a page is still linked to nodes. Closes #2301
Add foreign key on nodes to restrict on delete page_id and add a warning on delete if a page is still linked to nodes. Closes AlchemyCMS#2301
What is this pull request for?
It changes the behavior on delete of the node table's page_id foreign key from cascade to restrict.
When the user wants to delete a page, if it still linked to any node, we show a warning and abort the deletion.
Closes #2301
Checklist