search_api_saved_searches_i18n.controller.inc 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. /**
  3. * @file
  4. * Contains the SearchApiSavedSearchesSettingsI18nStringObjectWrapper class.
  5. */
  6. /**
  7. * Customized i18n string integration controller.
  8. */
  9. class SearchApiSavedSearchesSettingsI18nController extends EntityDefaultI18nStringController {
  10. /**
  11. * Overriddes EntityDefaultI18nStringController::hook_object_info() to include a custom object wrapper.
  12. */
  13. public function hook_object_info() {
  14. $info = parent::hook_object_info();
  15. $info['search_api_saved_searches_settings']['class'] = 'SearchApiSavedSearchesSettingsI18nStringObjectWrapper';
  16. return $info;
  17. }
  18. /**
  19. * Overrides EntityDefaultI18nStringController::translatableProperties() to define our custom ones.
  20. */
  21. protected function translatableProperties() {
  22. $properties = array();
  23. $properties['description'] = t('Description');
  24. $properties['mail.activate.title'] = t('Activation mail, subject');
  25. $properties['mail.activate.body'] = t('Activation mail, body');
  26. $properties['mail.notify.title'] = t('Notification mail, subject');
  27. $properties['mail.notify.body'] = t('Notification mail, body');
  28. $properties['mail.notify.results'] = t('Notification mail, results replacement');
  29. $properties['mail.notify.result'] = t('Notification mail, result item replacement');
  30. $properties['mail.notify.results_capped'] = t('Notification mail, "Not all results" message');
  31. return $properties;
  32. }
  33. }