mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-26 19:58:53 +02:00
parent
ccdac1a94b
commit
a3c626d0ab
8 changed files with 92 additions and 7 deletions
|
@ -89,7 +89,15 @@ abstract class AbstractNamedDBElement extends AbstractDBElement implements Named
|
|||
public function setName(string $new_name): self
|
||||
{
|
||||
$this->name = $new_name;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function __clone()
|
||||
{
|
||||
if ($this->id) {
|
||||
//We create a new object, so give it a new creation date
|
||||
$this->addedDate = null;
|
||||
}
|
||||
parent::__clone(); // TODO: Change the autogenerated stub
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue