function translation_entity_set_config

Stores the given value for the specified setting.

Parameters

string $entity_type: The type of the entity the setting refer to.

string $bundle: The bundle of the entity the setting refer to.

string $setting: The name of the setting.

$value: The value to be stored for the given setting.

2 calls to translation_entity_set_config()
EntityTranslationUITest::enableTranslation in drupal/core/modules/translation_entity/lib/Drupal/translation_entity/Tests/EntityTranslationUITest.php
Enables translation for the current entity type and bundle.
translation_entity_language_configuration_element_submit in drupal/core/modules/translation_entity/translation_entity.module
Form submission handler for element added with translation_entity_language_configuration_element_process().

File

drupal/core/modules/translation_entity/translation_entity.module, line 310
Allows entities to be translated into different languages.

Code

function translation_entity_set_config($entity_type, $bundle, $setting, $value) {
  $key = translation_entity_get_config_key($entity_type, $bundle, $setting);
  return config('translation_entity.settings')
    ->set($key, $value)
    ->save();
}