public function ParagraphSet::setPublished in Paragraphs frontend ui 8
Sets the published status of a Paragraph set.
Parameters
bool $published: TRUE to set this Paragraph set to published, FALSE to for unpublished.
Return value
\Drupal\paragraphs_frontend_ui\Entity\ParagraphSetInterface The called Paragraph set entity.
Overrides ParagraphSetInterface::setPublished
File
- src/
Entity/ ParagraphSet.php, line 143
Class
- ParagraphSet
- Defines the Paragraph set entity.
Namespace
Drupal\paragraphs_frontend_ui\EntityCode
public function setPublished($published) {
$this
->set('status', $published ? TRUE : FALSE);
return $this;
}