mirror of
https://github.com/Combodo/iTop.git
synced 2026-03-02 23:54:12 +01:00
Panel factory: Remove SetClassColor() method as it has been move directly in the panel in a previous commit
This commit is contained in:
@@ -20,8 +20,6 @@
|
||||
namespace Combodo\iTop\Application\UI\Base\Component\Panel;
|
||||
|
||||
use Combodo\iTop\Application\UI\Base\AbstractUIBlockFactory;
|
||||
use MetaModel;
|
||||
use ormStyle;
|
||||
|
||||
/**
|
||||
* Class PanelUIBlockFactory
|
||||
@@ -175,24 +173,4 @@ class PanelUIBlockFactory extends AbstractUIBlockFactory
|
||||
|
||||
return $oPanel;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $sClass
|
||||
* @param \Combodo\iTop\Application\UI\Base\Component\Panel\Panel $oPanel
|
||||
*
|
||||
* @throws \CoreException
|
||||
*/
|
||||
public static function SetClassColor(string $sClass, Panel $oPanel): void
|
||||
{
|
||||
/** @var ormStyle $oStyle */
|
||||
$sColor = null;
|
||||
$oStyle = MetaModel::GetClassStyle($sClass);
|
||||
if ($oStyle) {
|
||||
$sColor = $oStyle->GetMainColor();
|
||||
}
|
||||
if (strlen($sColor) == 0) {
|
||||
$sColor = Panel::ENUM_COLOR_BLUE;
|
||||
}
|
||||
$oPanel->SetColor($sColor);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user