You are here

fz152_contact.module in FZ152 8

Main file for hooks and custom functions.

File

modules/contact/fz152_contact.module
View source
<?php

/**
 * @file
 * Main file for hooks and custom functions.
 */

/**
 * Implements hook_config_translation_info().
 */
function fz152_contact_config_translation_info(&$info) {
  $bundle_info = \Drupal::service('entity_type.bundle.info');
  $contact_bundles = $bundle_info
    ->getBundleInfo('contact_message');
  $names = [];
  foreach ($contact_bundles as $bundle_name => $bundle_info) {
    $names[] = "fz152_contact.settings.{$bundle_name}";
  }
  $info['fz152_contact.settings'] = [
    'title' => 'FZ152 — Contact',
    'base_route_name' => 'fz152.settings.contact',
    'names' => $names,
    'provider' => 'fz152_contact',
  ];
}