mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-08 17:34:32 +02:00
Added possibility to define alternative names on data structures
This can be used to find elements, based on the data returned by info providers
This commit is contained in:
parent
edc54aaf91
commit
b74ab18a6d
11 changed files with 79 additions and 5 deletions
|
@ -265,6 +265,7 @@ final class DTOtoEntityConverter
|
|||
//If the entity was newly created, set the file filter
|
||||
if ($tmp->getId() === null) {
|
||||
$tmp->setFiletypeFilter('application/pdf');
|
||||
$tmp->setAlternativeNames(self::TYPE_DATASHEETS_NAME);
|
||||
}
|
||||
|
||||
return $tmp;
|
||||
|
@ -282,6 +283,7 @@ final class DTOtoEntityConverter
|
|||
//If the entity was newly created, set the file filter
|
||||
if ($tmp->getId() === null) {
|
||||
$tmp->setFiletypeFilter('image/*');
|
||||
$tmp->setAlternativeNames(self::TYPE_DATASHEETS_NAME);
|
||||
}
|
||||
|
||||
return $tmp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue