66 lines
1.2 KiB
PHP
66 lines
1.2 KiB
PHP
<?php
|
|
|
|
namespace App\Entity;
|
|
|
|
use App\Repository\ActionsRepository;
|
|
use Doctrine\ORM\Mapping as ORM;
|
|
|
|
#[ORM\Entity(repositoryClass: ActionsRepository::class)]
|
|
class Actions
|
|
{
|
|
#[ORM\Id]
|
|
#[ORM\GeneratedValue]
|
|
#[ORM\Column]
|
|
private ?int $id = null;
|
|
|
|
#[ORM\OneToOne(cascade: ['persist', 'remove'])]
|
|
private ?user $users = null;
|
|
|
|
#[ORM\Column(length: 255)]
|
|
private ?string $action_type = null;
|
|
|
|
#[ORM\Column(options: ['default' => 'CURRENT_TIMESTAMP'])]
|
|
private ?\DateTimeImmutable $date = null;
|
|
|
|
public function getId(): ?int
|
|
{
|
|
return $this->id;
|
|
}
|
|
|
|
public function getUsers(): ?user
|
|
{
|
|
return $this->users;
|
|
}
|
|
|
|
public function setUsers(?user $users): static
|
|
{
|
|
$this->users = $users;
|
|
|
|
return $this;
|
|
}
|
|
|
|
public function getActionType(): ?string
|
|
{
|
|
return $this->action_type;
|
|
}
|
|
|
|
public function setActionType(string $action_type): static
|
|
{
|
|
$this->action_type = $action_type;
|
|
|
|
return $this;
|
|
}
|
|
|
|
public function getDate(): ?\DateTimeImmutable
|
|
{
|
|
return $this->date;
|
|
}
|
|
|
|
public function setDate(\DateTimeImmutable $date): static
|
|
{
|
|
$this->date = $date;
|
|
|
|
return $this;
|
|
}
|
|
}
|