diff --git a/sources/application/WebPage/AjaxPage.php b/sources/application/WebPage/AjaxPage.php index 185fd18d3..9eb53234a 100644 --- a/sources/application/WebPage/AjaxPage.php +++ b/sources/application/WebPage/AjaxPage.php @@ -179,17 +179,7 @@ class AjaxPage extends WebPage implements iTabbedPage ConsoleBlockRenderer::AddCssJsToPage($this, $this->oContentLayout); // Render the blocks - // Additional UI widgets to be activated inside the ajax fragment - // Important: Testing the content type is not enough because some ajax handlers have not correctly positionned the flag (e.g json response corrupted by the script) - // TODO 3.0.0 à revoir - if (($this->sContentType == 'text/html') && (preg_match('/class="date-pick"/', $this->s_content) || preg_match('/class="datetime-pick"/', $this->s_content))) { - $this->add_ready_script( - <<outputCollapsibleSectionInit(); $aData = []; diff --git a/sources/application/WebPage/iTopWebPage.php b/sources/application/WebPage/iTopWebPage.php index 5d6caf0c7..d1f7929ff 100644 --- a/sources/application/WebPage/iTopWebPage.php +++ b/sources/application/WebPage/iTopWebPage.php @@ -412,6 +412,8 @@ JS setTimeout(function(){ CombodoTooltip.InitAllNonInstantiatedTooltips(); CombodoBackofficeToolbox.InitCodeHighlighting(); + // Initialize date / datetime pickers if needed + PrepareWidgets(); }, 500); }); JS