Skip to content

Commit

Permalink
[TASK] Use correct TCA for nav_hide and content_from_pid fiels of pages
Browse files Browse the repository at this point in the history
'l10n_mode' => 'prefixLangTitle'
does not make sense for checkboxes and group types

Add language sync to those fields, so those can be overwritten in
translations.

Resolves: #88511
Releases: master, 9.5
Change-Id: Ib64b5455139100c113d3ded76e0b140b43542c4d
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/60891
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
  • Loading branch information
liayn authored and georgringer committed Aug 2, 2019
1 parent af6eac3 commit b359e4f
Show file tree
Hide file tree
Showing 10 changed files with 21 additions and 17 deletions.
12 changes: 8 additions & 4 deletions typo3/sysext/core/Configuration/TCA/pages.php
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,6 @@
],
'nav_hide' => [
'exclude' => true,
'l10n_mode' => 'prefixLangTitle',
'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:pages.nav_hide_toggle',
'config' => [
'type' => 'check',
Expand All @@ -398,6 +397,9 @@
'invertStateDisplay' => true
]
],
'behaviour' => [
'allowLanguageSynchronization' => true
],
]
],
'subtitle' => [
Expand Down Expand Up @@ -604,7 +606,6 @@
],
'content_from_pid' => [
'exclude' => true,
'l10n_mode' => 'prefixLangTitle',
'label' => 'LLL:EXT:frontend/Resources/Private/Language/locallang_tca.xlf:pages.content_from_pid',
'config' => [
'type' => 'group',
Expand All @@ -619,8 +620,11 @@
'addWhere' => ' AND pages.uid != ###THIS_UID###'
]
],
'default' => 0
]
'default' => 0,
'behaviour' => [
'allowLanguageSynchronization' => true
],
],
],
'mount_pid' => [
'l10n_mode' => 'exclude',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest",0,,,
,89,88,256,0,0,0,0,0,0,0,0,0,"Relations",1,,,
,90,88,512,0,0,0,0,0,0,0,0,0,"Target",0,,,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",1,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",1,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,92,90,256,0,0,0,89,0,0,0,0,0,"Relations",1,,,
,93,90,256,0,1,92,91,0,0,0,0,0,"[Translate to Dansk:] Relations",1,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,93,90,256,0,1,92,91,0,0,0,0,0,"[Translate to Dansk:] Relations",1,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
"tt_content",,,,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","header","tx_irretutorial_1nff_hotels",,,
,297,89,256,0,0,0,0,0,0,0,0,0,"Regular Element #1",2,,,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest",0,,,
,89,88,256,0,0,0,0,0,0,0,0,0,"Relations",2,,,
,90,88,512,0,0,0,0,0,0,0,0,0,"Target",0,,,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,92,90,256,0,0,0,89,0,0,0,0,0,"Relations",2,,,
,93,90,256,0,1,92,91,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,93,90,256,0,1,92,91,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
"tt_content",,,,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","header","tx_irretutorial_1nff_hotels",,,
,297,89,256,0,0,0,0,0,0,0,0,0,"Regular Element #1",2,,,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest",0,,,
,89,88,256,0,0,0,0,0,0,0,0,0,"Relations",2,,,
,90,88,512,0,0,0,0,0,0,0,0,0,"Target",0,,,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent""}",,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent""}",,
"tt_content",,,,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","header","tx_irretutorial_1nff_hotels",,,
,297,89,256,0,0,0,0,0,0,0,0,0,"Regular Element #1",2,,,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest",0,,,
,89,88,256,0,0,0,0,0,0,0,0,0,"Relations",2,,,
,90,88,512,0,0,0,0,0,0,0,0,0,"Target",0,,,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
"tt_content",,,,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","header","tx_irretutorial_1nff_hotels",,,
,297,89,256,0,0,0,0,0,0,0,0,0,"Regular Element #1",2,,,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest",0,,,
,89,88,256,0,0,0,0,0,0,0,0,0,"Relations",2,,,
,90,88,512,0,0,0,0,0,0,0,0,0,"Target",0,,,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
"tt_content",,,,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","header","tx_irretutorial_1nff_hotels",,,
,297,89,256,0,0,0,0,0,0,0,0,0,"Regular Element #1",2,,,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest",0,,,
,89,88,256,0,0,0,0,0,0,0,0,0,"Relations",1,,,
,90,88,512,0,0,0,0,0,0,0,0,0,"Target",0,,,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",1,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",1,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""parent""}",,
"tt_content",,,,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","header","tx_irretutorial_1nff_hotels",,,
,297,89,256,0,0,0,0,0,0,0,0,0,"Regular Element #1",2,,,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest",0,,,
,89,88,256,0,0,0,0,0,0,0,0,0,"Relations",1,,,
,90,88,512,0,0,0,0,0,0,0,0,0,"Target",0,,,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""custom""}",,
,91,88,256,0,1,89,0,0,0,0,0,0,"[Translate to Dansk:] Relations",2,"{""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent"",""tx_irretutorial_hotels"":""custom""}",,
"tx_irretutorial_1nff_hotel",,,,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","title","parentid","parenttable","parentidentifier","offers"
,2,89,1,0,0,0,0,0,0,0,0,0,"Hotel #0",89,"pages",,0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
,88,1,256,0,0,0,0,0,0,0,0,0,"DataHandlerTest","/data-handler",
,89,88,256,0,0,0,0,0,0,0,0,0,"Testing #1","/data-handler/relations",
,90,88,512,0,0,0,0,0,0,0,0,0,"Target","/data-handler/target",
,91,88,256,1,89,0,0,0,0,0,0,0,"Testing #1","/data-handler/relations","{""title"":""parent"",""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent""}"
,91,88,256,1,89,0,0,0,0,0,0,0,"Testing #1","/data-handler/relations","{""title"":""parent"",""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent""}"
,92,90,256,0,0,0,89,0,0,0,0,0,"Testing #1","/data-handler/relations-1",
,93,90,256,1,92,0,91,0,0,0,0,0,"Testing #1","/data-handler/relations-1","{""title"":""parent"",""starttime"":""parent"",""endtime"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent""}"
,93,90,256,1,92,0,91,0,0,0,0,0,"Testing #1","/data-handler/relations-1","{""title"":""parent"",""starttime"":""parent"",""endtime"":""parent"",""nav_hide"":""parent"",""url"":""parent"",""lastUpdated"":""parent"",""newUntil"":""parent"",""no_search"":""parent"",""shortcut"":""parent"",""shortcut_mode"":""parent"",""content_from_pid"":""parent"",""author"":""parent"",""author_email"":""parent"",""media"":""parent""}"
"tt_content",,,,,,,,,,,,,,,
,"uid","pid","sorting","deleted","sys_language_uid","l18n_parent","l10n_source","t3_origuid","t3ver_wsid","t3ver_state","t3ver_stage","t3ver_oid","t3ver_move_id","header",
,296,88,256,0,0,0,0,0,0,0,0,0,0,"Regular Element #0",
Expand Down
4 changes: 2 additions & 2 deletions typo3/sysext/frontend/Configuration/TCA/tt_content.php
Original file line number Diff line number Diff line change
Expand Up @@ -580,8 +580,8 @@
'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.text',
'config' => [
'type' => 'text',
'cols' => '80',
'rows' => '15',
'cols' => 80,
'rows' => 15,
'softref' => 'typolink_tag,email[subst],url',
'search' => [
'andWhere' => '{#CType}=\'text\' OR {#CType}=\'textpic\' OR {#CType}=\'textmedia\''
Expand Down

0 comments on commit b359e4f

Please sign in to comment.