31 lines
787 B
PHP
31 lines
787 B
PHP
<?php
|
|
|
|
namespace App\Http\Controllers\Api;
|
|
|
|
use App\Http\Controllers\Controller;
|
|
use App\Services\ConfigurationService;
|
|
use App\Traits\ApiResponse;
|
|
use Illuminate\Http\Request;
|
|
|
|
class ConfigurationController extends Controller
|
|
{
|
|
use ApiResponse;
|
|
|
|
protected $configurationService;
|
|
|
|
public function __construct(ConfigurationService $configurationService)
|
|
{
|
|
$this->configurationService = $configurationService;
|
|
}
|
|
|
|
public function getConfigurationService()
|
|
{
|
|
try {
|
|
$data = $this->configurationService->getConfigurationService();
|
|
return $this->successResponse($data);
|
|
} catch(\Exception $e) {
|
|
return $this->errorResponse('Failed to fetch configuration service', 400, $e->getMessage());
|
|
}
|
|
}
|
|
}
|