优化
This commit is contained in:
@@ -20,9 +20,8 @@ abstract class AetherController
|
||||
#[Inject]
|
||||
protected ResponseInterface $response;
|
||||
|
||||
|
||||
/**
|
||||
* 获取资源列表 (RESTFul: GET /resources)
|
||||
* 获取资源列表 (RESTFul: GET resources/list).
|
||||
*/
|
||||
public function index(): array
|
||||
{
|
||||
@@ -32,7 +31,7 @@ abstract class AetherController
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取单个资源 (RESTFul: GET /resources/{id})
|
||||
* 获取单个资源 (RESTFul: GET resources/{id}).
|
||||
*/
|
||||
public function detail(int $id): array
|
||||
{
|
||||
@@ -41,7 +40,7 @@ abstract class AetherController
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建资源 (RESTFul: POST /resources)
|
||||
* 创建资源 (RESTFul: POST resources).
|
||||
*/
|
||||
public function create(): array
|
||||
{
|
||||
@@ -51,7 +50,7 @@ abstract class AetherController
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新资源 (RESTFul: PUT /resources/{id})
|
||||
* 更新资源 (RESTFul: PUT resources/{id}).
|
||||
*/
|
||||
public function update(int $id): array
|
||||
{
|
||||
@@ -61,7 +60,7 @@ abstract class AetherController
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除资源 (RESTFul: DELETE /resources/{id})
|
||||
* 删除资源 (RESTFul: DELETE resources/{id}).
|
||||
*/
|
||||
public function delete(int $id): array
|
||||
{
|
||||
@@ -70,8 +69,7 @@ abstract class AetherController
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取对应的服务类
|
||||
* @return AetherCrudService
|
||||
* 获取对应的服务类.
|
||||
*/
|
||||
abstract protected function getService(): AetherCrudService;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user