<% if @easy_translation.errors.empty? %>
  $("#add_translation :selected").remove();
  $("#easy_translation_used_translation_container").find('.form_translated_field').append("<%=j render(:partial => 'form_translated_field', :locals => {:t => @easy_translation}) %>")
  $("#<%= dom_id(@easy_translation) %> input").focus();
  if ($("#add_translation option").length <= 1) {
    $("#easy_translation_add_translation_select").hide();
  }
<% else %>
  showFlashMessage("error", "<%= j @easy_translation.errors.full_messages.join('<br>').html_safe %>");
<% end %>
