[FOLLOWUP][BUGFIX] Fix evaluation of rootLevel configuration in NewRecordController 54/50154/2
authorNicole Cordes <typo3@cordes.co>
Sun, 9 Oct 2016 23:17:32 +0000 (01:17 +0200)
committerStefan Neufeind <typo3.neufeind@speedpartner.de>
Sun, 9 Oct 2016 23:20:44 +0000 (01:20 +0200)
commit31707ee51198045a0e9f52a506c8c0da1f5b48a8
tree8e38f1fef37886f964e88c7fa6878ef6ac4eb94e
parent53e5e7ba1227d6e6eaa09d4b7cc887d52b23a0bb
[FOLLOWUP][BUGFIX] Fix evaluation of rootLevel configuration in NewRecordController

If there is no configuration for the rootLevel in a tables' TCA, the
NewRecordController silently assumes -1. This means a table can be
inserted on a page AND on root level. This behaviour is wrong because in
TCA documentation per default rootLevel is 0 which means, this table can
only be used on pages.
This patch sets the correct default value for rootLevel if not set.

Resolves: #78170
Releases: master, 7.6
Change-Id: I3a34eb5abbd95b7ee60b8b676c86abaacd0e2a18
Reviewed-on: https://review.typo3.org/50154
Reviewed-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Tested-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Tested-by: TYPO3com <no-reply@typo3.com>
typo3/sysext/backend/Classes/Controller/NewRecordController.php