mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-25 03:08:51 +02:00
Fixed API Platform deprecations
This commit is contained in:
parent
d0a5b4dcd7
commit
717a9fb0a3
18 changed files with 72 additions and 29 deletions
|
@ -26,6 +26,7 @@ namespace App\ApiResource;
|
|||
use ApiPlatform\Metadata\ApiFilter;
|
||||
use ApiPlatform\Metadata\ApiResource;
|
||||
use ApiPlatform\Metadata\Get;
|
||||
use ApiPlatform\OpenApi\Model\Operation;
|
||||
use ApiPlatform\Serializer\Filter\PropertyFilter;
|
||||
use App\State\PartDBInfoProvider;
|
||||
|
||||
|
@ -35,7 +36,7 @@ use App\State\PartDBInfoProvider;
|
|||
#[ApiResource(
|
||||
uriTemplate: '/info.{_format}',
|
||||
description: 'Basic information about Part-DB like version, title, etc.',
|
||||
operations: [new Get(openapiContext: ['summary' => 'Get basic information about the installed Part-DB instance.'])],
|
||||
operations: [new Get(openapi: new Operation(summary: 'Get basic information about the installed Part-DB instance.'))],
|
||||
provider: PartDBInfoProvider::class
|
||||
)]
|
||||
#[ApiFilter(PropertyFilter::class)]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue