function globallink_entity_form_node_type_form_validate in GlobalLink Connect for Drupal 7.7
Same name and namespace in other branches
- 7.5 globallink_entity/globallink_entity.module \globallink_entity_form_node_type_form_validate()
- 7.6 globallink_entity/globallink_entity.module \globallink_entity_form_node_type_form_validate()
Validation to check if any active submission exists for this content type only if there is a change in multilingual options.
1 string reference to 'globallink_entity_form_node_type_form_validate'
- globallink_entity_form_node_type_form_alter in globallink_entity/
globallink_entity.module - Adds a validation handler to check for change in multilingual options.
File
- globallink_entity/
globallink_entity.module, line 21 - GlobalLink entity translation module.
Code
function globallink_entity_form_node_type_form_validate($form, &$form_state) {
module_load_include('inc', 'globallink', 'globallink');
$language_content_type = $form_state['values']['language_content_type'];
if ($language_content_type != 2 && globallink_pending_submission_exists_for_content_type($form_state['values']['old_type'])) {
form_set_error('language_content_type', t('Active submission exists for this content type in GlobalLink.'));
}
}