feat(117): smsplanet integration settings

This commit is contained in:
2026-05-12 13:18:41 +02:00
parent 09f9ca798d
commit bcbb35bc6b
22 changed files with 1392 additions and 22 deletions

View File

@@ -39,6 +39,9 @@ use App\Modules\Settings\InpostIntegrationController;
use App\Modules\Settings\InpostIntegrationRepository;
use App\Modules\Settings\IntegrationsHubController;
use App\Modules\Settings\IntegrationsRepository;
use App\Modules\Settings\SmsplanetApiClient;
use App\Modules\Settings\SmsplanetIntegrationController;
use App\Modules\Settings\SmsplanetIntegrationRepository;
use App\Modules\Settings\ShopproIntegrationsController;
use App\Modules\Settings\ShopproIntegrationsRepository;
use App\Modules\Settings\ShopproPullStatusMappingRepository;
@@ -205,6 +208,18 @@ return static function (Application $app): void {
new HostedSmsApiClient(),
new IntegrationsRepository($app->db())
);
$smsplanetIntegrationRepository = new SmsplanetIntegrationRepository(
$app->db(),
(string) $app->config('app.integrations.secret', '')
);
$smsplanetIntegrationController = new SmsplanetIntegrationController(
$template,
$translator,
$auth,
$smsplanetIntegrationRepository,
new SmsplanetApiClient(),
new IntegrationsRepository($app->db())
);
$integrationsHubController = new IntegrationsHubController(
$template,
$translator,
@@ -215,7 +230,8 @@ return static function (Application $app): void {
$inpostIntegrationRepository,
$shopproIntegrationsRepository,
$fakturowniaIntegrationRepository,
$hostedSmsIntegrationRepository
$hostedSmsIntegrationRepository,
$smsplanetIntegrationRepository
);
$cronSettingsController = new CronSettingsController(
$template,
@@ -562,6 +578,9 @@ return static function (Application $app): void {
$router->get('/settings/integrations/hostedsms', [$hostedSmsIntegrationController, 'index'], [$authMiddleware]);
$router->post('/settings/integrations/hostedsms/save', [$hostedSmsIntegrationController, 'save'], [$authMiddleware]);
$router->post('/settings/integrations/hostedsms/test', [$hostedSmsIntegrationController, 'test'], [$authMiddleware]);
$router->get('/settings/integrations/smsplanet', [$smsplanetIntegrationController, 'index'], [$authMiddleware]);
$router->post('/settings/integrations/smsplanet/save', [$smsplanetIntegrationController, 'save'], [$authMiddleware]);
$router->post('/settings/integrations/smsplanet/test', [$smsplanetIntegrationController, 'test'], [$authMiddleware]);
$router->get('/settings/integrations/shoppro', [$shopproIntegrationsController, 'index'], [$authMiddleware]);
$router->post('/settings/integrations/shoppro/save', [$shopproIntegrationsController, 'save'], [$authMiddleware]);
$router->post('/settings/integrations/shoppro/test', [$shopproIntegrationsController, 'test'], [$authMiddleware]);