[TYPO3-core] RFC: IRRE Localization
Oliver Hader
oh at inpublica.de
Tue Jan 8 11:59:23 CET 2008
Hi Berndhard,
IRRE basically has three methods of relating and storing records:
* 1:n with comma separated values
* 1:n with a pointer field (foreign_field)
* m:n (a)symmetric with the disposal of an intermediate table
Furthermore, an IRRE child record could again have child records on the
next level (e.g. hotel -> offer -> season price).
Bernhard Kraft schrieb:
> The new option "languageMode" can have 3 possible values:
>
> * "original" --> The translated IRRE container shows the IRRE records of
> its language-parent. You can add and move around the IRRE records - each
> of those changes (also editing) in the translated container will affect
> the original language and all other languages. So this isn't really a
> translation as the same IRRE records get displayed in all
> language-version containers.
What about calling this "keep" for "keep child records" or even
"passthrough"? The difficulties could come with the possibility to edit
or move child records inside the translated parent. I didn't test it,
but guess that this won't work currently for all relationship methods
mentioned above.
> * "separate" --> Each translated IRRE container will have it's own
> records. You can have a different amount of IRRE records in each
> language version - there is no correlation between default language and
> translated version of the sub/IRRE records.
What about calling this "select" for "select child records" with some
changes to the behaviour which are:
- untranslated child records of the default language are visible in this
forms view - but don't belong to the current translated parent record
- on translating a parent record, none of the children are duplicated
for the language to be translated (e.g. stay with sys_language_uid=0)
- there's a button "translate all child records" which does the same as
the functionality known from pages
- each child record has an own button "translate this record" which
allows a selective translation of a specific child record
> * "inherit" --> The translated IRRE container will contain as many
> records as it's language parent did - but not like in "original" mode
> the same records - but rather their "localized" pendants (so l18n_parent
> of those IRRE records is set to the uid of the respective IRRE record in
> the original-language container).
> It is not possible to move around/delete/hide those records in the
> translated container - you can only to this in the orig-language
> container. The changes will affect the alternate-language containers in
> such a way that the order of the records there also changes.
What about calling this "all" for "all child records"?
This is the 1:1 translation between the default language and the target
language. The interesting thing is, when the original parent record gets
some new child records added - these should also be "visible" in the
translated pendant.
The methods "select" and "all" are nearly the same and differ only in
the behaviour when the translation of the parent record get translated
and thus the child records get copied or not - depending on "all" or
"select".
Some further annotations to the patch:
* child records should be fetched by t3lib_transferdata and not be
direct query
* writing database operations should not occour in a TCEforms class
* copying records for translation purpose should be done by
TCEmain::localize
* new functionality for a special purpose (e.g. localization) should be
encapsulated in a new class method
olly
--
Oliver Hader
http://inpublica.de/
More information about the TYPO3-team-core
mailing list