From 0fa852ee4e9c3060ba7fc0daf4b08a44ea151f7f Mon Sep 17 00:00:00 2001 From: polo Date: Thu, 2 Jul 2026 00:01:31 +0200 Subject: =?UTF-8?q?entit=C3=A9=20Presentation,=20MAJ=20filtre=20ViewContro?= =?UTF-8?q?ller::SPECIAL=5FPAGES,=20table=20node=5Fdata=20non=20all=C3=A9g?= =?UTF-8?q?=C3=A9e=20pour=20l'instant?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/model/entities/NodeData.php | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) (limited to 'src/model/entities/NodeData.php') diff --git a/src/model/entities/NodeData.php b/src/model/entities/NodeData.php index c55f6a1..f6d6b01 100644 --- a/src/model/entities/NodeData.php +++ b/src/model/entities/NodeData.php @@ -24,7 +24,7 @@ class NodeData // inverseBy fait le lien avec $node_data dans Node (qui a "mappedBy") #[ORM\OneToOne(targetEntity: Node::class, inversedBy: "node_data")] #[ORM\JoinColumn(name: "node_id", referencedColumnName: "id_node", onDelete: "CASCADE")] - private Node $node; + private ?Node $node; #[ORM\Column(type: "json")] private array $data; @@ -44,18 +44,12 @@ class NodeData #[ORM\OneToMany(mappedBy: 'node_data', targetEntity: AssetEmployment::class, cascade: ['persist', 'remove'])] private Collection $asset_employment; - private int $nb_pages = 1; private array $emails = []; // => noeud "show_emails" - public function __construct(array $data, Node $node, Collection $asset_employment = new ArrayCollection, ?string $presentation = null, ?bool $chrono_order = null) - { + public function __construct(array $data, Node $node, Collection $asset_employment = new ArrayCollection){ $this->data = $data; $this->node = $node; $this->asset_employment = $asset_employment; - if(!empty($presentation) && $presentation === 'grid'){ - $this->grid_cols_min_width = 250; - } - $this->chrono_order = $chrono_order ?? null; } public function getId(): int @@ -82,7 +76,7 @@ class NodeData } // spécifique aux blocs contenant des articles - public function getPresentation(): ?string + /*public function getPresentation(): ?string { return $this->presentation; } @@ -117,6 +111,7 @@ class NodeData { $this->pagination_limit = $pagination_limit; } + private int $nb_pages = 1; public function getNumberOfPages(): int { return $this->nb_pages; @@ -124,13 +119,12 @@ class NodeData public function setNumberOfPages(int $nb_pages): void { $this->nb_pages = $nb_pages; - } + }*/ - /*public function setNode(Node $node): void + public function setNode(?Node $node): void { $this->node = $node; - }*/ - + } public function getNodeDataAssets(): Collection { -- cgit v1.2.3