createAction: is it possible to set newly created records (frontend) to "hidden" by default?
I want the Backend Admin to check them first and make them public afterwards.
createAction: is it possible to set newly created records (frontend) to "hidden" by default?
I want the Backend Admin to check them first and make them public afterwards.
In your model class add 'hidden' property with getter and setter like this:
/**
* hidden
*
* @var \integer
*/
protected $hidden;
/**
* Returns the hidden
*
* @return \integer $hidden
*/
public function getHidden() {
return $this->hidden;
}
/**
* Sets the hidden
*
* @param \integer $hidden
* @return void
*/
public function setHidden($hidden) {
$this->hidden = $hidden;
}
Then you can call it in your createAction method in your controller:
$model->setHidden(TRUE);
Add the below TSConfig code:
TCAdefaults {
tt_content.hidden = 1
}