0
0
mirror of https://github.com/salesagility/SuiteCRM.git synced 2024-11-24 08:36:48 +00:00
salesagility_SuiteCRM/Api/V8/Config/services/controllers.php
2020-01-28 17:06:26 +00:00

60 lines
2.1 KiB
PHP

<?php
use Api\V8\Controller;
use Api\V8\Service\ListViewSearchService;
use Api\V8\Service\ListViewService;
use Api\V8\Service\LogoutService;
use Api\V8\Service\MetaService;
use Api\V8\Service\ModuleService;
use Api\V8\Service\RelationshipService;
use Api\V8\Service\UserPreferencesService;
use Api\V8\Service\UserService;
use Psr\Container\ContainerInterface as Container;
use League\OAuth2\Server\ResourceServer;
use Api\Core\Loader\CustomLoader;
return CustomLoader::mergeCustomArray([
Controller\ListViewSearchController::class => function (Container $container) {
return new Controller\ListViewSearchController(
$container->get(ListViewSearchService::class)
);
},
Controller\UserPreferencesController::class => function (Container $container) {
return new Controller\UserPreferencesController(
$container->get(UserPreferencesService::class)
);
},
Controller\UserController::class => function (Container $container) {
return new Controller\UserController(
$container->get(UserService::class)
);
},
Controller\MetaController::class => function (Container $container) {
return new Controller\MetaController(
$container->get(MetaService::class)
);
},
Controller\ListViewController::class => function (Container $container) {
return new Controller\ListViewController(
$container->get(ListViewService::class)
);
},
Controller\ModuleController::class => function (Container $container) {
return new Controller\ModuleController(
$container->get(ModuleService::class)
);
},
Controller\LogoutController::class => function (Container $container) {
return new Controller\LogoutController(
$container->get(LogoutService::class),
$container->get(ResourceServer::class)
);
},
Controller\RelationshipController::class => function (Container $container) {
return new Controller\RelationshipController(
$container->get(RelationshipService::class)
);
},
], basename(__FILE__));