welcome back to dyb-tech

This commit is contained in:
Daniel Guzman
2024-05-18 02:28:01 +02:00
parent 9513cdba09
commit 9f30bc98c7
6149 changed files with 668407 additions and 0 deletions
+20
View File
@@ -0,0 +1,20 @@
<?php
namespace DMD\LaLigaApi\Service\Common;
use DMD\LaLigaApi\Dto\TeamDto;
use DMD\LaLigaApi\Entity\Team;
class TeamFactory
{
public static function create(TeamDto $teamDto): Team
{
$teamEntity = new Team();
if (!empty($teamDto->name))
{
$teamEntity->setName($teamDto->name);
}
$teamEntity->setActive(true);
return $teamEntity;
}
}