讨论区message样式

This commit is contained in:
huangjingquan 2013-11-25 15:07:34 +08:00
parent 24a12115b0
commit 19f183cb2b
3 changed files with 37 additions and 14 deletions

View File

@ -24,9 +24,9 @@
<!--display the board-->
<div class="borad-title"><%=h @board.name %></div>
<div class="borad-description"><%=h @board.description %></div>
<!-- <div class="borad-description"><%=h @board.description %></div> -->
<div class="borad-topic-count">共有 <%=link_to @topics.count %> 个贴子</div>
<div style="padding-top: 10px">
<% if @topics.any? %>
<!-- <table class="list messages">
<thead><tr>
@ -41,7 +41,7 @@
<table class="content-text-list">
<td colspan="2" valign="top" width="50" ><%= link_to image_tag(url_to_avatar(topic.author), :class => "avatar"), user_path(topic.author) %></td>
<td>
<table width="580px" border="0">
<table width="650px" border="0">
<tr>
<td valign="top" width="500px"><%= link_to h(topic.subject), board_message_path(@board, topic) %></td>
<td align="right" rowspan="3"><table class="borad-count"><tr><td align="center" class="borad-count-digit"><%=link_to (topic.replies_count), board_message_path(@board, topic) %></td></tr>
@ -51,8 +51,8 @@
<tr>
<td colspan="2" ><span class="font_description">标签</span></td>
</tr>
<tr><% if topic.last_reply %>
<td align="left" colspan="2" ><span class="font_lighter"><%= authoring topic.last_reply.created_on, topic.last_reply.author %><br /><% end %></span></td>
<tr>
<td align="left" colspan="2" ><span class="font_lighter"><%= authoring topic.created_on, topic.author %><br /></span></td>
</tr>
</table></td>
</tr>
@ -71,6 +71,7 @@
</td>
</tr> -->
<% end %>
</div>
<!-- </tbody>
</table> -->
<div class="pagination"><%= pagination_links_full @topic_pages, @topic_count %></div>

View File

@ -23,13 +23,11 @@
) if @message.destroyable_by?(User.current) %>
</div>
<h3><%= avatar(@topic.author, :size => "24") %><%=h @topic.subject %></h3>
<div class="borad-title"><%= avatar(@topic.author, :size => "24") %><%=h @topic.subject %></div>
<div class="message">
<p><span class="author"><%= authoring @topic.created_on, @topic.author %></span></p>
<div class="wiki">
<div class="borad-topic-count-message">
<%= textilizable(@topic, :content) %>
</div>
<%= authoring @topic.created_on, @topic.author %>
<%= link_to_attachments @topic, :author => false %>
</div>
<br />
@ -38,7 +36,7 @@
<h3 class="comments"><%= l(:label_reply_plural) %> (<%= @reply_count %>)</h3>
<% @replies.each do |message| %>
<div class="message reply" id="<%= "message-#{message.id}" %>">
<div class="contextual">
<div class="contextual-borad">
<%= link_to(
image_tag('comment.png'),
{:action => 'quote', :id => message},
@ -58,15 +56,25 @@
:title => l(:button_delete)
) if message.destroyable_by?(User.current) %>
</div>
<h4>
<table class="borad-text-list">
<tr><td rowspan="3" valign="top" width="60px"><%= link_to image_tag(url_to_avatar(message.author), :class => "avatar"), user_path(message.author) %></td>
<td class="comments"><div class="wiki"><%= textilizable message, :content, :attachments => message.attachments %></div>
<%= link_to_attachments message, :author => false %>
</div> </td></tr>
<tr><td><%= link_to h(message.subject), { :controller => 'messages', :action => 'show', :board_id => @board, :id => @topic, :r => message, :anchor => "message-#{message.id}" } %></td></tr>
<tr><td class="font_lighter"><%= authoring message.created_on, message.author %></td></tr>
</table>
<!-- <h4>
<%= avatar(message.author, :size => "24") %>
<%= link_to h(message.subject), { :controller => 'messages', :action => 'show', :board_id => @board, :id => @topic, :r => message, :anchor => "message-#{message.id}" } %>
-
<%= authoring message.created_on, message.author %>
</h4>
<div class="wiki"><%= textilizable message, :content, :attachments => message.attachments %></div>
<%= link_to_attachments message, :author => false %>
</div>
<%= link_to_attachments message, :author => false %> -->
</div>
<% end %>
<div class="pagination"><%= pagination_links_full @reply_pages, @reply_count, :per_page_links => false %></div>
<% end %>

View File

@ -11,6 +11,20 @@ h4 {border-bottom: 1px dotted #bbb;}
/*new by huang*/
/**/
/*new code reconstruction*/
div.sidebar-content{
padding-left: 8px;
padding-right: 8px;
}
div.sidebar-content div.info-course{
font-family: 微软雅黑;
font-size: 16px;
color: #4d4d4d;
word-wrap: break-word;
word-break: break-all;
}
/*end*/
.welcome-index{
width: 290px;
white-space: nowrap;