NodeMakePublic.php in Private content 8.2
Namespace
Drupal\private_content\Plugin\ActionFile
src/Plugin/Action/NodeMakePublic.phpView source
<?php
namespace Drupal\private_content\Plugin\Action;
use Drupal\Core\Field\FieldUpdateActionBase;
/**
* Make a post public.
*
* @Action(
* id = "private_content_make_public",
* label = @Translation("Make selected content public"),
* type = "node"
* )
*/
class NodeMakePublic extends FieldUpdateActionBase {
/**
* {@inheritdoc}
*/
protected function getFieldsToUpdate() {
return [
'private' => 0,
];
}
}
Classes
Name | Description |
---|---|
NodeMakePublic | Make a post public. |