Skip to content

Commit

Permalink
Add managed option values for tag_used_for option group for each EC…
Browse files Browse the repository at this point in the history
…K entity type
  • Loading branch information
jensschuppe committed Jun 27, 2022
1 parent fc63ad0 commit 87fc164
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions managed/OptionValue_tag_used_for.mgd.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<?php
// Auto-generate managed records for each entity type
$values = [];
foreach (CRM_Eck_BAO_EckEntityType::getEntityTypes() as $type) {
// Synchronize tag_used_for option values.
$values[] = [
'name' => 'tag_used_for:' . $type['name'],
'entity' => 'OptionValue',
'cleanup' => 'always',
'update' => 'always',
'params' => [
'version' => 4,
'values' => [
'option_group_id.name' => 'tag_used_for',
'label' => $type['label'],
'value' => $type['table_name'],
'name' => $type['entity_name'],
'is_reserved' => TRUE,
'is_active' => TRUE,
],
],
];
}
return $values;

0 comments on commit 87fc164

Please sign in to comment.