|
| 1 | +<?php |
| 2 | +/** |
| 3 | + * Copyright since 2007 PrestaShop SA and Contributors |
| 4 | + * PrestaShop is an International Registered Trademark & Property of PrestaShop SA |
| 5 | + * |
| 6 | + * NOTICE OF LICENSE |
| 7 | + * |
| 8 | + * This source file is subject to the Academic Free License version 3.0 |
| 9 | + * that is bundled with this package in the file LICENSE.md. |
| 10 | + * It is also available through the world-wide-web at this URL: |
| 11 | + * https://opensource.org/licenses/AFL-3.0 |
| 12 | + * If you did not receive a copy of the license and are unable to |
| 13 | + * obtain it through the world-wide-web, please send an email |
| 14 | + * to license@prestashop.com so we can send you a copy immediately. |
| 15 | + * |
| 16 | + * @author PrestaShop SA and Contributors <contact@prestashop.com> |
| 17 | + * @copyright Since 2007 PrestaShop SA and Contributors |
| 18 | + * @license https://opensource.org/licenses/AFL-3.0 Academic Free License version 3.0 |
| 19 | + */ |
| 20 | + |
| 21 | +declare(strict_types=1); |
| 22 | + |
| 23 | +namespace PrestaShop\Module\APIResources\ApiPlatform\Resources\Shop; |
| 24 | + |
| 25 | +use ApiPlatform\Metadata\ApiResource; |
| 26 | +use PrestaShop\PrestaShop\Core\Domain\Shop\Query\GetLogosPaths; |
| 27 | +use PrestaShopBundle\ApiPlatform\Metadata\CQRSGet; |
| 28 | + |
| 29 | +#[ApiResource( |
| 30 | + operations: [ |
| 31 | + new CQRSGet( |
| 32 | + uriTemplate: '/shop/logos', |
| 33 | + openapiContext: ['summary' => 'Get shop logos', 'description' => 'Retrieves paths to header, email, invoice and favicon logos'], |
| 34 | + CQRSQuery: GetLogosPaths::class, |
| 35 | + scopes: [ |
| 36 | + 'shop_read', |
| 37 | + ], |
| 38 | + ), |
| 39 | + ], |
| 40 | +)] |
| 41 | +class ShopLogos |
| 42 | +{ |
| 43 | + public ?string $headerLogoPath = null; |
| 44 | + |
| 45 | + public ?string $mailLogoPath = null; |
| 46 | + |
| 47 | + public ?string $invoiceLogoPath = null; |
| 48 | + |
| 49 | + public ?string $faviconPath = null; |
| 50 | +} |
0 commit comments