I rightly do not know what this all is

This commit is contained in:
Michel 2024-10-30 19:40:26 +01:00
parent af6b2b752e
commit 287c1f67c5
78 changed files with 3484 additions and 3365 deletions

View file

@ -1,62 +1,62 @@
<?php
declare(strict_types=1);
namespace GamesShop\Entities;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use GamesShop\Entities\Account\User;
#[ORM\Entity]
#[ORM\Table(name: 'games_lists')]
final class GamesList
{
#[ORM\Id]
#[ORM\Column(type: 'integer', options: ['unsigned' => true])]
#[ORM\GeneratedValue]
private int|null $id;
#[ORM\ManyToOne]
private User $owner;
#[ORM\Column(nullable: true)]
private string|null $name;
#[ORM\JoinTable(name: 'games_list_claimer')]
#[ORM\JoinColumn(name: 'id', referencedColumnName: 'id')]
#[ORM\ManyToMany(targetEntity: User::class)]
private Collection $claimer;
/**
* @param User $owner
* @param string|null $name
*/
public function __construct(User $owner, ?string $name)
{
$this->owner = $owner;
$this->name = $name;
}
public function getId(): ?int
{
return $this->id;
}
public function getOwner(): User
{
return $this->owner;
}
public function getName(): ?string
{
return $this->name;
}
public function getClaimer(): array
{
return $this->claimer;
}
<?php
declare(strict_types=1);
namespace GamesShop\Entities;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use GamesShop\Entities\Account\User;
#[ORM\Entity]
#[ORM\Table(name: 'games_lists')]
final class GamesList
{
#[ORM\Id]
#[ORM\Column(type: 'integer', options: ['unsigned' => true])]
#[ORM\GeneratedValue]
private int|null $id;
#[ORM\ManyToOne]
private User $owner;
#[ORM\Column(nullable: true)]
private string|null $name;
#[ORM\JoinTable(name: 'games_list_claimer')]
#[ORM\JoinColumn(name: 'id', referencedColumnName: 'id')]
#[ORM\ManyToMany(targetEntity: User::class)]
private Collection $claimer;
/**
* @param User $owner
* @param string|null $name
*/
public function __construct(User $owner, ?string $name)
{
$this->owner = $owner;
$this->name = $name;
}
public function getId(): ?int
{
return $this->id;
}
public function getOwner(): User
{
return $this->owner;
}
public function getName(): ?string
{
return $this->name;
}
public function getClaimer(): array
{
return $this->claimer;
}
}