feat : init project Coltura (CRM/ERP)
Symfony 8 + API Platform 4 + Nuxt 4 monorepo. Backend: User entity, JWT auth, fixtures. Frontend: login, dashboard, auth middleware, i18n, @malio/layer-ui. Docker: dev (ports 8083/3003/5436) + prod multi-stage. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
25
src/State/AppVersionProvider.php
Normal file
25
src/State/AppVersionProvider.php
Normal file
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace App\State;
|
||||
|
||||
use ApiPlatform\Metadata\Operation;
|
||||
use ApiPlatform\State\ProviderInterface;
|
||||
use Symfony\Component\DependencyInjection\Attribute\Autowire;
|
||||
|
||||
/**
|
||||
* @implements ProviderInterface<object>
|
||||
*/
|
||||
class AppVersionProvider implements ProviderInterface
|
||||
{
|
||||
public function __construct(
|
||||
#[Autowire(param: 'app.version')]
|
||||
private readonly string $appVersion,
|
||||
) {}
|
||||
|
||||
public function provide(Operation $operation, array $uriVariables = [], array $context = []): object
|
||||
{
|
||||
return new \App\ApiResource\AppVersion($this->appVersion);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user