60331[BUGFIX] Enable preview of hidden page translations
Commit message
Review
-
Code review CR +2 Done
- Daniel Goerz +2
- Susi Moog +1
- Benni Mack +1
-
Verified V +2 Done
- Daniel Goerz +2
- Susi Moog +1
- Benni Mack +1
- TYPO3com +1 CI
Issues 1
Files 1
Review log 2427
Show 2 earlier messages
-
TYPO3com voted on patch set 1 V +1 03/25/19, 14:44 Completed build in 17m 10s on Mon, 25 Mar, 03:44 PM Test Summary: 47257 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32951
-
TYPO3com voted on patch set 2 V +1 03/25/19, 14:53 Completed build in 15m 52s on Mon, 25 Mar, 03:53 PM Test Summary: 47257 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32952
-
Benni Mack voted on patch set 2 V +1 CR +1 03/26/19, 07:22
-
Susi Moog commented on patch set 2 03/27/19, 08:12
-
Benni Mack commented on patch set 2 03/27/19, 08:21
TypoScriptFrontendController.php:945ReplyCurrent behaviour (also within Rootline) is always that the default page has to be non-hidden(+access starttime/endtime). Changing this would be a huge (I'd say breaking) change. -
Daniel Goerz commented on patch set 2 03/27/19, 08:23
For configuration with allowLanguageSynchronization on the fields hidden, starttime and endtime field the language parent has to be checked as well. Basically the idea is, if the default language is hidden, we are in preview mode, if it is not hidden, we check the current language. I guess we can switch the checks around but have to do both nevertheless. At least for starttime and endtime allowLanguageSynchronization is set per default TCA config. -
Susi Moog commented on patch set 2 03/27/19, 08:30
> Patch Set 2: > > For configuration with allowLanguageSynchronization on the fields hidden, starttime and endtime field the language parent has to be checked as well. Basically the idea is, if the default language is hidden, we are in preview mode, if it is not hidden, we check the current language. > > I guess we can switch the checks around but have to do both nevertheless. At least for starttime and endtime allowLanguageSynchronization is set per default TCA config. But allow language synchro really sets the values on the translation record, doesn't it - so why would we need to check the default again? -
Daniel Goerz commented on patch set 2 03/27/19, 09:05
> > Patch Set 2: > > > > For configuration with allowLanguageSynchronization on the fields > hidden, starttime and endtime field the language parent has to be > checked as well. Basically the idea is, if the default language is > hidden, we are in preview mode, if it is not hidden, we check the > current language. > > > > I guess we can switch the checks around but have to do both > nevertheless. At least for starttime and endtime allowLanguageSynchronization > is set per default TCA config. > > But allow language synchro really sets the values on the > translation record, doesn't it - so why would we need to check the > default again? Ah I forgot that the value is actually set in the database for the translated record. When I set up the allowLanguageSynchronization config for my tests I did the TCA changes when the records already existed so that was an error on my site. I withdraw my argument :) -
Susi Moog commented on patch set 2 03/27/19, 09:33
TypoScriptFrontendController.php:945Replyso basically I can only preview a hidden translation as long as the default page is not hidden? Meaning in case I create a new page with translation I'd have to first finish the default language, "publish/unhide" that, before I can even preview the translated one? -
Daniel Goerz commented on patch set 2 03/27/19, 09:42
TypoScriptFrontendController.php:945ReplyNo, with this code preview mode is active if default language is hidden and translation is not checked in this case. This is also the current behavior. Previews of hidden page translation do work if default language is hidden but it fails with active default language. That's what this patch is for. -
Susi Moog commented on patch set 2 03/27/19, 10:31
> Patch Set 2: > > (1 comment)TypoScriptFrontendController.php:945Replyso basically we have the cases hidden def | lang | result 0 | 1 | false (wrong) 1 | 1 | true 1 | 0 | true 0 | 0 | false then I'd still say for this method, checking translation if sys_language_uid > 0 requested would be enough? -
Daniel Goerz commented on patch set 2 03/27/19, 10:44
TypoScriptFrontendController.php:945ReplySo you suggest the following for sys_language_uid > 0 hidden def | lang | result 0 | 1 | true (different from current behavior) 1 | 1 | true 1 | 0 | false (different from current behavior) 0 | 0 | false I'd like to hear Bennis oppinion on that. -
Susi Moog commented on patch set 2 03/27/19, 10:54
TypoScriptFrontendController.php:945Replyalternatively: if sys_language_uid > 1 and check already returns true, don't check default, check default only if sys_language_uid > 1 && check == false. -
Daniel Goerz commented on patch set 2 03/27/19, 11:06
TypoScriptFrontendController.php:945ReplyThat would lead to the same result set as the current state of the patch but switch the order for the check in case we have sys_language_uid > 0. Might save us a query from time to time, so I would be fine with it. Still would like to hear Bennis oppinion, though :) -
Benni Mack commented on patch set 2 03/27/19, 11:28
TypoScriptFrontendController.php:945ReplyI'd say this is correct: hidden def | lang | result 0 | 1 | true (different from current behavior) 1 | 1 | true 1 | 0 | false (different from current behavior) 0 | 0 | false We should document that in the commit message. -
Daniel Goerz commented on patch set 2 CR -2 03/27/19, 11:37
TypoScriptFrontendController.php:945Reply UnresolvedAlright, will take care -
Daniel Goerz uploaded patch set 3 03/27/19, 12:52
-
Daniel Goerz voted on patch set 3 CR 0 03/27/19, 12:52
-
TYPO3com voted on patch set 3 V +1 03/27/19, 13:02 Completed build in 09m 51s on Wed, 27 Mar, 02:02 PM Test Summary: 47257 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32984
-
Benni Mack voted on patch set 3 V +1 CR +1 03/28/19, 07:04
-
Frans Saris commented on patch set 3 04/01/19, 17:02
Can this also be backported to 8.7? -
Benni Mack commented on patch set 3 04/02/19, 08:48
Hey Frans, we've fixed this with a hook in our installation for 8.7 and 9.5 (without site handling), but it's not possible with 9.5+site handling anymore... As this is actually a change of visibility / behavior I'd rather not backport this to 8.7, avoiding possible conflicts in 8 installations. -
Susi Moog voted on patch set 3 V +1 CR +1 04/03/19, 05:29
-
Daniel Goerz voted on patch set 3 V +2 CR +2 04/03/19, 11:20
-
Daniel Goerz merged patch set 4 04/03/19, 11:20
TypoScriptFrontendController.php:945