mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-02 22:44:33 +02:00
Do not cache entities directly in NodesListBuilder but cache only the IDs instead
Otherwise the doctrine proxies break, and we get issues with loading the preview_images in structural Elements.
This commit is contained in:
parent
2e8cb35acc
commit
8ce5f4a796
9 changed files with 173 additions and 25 deletions
|
@ -26,6 +26,7 @@ use App\Entity\Base\AbstractNamedDBElement;
|
|||
use App\Entity\Base\MasterAttachmentTrait;
|
||||
use App\Entity\Contracts\HasAttachmentsInterface;
|
||||
use App\Entity\Contracts\HasMasterAttachmentInterface;
|
||||
use App\Repository\AttachmentContainingDBElementRepository;
|
||||
use Doctrine\Common\Collections\ArrayCollection;
|
||||
use Doctrine\Common\Collections\Collection;
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
@ -34,7 +35,7 @@ use Symfony\Component\Serializer\Annotation\Groups;
|
|||
/**
|
||||
* @template-covariant AT of Attachment
|
||||
*/
|
||||
#[ORM\MappedSuperclass]
|
||||
#[ORM\MappedSuperclass(repositoryClass: AttachmentContainingDBElementRepository::class)]
|
||||
abstract class AttachmentContainingDBElement extends AbstractNamedDBElement implements HasMasterAttachmentInterface, HasAttachmentsInterface
|
||||
{
|
||||
use MasterAttachmentTrait;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue