Closed bezin closed 3 years ago
Can't we just do $this->parent
? And wouldn't it be helpful to pass that to all of the templates?
So underneath where we set $this->tableless = true;
, maybe? I cannot really test it right now so I'm asking all these dumb questions :D
Yep, of course that was possible – however not with $this->parent
, as this is already a function in the TemplateInheritance trait. So I went with parentModel
, which I like better anyways, as it is more precise.
Took me way longer than I would like to admit to spot the early return, but now it is added to all templates 👍
This allows for extending the content or module model with e.g. another text field to accompany the form. You have access to the whole content/module model in the form templates.