Review 13.4 Merged

87689[BUGFIX] Sync language of inline children on copy

Benni Mack CR +2 V +2 Hard +507 −35 updated 01/10/25, 10:07

Commit message

There are three copy related DataHandler operations, each with
suble differences when elements are copied or localized to
different localizations:

* "copy" is a "free mode" copy operation
* "copyToLanguage" is a "free mode" copy operation
* "localize" is a "connected mode" copy operation

"copy" (which uses DH copyRecord()) and "copyToLanguage" (which
uses DH localize()) are quite similar, except sorting and record
prefixing details. This distinction is unfortunate and convoluted
in general, but there is also a straight issue: When using "copy"
(typically from clipboard), copied inline children do not get the
correct sys_language_uid set.

The patch adapts behavior of inline elements to that of the parent
on copy: The language field of all copied records is updated after
the actual copying has taken place. This way not only the copied
parent but also its inline relations will have the new language value
when copied to another language.

The patch implements an according loopt to DH process_cmdmap()
together with a relatively straight code refactoring and a hint
this overall scenario should be streamlined.

Review

  • Code review CR +2 Done
    • Benni Mack +2
  • Verified V +2 Done
    • Benni Mack +2
    • core-ci +1 CI

Issues 4

Files 15

Review log 34

  1. Benni Mack commented on patch set 1 01/10/25, 09:55

    Cherry Picked from branch main.
  2. core-ci voted on patch set 1 V +1 01/10/25, 10:02 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/72200

  3. Benni Mack voted on patch set 1 CR +2 V +2 01/10/25, 10:07

  4. Benni Mack merged patch set 2 01/10/25, 10:07