| Creating a translation links it to the default record |
Core bugThe English article 1 is localized to German through DataHandler, the backend action "localize". DataHandler creates the German article 2 and links it: l10n_parent and l10n_source point to article 1, l10n_diffsource holds the values of article 1 at the time of the translation, and l10n_state marks the synchronized field subtitle as following its parent. |
DeviatesExtbase has no localize action. The twin creates a new object, sets its language to German through the property "_languageUid" and persists it with add() and persistAll(). Extbase writes the German article 2 with the language 1, but l10n_parent and l10n_source stay 0, l10n_diffsource stays empty and l10n_state stays NULL: the new row is not linked to article 1. |
| A translation copies the values of the default record |
The English article 1 is localized to German through DataHandler, the backend action "localize". DataHandler copies the values of the title and the subtitle from article 1 to the new German article 2. |
Same as coreExtbase has no localize action and copies nothing by itself. The twin reads article 1 through the repository, creates a new object with the language German (property "_languageUid"), assigns the title and the subtitle of article 1 in code and persists it with add() and persistAll(). The German article 2 has the same values as with DataHandler, because the code assigned them; the row is not linked to article 1, which this scenario does not compare. |
| Prefix lang title prefixes the translated value |
The English article 1 is localized to German through DataHandler, the backend action "localize". The field label has the language prefix (prefixLangTitle), so DataHandler writes the label of the German article 2 with the prefix "[Translate to German:]" in front of the value of article 1. |
DeviatesExtbase has no localize action. The twin creates a new German object (property "_languageUid") with the label of article 1 and persists it with add() and persistAll(). Extbase stores the label exactly as the code assigned it, without the language prefix; the TCA setting prefixLangTitle is ignored. |
| Changing a translation keeps its link |
The title of the German translation 2 is changed through DataHandler. DataHandler keeps l10n_parent 1, writes the new title, updates l10n_diffsource with the values of the default record 1 and writes l10n_state with the synchronized field subtitle marked as following its parent. |
DeviatesExtbase reads the German translation through the repository (language aspect German), changes the title and persists it with update() and persistAll(). Extbase writes the new title into the translation 2 and keeps l10n_parent 1, but leaves l10n_diffsource empty and l10n_state NULL. |
| A synchronized field follows the default record |
The subtitle of the English article 1 is changed through DataHandler. The field subtitle allows language synchronization and the translation 2 follows its parent, so DataHandler writes the new subtitle into the translation as well and records the state "parent" for the field in l10n_state. |
DeviatesExtbase reads article 1 through the repository, changes the subtitle and persists it with update() and persistAll(). Extbase writes the new subtitle into article 1 only; the translation 2 keeps its old subtitle and l10n_state stays NULL, because Extbase does not know language synchronization. |
| A record for all languages |
A new article with the language "all languages" (-1) is created through DataHandler. DataHandler writes the row with sys_language_uid -1 and l10n_parent 0. |
Same as coreExtbase creates a new object, sets its language to -1 through the property "_languageUid" and persists it with add() and persistAll(). Extbase writes sys_language_uid -1 and l10n_parent 0, like DataHandler. |
| Saving the default tour gives the translation its own copies |
The title of the English tour 1 is changed through DataHandler and its stops are sent as the backend form sends them: the field stops holds "1,2". The German translation 2 has no copies yet. DataHandler creates the stops 3 and 4 as copies of the stops 1 and 2: they belong to the German tour 2, carry t3_origuid 1 and 2 and the sorting 1 and 2, and DataHandler writes the number of stops, 2, into the field stops of tour 2. |
DeviatesExtbase reads tour 1 through the repository, changes the title and persists it with update() and persistAll(). Extbase writes the new title into tour 1, but does not touch the German translation: it creates no copies of the stops, the stops 1 and 2 stay the only stops and the field stops of tour 2 stays 0. |
| Saving the default tour with two translations copies only for the last one |
Core bugThe title of the English tour 1 is changed through DataHandler and its stops are sent as the backend form sends them: the field stops holds "1,2". The German translation 2 and the French translation 3 have no copies yet. DataHandler creates only one set of copies, the stops 3 and 4 with t3_origuid 1 and 2, and attaches it to the French tour 3. The German tour 2 gets no copy, although the field stops of tour 2 holds 2, like that of tour 3. This pins a bug in DataHandler, see https://forge.typo3.org/issues/111069. |
DeviatesExtbase reads tour 1 through the repository, changes the title and persists it with update() and persistAll(). Extbase writes the new title into tour 1, but does not touch the translations: it creates no copies of the stops for the German tour 2 or the French tour 3, the stops 1 and 2 stay the only stops and the field stops of both translations stays 0. |
| A stop added to the default tour is copied without its origin |
Core bugA new stop is sent as a child of the English tour 1 through DataHandler, as the backend form sends it: the field stops holds "1,NEW1" and the stop is a NEW record with its pid, its title and the uid of the tour in its field tour. The German translation 2 already has the stop 2 as copy of stop 1. DataHandler creates the stop 3 for tour 1 and a copy of it, the stop 4, for tour 2, and writes the number of stops, 2, into both tours. The stop 4 has t3_origuid 0 instead of 3, because DataHandler duplicates the new record in the data map instead of copying it. This pins a bug in DataHandler, see https://forge.typo3.org/issues/111070. |
DeviatesExtbase attaches a new stop to tour 1 and persists it with update() and persistAll(). Extbase creates the stop 3 for tour 1 with the sorting 0 and writes the number of stops, 2, into tour 1. It does not touch the German translation: tour 2 gets no copy of the new stop, and its field stops stays 1. |