forked from wallabag/wallabag
Update annotations to OpenApi 3
Most of the API annotations are directly converted. The changes in meaning are: - Parameters "in body" is not supported anymore. These are changed to "in query" or to a request body (depending on the code).
This commit is contained in:
@ -5,9 +5,9 @@ namespace Wallabag\ApiBundle\Controller;
|
||||
use Hateoas\Configuration\Route as HateoasRoute;
|
||||
use Hateoas\Representation\Factory\PagerfantaFactory;
|
||||
use Nelmio\ApiDocBundle\Annotation\Operation;
|
||||
use OpenApi\Annotations as OA;
|
||||
use Pagerfanta\Doctrine\ORM\QueryAdapter as DoctrineORMAdapter;
|
||||
use Pagerfanta\Pagerfanta;
|
||||
use Swagger\Annotations as SWG;
|
||||
use Symfony\Component\HttpFoundation\JsonResponse;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\Routing\Annotation\Route;
|
||||
@ -21,34 +21,34 @@ class SearchRestController extends WallabagRestController
|
||||
* @Operation(
|
||||
* tags={"Search"},
|
||||
* summary="Search all entries by term.",
|
||||
* @SWG\Parameter(
|
||||
* @OA\Parameter(
|
||||
* name="term",
|
||||
* in="body",
|
||||
* in="query",
|
||||
* description="Any query term",
|
||||
* required=false,
|
||||
* @SWG\Schema(type="string")
|
||||
* @OA\Schema(type="string")
|
||||
* ),
|
||||
* @SWG\Parameter(
|
||||
* @OA\Parameter(
|
||||
* name="page",
|
||||
* in="body",
|
||||
* in="query",
|
||||
* description="what page you want.",
|
||||
* required=false,
|
||||
* @SWG\Schema(
|
||||
* @OA\Schema(
|
||||
* type="integer",
|
||||
* default=1
|
||||
* )
|
||||
* ),
|
||||
* @SWG\Parameter(
|
||||
* @OA\Parameter(
|
||||
* name="perPage",
|
||||
* in="body",
|
||||
* in="query",
|
||||
* description="results per page.",
|
||||
* required=false,
|
||||
* @SWG\Schema(
|
||||
* @OA\Schema(
|
||||
* type="integer",
|
||||
* default=30
|
||||
* )
|
||||
* ),
|
||||
* @SWG\Response(
|
||||
* @OA\Response(
|
||||
* response="200",
|
||||
* description="Returned when successful"
|
||||
* )
|
||||
|
||||
Reference in New Issue
Block a user