Files
spa-api/app/Http/Controllers/HomeController.php
2025-05-07 14:48:34 +08:00

37 lines
777 B
PHP

<?php
namespace App\Http\Controllers;
use App\BaseApp\BaseController;
use App\Service\HomeService;
use App\Service\ProjectService;
use Illuminate\Http\JsonResponse;
use Psr\Container\ContainerExceptionInterface;
use Psr\Container\NotFoundExceptionInterface;
class HomeController extends BaseController
{
//
public function __construct()
{
parent::__construct();
$this->service = HomeService::getInstance();
}
/**
* 轮播图列表
* @Method GET
* @return JsonResponse
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/
public function carousel(): JsonResponse
{
return jok(
$this->service->carousel(),
'轮播图列表'
);
}
}