diff --git a/setup/setuppage.class.inc.php b/setup/setuppage.class.inc.php index 2beda5e1d..391067bf9 100644 --- a/setup/setuppage.class.inc.php +++ b/setup/setuppage.class.inc.php @@ -36,6 +36,8 @@ class SetupPage extends NiceWebPage { public const DEFAULT_PAGE_TEMPLATE_REL_PATH = 'pages/backoffice/setuppage/layout'; + protected const BODY_DATA_GUI_TYPE = 'setup'; + public function __construct($sTitle) { parent::__construct($sTitle); diff --git a/sources/Application/WebPage/AjaxPage.php b/sources/Application/WebPage/AjaxPage.php index 9bec75ea7..fa6b70102 100644 --- a/sources/Application/WebPage/AjaxPage.php +++ b/sources/Application/WebPage/AjaxPage.php @@ -218,6 +218,7 @@ class AjaxPage extends WebPage implements iTabbedPage 'aJsInlineLive' => $this->a_scripts, 'aJsInlineOnDomReady' => $this->GetReadyScripts(), 'aJsInlineOnInit' => $this->a_init_scripts, + 'sBodyDataGuiType' => static::BODY_DATA_GUI_TYPE, 'bEscapeContent' => ($this->sContentType == 'text/html') && ($this->sContentDisposition == 'inline'), // TODO 3.0.0: TEMP, used while developping, remove it. 'sSanitizedContent' => utils::FilterXSS($this->s_content), diff --git a/sources/Application/WebPage/UnauthenticatedWebPage.php b/sources/Application/WebPage/UnauthenticatedWebPage.php index 2794c63a2..f2cb4a996 100644 --- a/sources/Application/WebPage/UnauthenticatedWebPage.php +++ b/sources/Application/WebPage/UnauthenticatedWebPage.php @@ -172,6 +172,7 @@ class UnauthenticatedWebPage extends NiceWebPage 'aJsInlineLive' => $this->a_scripts, 'aJsInlineOnDomReady' => $this->GetReadyScripts(), 'aJsInlineOnInit' => $this->a_init_scripts, + 'sBodyDataGuiType' => static::BODY_DATA_GUI_TYPE, // TODO 3.0.0: TEMP, used while developing, remove it. 'sCapturedOutput' => utils::FilterXSS($s_captured_output), diff --git a/sources/Application/WebPage/WebPage.php b/sources/Application/WebPage/WebPage.php index 0b2c7179c..c6085420e 100644 --- a/sources/Application/WebPage/WebPage.php +++ b/sources/Application/WebPage/WebPage.php @@ -152,6 +152,8 @@ class WebPage implements Page */ public const DEFAULT_PAGE_TEMPLATE_REL_PATH = 'pages/backoffice/webpage/layout'; + protected const BODY_DATA_GUI_TYPE = 'backoffice'; + protected $s_title; protected $s_content; protected $s_deferred_content; @@ -1566,6 +1568,7 @@ JS; 'aJsInlineLive' => $this->a_scripts, 'aJsInlineOnDomReady' => $this->GetReadyScripts(), 'aJsInlineOnInit' => $this->a_init_scripts, + 'sBodyDataGuiType' => static::BODY_DATA_GUI_TYPE, // TODO 3.0.0: TEMP, used while developing, remove it. 'sCapturedOutput' => utils::FilterXSS($s_captured_output), diff --git a/sources/Application/WebPage/iTopWebPage.php b/sources/Application/WebPage/iTopWebPage.php index 9ea9e4362..607e017f8 100644 --- a/sources/Application/WebPage/iTopWebPage.php +++ b/sources/Application/WebPage/iTopWebPage.php @@ -929,6 +929,7 @@ HTML; 'aJsInlineOnInit' => $this->a_init_scripts, 'aJsInlineOnDomReady' => $this->GetReadyScripts(), 'aJsInlineLive' => $this->a_scripts, + 'sBodyDataGuiType' => static::BODY_DATA_GUI_TYPE, // TODO 3.0.0: TEMP, used while developping, remove it. 'sSanitizedContent' => utils::FilterXSS($this->s_content), 'sDeferredContent' => utils::FilterXSS($this->s_deferred_content), diff --git a/templates/pages/backoffice/webpage/layout.html.twig b/templates/pages/backoffice/webpage/layout.html.twig index 597fedfa5..6821369f8 100644 --- a/templates/pages/backoffice/webpage/layout.html.twig +++ b/templates/pages/backoffice/webpage/layout.html.twig @@ -49,7 +49,7 @@ {% endfor %} {% endblock %} -
+ {% if aPage.isPrintable %}