2014-06-18 16:29:29 +08:00
|
|
|
<% if @project %>
|
|
|
|
<%= render :partial => 'project_show', locals: {project: @project} %>
|
|
|
|
<% elsif @course %>
|
|
|
|
<%= render :partial => 'course_show', locals: {course: @course} %>
|
2013-08-01 10:33:49 +08:00
|
|
|
<% end %>
|
2015-06-26 09:16:37 +08:00
|
|
|
<script type="text/javascript">
|
|
|
|
$(function(){
|
|
|
|
$("#add_comment_form").submit(function(){
|
|
|
|
if($("#comment").val() == ''){
|
|
|
|
alert('请输入评论内容');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
$(this)[0].submit();
|
|
|
|
//return true;
|
|
|
|
});
|
|
|
|
})
|
|
|
|
</script>
|