lib/rails/generators/humdrum/resource/templates/views/bootstrap3/resource/update.js.erb in humdrum-rails-0.0.9 vs lib/rails/generators/humdrum/resource/templates/views/bootstrap3/resource/update.js.erb in humdrum-rails-0.1.1

- old
+ new

@@ -9,13 +9,13 @@ // Close Modal closeModal(); <%% else %> - // Reload the form partial to display errors - $('#div_<%= instance_name %>_details').html("<%%= escape_javascript(render(:partial=>"edit")) %>"); - - // Validate the form + // Show the new form in the pop up form. + heading = "Edit <%= model_class.titleize %>"; + bodyContent = "<%%= escape_javascript(render(:partial=>"form")) %>"; + showModal(heading, bodyContent); validate<%= model_class %>Form(); // Populate Server Side Errors errorMessages = <%%= @<%= instance_name %>.errors.full_messages.to_json.html_safe %>; populateServerSideErrors('<%= instance_name %>', errorMessages);