You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 29, 2019. It is now read-only.
The Article model has a content field of type PlaceholderField (internally it's a ForeignKey) that is used to receive at least the TextPlugin for the body of an article - the cms_wizards automatically add a TextPlugin if content is filled in the form, indeed.
But I realized that when you remove article(s) on the admin, it's not removing none of those, the placeholder used by the content field and its related plugins.
Try this:
Create an Article with content
Note the TextPlugin's id and the Placeholder's id of content field
Remove the article
Query for the plugin's id on CMSPlugin model - it'll still there
Query for the placeholder's id on Placeholder model - it'll still there
I think it's a problem because generates garbage - useless registers - on yout database.
Maybe it's actually a design issue on Django CMS's PlaceholderField that do not delete cascade by default.
The text was updated successfully, but these errors were encountered:
sidneijp
changed the title
content's PlaceholderField and related TextPlugin isn't deleted when an Article is remove
content's PlaceholderField and related TextPlugin isn't deleted when an Article is removed
Apr 10, 2017
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The
Article
model has acontent
field of typePlaceholderField
(internally it's aForeignKey
) that is used to receive at least theTextPlugin
for the body of an article - the cms_wizards automatically add aTextPlugin
ifcontent
is filled in the form, indeed.But I realized that when you remove article(s) on the admin, it's not removing none of those, the placeholder used by the content field and its related plugins.
Try this:
TextPlugin
's id and thePlaceholder
's id ofcontent
fieldCMSPlugin
model - it'll still therePlaceholder
model - it'll still thereI think it's a problem because generates garbage - useless registers - on yout database.
Maybe it's actually a design issue on Django CMS's
PlaceholderField
that do not delete cascade by default.The text was updated successfully, but these errors were encountered: