<% if @save_flag %> window.location.reload(); <% else %> // alert('添加文件失败:\n<%=@save_message[0]%>'); $('#ajax-modal').html('

添加文件失败

<%=@save_message.join(', ')%>'); var el = $('#ajax-modal').first(); var title = el.find('h3.title').text(); el.dialog({ width: '200px', modal: true, resizable: false, dialogClass: 'modal', title: title }); <% end %>