mirror of
https://github.com/SuiteCRM/SuiteCRM-Core.git
synced 2025-08-29 01:10:42 +08:00
34 lines
696 B
PHP
34 lines
696 B
PHP
<?php
|
|
|
|
namespace SuiteCRM\Core\Base\Module\Service;
|
|
|
|
use SuiteCRM\Core\Base\Module\Manager as ModuleManager;
|
|
use SuiteCRM\Core\Base\Module\Service\ServiceCollection;
|
|
|
|
use Symfony\Component\Config\FileLocator;
|
|
|
|
/**
|
|
* Class Manager
|
|
* @package SuiteCRM\Core\Base\Module\Service
|
|
*/
|
|
class Manager
|
|
{
|
|
protected $serviceList = [];
|
|
|
|
/**
|
|
* Manager constructor.
|
|
* @param ModuleManager $moduleManager
|
|
*/
|
|
public function __construct(ModuleManager $moduleManager)
|
|
{
|
|
foreach ($moduleManager->listEnabled() as $module) {
|
|
$file = new FileLocator();
|
|
|
|
$service = new $module();
|
|
}
|
|
|
|
return (new ServiceCollection())->load();
|
|
}
|
|
|
|
|
|
}
|