This commit is contained in:
nieguanghui 2013-12-10 19:45:38 +08:00
parent e5010d118b
commit 25baf61185
2 changed files with 27 additions and 2 deletions

View File

@ -104,6 +104,10 @@ module WelcomeHelper
# or
searchStudent(project).count
end
#To do
def find_new_forum_topics
end
private

View File

@ -126,19 +126,40 @@
</script>
<!-- <style>
.forum-topic li{
float: left;
}
</style> -->
<!-- info display block -->
<%= stylesheet_link_tag 'welcome' %>
<div class="body_resize">
<div class="left" style="float: left; height: 445px; width: 50%;">
<ul class="welcome-message-list" style="width: 90%; ">
<h3 style="color: rgb(21, 188, 207);margin-left: 8px;"><strong>论坛热帖</strong></h3>
<div class="forum-topic">
<ul>
<li>
<h3 style="color: rgb(21, 188, 207);margin-left: 8px;"><strong>论坛动态</strong></h3>
</li>
<!-- <li>
<h4>最新帖子</h4>
</li>
<li>
<h4>最热帖子</h4>
</li>
<li>
<h4>更多主题</h4>
</li> -->
</ul>
</div>
<div class="welcome-box-list">
<% find_hot_forum_topics.each do |topic|%>
<li class="message-brief-intro" style="min-height: 25px;">
<div style="display: inline-block; width: 100%;">
<span style="color:gray; display: inline-block; background: url('/images/list-icon.png') no-repeat scroll ;background-position: left center;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<%= link_to topic.subject.truncate(30, omission: '...'), topic.event_url, :class => "gray" , :style => "font-size: 10pt !important;"%>
<%= link_to topic.subject.truncate(30, omission: '...'), topic.event_url, :class => "gray" , :style => "font-size: 10pt !important;"%>
</span>
<br>
<span style="margin-left: 20px; color: rgb(172, 174, 177); white-space: nowrap; font-size 9pt !important;;"><%=l(:field_updated_on)%><%=time_tag_welcome(topic_last_time topic)%>前</span>