Correctly display the success message when transfer was successful

This commit is contained in:
gregoirenovel 2017-06-22 17:53:30 +02:00
parent 12f61b490a
commit ed51c77895

View file

@ -1,14 +1,12 @@
<%- if response.status == 404 %>
transfer_errors_message(true);
<%- else %>
<% flash.each do |type, message| %>
$("#flash_message").html("<div class=\"alert alert-success\"> <%= message.html_safe %></div>")
<% end %>
$("#main-container").prepend("<div class='row'><div id='flash_message'></div></div>");
$("#flash_message").prepend("<div class=\"alert alert-success\"> <%= flash.notice.html_safe %></div>");
<% flash.clear %>
transfer_errors_message(false);
$("#email_admin").val('');
$("button#cancel").click();
<%- end %>