349d2cf202
Logique métier d'écriture et de lecture du ticket de pesée (M5).
Processor (POST/PATCH) :
- résolution du site courant (CurrentSiteProvider) + attribution du numéro
{siteCode}-TP-{NNNN} à la création, immuables ensuite (RG-5.02 / RG-5.09) ;
- exclusivité de la contrepartie CLIENT/FOURNISSEUR/AUTRE — null-ification des
champs hors-branche (RG-5.03, garde-fou CHECK Postgres) ;
- normalisation immatriculation trim/UPPER + masque XX-000-XX hors « Tout
format », 422 inline sur le champ si invalide (RG-5.01 / RG-5.10) ;
- DSD autoritaire pour les pesées AUTO via DsdAllocator (verrou), MANUEL conservé
(RG-5.04) ;
- poids net = plein − vide recalculé (RG-5.05).
Provider (GET) : liste paginée (Paginator ORM, règle n°13), recherche ?search=,
tri ?order[displayDate], cloisonnement par site courant appliqué dans le provider
(le SiteScopedQueryExtension ne traverse pas un provider custom), fetch-join
client/supplier/site anti-N+1, 404 hors périmètre / soft-delete.
Ajouts : WeighingTicketNumberAllocator (compteur weighing_ticket_counter,
SELECT FOR UPDATE), WeighingTicketFieldNormalizer, InvalidImmatriculationException
+ alias DI.
make test vert (811), Architecture vert (CollectionsArePaginatedTest).
47 lines
2.0 KiB
YAML
47 lines
2.0 KiB
YAML
# yaml-language-server: $schema=../vendor/symfony/dependency-injection/Loader/schema/services.schema.json
|
|
|
|
parameters:
|
|
|
|
imports:
|
|
- { resource: version.yaml }
|
|
|
|
services:
|
|
# default configuration for services in *this* file
|
|
_defaults:
|
|
autowire: true # Automatically injects dependencies in your services.
|
|
autoconfigure: true # Automatically registers your services as commands, event subscribers, etc.
|
|
|
|
# makes classes in src/ available to be used as services
|
|
# this creates a service per class whose id is the fully-qualified class name
|
|
App\:
|
|
resource: '../src/'
|
|
|
|
App\Module\Core\Domain\Repository\PermissionRepositoryInterface:
|
|
alias: App\Module\Core\Infrastructure\Doctrine\DoctrinePermissionRepository
|
|
|
|
App\Module\Core\Domain\Repository\RoleRepositoryInterface:
|
|
alias: App\Module\Core\Infrastructure\Doctrine\DoctrineRoleRepository
|
|
|
|
App\Module\Core\Domain\Repository\UserRepositoryInterface:
|
|
alias: App\Module\Core\Infrastructure\Doctrine\DoctrineUserRepository
|
|
|
|
App\Module\Sites\Domain\Repository\SiteRepositoryInterface:
|
|
alias: App\Module\Sites\Infrastructure\Doctrine\DoctrineSiteRepository
|
|
|
|
App\Shared\Domain\Contract\SiteProviderInterface:
|
|
alias: App\Module\Sites\Infrastructure\Doctrine\DoctrineSiteRepository
|
|
|
|
App\Module\Sites\Application\Service\CurrentSiteProviderInterface:
|
|
alias: App\Module\Sites\Application\Service\CurrentSiteProvider
|
|
|
|
# M5 Logistique — pesee pont bascule (ERP-184)
|
|
App\Module\Logistique\Domain\Contract\WeighbridgeReaderInterface:
|
|
alias: App\Module\Logistique\Infrastructure\Weighbridge\RandomWeighbridgeReader
|
|
|
|
App\Module\Logistique\Application\Service\DsdAllocatorInterface:
|
|
alias: App\Module\Logistique\Infrastructure\Service\DsdAllocator
|
|
|
|
# M5 Logistique — Provider/Processor ticket de pesee (ERP-185)
|
|
App\Module\Logistique\Application\Service\WeighingTicketNumberAllocatorInterface:
|
|
alias: App\Module\Logistique\Infrastructure\Service\WeighingTicketNumberAllocator
|