Problem/Motivation

When duplicating a translated node, but duplicating only some translations (using the patch from #3215573: Allow Editors to choose whether to replicate all translations or only default language ), the translations of the paragraphs are still kept.

Steps to reproduce

Create a node with a translation. The node should contain a paragraph inside of another paragraph that allows nesting.
Duplicate the node, not keeping the translation (only the original language).
Go to the new node, to the translation language.
You see the translations from the original node, instead of the original language.

Proposed resolution

Fix in the onClone function.

Remaining tasks

Tests

User interface changes

API changes

Data model changes

Issue fork paragraphs-3485869

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

mathilde_dumond created an issue. See original summary.

mathilde_dumond’s picture

Status: Active » Needs review

Pushed a fix, but tests are missing. We have a test locally that passes with that.

berdir made their first commit to this issue’s fork.

berdir’s picture

Status: Needs review » Needs work

This is missing the replicateEntity() call now.

mathilde_dumond’s picture

Status: Needs work » Needs review

I have added that, and also a test for this change. I have run the test locally and it fails without the change, not sure how it works to test the failing tests now that we don't use patches anymore?

berdir’s picture

Status: Needs review » Fixed

Merged.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.