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 was archived by the owner on Mar 26, 2025. It is now read-only.
Create a Text plugin with some simple text content
Save and publish the page
Go to edit mode again and edit the same Text plugin
Add any plugin using CMS Plugins menu
Click cancel
Reload the page
Expected result
Only new nested plugin was removed, but the text content and old plugins remains the same
Actual result
The whole content of plugin is cleared, the whole old published content is lost
Analysis
I've tried to debug the issue and found that cms.admin.placeholderadmin.PlaceholderAdminMixin.edit_plugin is called on Cancel click because newly created plugins should be cleared, which is make sense. Although inside that method I can see that new Text plugin instance is created, then plugins which are not needed should be cleared. But even adding plugin.body = obj.body there doesn't help, because it's being overwritten somewhere inside in operations.CHANGE_PLUGIN calls.
Do you have any ideas where to look at? I have a feeling that it's something with post_placeholder_operation call which doesn't copy the content from the old plugin, but not sure.
djangocms-test-ckeditor==5.1.1 (also reproducible with 5.1.2)
djangocms==3.9.0 (but also reproducible with 3.11.1)