コード例 #1
0
 /**
  * No template
  *
  * @param int $newStandardTemplate
  * @return string
  */
 public function noTemplate($newStandardTemplate = 0)
 {
     $this->templateService = GeneralUtility::makeInstance(ExtendedTemplateService::class);
     $this->templateService->init();
     $moduleContent['state'] = InfoboxViewHelper::STATE_INFO;
     // New standard?
     if ($newStandardTemplate) {
         $selector = '';
         $staticsText = '';
         // Hook to change output, implemented for statictemplates
         $hookObject = $this->getHookObjectForAction('newStandardTemplateView');
         if (!empty($hookObject)) {
             $reference = ['selectorHtml' => &$selector, 'staticsText' => &$staticsText];
             GeneralUtility::callUserFunction($hookObject, $reference, $this);
             $selector = $reference['selectorHtml'];
             $staticsText = $reference['staticsText'];
         }
         // Extension?
         $moduleContent['staticsText'] = $staticsText;
         $moduleContent['selector'] = $selector;
     }
     // Go to previous Page with Template...
     $previousPage = $this->templateService->ext_prevPageWithTemplate($this->id, $this->perms_clause);
     if ($previousPage) {
         $urlParameters = ['id' => $previousPage['uid']];
         $previousPage['aHref'] = BackendUtility::getModuleUrl('web_ts', $urlParameters);
         $moduleContent['previousPage'] = $previousPage;
     }
     $view = $this->getFluidTemplateObject('tstemplate', 'NoTemplate');
     $view->assign('content', $moduleContent);
     return $view->render();
 }