Skip to content

Commit

Permalink
Return country code instead of name
Browse files Browse the repository at this point in the history
  • Loading branch information
vvoleman committed May 5, 2024
1 parent 1e6e767 commit 0928b67
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Entity/MedicalProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ public function serialize(): array
'registrationHolder' => $this->registrationHolder,
'recentlyDelivered' => $this->recentlyDelivered,
'expirationHours' => $this->expirationHours,
'country' => $this->countryHolder?->getName(),
'country' => $this->countryHolder?->getEdqmCode(),
'substances' => $substances,
];
}
Expand Down
7 changes: 7 additions & 0 deletions src/Service/SUKL/Syncers/MedicalProductSyncer.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,20 @@

use App\Entity\MedicalProduct;
use App\Service\AbstractSyncer;
use Doctrine\ORM\EntityManagerInterface;
use Doctrine\ORM\EntityRepository;
use Psr\Log\LoggerInterface;

class MedicalProductSyncer extends AbstractSyncer
{

private const FILENAME = 'dlp_lecivepripravky.csv';

public function __construct(EntityManagerInterface $entityManager, LoggerInterface $logger, string $csvPath, string $encoding = 'UTF-8')
{
parent::__construct($entityManager, $logger, $csvPath, $encoding);
}

public static function getDependencies(): array
{
return [
Expand Down

0 comments on commit 0928b67

Please sign in to comment.