feat: sku
This commit is contained in:
@@ -7,19 +7,30 @@ use App\Service\Api\Good\MealListService;
|
||||
use App\Service\Api\Good\OptionalListService;
|
||||
use Hyperf\HttpServer\Annotation\Controller;
|
||||
use Hyperf\HttpServer\Annotation\RequestMapping;
|
||||
use Hyperf\Validation\Annotation\Scene;
|
||||
use Psr\Container\ContainerExceptionInterface;
|
||||
use Psr\Container\NotFoundExceptionInterface;
|
||||
|
||||
#[Controller(prefix: 'api/good')]
|
||||
class GoodController extends AbstractController
|
||||
{
|
||||
/**
|
||||
* @return array[]
|
||||
* @throws ContainerExceptionInterface
|
||||
* @throws NotFoundExceptionInterface
|
||||
*/
|
||||
#[RequestMapping(path: 'optional',methods: 'GET')]
|
||||
public function optional()
|
||||
public function optional(): array
|
||||
{
|
||||
return (new OptionalListService)->handle();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array[]
|
||||
* @throws ContainerExceptionInterface
|
||||
* @throws NotFoundExceptionInterface
|
||||
*/
|
||||
#[RequestMapping(path: 'meal',methods: 'GET')]
|
||||
public function meal()
|
||||
public function meal(): array
|
||||
{
|
||||
return (new MealListService)->handle();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user