mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-19 15:22:17 +02:00
N°2060 fix portal crash if css not yet compiled
Was using services.yaml parameters before they were defined
This commit is contained in:
@@ -313,13 +313,13 @@ class Basic extends AbstractConfiguration
|
|||||||
foreach (MetaModel::EnumPlugins('iPortalUIExtension') as $oExtensionInstance)
|
foreach (MetaModel::EnumPlugins('iPortalUIExtension') as $oExtensionInstance)
|
||||||
{
|
{
|
||||||
// Adding CSS files
|
// Adding CSS files
|
||||||
$aImportPaths = array($oContainer->getParameter('combodo.portal.base.absolute_path').'css/');
|
$aImportPaths = array($_ENV['COMBODO_PORTAL_BASE_ABSOLUTE_PATH'].'css/');
|
||||||
foreach ($oExtensionInstance->GetCSSFiles($oContainer) as $sCSSFile)
|
foreach ($oExtensionInstance->GetCSSFiles($oContainer) as $sCSSFile)
|
||||||
{
|
{
|
||||||
// Removing app root url as we need to pass a path on the file system (relative to app root)
|
// Removing app root url as we need to pass a path on the file system (relative to app root)
|
||||||
$sCSSFilePath = str_replace(utils::GetAbsoluteUrlAppRoot(), '', $sCSSFile);
|
$sCSSFilePath = str_replace(utils::GetAbsoluteUrlAppRoot(), '', $sCSSFile);
|
||||||
// Compiling SCSS file
|
// Compiling SCSS file
|
||||||
$sCSSFileCompiled = $oContainer->getParameter('combodo.absolute_url').utils::GetCSSFromSASS($sCSSFilePath,
|
$sCSSFileCompiled = utils::GetAbsoluteUrlAppRoot().utils::GetCSSFromSASS($sCSSFilePath,
|
||||||
$aImportPaths);
|
$aImportPaths);
|
||||||
|
|
||||||
if (!in_array($sCSSFileCompiled, $aUIExtensions['css_files']))
|
if (!in_array($sCSSFileCompiled, $aUIExtensions['css_files']))
|
||||||
|
|||||||
Reference in New Issue
Block a user