Browse Source

post MR fixes

Olivier Massot 9 tháng trước cách đây
mục cha
commit
b7f5ac069c

+ 0 - 1
src/ApiResources/Dolibarr/DolibarrDocDownload.php

@@ -19,7 +19,6 @@ use Symfony\Component\Validator\Constraints as Assert;
         new Get(
             uriTemplate: '/dolibarr/download/{dolibarrDocType}/{ref}',
             requirements: [
-                'dolibarrDocType' => DolibarrDocTypeEnum::VALIDATION_REGEX,
                 'ref' => '[\w-]+',
             ],
             security: '(is_granted("ROLE_ADMIN_CORE") or 

+ 0 - 2
src/Enum/Dolibarr/DolibarrDocTypeEnum.php

@@ -16,6 +16,4 @@ enum DolibarrDocTypeEnum: string
     case ORDER = 'order'; // Bon de commande
     case INVOICE = 'invoice'; // Facture
     case CONTRACT = 'contract'; // Contrat
-
-    public const VALIDATION_REGEX = '^'.self::ORDER->value.'|'.self::INVOICE->value.'|'.self::CONTRACT->value.'$';
 }