diff --git a/application/Espo/Core/Utils/ClientManager.php b/application/Espo/Core/Utils/ClientManager.php index 15f2c6c3d9..37527f47e7 100644 --- a/application/Espo/Core/Utils/ClientManager.php +++ b/application/Espo/Core/Utils/ClientManager.php @@ -98,19 +98,27 @@ class ClientManager if ($isDeveloperMode) { $useCache = $this->getConfig()->get('useCacheInDeveloperMode'); - $jsFileList = $this->getMetadata()->get(['app', 'client', 'developerModeScriptList']); + $jsFileList = $this->getMetadata()->get(['app', 'client', 'developerModeScriptList'], []); + $cssFileList = $this->getMetadata()->get(['app', 'client', 'developerModeCssList'], []); $loaderCacheTimestamp = 'null'; } else { $useCache = $this->getConfig()->get('useCache'); - $jsFileList = $this->getMetadata()->get(['app', 'client', 'scriptList']); + $jsFileList = $this->getMetadata()->get(['app', 'client', 'scriptList'], []); + $cssFileList = $this->getMetadata()->get(['app', 'client', 'cssList'], []); $loaderCacheTimestamp = $cacheTimestamp; } $scriptsHtml = ''; - foreach ($jsFileList as $jsFile) { + foreach ($jsFileList as $i => $jsFile) { $src = $this->basePath . $jsFile . '?r=' . $cacheTimestamp; - $scriptsHtml .= ' ' . - '' . "\n"; + $scriptsHtml .= "\n " . + ""; + } + + $additionalStyleSheetsHtml = ''; + foreach ($cssFileList as $cssFile) { + $src = $this->basePath . $cssFile . '?r=' . $cacheTimestamp; + $additionalStyleSheetsHtml .= "\n "; } $data = [ @@ -124,7 +132,8 @@ class ClientManager 'basePath' => $this->basePath, 'useCache' => $useCache ? 'true' : 'false', 'appClientClassName' => 'app', - 'scriptsHtml' => $scriptsHtml + 'scriptsHtml' => $scriptsHtml, + 'additionalStyleSheetsHtml' => $additionalStyleSheetsHtml, ]; $html = file_get_contents($htmlFilePath); diff --git a/html/main.html b/html/main.html index 03a3f2e0ce..57ae80d9c2 100644 --- a/html/main.html +++ b/html/main.html @@ -1,9 +1,8 @@
-