You are here

public function TMGMTEntitySourceUIController::overviewFormValidate in Translation Management Tool 7

Overrides TMGMTDefaultSourceUIController::overviewFormValidate

File

sources/entity/ui/tmgmt_entity_ui.ui.inc, line 111

Class

TMGMTEntitySourceUIController
Generic entity ui controller class for source plugin.

Code

public function overviewFormValidate($form, &$form_state, $type) {
  if (!empty($form_state['values']['search']['target_language']) && $form_state['values']['search']['language'] == $form_state['values']['search']['target_language']) {
    form_set_error('search[target_language]', t('The source and target languages must not be the same.'));
  }
}