bigdir/app/views/homework_attach/add_jour_reply.js.erb

14 lines
544 B
Plaintext

<% if @save_succ %>
var pre_append = $('<%= j(
render :partial => "journal_reply_items",
:locals => {:reply => @jfm, :journal => @jfm.parent, :m_reply_id => @jfm}
) %>').hide();
$('#journal_reply_ul_<%=@jfm.m_parent_id%>').append(pre_append);
pre_append.fadeIn(600);
var textarea = $('#project_respond_form_<%=@jfm.m_reply_id.to_s%> textarea');
textarea.val('');
$('#project_respond_form_<%=@jfm.m_reply_id.to_s%>').hide();
setMaxLengthItem(pre_append.find('textarea')[0]);
<% else %>
alert("<%= l(:label_feedback_fail) %>");
<% end %>