You are here

function workspace_update_8110 in Workspace 8

Add the doc_ids field.

File

./workspace.install, line 212
Install, update and uninstall functions for the workspace module.

Code

function workspace_update_8110() {
  $definition_update_manager = \Drupal::entityDefinitionUpdateManager();

  // Add the replication status field to the replication entity type.
  $field = BaseFieldDefinition::create('string_long')
    ->setLabel(t('Selected entity UUIDs for deployment'))
    ->setDescription(t('If this field contains at leas one entity UUID, then it will deploy only changes for that entity.'))
    ->setRequired(FALSE)
    ->setDefaultValue('')
    ->setInitialValue('')
    ->setSetting('case_sensitive', TRUE);
  $definition_update_manager
    ->installFieldStorageDefinition('doc_ids', 'replication', 'workspace', $field);
}