ask module: add rescue ackknowledgement
This commit is contained in:
parent
dcc5fc39a7
commit
841fa10c55
|
@ -1,5 +1,5 @@
|
||||||
<% if @ask_question.errors.empty? %>
|
<% if @ask_question.errors.empty? %>
|
||||||
$('#acknowledgement').html('<p><%= t('ask.save_success') %>!</p><p><%= @ask_acknowledgement.content %></p>');
|
$('#acknowledgement').html('<p><%= t('ask.save_success') %>!</p><p><%= @ask_acknowledgement.content rescue '' %></p>');
|
||||||
$('html,body').scrollTop(0);
|
$('html,body').scrollTop(0);
|
||||||
<% else %>
|
<% else %>
|
||||||
alert('<%= @ask_question.errors.full_messages.join('\n') %>');
|
alert('<%= @ask_question.errors.full_messages.join('\n') %>');
|
||||||
|
|
Loading…
Reference in New Issue