mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2025-09-13 13:57:10 +02:00
Optimized ORM-Structure
This commit is contained in:
25
application/src/Entity/Attribut/UsernameAttribut.php
Normal file
25
application/src/Entity/Attribut/UsernameAttribut.php
Normal file
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
namespace App\Entity\Attribut;
|
||||
|
||||
/**
|
||||
* This trait doesn't need an own interface because it's covered by symfony
|
||||
* @author kevinfrantz
|
||||
*
|
||||
*/
|
||||
trait UsernameAttribut{
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string", length=25, unique=true)
|
||||
*/
|
||||
protected $username;
|
||||
|
||||
public function getUsername():string
|
||||
{
|
||||
return $this->username;
|
||||
}
|
||||
|
||||
public function setUsernames(string $username):void{
|
||||
$this->username = $username;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user