function photos_access_node_builder in Album Photos 6.0.x
Same name and namespace in other branches
- 8.5 photos_access/photos_access.module \photos_access_node_builder()
- 8.4 photos_access/photos_access.module \photos_access_node_builder()
Entity form builder to add the photos_access information to the node.
@todo Remove this in favor of an entity field.
1 string reference to 'photos_access_node_builder'
- photos_access_form_node_form_alter in photos_access/
photos_access.module - Implements hook_form_BASE_FORM_ID_alter() for form_node.
File
- photos_access/
photos_access.module, line 398 - Implementation of photos_access.module.
Code
function photos_access_node_builder($entity_type, NodeInterface $entity, &$form, FormStateInterface $form_state) {
if (!$form_state
->isValueEmpty('photos_privacy')) {
$entity->photos_privacy = $form_state
->getValue('photos_privacy');
}
}