storedObject: add title field on StoredObject entity

This commit is contained in:
nobohan
2022-05-25 16:32:52 +02:00
parent 5948ac5b2a
commit dea554ced4
2 changed files with 54 additions and 0 deletions

View File

@@ -71,6 +71,12 @@ class StoredObject implements AsyncFileInterface, Document
*/
private array $keyInfos = [];
/**
* @ORM\Column(type="text", name="title")
* @Serializer\Groups({"read", "write"})
*/
private string $title = '';
/**
* @ORM\Column(type="text", name="type")
* @Serializer\Groups({"read", "write"})
@@ -127,6 +133,11 @@ class StoredObject implements AsyncFileInterface, Document
return $this->getFilename();
}
public function getTitle()
{
return $this->title;
}
public function getType()
{
return $this->type;
@@ -177,6 +188,13 @@ class StoredObject implements AsyncFileInterface, Document
return $this;
}
public function setTitle(?string $title)
{
$this->title = (string) $title;
return $this;
}
public function setType(?string $type)
{
$this->type = (string) $type;