Sha256: a70be1adec7d74a2025a6a9d6f3fcce020809653eb6ba5fba10537261fcf3ed3
Contents?: true
Size: 1.08 KB
Versions: 27
Compression:
Stored size: 1.08 KB
Contents
(function() { var $el = $('#element_<%= @element.id %>'); $('.content_editor', $el).removeClass('validation_failed'); <%- if @element_validated -%> $('.element_head', $el).replaceWith('<%= j render("element_head", element: @element) %>'); Alchemy.ElementEditors.reinit($el); $("#element_<%= @element.id %>_errors").hide(); Alchemy.setElementSaved($el); Alchemy.growl('<%= _t(:element_saved) %>'); Alchemy.PreviewWindow.refresh(function() { Alchemy.ElementEditors.selectElementInPreview(<%= @element.id %>); }); <%= update_essence_select_elements(@page, @element) -%> <%- else -%> Alchemy.growl('<%= j @notice %>', 'warn'); $('#element_<%= @element.id %>_errors').html('<%= j @error_message %><ul><li><%== j @element.essence_error_messages.join("</li><li>") %></li></ul>'); $("#element_<%= @element.id %>_errors").show(); $('<%= @element.contents_with_errors.map { |content| "#" + content.dom_id }.join(", ") %>').addClass('validation_failed'); Alchemy.ElementEditors.scrollToElement('#element_<%= @element.id %>'); Alchemy.Buttons.enable($el); <%- end -%> })();
Version data entries
27 entries across 27 versions & 2 rubygems