From 3b01378ea5e2b2049bcf681eef25008acbb8d3a1 Mon Sep 17 00:00:00 2001 From: Dries Date: Tue, 22 Nov 2011 21:03:58 -0500 Subject: - Patch #1206992 by oriol_e9g: fixed Field UI error message and incorrect type level. --- modules/field_ui/field_ui.admin.inc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'modules/field_ui') diff --git a/modules/field_ui/field_ui.admin.inc b/modules/field_ui/field_ui.admin.inc index 693e8153d..fa19afc0a 100644 --- a/modules/field_ui/field_ui.admin.inc +++ b/modules/field_ui/field_ui.admin.inc @@ -799,7 +799,7 @@ function field_ui_field_overview_form_submit($form, &$form_state) { $form_state['fields_added']['_add_new_field'] = $field['field_name']; } catch (Exception $e) { - drupal_set_message(t('There was a problem creating field %label: @message.', array('%label' => $instance['label'], '@message' => $e->getMessage())), 'error'); + drupal_set_message(t('There was a problem creating field %label: !message', array('%label' => $instance['label'], '!message' => $e->getMessage())), 'error'); } } @@ -808,7 +808,7 @@ function field_ui_field_overview_form_submit($form, &$form_state) { $values = $form_values['_add_existing_field']; $field = field_info_field($values['field_name']); if (!empty($field['locked'])) { - drupal_set_message(t('The field %label cannot be added because it is locked.', array('%label' => $values['label']))); + drupal_set_message(t('The field %label cannot be added because it is locked.', array('%label' => $values['label'])), 'error'); } else { $instance = array( @@ -1670,7 +1670,7 @@ function field_ui_widget_type_form_submit($form, &$form_state) { drupal_set_message(t('Changed the widget for field %label.', array('%label' => $instance['label']))); } catch (Exception $e) { - drupal_set_message(t('There was a problem changing the widget for field %label.', array('%label' => $instance['label']))); + drupal_set_message(t('There was a problem changing the widget for field %label.', array('%label' => $instance['label'])), 'error'); } $form_state['redirect'] = field_ui_next_destination($entity_type, $bundle); @@ -1727,7 +1727,7 @@ function field_ui_field_delete_form_submit($form, &$form_state) { drupal_set_message(t('The field %field has been deleted from the %type content type.', array('%field' => $instance['label'], '%type' => $bundle_label))); } else { - drupal_set_message(t('There was a problem removing the %field from the %type content type.', array('%field' => $instance['label'], '%type' => $bundle_label))); + drupal_set_message(t('There was a problem removing the %field from the %type content type.', array('%field' => $instance['label'], '%type' => $bundle_label)), 'error'); } $admin_path = _field_ui_bundle_admin_path($entity_type, $bundle); -- cgit v1.2.3