Basket Bundle Attributes

This commit is contained in:
Thomas Peterson 2025-12-15 17:01:07 +01:00
parent c504f9e4de
commit 1cc2bc57ba
212 changed files with 2149 additions and 3292 deletions

View File

@ -474,7 +474,7 @@ namespace Symfony\Component\DependencyInjection\Loader\Configurator;
* datetime?: array{
* default_format?: scalar|null, // Default: "Y-m-d\\TH:i:sP"
* default_deserialization_formats?: list<scalar|null>,
* default_timezone?: scalar|null, // Default: "Europe/Berlin"
* default_timezone?: scalar|null, // Default: "UTC"
* cdata?: scalar|null, // Default: true
* },
* array_collection?: array{
@ -574,7 +574,7 @@ namespace Symfony\Component\DependencyInjection\Loader\Configurator;
* datetime?: array{
* default_format?: scalar|null, // Default: "Y-m-d\\TH:i:sP"
* default_deserialization_formats?: list<scalar|null>,
* default_timezone?: scalar|null, // Default: "Europe/Berlin"
* default_timezone?: scalar|null, // Default: "UTC"
* cdata?: scalar|null, // Default: true
* },
* array_collection?: array{

View File

@ -23,7 +23,7 @@ use PSC\System\UpdateBundle\Service\Migration;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Intl\NumberFormatter\NumberFormatter;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\UX\Chartjs\Builder\ChartBuilderInterface;
use Symfony\UX\Chartjs\Model\Chart;

View File

@ -15,7 +15,7 @@ namespace PSC\Backend\DashboardBundle\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;

View File

@ -16,7 +16,7 @@ namespace PSC\Backend\DashboardBundle\Controller;
use Http\Message\Authentication;
use PSC\System\UpdateBundle\Service\Migration;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Security\Http\Authentication\AuthenticationUtils;

View File

@ -30,7 +30,7 @@ use Symfony\Component\Form\FormError;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -4,7 +4,7 @@ namespace PSC\Backend\ToolsBundle\Controller\Backend;
use PSC\Backend\ToolsBundle\Interfaces\ConfigurableElementInterface;
use PSC\Backend\ToolsBundle\Service\ExporterRegistry;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;

View File

@ -5,7 +5,7 @@ namespace PSC\Backend\ToolsBundle\Controller\Backend;
use PSC\Backend\ToolsBundle\Interfaces\ConfigurableElementInterface;
use PSC\Backend\ToolsBundle\Service\ImporterRegistry;
use Symfony\Component\DependencyInjection\Attribute\TaggedIterator;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;

View File

@ -3,65 +3,65 @@
namespace PSC\Component\ApiBundle\Api\Account;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Component\ApiBundle\Dto\Account\GetParentByTitle\Input;
use PSC\Component\ApiBundle\Dto\Account\GetParentByTitle\Output;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Component\ApiBundle\Dto\Shop\Shops;
use PSC\Component\ApiBundle\Model\Shop;
use PSC\Component\ApiBundle\Model\Shop\Domain;
use PSC\Shop\EntityBundle\Entity\Account;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;
class GetParentByTitle extends AbstractController
{
private EntityManagerInterface $entityManager;
private \PSC\System\SettingsBundle\Service\Shop $shopService;
public function __construct(EntityManagerInterface $entityManager, \PSC\System\SettingsBundle\Service\Shop $shopService)
{
public function __construct(
EntityManagerInterface $entityManager,
\PSC\System\SettingsBundle\Service\Shop $shopService,
) {
$this->entityManager = $entityManager;
$this->shopService = $shopService;
}
/**
* Check account parents by title
*
* @OA\Response(
* response=200,
* description="account",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Account\GetParentByTitle\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Component\ApiBundle\Dto\Account\GetParentByTitle\Input::class))
* )
* @OA\Tag(name="Account")
* @IsGranted("ROLE_API")
* @Security(name="ApiKeyAuth")
*/
#[Response(
response: 200,
description: 'account',
content: new JsonContent(
ref: new Model(type: PSC\Component\ApiBundle\Dto\Account\GetParentByTitle\Output::class),
),
)]
#[RequestBody(
description: 'This is a request body',
content: new Model(type: PSC\Component\ApiBundle\Dto\Account\GetParentByTitle\Input::class),
)]
#[Tag(name: 'Account')]
#[IsGranted('ROLE_API')]
#[Security(name: 'ApiKeyAuth')]
#[Route(path: '/account/getparentbytitle', methods: ['POST'])]
public function existsAction(#[MapRequestPayload] Input $data): JsonResponse
public function existsAction(#[MapRequestPayload] Input $data): JsonResponse
{
$output = new Output();
$account = $this->entityManager
->getRepository('PSC\Shop\EntityBundle\Entity\Account')
->getAccountByTitle(
$data->title
);
->getAccountByTitle($data->title);
if (!$account) {
$output->parent = "";
$output->parent = '';
$output->parent_id = 0;
return $this->json($output);
}
@ -76,14 +76,7 @@ class GetParentByTitle extends AbstractController
return $this->json($output);
}
/**
* Gets the Parent Account
*
* @param \PSC\Shop\EntityBundle\Entity\Account $account
*
* @return \PSC\Shop\EntityBundle\Entity\Account
*/
protected function recursiveParent(\PSC\Shop\EntityBundle\Entity\Account $account)
protected function recursiveParent(\PSC\Shop\EntityBundle\Entity\Account $account): Account
{
if ($account->getParent()) {
$account = $this->recursiveParent($account->getParent());

View File

@ -3,9 +3,11 @@
namespace PSC\Component\ApiBundle\Api\Cms;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Component\ApiBundle\Dto\Cms\Cms\Output;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Component\ApiBundle\Dto\Shop\Shops;
@ -14,11 +16,11 @@ use PSC\Component\ApiBundle\Model\Shop;
use PSC\Component\ApiBundle\Model\Shop\Domain;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;
class Get extends AbstractController
{
@ -26,27 +28,24 @@ class Get extends AbstractController
private Cms $hydrateCms;
private \PSC\System\SettingsBundle\Service\Shop $shopService;
public function __construct(EntityManagerInterface $entityManager, \PSC\System\SettingsBundle\Service\Shop $shopService, Cms $hydrateCms)
{
public function __construct(
EntityManagerInterface $entityManager,
\PSC\System\SettingsBundle\Service\Shop $shopService,
Cms $hydrateCms,
) {
$this->entityManager = $entityManager;
$this->hydrateCms = $hydrateCms;
$this->shopService = $shopService;
}
/**
* Cms
*
* @OA\Response(
* response=200,
* description="cms",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Cms\Cms\Output::class))
* )
* @OA\Tag(name="Cms")
*/
#[Response(response: 200, description: 'cms', content: new JsonContent(ref: new Model(type: Output::class)))]
#[Tag(name: 'Cms')]
#[Route(path: '/cms', methods: ['GET'])]
public function allAction(): JsonResponse
{
$cmss = $this->entityManager->getRepository(\PSC\Shop\EntityBundle\Entity\Cms::class)->findAllByShop($this->shopService->getShopByDomain());
$cmss = $this->entityManager
->getRepository(\PSC\Shop\EntityBundle\Entity\Cms::class)
->findAllByShop($this->shopService->getShopByDomain());
$data = [];
/** @var \PSC\Shop\EntityBundle\Entity\Cms $cms */
@ -57,21 +56,17 @@ class Get extends AbstractController
return $this->json(new Output($data));
}
/**
* Get One Cms
*
* @OA\Response(
* response=200,
* description="found cms",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Model\Cms::class))
* )
* @OA\Response(
* response=404,
* description="not found",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Error\NotFound::class))
* )
* @OA\Tag(name="Cms")
*/
#[Response(
response: 200,
description: 'found cms',
content: new JsonContent(ref: new Model(type: \PSC\Component\ApiBundle\Model\Cms::class)),
)]
#[Response(
response: 404,
description: 'not found',
content: new JsonContent(ref: new Model(type: NotFound::class)),
)]
#[Tag(name: 'Cms')]
#[Route(path: '/cms/{id}', methods: ['GET'])]
public function one($id): JsonResponse
{

View File

@ -4,9 +4,11 @@ namespace PSC\Component\ApiBundle\Api\Plugin;
use Doctrine\ODM\MongoDB\DocumentManager;
use MongoDB\BSON\ObjectId;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Component\ApiBundle\Dto\Shop\Shops;
use PSC\Component\ApiBundle\Model\Shop;
@ -14,11 +16,11 @@ use PSC\Component\ApiBundle\Model\Shop\Domain;
use PSC\System\PluginBundle\Interfaces\Plugin;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;
class Get extends AbstractController
{
@ -29,16 +31,12 @@ class Get extends AbstractController
$this->documentManager = $documentManager;
}
/**
* Layouter Plugins
*
* @OA\Response(
* response=200,
* description="shops",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Plugin\Plugins\Output::class))
* )
* @OA\Tag(name="Plugin")
*/
#[Response(
response: 200,
description: 'shops',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Dto\Plugin\Plugins\Output::class)),
)]
#[Tag(name: 'Plugin')]
#[Route(path: '/plugins/layouter', methods: ['GET'])]
public function layouterAction(): JsonResponse
{
@ -61,17 +59,13 @@ class Get extends AbstractController
return $this->json(new Shops\Output($data));
}
/**
* Plugins
*
* @OA\Response(
* response=200,
* description="shops",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Plugin\Plugins\Output::class))
* )
* @OA\Tag(name="Plugin")
* @Security(name="ApiKeyAuth")
*/
#[Response(
response: 200,
description: 'shops',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Dto\Plugin\Plugins\Output::class)),
)]
#[Tag(name: 'Plugin')]
#[Security(name: 'ApiKeyAuth')]
#[Route(path: '/plugins', methods: ['GET'])]
#[IsGranted('ROLE_API')]
public function allAction(): JsonResponse
@ -90,27 +84,25 @@ class Get extends AbstractController
return $this->json(new Shops\Output($data));
}
/**
* Get one plugin
*
* @OA\Response(
* response=200,
* description="found plugin",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Model\Plugin::class))
* )
* @OA\Response(
* response=404,
* description="not found",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Error\NotFound::class))
* )
* @OA\Tag(name="Plugin")
* @Security(name="ApiKeyAuth")
*/
#[Response(
response: 200,
description: 'found plugin',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Model\Plugin::class)),
)]
#[Response(
response: 404,
description: 'not found',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Dto\Error\NotFound::class)),
)]
#[Tag(name: 'Plugin')]
#[Security(name: 'ApiKeyAuth')]
#[Route(path: '/plugins/{uuid}', methods: ['GET'])]
#[IsGranted('ROLE_API')]
public function one($uuid): JsonResponse
{
$plugin = $this->documentManager->getRepository(\PSC\System\PluginBundle\Document\Plugin::class)->findOneBy(['id' => new ObjectId($uuid)]);
$plugin = $this->documentManager
->getRepository(\PSC\System\PluginBundle\Document\Plugin::class)
->findOneBy(['id' => new ObjectId($uuid)]);
if (!$plugin) {
return $this->json(new NotFound());
}

View File

@ -3,44 +3,44 @@
namespace PSC\Component\ApiBundle\Api\Shop;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Component\ApiBundle\Dto\Shop\Shops;
use PSC\Component\ApiBundle\Model\Shop;
use PSC\Component\ApiBundle\Model\Shop\Domain;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;
class Get extends AbstractController
{
private EntityManagerInterface $entityManager;
private \PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop;
public function __construct(EntityManagerInterface $entityManager, \PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop)
{
public function __construct(
EntityManagerInterface $entityManager,
\PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop,
) {
$this->entityManager = $entityManager;
$this->hydrateShop = $hydrateShop;
}
/**
* Shops
*
* @OA\Response(
* response=200,
* description="shops",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Shop\Shops\Output::class))
* )
* @OA\Tag(name="Shops")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")
*/
#[Response(
response: 200,
description: 'shops',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Dto\Shop\Shops\Output::class)),
)]
#[Tag(name: 'Shops')]
#[Security(name: 'ApiKeyAuth')]
#[Security(name: 'Bearer')]
#[Route(path: '/shops', methods: ['GET'])]
#[IsGranted('ROLE_SHOP')]
public function allAction(): JsonResponse
@ -56,27 +56,25 @@ class Get extends AbstractController
return $this->json(new Shops\Output($data));
}
/**
* Get One Shop
*
* @OA\Response(
* response=200,
* description="found shop",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Model\Shop::class))
* )
* @OA\Response(
* response=404,
* description="not found",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Error\NotFound::class))
* )
* @OA\Tag(name="Shops")
* @Security(name="ApiKeyAuth")
*/
#[Response(
response: 200,
description: 'found shop',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Model\Shop::class)),
)]
#[Response(
response: 404,
description: 'not found',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Dto\Error\NotFound::class)),
)]
#[Tag(name: 'Shops')]
#[Security(name: 'ApiKeyAuth')]
#[Route(path: '/shops/{id}', methods: ['GET'])]
#[IsGranted('ROLE_API')]
public function one($id): JsonResponse
{
$shop = $this->entityManager->getRepository(\PSC\Shop\EntityBundle\Entity\Shop::class)->findOneBy(['uid' => $id]);
$shop = $this->entityManager
->getRepository(\PSC\Shop\EntityBundle\Entity\Shop::class)
->findOneBy(['uid' => $id]);
if ($shop) {
return $this->json($this->hydrateShop->hydrateToModel($shop));

View File

@ -3,9 +3,12 @@
namespace PSC\Component\ApiBundle\Api\Stockbooking;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Component\ApiBundle\Dto\Error\PersistFailure;
use PSC\Component\ApiBundle\Dto\Shop\Shops;
@ -17,55 +20,58 @@ use PSC\Component\ApiBundle\Model\Shop\Domain;
use PSC\Component\ApiBundle\Model\Stockbooking;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;
class CreateByNr extends AbstractController
{
private EntityManagerInterface $entityManager;
private \PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop;
public function __construct(EntityManagerInterface $entityManager, \PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop)
{
public function __construct(
EntityManagerInterface $entityManager,
\PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop,
) {
$this->entityManager = $entityManager;
$this->hydrateShop = $hydrateShop;
}
/**
* create by nr
*
* @OA\Response(
* response=200,
* description="stockbooking",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Stockbooking\CreateByNr\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Component\ApiBundle\Dto\Stockbooking\CreateByNr\Input::class))
* )
* @OA\Tag(name="Stockbooking")
* @IsGranted("ROLE_API")
* @Security(name="ApiKeyAuth")
*/
#[Response(
response: 200,
description: 'stockbooking',
content: new JsonContent(
ref: new Model(type: PSC\Component\ApiBundle\Dto\Stockbooking\CreateByNr\Output::class),
),
)]
#[RequestBody(
description: 'This is a request body',
content: new Model(type: PSC\Component\ApiBundle\Dto\Stockbooking\CreateByNr\Input::class),
)]
#[Tag(name: 'Stockbooking')]
#[IsGranted('ROLE_API')]
#[Security(name: 'ApiKeyAuth')]
#[Route(path: '/stockbooking/createbynr', methods: ['POST'])]
public function create(#[MapRequestPayload] Input $data): JsonResponse
public function create(#[MapRequestPayload] Input $data): JsonResponse
{
$product = $this->entityManager
->getRepository('PSC\Shop\EntityBundle\Entity\Product')->createQueryBuilder('product')
->getRepository('PSC\Shop\EntityBundle\Entity\Product')
->createQueryBuilder('product')
->andWhere('product.nrIntern = :nr or product.nrExtern = :nr')
->setParameter('nr', $data->product_nr)
->getQuery()->getOneOrNullResult();
->getQuery()
->getOneOrNullResult();
if ($product) {
$contact = $this->entityManager
->getRepository('PSC\Shop\EntityBundle\Entity\Contact')->findOneBy(['uid' => $data->contact_id]);
->getRepository('PSC\Shop\EntityBundle\Entity\Contact')
->findOneBy(['uid' => $data->contact_id]);
if (!$contact) {
return $this->json(new NotFound("Contact not found"));
return $this->json(new NotFound('Contact not found'));
}
$stBooking = new \PSC\Shop\EntityBundle\Entity\Stockbooking($product);
@ -89,6 +95,6 @@ class CreateByNr extends AbstractController
return $this->json(new Output());
}
return $this->json(new NotFound("Product not found"));
return $this->json(new NotFound('Product not found'));
}
}

View File

@ -3,9 +3,12 @@
namespace PSC\Component\ApiBundle\Api\Stockbooking;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Component\ApiBundle\Dto\Shop\Shops;
use PSC\Component\ApiBundle\Dto\Stockbooking\GetByNr\Input;
@ -16,55 +19,55 @@ use PSC\Component\ApiBundle\Model\Shop\Domain;
use PSC\Component\ApiBundle\Model\Stockbooking;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;
class GetByNr extends AbstractController
{
private EntityManagerInterface $entityManager;
private \PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop;
public function __construct(EntityManagerInterface $entityManager, \PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop)
{
public function __construct(
EntityManagerInterface $entityManager,
\PSC\Component\ApiBundle\Hydrate\Shop $hydrateShop,
) {
$this->entityManager = $entityManager;
$this->hydrateShop = $hydrateShop;
}
/**
* get all by nr
*
* @OA\Response(
* response=200,
* description="account",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Dto\Stockbooking\GetByNr\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Component\ApiBundle\Dto\Stockbooking\GetByNr\Input::class))
* )
* @OA\Tag(name="Stockbooking")
* @IsGranted("ROLE_API")
* @Security(name="ApiKeyAuth")
*/
#[Response(
response: 200,
description: 'account',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Dto\Stockbooking\GetByNr\Output::class)),
)]
#[RequestBody(
description: 'This is a request body',
content: new Model(type: PSC\Component\ApiBundle\Dto\Stockbooking\GetByNr\Input::class),
)]
#[Tag(name: 'Stockbooking')]
#[IsGranted('ROLE_API')]
#[Security(name: 'ApiKeyAuth')]
#[Route(path: '/stockbooking/getallbynr', methods: ['POST'])]
public function allAction(#[MapRequestPayload] Input $data): JsonResponse
public function allAction(#[MapRequestPayload] Input $data): JsonResponse
{
$product = $this->entityManager
->getRepository('PSC\Shop\EntityBundle\Entity\Product')->createQueryBuilder('product')
->getRepository('PSC\Shop\EntityBundle\Entity\Product')
->createQueryBuilder('product')
->andWhere('product.nrIntern = :nr or product.nrExtern = :nr')
->setParameter('nr', $data->nr)
->getQuery()->getOneOrNullResult();
->getQuery()
->getOneOrNullResult();
if ($product) {
$bookings = $this->entityManager
->getRepository('PSC\Shop\EntityBundle\Entity\Stockbooking')
->findByProduct($product);
$bookingsTemp = array();
$bookingsTemp = [];
/** @var \PSC\Shop\EntityBundle\Entity\Stockbooking $booking */
foreach ($bookings as $booking) {
$contact = new Contact();
@ -85,6 +88,6 @@ class GetByNr extends AbstractController
return $this->json(new Output($bookingsTemp));
}
return $this->json(new NotFound("Product not found"));
return $this->json(new NotFound('Product not found'));
}
}

View File

@ -3,32 +3,28 @@
namespace PSC\Component\ApiBundle\Api\System;
use Doctrine\ODM\MongoDB\DocumentManager;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Component\ApiBundle\Model\Instance;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;
class Info extends AbstractController
{
/**
* Get system info.
*
*
* @Security(name="ApiKeyAuth")
* @OA\Response(
* response=200,
* description="Returns system info",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Model\Instance::class))
* )
* @OA\Tag(name="System")
*/
#[Tag(name: 'System')]
#[Response(
response: 200,
description: 'Returns system info',
content: new JsonContent(ref: new Model(type: Instance::class)),
)]
#[Route(path: '/system/info', methods: ['GET'])]
#[IsGranted('ROLE_API')]
public function infoAction(DocumentManager $documentManager): JsonResponse
@ -38,14 +34,13 @@ class Info extends AbstractController
->getRepository(\PSC\Shop\EntityBundle\Document\Instance::class)
->findOneBy(['appId' => '1']);
$data = new Instance();
$data->sftpHost = getenv('ftpIp');
$data->ip = getenv('ftpIp');
$data->sftpUserName = getenv('ftpUsername');
$data->sftpPassword = getenv('ftpPassword');
$data->sftpPort = getenv('ftpPort');
if($instance && $instance->isSmtpOwn()) {
if ($instance && $instance->isSmtpOwn()) {
$data->smtpOwn = true;
}

View File

@ -2,14 +2,16 @@
namespace PSC\Component\ApiBundle\Api\System;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
class Version extends AbstractController
@ -21,17 +23,12 @@ class Version extends AbstractController
$this->kernel = $kernel;
}
/**
* Get Release version.
*
*
* @OA\Response(
* response=200,
* description="release version",
* @OA\JsonContent(ref=@Model(type=\PSC\Component\ApiBundle\Model\Version::class))
* )
* @OA\Tag(name="System")
*/
#[Response(
response: 200,
description: 'release version',
content: new JsonContent(ref: new Model(type: PSC\Component\ApiBundle\Model\Version::class)),
)]
#[Tag(name: 'System')]
#[Route(path: '/system/version', methods: ['GET'])]
public function versionAction(): JsonResponse
{

View File

@ -2,15 +2,12 @@
namespace PSC\Component\ApiBundle\Dto\Account\GetParentByTitle;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
final class Input
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $title;
}

View File

@ -2,22 +2,15 @@
namespace PSC\Component\ApiBundle\Dto\Account\GetParentByTitle;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
final class Output
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $parent;
/**
* @var int
*
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $parent_id;
}

View File

@ -3,8 +3,10 @@
namespace PSC\Component\ApiBundle\Dto\Cms\Cms;
use PSC\Component\ApiBundle\Model\Cms;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
class Output
{
@ -14,17 +16,9 @@ class Output
$this->count = count($cms);
}
/**
* @var Cms[]
*
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Component\ApiBundle\Model\Cms::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Component\ApiBundle\Model\Cms::class)))]
public array $data = [];
/**
* @var int
*
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $count = 0;
}

View File

@ -3,8 +3,9 @@
namespace PSC\Component\ApiBundle\Dto\Error;
use PSC\Component\ApiBundle\Model\Shop;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class NotFound
{
@ -13,8 +14,6 @@ class NotFound
$this->message = $message;
}
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $message = "";
}

View File

@ -3,8 +3,9 @@
namespace PSC\Component\ApiBundle\Dto\Error;
use PSC\Component\ApiBundle\Model\Shop;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class PersistFailure
{
@ -13,8 +14,6 @@ class PersistFailure
$this->message = $message;
}
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $message = "";
}

View File

@ -2,8 +2,10 @@
namespace PSC\Component\ApiBundle\Dto\Plugin\Plugins;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
use PSC\Component\ApiBundle\Model\Plugin;
class Output
@ -14,17 +16,9 @@ class Output
$this->count = count($plugins);
}
/**
* @var Plugin[]
*
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Component\ApiBundle\Model\Plugin::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Component\ApiBundle\Model\Plugin::class)))]
public array $data = [];
/**
* @var int
*
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $count = 0;
}

View File

@ -3,8 +3,10 @@
namespace PSC\Component\ApiBundle\Dto\Shop\Shops;
use PSC\Component\ApiBundle\Model\Shop;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
class Output
{
@ -14,17 +16,9 @@ class Output
$this->count = count($shops);
}
/**
* @var Shop[]
*
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Component\ApiBundle\Model\Shop::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Component\ApiBundle\Model\Shop::class)))]
public array $data = [];
/**
* @var int
*
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $count = 0;
}

View File

@ -2,43 +2,24 @@
namespace PSC\Component\ApiBundle\Dto\Stockbooking\CreateByNr;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Input
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $product_nr = "";
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $description = "";
/**
* @var int
*
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $amount = 0;
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $delivery_nr = "";
/**
* @var int
*
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $contact_id = 0;
}

View File

@ -2,16 +2,13 @@
namespace PSC\Component\ApiBundle\Dto\Stockbooking\CreateByNr;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use PSC\Component\ApiBundle\Model\Stockbooking;
class Output
{
/**
* @var bool
*
* @OA\Property(type="boolean")
*/
#[Property(type: 'boolean')]
public bool $success = true;
}

View File

@ -2,15 +2,12 @@
namespace PSC\Component\ApiBundle\Dto\Stockbooking\GetByNr;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Input
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $nr = "";
}

View File

@ -2,8 +2,10 @@
namespace PSC\Component\ApiBundle\Dto\Stockbooking\GetByNr;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
use PSC\Component\ApiBundle\Model\Stockbooking;
class Output
@ -14,17 +16,9 @@ class Output
$this->count = count($shops);
}
/**
* @var Stockbooking[]
*
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Component\ApiBundle\Model\Stockbooking::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Component\ApiBundle\Model\Stockbooking::class)))]
public array $data = [];
/**
* @var int
*
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $count = 0;
}

View File

@ -13,25 +13,18 @@
namespace PSC\Component\ApiBundle\Model;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Cms
{
/**
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $id;
/**
* @OA\Property(type="string", maxLength=255)
*/
public string $title = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
public string $text = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
public string $shopId = "";
#[Property(type: 'string', maxLength: 255)]
public string $title = '';
#[Property(type: 'string', maxLength: 255)]
public string $text = '';
#[Property(type: 'string', maxLength: 255)]
public string $shopId = '';
}

View File

@ -13,34 +13,23 @@
namespace PSC\Component\ApiBundle\Model;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Instance
{
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $sftpUserName = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $sftpPassword;
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $sftpPort;
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $sftpHost;
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $ip;
/**
* @OA\Property(type="boolean")
*/
#[Property(type: 'boolean')]
public bool $smtpOwn = false;
}

View File

@ -13,8 +13,9 @@
namespace PSC\Component\ApiBundle\Model;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Plugin
{
@ -24,16 +25,10 @@ class Plugin
$this->title = $title;
}
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $uuid = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $title = "";
/**
* @OA\Property(type="boolean")
*/
#[Property(type: 'boolean')]
public bool $installed = false;
}

View File

@ -13,62 +13,38 @@
namespace PSC\Component\ApiBundle\Model;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
class Shop
{
/**
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $id = 0;
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $uuid = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $name = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $basketField1 = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $basketField2 = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $logo1 = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $logo2 = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $browsericon = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $basketPosField1 = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $basketPosField2 = "";
/**
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Component\ApiBundle\Model\Shop\Domain::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Component\ApiBundle\Model\Shop\Domain::class)))]
public array $domains = [];
/**
* @OA\Property(type="boolean")
*/
#[Property(type: 'boolean')]
public bool $disabled = false;
/**
* @OA\Property(type="boolean")
*/
#[Property(type: 'boolean')]
public bool $private = false;
/**

View File

@ -13,8 +13,9 @@
namespace PSC\Component\ApiBundle\Model\Shop;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Domain
{
@ -25,16 +26,10 @@ class Domain
$this->ssl = $ssl;
}
/**
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $id;
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $name = "";
/**
* @OA\Property(type="boolean")
*/
#[Property(type: 'boolean')]
public bool $ssl = false;
}

View File

@ -13,37 +13,24 @@
namespace PSC\Component\ApiBundle\Model;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Stockbooking
{
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $id;
/**
* @OA\Property(type="object")
*/
#[Property(type: 'object')]
public Contact $contact;
/**
* @OA\Property(type="object")
*/
#[Property(type: 'object')]
public Product $product;
/**
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
public int $amount = 0;
/**
* @OA\Property(type="date")
*/
#[Property(type: 'date')]
public \DateTime $created;
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $deliveryNumber;
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $description;
}

View File

@ -13,17 +13,15 @@
namespace PSC\Component\ApiBundle\Model;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Nelmio\ApiDocBundle\Attribute\Model;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Version
{
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $datum = "";
/**
* @OA\Property(type="string", maxLength=255)
*/
#[Property(type: 'string', maxLength: 255)]
public string $release = "";
}

View File

@ -26,7 +26,7 @@ use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Security\Core\Exception\AccessDeniedException;
use Symfony\Component\Security\Core\Authentication\Token\UsernamePasswordToken;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Translation\Exception\NotFoundResourceException;

View File

@ -14,7 +14,7 @@
namespace PSC\Component\SteplayouterBundle\Calendar\Type;
use PSC\Component\SteplayouterBundle\Calendar\Type;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;

View File

@ -14,7 +14,7 @@
namespace PSC\Component\SteplayouterBundle\Calendar\Type;
use PSC\Component\SteplayouterBundle\Calendar\Type;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;

View File

@ -14,7 +14,7 @@
namespace PSC\Component\SteplayouterBundle\Calendar\Type;
use PSC\Component\SteplayouterBundle\Calendar\Type;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;

View File

@ -18,7 +18,7 @@ use PSC\Component\SteplayouterBundle\Calendar\Type\Quer;
use PSC\Component\SteplayouterBundle\Calendar\Type\Hoch;
use PSC\Component\SteplayouterBundle\Calendar\Design;
use PSC\Component\SteplayouterBundle\Calendar\Generator;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Bridge\Twig\Attribute\Template;

View File

@ -13,7 +13,7 @@
namespace PSC\Component\SteplayouterBundle\Controller;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;

View File

@ -36,7 +36,7 @@ use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Core\Authentication\Token\UsernamePasswordToken;
use Symfony\Component\Security\Core\Exception\AccessDeniedException;
use Symfony\Component\Translation\Exception\NotFoundResourceException;

View File

@ -23,7 +23,7 @@ use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Security\Core\Exception\AccessDeniedException;
use Symfony\Component\Security\Core\Authentication\Token\UsernamePasswordToken;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Translation\Exception\NotFoundResourceException;
use PSC\Component\SteplayouterBundle\Config\Converter\ToArray;

View File

@ -25,7 +25,7 @@ use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Security\Core\Exception\AccessDeniedException;
use Symfony\Component\Security\Core\Authentication\Token\UsernamePasswordToken;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Translation\Exception\NotFoundResourceException;

View File

@ -24,7 +24,7 @@ use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Form\FormError;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -24,7 +24,7 @@ use Symfony\Component\Form\FormError;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -17,7 +17,7 @@ use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Yaml\Yaml;

View File

@ -30,7 +30,7 @@ use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -26,7 +26,7 @@ use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Session\Session;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -3,15 +3,13 @@
namespace PSC\Shop\AccountBundle\Dto\All;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
use PSC\Shop\ContactBundle\Model\Contact;
class Output
{
/**
* @var Contact[]
*
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Shop\AccountBundle\Model\Account::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Shop\AccountBundle\Model\Account::class)))]
public array $data = [];
}

View File

@ -3,33 +3,24 @@
namespace PSC\Shop\AccountBundle\Model;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Account
{
/**
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
private int $id = 0;
/**
* @OA\Property(type="integer")
*/
#[Property(type: 'integer')]
private int $uid = 0;
/**
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
private string $uuid = "";
/**
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
private string $appendix;
/**
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
private string $title;
public function getUuid(): string

View File

@ -10,41 +10,82 @@ use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use PSC\Shop\BasketBundle\Dto\Layouter\Input;
use PSC\Shop\BasketBundle\Dto\Legacy\Output;
use PSC\Shop\EntityBundle\Entity\LayouterSession;
use PSC\Shop\EntityBundle\Repository\LayouterSessionRepository;
use PSC\Shop\EntityBundle\Repository\ProductRepository;
use Ramsey\Uuid\Nonstandard\Uuid;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface;
use Symfony\Contracts\EventDispatcher\EventDispatcherInterface;
use TP_Layouter_Item;
class Save extends AbstractController
{
public function __construct(
private readonly EntityManagerInterface $entityManager,
private readonly LayouterSessionRepository $layouterSessionRepository,
private readonly EventDispatcherInterface $eventDispatcher,
private readonly ProductRepository $productRepository,
private readonly TokenStorageInterface $tokenStorage,
) {}
/**
* change temp basketitem
*
* @deprecated
*/
#[Tag(name: 'Basket')]
#[Response(
response: 200,
description: 'basket',
content: new JsonContent(ref: new Model(type: Output::class))
)]
#[RequestBody(
description: 'This is a request body',
content: new Model(type: Input::class)
)]
#[Response(response: 200, description: 'basket', content: new JsonContent(ref: new Model(type: Output::class)))]
#[RequestBody(description: 'This is a request body', content: new Model(type: Input::class))]
#[Route(path: '/layouter/save', methods: ['POST'])]
public function save(#[MapRequestPayload] Input $data): JsonResponse
{
include_once __DIR__ . '/../../../../EntityBundle/Lagacy/TP_Basket_Item.php';
include_once __DIR__ . '/../../../../EntityBundle/Lagacy/TP_Basket_Collection.php';
include_once __DIR__ . '/../../../../EntityBundle/Lagacy/TP_Util.php';
include_once __DIR__ . '/../../../EntityBundle/Lagacy/TP_Basket_Item.php';
include_once __DIR__ . '/../../../EntityBundle/Lagacy/TP_Basket_Collection.php';
include_once __DIR__ . '/../../../EntityBundle/Lagacy/TP_Util.php';
include_once __DIR__ . '/../../../EntityBundle/Lagacy/TP_Layouter_Item.php';
include_once __DIR__ . '/../../../EntityBundle/Lagacy/TP_Layoutersession.php';
$product = $this->productRepository->findOneBy(['uuid' => $data->productUUId]);
if ($this->tokenStorage->getToken()) {
$row = new LayouterSession();
$row->setUuid(Uuid::uuid4()->toString());
$row->setContactId(
$this->tokenStorage
->getToken()
->getUser()
->getId(),
);
$row->setProductId($data->productUUId);
$row->setTitle($product->getTitle());
$row->setLayouterModus($data->layouterModus);
// TODO: Store uploadedFiles in session data
$this->entityManager->persist($row);
return $this->json([
'success' => true,
'layouterUUId' => $row->getUuid(),
'auth' => true,
'user' => $this->tokenStorage
->getToken()
->getUser()
->getUsername(),
]);
}
$session = new TP_Layouter_Item();
$session->setTitle($product->getTitle());
$session->setArticleId(Uuid::uuid4()->toString());
$session->setOrgArticleId($data->productUUId);
$session->setIsEdit(true);
$session->setUpdated(date('Y-m-d H:i:s'));
$session->setLayouterModus($data->layouterModus);
// Store uploaded files in session
$_SESSION['Layoutersession']['data'][$session->getArticleId()] = $session;
return $this->json([
'success' => true,
'auth' => false,
'layouterUUId' => $session->getArticleId(),
]);
}
}

View File

@ -0,0 +1,91 @@
<?php
namespace PSC\Shop\BasketBundle\Api\Layouter;
use Doctrine\ODM\MongoDB\DocumentManager;
use Nelmio\ApiDocBundle\Attribute\Security;
use OpenApi\Attributes\MediaType;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\RequestBody;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Schema;
use OpenApi\Attributes\Tag;
use PSC\Shop\MediaBundle\Document\Folder;
use PSC\Shop\MediaBundle\Document\Media;
use PSC\Shop\MediaBundle\Helper\MediaManager;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Attribute\Route;
class Upload extends AbstractController
{
#[RequestBody(description: 'PDF file for layouter', content: [
new MediaType(
'multipart/form-data',
new Schema(
properties: [
new Property(
property: 'file',
format: 'binary',
type: 'file',
description: 'PDF file',
),
new Property(
property: 'fileName',
type: 'string',
description: 'Original file name',
),
new Property(
property: 'folder',
type: 'string',
description: 'Folder',
),
],
required: ['file'],
),
),
])]
#[Response(response: 200, description: 'File uploaded successfully')]
#[Response(response: 400, description: 'Bad request - no file provided')]
#[Route(path: '/layouter/upload', methods: ['POST'])]
#[Tag(name: 'Basket')]
public function upload(MediaManager $mediaManager, DocumentManager $documentManager, Request $req): JsonResponse
{
$file = $req->files->get('file');
if (!$file) {
return $this->json(
data: ['error' => 'No file provided'],
status: JsonResponse::HTTP_BAD_REQUEST,
);
}
try {
$selectedFolder = $documentManager->getRepository(Folder::class)->findOneBy(['_id' => $req->get('folder')]);
$handler = $mediaManager->getHandlerForType('pdf');
$media = new Media();
$media->setContent($file);
$media->setFolder($selectedFolder);
$handler->prepareMedia($media);
// Store additional metadata
$media->setTitle($req->get('fileName', $file->getClientOriginalName()));
$documentManager->persist($media);
$documentManager->flush();
return $this->json([
'success' => true,
'uuid' => $media->getId(),
'url' => $media->getUrl(),
]);
} catch (\Exception $e) {
return $this->json(
data: ['error' => 'Upload failed: ' . $e->getMessage()],
status: JsonResponse::HTTP_INTERNAL_SERVER_ERROR,
);
}
}
}

View File

@ -2,6 +2,7 @@
namespace PSC\Shop\BasketBundle\Dto\Layouter;
use OpenApi\Attributes\Items;
use OpenApi\Attributes\Property;
class Input
@ -9,6 +10,6 @@ class Input
#[Property(type: 'string')]
public string $productUUId = '';
#[Property(type: 'string')]
public string $layouterUUId = '';
#[Property(type: 'integer')]
public int $layouterModus = 0;
}

View File

@ -34,7 +34,7 @@ use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -24,7 +24,7 @@ use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -19,7 +19,7 @@ use PSC\System\SettingsBundle\Service\Shop;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -43,7 +43,7 @@ use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\RedirectResponse;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -13,7 +13,7 @@ use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use OpenApi\Attributes as OA;
class Crud extends AbstractController {

View File

@ -13,7 +13,7 @@ use PSC\System\SettingsBundle\Service\Shop;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use OpenApi\Attributes as OA;
class GetAllForType extends AbstractController

View File

@ -13,7 +13,7 @@ use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use OpenApi\Attributes as OA;
use Nelmio\ApiDocBundle\Annotation\Security;

View File

@ -14,7 +14,7 @@ use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use OpenApi\Attributes as OA;
class AllByShop extends AbstractController

View File

@ -14,7 +14,7 @@ use setasign\Fpdi\PdfReader\DataStructure\Rectangle;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use OpenApi\Attributes as OA;
class Crud extends AbstractController {

View File

@ -5,7 +5,11 @@ namespace PSC\Shop\ContactBundle\Api;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Shop\ContactBundle\Dto\Exists\Input;
use PSC\Shop\ContactBundle\Dto\Exists\Output;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
@ -14,9 +18,9 @@ use PSC\Component\ApiBundle\Model\Shop;
use PSC\Component\ApiBundle\Model\Shop\Domain;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -35,16 +39,16 @@ class Exists extends AbstractController
/**
* User exists in database
*
* @OA\Response(
* response=200,
* description="contact",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\ContactBundle\Dto\Exists\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\ContactBundle\Dto\Exists\Input::class))
* )
* @OA\Tag(name="Contact")
#[Response(
* response: 200,
* description: 'contact',
* content: new JsonContent(ref: new Model(type: PSC\Shop\ContactBundle\Dto\Exists\Output::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\ContactBundle\Dto\Exists\Input::class)
* )]
#[Tag(name: 'Contact')]
* @IsGranted("ROLE_API")
* @Security(name="ApiKeyAuth")
*/
@ -71,16 +75,16 @@ class Exists extends AbstractController
/**
* User exists in database
*
* @OA\Response(
* response=200,
* description="contact",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\ContactBundle\Dto\Exists\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\ContactBundle\Dto\ExistsWithPassword\Input::class))
* )
* @OA\Tag(name="Contact")
#[Response(
* response: 200,
* description: 'contact',
* content: new JsonContent(ref: new Model(type: PSC\Shop\ContactBundle\Dto\Exists\Output::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\ContactBundle\Dto\ExistsWithPassword\Input::class)
* )]
#[Tag(name: 'Contact')]
* @IsGranted("ROLE_API")
* @Security(name="ApiKeyAuth")
*/

View File

@ -13,7 +13,7 @@ use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
use Lexik\Bundle\JWTAuthenticationBundle\Services\JWTTokenManagerInterface;

View File

@ -7,7 +7,7 @@ use Nelmio\ApiDocBundle\Annotation\Security;
use PSC\Shop\ContactBundle\Dto\Refresh\Output;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Lexik\Bundle\JWTAuthenticationBundle\Services\JWTTokenManagerInterface;
use OpenApi\Attributes as OA;

View File

@ -15,7 +15,7 @@ use PSC\System\SettingsBundle\Service\History;
use PSC\System\SettingsBundle\Service\Log;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\HttpFoundation\Request;

View File

@ -33,7 +33,7 @@ use Symfony\Component\HttpFoundation\File\File;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -44,7 +44,7 @@ use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -21,7 +21,7 @@ use PSC\System\SettingsBundle\Service\Shop;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\RequestStack;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -3,15 +3,13 @@
namespace PSC\Shop\ContactBundle\Dto\Address\GetAllForType;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
use PSC\Shop\ContactBundle\Model\Address;
class Output
{
/**
* @var Address[]
*
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Shop\ContactBundle\Model\Address::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Shop\ContactBundle\Model\Address::class)))]
public array $data = [];
}

View File

@ -3,15 +3,13 @@
namespace PSC\Shop\ContactBundle\Dto\All;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Items;
use PSC\Shop\ContactBundle\Model\Contact;
class Output
{
/**
* @var Contact[]
*
* @OA\Property(type="array", @OA\Items(ref=@Model(type=\PSC\Shop\ContactBundle\Model\Contact::class)))
*/
#[Property(type: 'array', items: new Items(ref: new Model(type: PSC\Shop\ContactBundle\Model\Contact::class)))]
public array $data = [];
}

View File

@ -3,14 +3,11 @@
namespace PSC\Shop\ContactBundle\Dto\Exists;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Input
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $username = "";
}

View File

@ -3,14 +3,11 @@
namespace PSC\Shop\ContactBundle\Dto\Exists;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Output
{
/**
* @var bool
*
* @OA\Property(type="boolean")
*/
#[Property(type: 'boolean')]
public string $exists;
}

View File

@ -3,21 +3,14 @@
namespace PSC\Shop\ContactBundle\Dto\ExistsWithPassword;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Input
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $username = "";
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $password = "";
}

View File

@ -3,14 +3,11 @@
namespace PSC\Shop\ContactBundle\Dto\Login;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Output
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $token;
}

View File

@ -3,29 +3,18 @@
namespace PSC\Shop\ContactBundle\Dto\Refresh;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
class Output
{
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $token;
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $userName;
/**
* @var string
*
* @OA\Property(type="string")
*/
#[Property(type: 'string')]
public string $email;
}

View File

@ -22,7 +22,7 @@ use PSC\Shop\EntityBundle\Entity\ShopAccount;
use PSC\Shop\EntityBundle\Entity\ShopContact;
use PSC\System\SettingsBundle\Service\Shop;
use Ramsey\Uuid\Uuid;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;

View File

@ -14,7 +14,7 @@ use PSC\Shop\EntityBundle\Entity\Shop;
use PSC\Shop\EntityBundle\Entity\ShopAccount;
use PSC\Shop\EntityBundle\Entity\ShopContact;
use Ramsey\Uuid\Uuid;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;

View File

@ -17,6 +17,29 @@ class LayouterSession
#[ORM\Column(name: 'uuid', type: 'string', length: 255, nullable: true)]
protected string $uuid;
#[ORM\Column(name: 'layouter_modus', type: 'integer')]
protected int $layouterModus = 0;
#[ORM\Column(name: 'title', type: 'string', length: 255, nullable: true)]
protected string $title;
#[ORM\Column(name: 'org_article_id', type: 'integer')]
protected string $productId;
#[ORM\Column(name: 'contact_id', type: 'integer')]
protected string $contactId;
#[ORM\Column(name: 'created', type: 'datetime', nullable: true)]
protected \DateTime $createdAt;
#[ORM\Column(name: 'updated', type: 'datetime', nullable: true)]
protected \DateTime $updatedAt;
public function __construct()
{
$this->createdAt = new \DateTime();
$this->updatedAt = new \DateTime();
}
public function getUid(): int
{
return $this->uid;
@ -36,4 +59,64 @@ class LayouterSession
{
$this->uuid = $uuid;
}
public function getLayouterModus(): int
{
return $this->layouterModus;
}
public function setLayouterModus(int $layouterModus): void
{
$this->layouterModus = $layouterModus;
}
public function getTitle(): string
{
return $this->title;
}
public function setTitle(string $title): void
{
$this->title = $title;
}
public function getProductId(): string
{
return $this->productId;
}
public function setProductId(string $productId): void
{
$this->productId = $productId;
}
public function getContactId(): string
{
return $this->contactId;
}
public function setContactId(string $contactId): void
{
$this->contactId = $contactId;
}
public function getCreatedAt(): \DateTime
{
return $this->createdAt;
}
public function setCreatedAt(\DateTime $createdAt): void
{
$this->createdAt = $createdAt;
}
public function getUpdatedAt(): \DateTime
{
return $this->updatedAt;
}
public function setUpdatedAt(\DateTime $updatedAt): void
{
$this->updatedAt = $updatedAt;
}
}

View File

@ -0,0 +1,257 @@
<?php
if (!class_exists('TP_Layouter_Item')) {
class TP_Layouter_Item
{
private $ref = '';
private $kst = '';
private $templatePrintContactId = 0;
private $_config_xml = '';
private $_page_templates = '';
private $_pages_xml = '';
private $_page_objects = '';
private $_title = '';
private $_xslfo = '';
private $_preview_xslfo = '';
private $_extend_preview_xslfo = '';
private $_article_id = '';
private $_org_article_id = '';
private $is_edit = false;
private $preview_path = '';
private $designer_xml = '';
private $template_print_id = '';
public $layouter_modus = 1;
private $updated;
public function setTemplatePrintId($var)
{
$this->template_print_id = $var;
}
public function getTemplatePrintId()
{
return $this->template_print_id;
}
public function setPreviewPath($xml)
{
$this->preview_path = $xml;
}
public function getPreviewPath()
{
return $this->preview_path;
}
public function setDesignerXML($xml)
{
$this->designer_xml = $xml;
$this->updated = date('Y-m-d H:i:s');
}
public function getDesignerXML()
{
return $this->designer_xml;
}
public function setIsEdit()
{
$this->is_edit = true;
}
public function getIsEdit()
{
return $this->is_edit;
}
public function getArticleId()
{
return $this->_article_id;
}
public function setArticleId($id)
{
$this->_article_id = $id;
}
public function getOrgArticleId()
{
return $this->_org_article_id;
}
public function setOrgArticleId($id)
{
$this->_org_article_id = $id;
}
public function getPageObjects()
{
return $this->_page_objects;
}
public function setPageObjects($xml)
{
$this->_page_objects = $xml;
}
public function setTitle($xml)
{
$this->_title = $xml;
}
public function getTitle()
{
return $this->_title;
}
public function getPageTemplates()
{
return $this->_page_templates;
}
public function setPageTemplates($xml)
{
$this->_page_templates = $xml;
}
public function getConfigXml()
{
return $this->_config_xml;
}
public function setConfigXml($xml)
{
$this->_config_xml = $xml;
}
public function getPagesXml()
{
return $this->_pages_xml;
}
public function setPagesXml($xml)
{
$this->_pages_xml = $xml;
}
public function getXslFo()
{
return $this->_xslfo;
}
public function setXslFo($xml)
{
$this->_xslfo = $xml;
}
public function getPreviewXslFo()
{
return $this->_preview_xslfo;
}
public function setPreviewXslFo($xml)
{
$this->_preview_xslfo = $xml;
}
public function getExtendPreviewXslFo()
{
return $this->_extend_preview_xslfo;
}
public function setExtendPreviewXslFo($xml)
{
$this->_extend_preview_xslfo = $xml;
}
public function getLayouterModus()
{
return $this->layouter_modus;
}
public function setLayouterModus($layouter_modus)
{
$this->layouter_modus = $layouter_modus;
}
/**
* @return bool|string
*/
public function getUpdated()
{
return $this->updated;
}
/**
* @param bool|string $updated
*/
public function setUpdated($updated)
{
$this->updated = $updated;
}
/**
* @return int
*/
public function getTemplatePrintContactId()
{
return $this->templatePrintContactId;
}
/**
* @param int $templatePrintContactId
*/
public function setTemplatePrintContactId($templatePrintContactId)
{
$this->templatePrintContactId = $templatePrintContactId;
}
/**
* @return string
*/
public function getRef()
{
return $this->ref;
}
/**
* @param string $ref
*/
public function setRef($ref)
{
$this->ref = $ref;
}
/**
* @return string
*/
public function getKst()
{
return $this->kst;
}
/**
* @param string $kst
*/
public function setKst($kst)
{
$this->kst = $kst;
}
}
}

View File

@ -0,0 +1,69 @@
<?php
require_once __DIR__ . '/TP_Layouter_Item.php';
if (!class_exists('TP_Layoutersession')) {
class TP_Layoutersession implements IteratorAggregate, Countable
{
/**
* Collection items
*
* @var array
*/
protected $_items = [];
/**
* Item object class name
*
* @var string
*/
protected $_itemObjectClass = 'Varien_Object';
/**
* Current page number for items pager
*
* @var int
*/
protected $_curPage = 1;
/**
* Pager page size
*
* if page size is false, then we works with all items
*
* @var int || false
*/
protected $_pageSize = false;
/**
* Total items number
*
* @var int
*/
protected $_totalRecords;
/**
* Loading state flag
*
* @var bool
*/
protected $_isCollectionLoaded;
public function __construct() {}
/**
* Implementation of IteratorAggregate::getIterator()
*/
#[\Override]
public function getIterator(): ArrayIterator
{
return new ArrayIterator($this->_items);
}
/**
* Retireve count of collection loaded items
*
* @return int
*/
#[\Override]
public function count(): int
{
return count($this->_items);
}
}
}

View File

@ -2,8 +2,14 @@
namespace PSC\Shop\EntityBundle\Repository;
use Doctrine\ORM\EntityRepository;
use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
use Doctrine\Persistence\ManagerRegistry;
use PSC\Shop\EntityBundle\Entity\LayouterSession;
class LayouterSessionRepository extends EntityRepository
class LayouterSessionRepository extends ServiceEntityRepository
{
public function __construct(ManagerRegistry $registry)
{
parent::__construct($registry, LayouterSession::class);
}
}

View File

@ -5,7 +5,12 @@ namespace PSC\Shop\MediaBundle\Api;
use Doctrine\ODM\MongoDB\DocumentManager;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Property;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Shop\MediaBundle\Document\Embed\Variant;
use PSC\Shop\MediaBundle\Document\Media;
use PSC\Shop\MediaBundle\Helper\MediaManager;
@ -54,7 +59,7 @@ class UploadVariant extends AbstractController
* )
* )
* )
* @OA\Tag(name="Media")
#[Tag(name: 'Media')]
* @IsGranted("ROLE_USER")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

View File

@ -14,7 +14,7 @@ use PSC\Shop\MediaBundle\Helper\FolderManager;
use PSC\Shop\MediaBundle\Helper\Media\AbstractMediaHandler;
use PSC\Shop\MediaBundle\Helper\MediaManager;
use PSC\System\SettingsBundle\Service\Shop;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\RedirectResponse;

View File

@ -37,7 +37,7 @@ use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -30,7 +30,7 @@ use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -32,7 +32,7 @@ use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -14,10 +14,10 @@
namespace PSC\Shop\MediaBundle\Document;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\ODM\MongoDB\Mapping\Annotations\Document;
use Doctrine\ODM\MongoDB\Mapping\Annotations\EmbedMany;
use Doctrine\ODM\MongoDB\Mapping\Annotations\Field;
use Doctrine\ODM\MongoDB\Mapping\Annotations\Id;
use Doctrine\ODM\MongoDB\Mapping\Annotations\Document;
use Doctrine\ODM\MongoDB\Mapping\Annotations\ReferenceOne;
use Doctrine\ODM\MongoDB\PersistentCollection;
use PSC\Shop\MediaBundle\Document\Embed\Variant;
@ -41,67 +41,67 @@ class Media implements MediaInterface
#[Field(type: 'string')]
protected $title;
/**
* @var string
*/
* @var string
*/
#[Field(type: 'string')]
protected $description;
/**
* @var string
*/
* @var string
*/
#[Field(type: 'string')]
protected $copyright;
/**
* @var string
*/
* @var string
*/
#[Field(type: 'string')]
protected $location;
/**
* @var string
*/
* @var string
*/
#[Field(type: 'string')]
protected $contentType;
/**
* @var array
*/
* @var array
*/
#[Field(type: 'hash')]
protected $metadata = array();
protected $metadata = [];
/**
* @var \DateTime
*/
* @var \DateTime
*/
#[Field(type: 'date')]
protected $createdAt;
/**
* @var \DateTime
*/
* @var \DateTime
*/
#[Field(type: 'date')]
protected $updatedAt;
/**
* @var Folder
*/
* @var Folder
*/
#[ReferenceOne(targetDocument: 'PSC\Shop\MediaBundle\Document\Folder')]
protected $folder;
/**
* @var mixed
*/
* @var mixed
*/
protected $content;
/**
* @var int
*/
* @var int
*/
#[Field(type: 'int')]
protected $filesize;
/**
* @var string
*/
* @var string
*/
#[Field(type: 'string')]
protected $url;
/**
* @var string
*/
* @var string
*/
#[Field(type: 'string')]
protected $originalFilename;
/**
* @var bool
*/
* @var bool
*/
#[Field(type: 'bool')]
protected $deleted;
#[Field(type: 'string')]
@ -112,6 +112,9 @@ class Media implements MediaInterface
protected $providerReference;
#[Field(type: 'hash')]
protected $providerMetadata = [];
#[Field(type: 'hash')]
protected array $additionalInfos = [];
public function __construct()
{
$this->setCreatedAt(new \DateTime());
@ -151,6 +154,7 @@ class Media implements MediaInterface
{
$this->shop = $shop;
}
/**
* @return string
*/
@ -158,13 +162,13 @@ class Media implements MediaInterface
{
$size = $this->filesize;
if ($size < 1024) {
return $size . "b";
return $size . 'b';
} else {
$help = $size / 1024;
if ($help < 1024) {
return round($help, 1) . "kb";
return round($help, 1) . 'kb';
} else {
return round(($help / 1024), 1) . "mb";
return round($help / 1024, 1) . 'mb';
}
}
}
@ -242,7 +246,7 @@ class Media implements MediaInterface
public function getContentTypeShort()
{
$contentType = $this->contentType;
$array = explode("/", $contentType);
$array = explode('/', $contentType);
$contentType = end($array);
return $contentType;
}
@ -307,7 +311,7 @@ class Media implements MediaInterface
/**
* {@inheritdoc}
*/
public function setCreatedAt(\DateTime $createdAt = null)
public function setCreatedAt(null|\DateTime $createdAt = null)
{
$this->createdAt = $createdAt;
}
@ -325,7 +329,7 @@ class Media implements MediaInterface
/**
* {@inheritdoc}
*/
public function setUpdatedAt(\DateTime $updatedAt = null)
public function setUpdatedAt(null|\DateTime $updatedAt = null)
{
$this->updatedAt = $updatedAt;
}
@ -732,7 +736,7 @@ class Media implements MediaInterface
/**
* @inheritDoc
*/
public function setCdnFlushAt(\DateTime $cdnFlushAt = null)
public function setCdnFlushAt(null|\DateTime $cdnFlushAt = null)
{
// TODO: Implement setCdnFlushAt() method.
}
@ -847,4 +851,14 @@ class Media implements MediaInterface
{
return $this->variants;
}
public function getAdditionalInfos(): array
{
return $this->additionalInfos;
}
public function setAdditionalInfos(array $additionalInfos): void
{
$this->additionalInfos = $additionalInfos;
}
}

View File

@ -30,7 +30,7 @@ use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -21,7 +21,7 @@ use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Bridge\Twig\Attribute\Template;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpFoundation\Request;

View File

@ -6,7 +6,10 @@ use Doctrine\ORM\EntityManagerInterface;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use PSC\Shop\EntityBundle\Entity\Order;
use PSC\Shop\OrderBundle\Dto\Order\Status\Change\Input;
use PSC\Shop\OrderBundle\Dto\Order\Status\Change\Output;
@ -15,7 +18,7 @@ use PSC\System\SettingsBundle\Service\Shop;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
class Create extends AbstractController
{
@ -32,12 +35,12 @@ class Create extends AbstractController
/**
* create action for order
*
* @OA\Response(
* response=200,
* description="order",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Dto\Order\Status\Change\Output::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'order',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Status\Change\Output::class))
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_SHOP")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

View File

@ -5,15 +5,19 @@ namespace PSC\Shop\OrderBundle\Api\Order;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Shop\OrderBundle\Model\Order as ModelOrder;
use PSC\Shop\OrderBundle\Model\Order\Position\DummyProductTypeObject;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -32,16 +36,16 @@ class Calc extends AbstractController
/**
* create order
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Model\Order::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Model\Order::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Model\Order::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Model\Order::class)
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_SHOP")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

View File

@ -5,16 +5,20 @@ namespace PSC\Shop\OrderBundle\Api\Order;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Shop\OrderBundle\Dto\Order\ChangeContact\Input;
use PSC\Shop\OrderBundle\Model\Order\Position\DummyProductTypeObject;
use PSC\Shop\OrderBundle\Service\Order;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -33,16 +37,16 @@ class ChangeContact extends AbstractController
/**
* get order by uuid
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Model\Order::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Dto\Order\ChangeContact\Input::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Model\Order::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Dto\Order\ChangeContact\Input::class)
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_SHOP")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

View File

@ -5,16 +5,20 @@ namespace PSC\Shop\OrderBundle\Api\Order;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Shop\OrderBundle\Dto\Order\Copy\Input;
use PSC\Shop\OrderBundle\Model\Order\Position\DummyProductTypeObject;
use PSC\Shop\OrderBundle\Service\Order;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -33,16 +37,16 @@ class Copy extends AbstractController
/**
* get order by uuid
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Model\Order::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Dto\Order\Copy\Input::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Model\Order::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Copy\Input::class)
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_SHOP")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

View File

@ -5,16 +5,20 @@ namespace PSC\Shop\OrderBundle\Api\Order;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Shop\OrderBundle\Model\Order as ModelOrder;
use PSC\Shop\OrderBundle\Model\Order\Position\DummyProductTypeObject;
use PSC\Shop\OrderBundle\Service\Order;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -33,16 +37,16 @@ class Create extends AbstractController
/**
* create order
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Model\Order::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Model\Order::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Model\Order::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Model\Order::class)
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_SHOP")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

View File

@ -5,16 +5,20 @@ namespace PSC\Shop\OrderBundle\Api\Order;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Shop\OrderBundle\Dto\Order\GetOneByUuid\Input;
use PSC\Shop\OrderBundle\Model\Order\Position\DummyProductTypeObject;
use PSC\Shop\OrderBundle\Service\Order;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -33,16 +37,16 @@ class GetOneByUuid extends AbstractController
/**
* get order by uuid
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Model\Order::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Dto\Order\GetOneByUuid\Input::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Model\Order::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Dto\Order\GetOneByUuid\Input::class)
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_SHOP")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

View File

@ -5,7 +5,11 @@ namespace PSC\Shop\OrderBundle\Api\Order\Package;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Shop\OrderBundle\Dto\Order\Package\Nr\Input;
use PSC\Shop\OrderBundle\Dto\Order\Package\Nr\Output;
@ -15,9 +19,9 @@ use PSC\Shop\QueueBundle\Service\Event\Manager;
use PSC\System\SettingsBundle\Service\Shop;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -34,16 +38,16 @@ class Nr extends AbstractController
/**
* change packagenumber for order
*
* @OA\Response(
* response=200,
* description="order",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Dto\Order\Package\Nr\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Dto\Order\Package\Nr\Input::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'order',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Package\Nr\Output::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Package\Nr\Input::class)
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_API")
* @Security(name="ApiKeyAuth")
*/

View File

@ -5,7 +5,11 @@ namespace PSC\Shop\OrderBundle\Api\Order\Status;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Component\ApiBundle\Dto\Error\NotFound;
use PSC\Shop\OrderBundle\Dto\Order\Status\Change\Input;
use PSC\Shop\OrderBundle\Dto\Order\Status\Change\Output;
@ -15,9 +19,9 @@ use PSC\Shop\QueueBundle\Service\Event\Manager;
use PSC\System\SettingsBundle\Service\Shop;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted as SymfonyIsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -37,16 +41,16 @@ class Change extends AbstractController
/**
* change status for order
*
* @OA\Response(
* response=200,
* description="order",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Dto\Order\Status\Change\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Dto\Order\Status\Change\Input::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'order',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Status\Change\Output::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Status\Change\Input::class)
* )]
#[Tag(name: 'Order')]
* @Security(name="ApiKeyAuth")
*/
#[SymfonyIsGranted('ROLE_API')]

View File

@ -5,16 +5,20 @@ namespace PSC\Shop\OrderBundle\Api\Order\Status;
use Doctrine\ORM\EntityManagerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use OpenApi\Annotations as OA;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use OpenApi\Attributes\RequestBody;
use PSC\Shop\OrderBundle\Dto\Order\Status\GetAllByStatus\Input;
use PSC\Shop\OrderBundle\Dto\Order\Status\GetAllByStatus\Output;
use PSC\Shop\OrderBundle\Model\Order\Position\DummyProductTypeObject;
use PSC\Shop\OrderBundle\Service\Order;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Response as HttpResponse;
use Symfony\Component\HttpKernel\KernelInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Routing\Attribute\Route;
use Symfony\Component\Yaml\Yaml;
use Symfony\Component\Security\Http\Attribute\IsGranted;
use Symfony\Component\HttpKernel\Attribute\MapRequestPayload;
@ -33,16 +37,16 @@ class GetAllByStatus extends AbstractController
/**
* get orders by status
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Dto\Order\Status\GetAllByStatus\Output::class))
* )
* @OA\RequestBody(
* description="This is a request body",
* @Model(type=\PSC\Shop\OrderBundle\Dto\Order\Status\GetAllByStatus\Input::class))
* )
* @OA\Tag(name="Order")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Status\GetAllByStatus\Output::class))
* )]
#[RequestBody(
* description: 'This is a request body',
* content: new Model(type: PSC\Shop\OrderBundle\Dto\Order\Status\GetAllByStatus\Input::class)
* )]
#[Tag(name: 'Order')]
* @IsGranted("ROLE_API")
* @Security(name="ApiKeyAuth")
*/

View File

@ -7,8 +7,11 @@ use PSC\Shop\OrderBundle\Dto\Position\CheckDownload\Output;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\DependencyInjection\Attribute\TaggedIterator;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Routing\Annotation\Route;
use OpenApi\Annotations as OA;
use Symfony\Component\Routing\Attribute\Route;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
@ -22,12 +25,12 @@ class CheckDownload extends AbstractController
/**
* get order by uuid
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Dto\Position\CheckDownload\Output::class))
* )
* @OA\Tag(name="Position")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Dto\Position\CheckDownload\Output::class))
* )]
#[Tag(name: 'Position')]
*/
#[Route(path: '/position/checkdownload/{posUuid}', methods: ['GET'])]
public function checkDownload(string $posUuid): JsonResponse

View File

@ -7,8 +7,11 @@ use PSC\Shop\OrderBundle\Dto\Position\GetPluginListDisplay\Output;
use PSC\Shop\OrderBundle\Interface\List\Position;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Routing\Annotation\Route;
use OpenApi\Annotations as OA;
use Symfony\Component\Routing\Attribute\Route;
use OpenApi\Attributes as OA;
use OpenApi\Attributes\Response;
use OpenApi\Attributes\Tag;
use OpenApi\Attributes\JsonContent;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Security;
use Symfony\Component\Security\Http\Attribute\IsGranted;
@ -25,12 +28,12 @@ class GetPluginListDisplay extends AbstractController
/**
* get order by uuid
*
* @OA\Response(
* response=200,
* description="orders",
* @OA\JsonContent(ref=@Model(type=\PSC\Shop\OrderBundle\Dto\Position\GetPluginListDisplay\Output::class))
* )
* @OA\Tag(name="Position")
#[Response(
* response: 200,
* description: 'orders',
* content: new JsonContent(ref: new Model(type: PSC\Shop\OrderBundle\Dto\Position\GetPluginListDisplay\Output::class))
* )]
#[Tag(name: 'Position')]
* @IsGranted("ROLE_SHOP")
* @Security(name="ApiKeyAuth")
* @Security(name="Bearer")

Some files were not shown because too many files have changed in this diff Show More