Prado\Web\UI\TThemeManager::init PHP Метод

init() публичный Метод

This method is required by IModule and is invoked by application.
public init ( $config )
    public function init($config)
    {
        $this->_initialized = true;
        $service = $this->getService();
        if ($service instanceof TPageService) {
            $service->setThemeManager($this);
        } else {
            throw new TConfigurationException('thememanager_service_unavailable');
        }
    }

Usage Example

Пример #1
0
 private function _startThemeManager()
 {
     $themeManager = new TThemeManager();
     $themeManager->BasePath = "System.Wsat.themes";
     $url = Prado::getApplication()->getAssetManager()->publishFilePath(Prado::getPathOfNamespace('System.Wsat'));
     $themeManager->BaseUrl = "{$url}/themes";
     $themeManager->init(null);
     $this->setThemeManager($themeManager);
 }