added section name for meta-fields positioning (#5747)

This commit is contained in:
Kevin Papst
2025-12-26 12:54:15 +01:00
committed by GitHub
parent 26361da873
commit 5a0c783a76
10 changed files with 101 additions and 52 deletions

View File

@@ -67,6 +67,7 @@ trait MetaTableTypeTrait
*/
private mixed $data = null;
private bool $updated = false;
private ?string $section = null;
public function getName(): ?string
{
@@ -193,13 +194,11 @@ trait MetaTableTypeTrait
public function merge(MetaTableTypeInterface $meta): MetaTableTypeInterface
{
$this
->setConstraints($meta->getConstraints())
->setIsRequired($meta->isRequired())
->setIsVisible($meta->isVisible())
->setOptions($meta->getOptions())
->setOrder($meta->getOrder())
;
$this->setConstraints($meta->getConstraints());
$this->setIsRequired($meta->isRequired());
$this->setIsVisible($meta->isVisible());
$this->setOptions($meta->getOptions());
$this->setOrder($meta->getOrder());
if ($meta->getLabel() !== null) {
$this->setLabel($meta->getLabel());
@@ -209,6 +208,10 @@ trait MetaTableTypeTrait
$this->setType($meta->getType());
}
if ($meta->getSection() !== null) {
$this->setSection($meta->getSection());
}
return $this;
}
@@ -266,6 +269,16 @@ trait MetaTableTypeTrait
}
}
public function setSection(?string $section): void
{
$this->section = $section;
}
public function getSection(): ?string
{
return $this->section;
}
/**
* Whether this field is defined by a plugin or just a value stored in the database.
*/