Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Settings for media alias display for documents type #557

Open
wants to merge 6 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@
"codemirror/codemirror": "5.65.12",
"jquery/inputmask": "5.0.8",
"jquery/intl-tel-input": "17.0.19",
"progress-tracker/progress-tracker": "2.0.7"
"progress-tracker/progress-tracker": "2.0.7",
"drupal/media_alias_display": "^2.1"
},
"repositories": {
"drupal": {
Expand Down
4 changes: 4 additions & 0 deletions config/install/media_alias_display.settings.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
_core:
sharmasahil marked this conversation as resolved.
Show resolved Hide resolved
default_config_hash: WYvSMTu0VCW_FhkuJjHuUhmJ9nerYL0JtZrvGJajNig
kill_switch: false
media_bundles: { }
16 changes: 16 additions & 0 deletions modules/tide_media/tide_media.install
Original file line number Diff line number Diff line change
Expand Up @@ -81,3 +81,19 @@ function tide_media_update_10005() {
$config->set('track_enabled_target_entity_types', $result);
$config->save();
}

/**
* Adds media_alias_display settings for document type.
*/
function tide_media_update_10006() {
if (\Drupal::moduleHandler()->moduleExists('media_alias_display') === FALSE) {
\Drupal::service('module_installer')->install(['media_alias_display']);
}

$media_config = \Drupal::service('config.factory')->getEditable('media_alias_display.settings');
if ($media_config ) {
$media_config->set('media_bundles', ['document' => 'document']);
$media_config->save();
}
}

Loading