课程首页缓存
This commit is contained in:
parent
84a79ac8e2
commit
b2cdcf4bbe
|
@ -173,10 +173,8 @@
|
||||||
<%break if Time.new.strftime("%Y").to_i - year_now >= 2%>
|
<%break if Time.new.strftime("%Y").to_i - year_now >= 2%>
|
||||||
<% all_new_hot_course += find_all_new_hot_course(9-(all_new_hot_course.count + cur_school_course.count), @school_id, year_now, course_term)%>
|
<% all_new_hot_course += find_all_new_hot_course(9-(all_new_hot_course.count + cur_school_course.count), @school_id, year_now, course_term)%>
|
||||||
<% end%>
|
<% end%>
|
||||||
<% cache all_new_hot_course.max().created_at do %>
|
|
||||||
<%= render :partial => 'course_list', :locals => {:course_list => all_new_hot_course} %>
|
<%= render :partial => 'course_list', :locals => {:course_list => all_new_hot_course} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue