[BUGFIX] Remove duplicate docheader in Web->Info->Log 16/43916/2
authorMathias Schreiber <mathias.schreiber@wmdb.de>
Thu, 8 Oct 2015 20:45:57 +0000 (22:45 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Thu, 8 Oct 2015 20:57:25 +0000 (22:57 +0200)
Releases: master
Resolves: #70513
Change-Id: I36bd4f211a7cfe6f0f714dbfe50486097f664b09
Reviewed-on: http://review.typo3.org/43916
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Daniel Goerz <ervaude@gmail.com>
Tested-by: Daniel Goerz <ervaude@gmail.com>
typo3/sysext/belog/Classes/Controller/AbstractController.php

index 572d66d..d7d56be 100644 (file)
@@ -84,13 +84,6 @@ abstract class AbstractController extends ActionController {
        protected $view;
 
        /**
-        * BackendTemplateView Container
-        *
-        * @var BackendTemplateView
-        */
-       protected $defaultViewObjectName = BackendTemplateView::class;
-
-       /**
         * @param \TYPO3\CMS\Belog\Domain\Repository\LogEntryRepository $logEntryRepository
         */
        public function injectLogEntryRepository(\TYPO3\CMS\Belog\Domain\Repository\LogEntryRepository $logEntryRepository) {
@@ -104,10 +97,11 @@ abstract class AbstractController extends ActionController {
         * @return void
         */
        protected function initializeView(ViewInterface $view) {
-               /** @var BackendTemplateView $view */
-               parent::initializeView($view);
-               $view->getModuleTemplate()->getPageRenderer()->loadExtJS();
-               $view->getModuleTemplate()->getPageRenderer()->loadRequireJsModule('TYPO3/CMS/Backend/DateTimePicker');
+               if ($view instanceof BackendTemplateView) {
+                       parent::initializeView($view);
+                       $view->getModuleTemplate()->getPageRenderer()->loadExtJS();
+                       $view->getModuleTemplate()->getPageRenderer()->loadRequireJsModule('TYPO3/CMS/Backend/DateTimePicker');
+               }
        }
 
        /**
@@ -115,6 +109,9 @@ abstract class AbstractController extends ActionController {
         * @return void
         */
        public function initializeAction() {
+               if ($this->isInPageContext === FALSE) {
+                       $this->defaultViewObjectName = BackendTemplateView::class;
+               }
        }
 
        /**