如何在Magnolia 5.4.1中的多值复合字段中启用I18N?在我的yaml中,我在每个部分都设置了i18n: true
,但是,在我只能提供的对话框中所有语言的字段都有一个值,它们没有I18N支持。
相关字段是“features
”,每个字段都包含标题和图像。
我的.yaml:
actions:
cancel:
class: info.magnolia.ui.admincentral.dialog.action.CancelDialogActionDefinition
commit:
class: info.magnolia.ui.admincentral.dialog.action.SaveDialogActionDefinition
form:
label: Abschnitt
tabs:
- name: tabMain
label: Abschnitt
fields:
- name: image
class: info.magnolia.ui.form.field.definition.LinkFieldDefinition
targetWorkspace: dam
appName: assets
identifierToPathConverter:
class: info.magnolia.dam.app.assets.field.translator.AssetCompositeIdKeyTranslator
contentPreviewDefinition:
contentPreviewClass: info.magnolia.dam.app.ui.field.DamFilePreviewComponent
label: Bild
required: false
i18n: true
- name: bodyText
class: info.magnolia.ui.form.field.definition.RichTextFieldDefinition
configJsFile: /.resources/sorba-templates/webresources/ckeditor/config-magnolia.js
rows: 6
label: Text
required: true
source: true
i18n: true
- name: features
class: info.magnolia.ui.form.field.definition.MultiValueFieldDefinition
label: Features
i18n: true
transformerClass: info.magnolia.ui.form.field.transformer.multi.MultiValueSubChildrenNodePropertiesTransformer
field:
name: compositeField
class: info.magnolia.ui.form.field.definition.CompositeFieldDefinition
transformerClass: info.magnolia.ui.form.field.transformer.composite.NoOpCompositeTransformer
layout: vertical
i18n: true
fields:
- name: title
class: info.magnolia.ui.form.field.definition.TextFieldDefinition
label: Titel
i18n: true
required: true
- name: image
class: info.magnolia.ui.form.field.definition.LinkFieldDefinition
targetWorkspace: dam
appName: assets
identifierToPathConverter:
class: info.magnolia.dam.app.assets.field.translator.AssetCompositeIdKeyTranslator
contentPreviewDefinition:
contentPreviewClass: info.magnolia.dam.app.ui.field.DamFilePreviewComponent
label: Bild
required: true
i18n: true
该对话框仅支持除“features
”以外的所有其他字段的I18N以及此类字段(标题,图片):
答案 0 :(得分:2)
Magnolia已承认错误报告:https://jira.magnolia-cms.com/browse/MAGNOLIA-6396。应该在将来的版本中修复。
<强>更新强>
错误报告已被拒绝,因为它实际上已经可能,只需要使用不同的变压器。请参阅此处的评论: