[BUGFIX] pages.shortcut suggest wizard should not suggest itself 28/58428/2
authorJosef Glatz <josefglatz@gmail.com>
Fri, 28 Sep 2018 04:30:53 +0000 (06:30 +0200)
committerJan Helke <typo3@helke.de>
Fri, 28 Sep 2018 08:49:43 +0000 (10:49 +0200)
Make it impossible to select the page you are currently
working on within the suggest wizard result set.

Releases: master, 8.7
Resolves: #86412
Related: #54867
Change-Id: Ibeaacf86061f79cc3d75f181466e5caf96657401
Reviewed-on: https://review.typo3.org/58428
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Jan Helke <typo3@helke.de>
Tested-by: Jan Helke <typo3@helke.de>
typo3/sysext/core/Configuration/TCA/pages.php

index 9c271ea..1d1321b 100644 (file)
@@ -501,7 +501,8 @@ return [
                 'minitems' => 0,
                 'suggestOptions' => [
                     'default' => [
-                        'additionalSearchFields' => 'nav_title, alias, url'
+                        'additionalSearchFields' => 'nav_title, alias, url',
+                        'addWhere' => ' AND pages.uid != ###THIS_UID###'
                     ]
                 ],
                 'default' => 0