修改了谈论区框架、列表等
This commit is contained in:
parent
19f183cb2b
commit
dc00216603
|
@ -41,19 +41,15 @@
|
|||
<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="650px" border="0">
|
||||
<table width="640px" 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>
|
||||
<tr><td align="center">回答</td></tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" ><span class="font_description">标签</span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="left" colspan="2" ><span class="font_lighter"><%= authoring topic.created_on, topic.author %><br /></span></td>
|
||||
</tr>
|
||||
<tr><td colspan="2" ><span class="font_description">标签</span></td></tr>
|
||||
<tr><td align="left" colspan="2" ><span class="font_lighter"><%= authoring topic.created_on, topic.author %><br /></span></td></tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<tr>
|
||||
<td colspan="2" valign="top" width="50" ><%= link_to image_tag(url_to_avatar(forum.creator), :class => "avatar"), user_path(forum.creator) %></td>
|
||||
<td>
|
||||
<table width="650px" border="0">
|
||||
<table width="880px" border="0">
|
||||
<tr>
|
||||
<td valign="top" width="500px"><%= link_to h(forum.name), forum_path(forum) %></td>
|
||||
<td align="right" rowspan="3">
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<!-- added by fq -->
|
||||
<!--display the board-->
|
||||
<div class="borad-title"><%=h @forum.name %></div>
|
||||
<div class="borad-topic-count">共有 <%=link_to memos.count %> 个贴子</div>
|
||||
<div style="padding-top: 10px">
|
||||
<% if memos.any? %>
|
||||
|
|
|
@ -8,9 +8,9 @@
|
|||
<p>
|
||||
<%= %>
|
||||
</p>
|
||||
|
||||
<%= link_to 'Edit', edit_forum_path(@forum) %> |
|
||||
<%= link_to 'Back', forums_path %>
|
||||
<%= link_to 'new_topic', new_forum_memo_path(@forum) %>
|
||||
|
||||
<!--modified by huang-->
|
||||
<%= link_to '新建', new_forum_memo_path(@forum), :class => 'icon icon-add' %>
|
||||
<% if User.current.admin?||User.current.login==@forum.creator.login %> |
|
||||
<%= link_to '编辑', edit_forum_path(@forum), :class => 'icon icon-edit' %>
|
||||
<% end %>
|
||||
<%= render :partial => 'forums/show_topics', :locals => {:memos => @memos} %>
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
<!--added by huang-->
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
|
@ -14,17 +15,14 @@
|
|||
<%= call_hook :view_layouts_base_html_head %>
|
||||
<!-- page specific tags -->
|
||||
<%= yield :header_tags -%>
|
||||
</head>
|
||||
<!--add by huang-->
|
||||
</head>
|
||||
<body class="<%= h body_css_classes %>">
|
||||
<div id="wrapper">
|
||||
<div id="wrapper2">
|
||||
<div id="wrapper3">
|
||||
<%=render :partial => 'layouts/base_header'%>
|
||||
<div id="main">
|
||||
|
||||
<!-- added by bai -->
|
||||
<div class="top-content">
|
||||
<div class="top-content">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="info_font" style="width: 240px; color: #15bccf"">软件项目托管社区</td>
|
||||
|
@ -41,111 +39,33 @@
|
|||
</tr>
|
||||
<tr>
|
||||
<td style="padding-left: 8px"><a><%= link_to "forge.trustie.net/projects", :controller => 'projects', :action => 'index', :project_type => 0 %></a></td>
|
||||
<td><p class="top-content-list"><%=link_to l(:label_home),home_path %> > <%=link_to '讨论区', :controller => 'forums', :action => 'index' %> > <%=link_to @forum.name, forum_path(@forum) %></p></td>
|
||||
<td><p
|
||||
class="top-content-list"><%=link_to l(:label_home),home_path %> > <%=link_to '讨论区', :controller => 'forums', :action => 'index' %> > <%=link_to @forum.name, forum_path(@forum) %></p></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<!-- end -->
|
||||
<!--project page-->
|
||||
</div>
|
||||
<div id="sidebar">
|
||||
<div class="spaceleft">
|
||||
|
||||
<!--informations-->
|
||||
<div class="inf_user_image">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="info-course">
|
||||
<%= @forum.name %>
|
||||
</div>
|
||||
<div>
|
||||
<% unless User.current.member_of? @forum %>
|
||||
<%= watcher_link(@fourm, User.current) %>
|
||||
<% end %>
|
||||
</div></td>
|
||||
</tr>
|
||||
</table>
|
||||
<!--informations-->
|
||||
<div class="sidebar-forums">
|
||||
<div class="forums-line">
|
||||
<div class="forums-title"><%= @forum.name %></div>
|
||||
<div class="forums-description"><%= textilizable @forum.description %></div>
|
||||
</div>
|
||||
<!--informations-->
|
||||
<div class="formus-first-title" >创建人信息</div>
|
||||
<div class="forums-info">
|
||||
<div style="padding-top: 20px" >
|
||||
<span class="forums-avatar-left"><%= image_tag(url_to_avatar(@forum.creator), :class => 'avatar2') %></span>
|
||||
<span class="forums-avatar-right"><%=link_to @forum.creator.show_name, user_path(@forum.creator) %>
|
||||
<div>
|
||||
<%= link_to l(:label_user_watcher)+"("+User.watched_by(@forum.creator.id).count.to_s+")" ,:controller=>"users", :action=>"user_watchlist", :id => @forum.creator.id %>
|
||||
<%= link_to l(:label_x_user_fans, :count => User.current.watcher_users(User.current.id).count)+"("+@forum.creator.watcher_users(@forum.creator.id).count.to_s+")", :controller=>"users", :action=>"user_fanslist", :id => @forum.creator.id %></div></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--parameter -->
|
||||
<div class="user_fans">
|
||||
|
||||
<table width="240" border="0">
|
||||
<tr align="center" width="80px">
|
||||
|
||||
<td class="font_index"><%=link_to 1, forum_path(@forum) %></td>
|
||||
<td class="font_index"><%=link_to 2, forum_path(@forum) %></td>
|
||||
<td class="font_index"><%=link_to 3, forum_path(@forum) %></td>
|
||||
|
||||
<tr class="font_aram">
|
||||
<td align="center" width="70px"> <%= l(:label_member) %></td>
|
||||
<td align="center" width="100px"><%= l(:label_user_watchered) %></td>
|
||||
<td align="center" width="70px"> <%= l(:label_project_issues) %></td>
|
||||
<!-- <td align="center" width="58px"><%= l(:label_attachment) %></td> -->
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<div class="user_underline"></div>
|
||||
</div>
|
||||
|
||||
<!--informations-->
|
||||
<div class="inf_user">
|
||||
|
||||
<div class="font_title_left">
|
||||
创建人信息
|
||||
</div>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td><%= image_tag(url_to_avatar(@forum.creator), :class => 'avatar2') %></td>
|
||||
<td>
|
||||
<div class="info-course">
|
||||
<%= @forum.name %>
|
||||
</div>
|
||||
<div>
|
||||
<!-- 此处原来是关注 -->
|
||||
</div></td>
|
||||
</tr>
|
||||
</table><div class="user_underline"></div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<!--description-->
|
||||
<div class="inf_user_context">
|
||||
<div class="font_title_left">
|
||||
<%= l(:label_project_overview) %>
|
||||
</div>
|
||||
|
||||
<div style="padding-bottom: 8px">
|
||||
<div class="font_lighter_sidebar">
|
||||
|
||||
<%= textilizable @forum.description %>
|
||||
</div>
|
||||
<div class="created_on_project">
|
||||
<strong style="color: #15bccf"><%= l(:label_create_time) %>:</strong><%= format_time(@forum.created_at) %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="user_underline"></div>
|
||||
</div>
|
||||
<!--tags-->
|
||||
|
||||
<div class="user_fans">
|
||||
<!-- added by william -for tag -->
|
||||
<div class="user_tags">
|
||||
<div id="tags">
|
||||
<!-- 此处为tag -->
|
||||
<%= render :partial => 'tags/tag', :locals => {:obj => @forum,:object_flag => "5"}%>
|
||||
</div></div>
|
||||
</div>
|
||||
|
||||
|
||||
<!--tool-->
|
||||
<div class="user_underline"></div>
|
||||
|
||||
<!--tags-->
|
||||
<% if User.current.logged? || User.current.admin? %>
|
||||
<div class="forums-tags"><%= render :partial => 'tags/tag', :locals => {:obj => @forum.creator,:object_flag => "1"} %></div>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
<div id="content">
|
||||
|
@ -157,9 +77,8 @@
|
|||
|
||||
</div>
|
||||
<%= render :partial => 'layouts/base_footer'%>
|
||||
<%= debug(params) if Rails.env.development? %>
|
||||
<%= debug(params) if Rails.env.development? %>
|
||||
</div>
|
||||
|
||||
<div id="ajax-indicator" style="display:none;">
|
||||
<span><%= l(:label_loading) %></span>
|
||||
</div>
|
||||
|
|
|
@ -45,107 +45,30 @@
|
|||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div id="sidebar">
|
||||
<div class="spaceleft">
|
||||
|
||||
<!--informations-->
|
||||
<div class="inf_user_image">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="info-course">
|
||||
<%= @forum.name %>
|
||||
</div>
|
||||
<div>
|
||||
<% unless User.current.member_of? @forum %>
|
||||
<%= watcher_link(@fourm, User.current) %>
|
||||
<% end %>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<!--parameter -->
|
||||
<div class="user_fans">
|
||||
|
||||
<table width="240" border="0">
|
||||
<tr align="center" width="80px">
|
||||
|
||||
<td class="font_index"><%=link_to 1, forum_path(@forum) %></td>
|
||||
<td class="font_index"><%=link_to 2, forum_path(@forum) %></td>
|
||||
<td class="font_index"><%=link_to 3, forum_path(@forum) %></td>
|
||||
</tr>
|
||||
|
||||
<tr class="font_aram">
|
||||
<td align="center" width="70px"> <%= l(:label_member) %></td>
|
||||
<td align="center" width="100px"><%= l(:label_user_watchered) %></td>
|
||||
<td align="center" width="70px"> <%= l(:label_project_issues) %></td>
|
||||
<!-- <td align="center" width="58px"><%= l(:label_attachment) %></td> -->
|
||||
</tr>
|
||||
</table>
|
||||
<div class="user_underline"></div>
|
||||
</div>
|
||||
|
||||
<div class="sidebar-forums">
|
||||
<div class="forums-line">
|
||||
<div class="forums-title"><%= @forum.name %></div>
|
||||
<div class="forums-description"><%= textilizable @forum.description %></div>
|
||||
</div>
|
||||
<!--informations-->
|
||||
<div class="inf_user">
|
||||
|
||||
<div class="font_title_left">
|
||||
创建人信息
|
||||
<div class="formus-first-title" >创建人信息</div>
|
||||
<div class="forums-info">
|
||||
<div style="padding-top: 20px" >
|
||||
<span class="forums-avatar-left"><%= image_tag(url_to_avatar(@forum.creator), :class => 'avatar2') %></span>
|
||||
<span class="forums-avatar-right"><%=link_to @forum.creator.show_name, user_path(@forum.creator) %>
|
||||
<div>
|
||||
<%= link_to l(:label_user_watcher)+"("+User.watched_by(@forum.creator.id).count.to_s+")" ,:controller=>"users", :action=>"user_watchlist", :id => @forum.creator.id %>
|
||||
<%= link_to l(:label_x_user_fans, :count => User.current.watcher_users(User.current.id).count)+"("+@forum.creator.watcher_users(@forum.creator.id).count.to_s+")", :controller=>"users", :action=>"user_fanslist", :id => @forum.creator.id %></div></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td><%= image_tag(url_to_avatar(@forum.creator), :class => 'avatar2') %></td>
|
||||
<td>
|
||||
<div class="info-course">
|
||||
<%= @forum.name %>
|
||||
</div>
|
||||
<div>
|
||||
<!-- 此处原来是关注 -->
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<div class="user_underline"></div>
|
||||
<!--tags-->
|
||||
<% if User.current.logged? || User.current.admin? %>
|
||||
<div class="forums-tags"><%= render :partial => 'tags/tag', :locals => {:obj => @forum.creator,:object_flag => "1"} %></div>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<!--description-->
|
||||
<div class="inf_user_context">
|
||||
<div class="font_title_left">
|
||||
<%= l(:label_project_overview) %>
|
||||
</div>
|
||||
|
||||
<div style="padding-bottom: 8px">
|
||||
<div class="font_lighter_sidebar">
|
||||
|
||||
<%= textilizable @forum.description %>
|
||||
</div>
|
||||
<div class="created_on_project">
|
||||
<strong style="color: #15bccf"><%= l(:label_create_time) %>:</strong><%= format_time(@forum.created_at) %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="user_underline"></div>
|
||||
</div>
|
||||
|
||||
<!--tags-->
|
||||
<div class="user_fans">
|
||||
<!-- added by william -for tag -->
|
||||
<div class="user_tags">
|
||||
<div id="tags"> <!-- 此处为tag --> 标签 </div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!--tool-->
|
||||
<div class="user_underline"></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="content">
|
||||
<%= render_flash_messages %>
|
||||
<%= yield %>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<%= board_breadcrumb(@message) %>
|
||||
<!-- <%= board_breadcrumb(@message) %>
|
||||
|
||||
<div class="contextual">
|
||||
<%= watcher_link(@topic, User.current) %>
|
||||
|
@ -21,19 +21,87 @@
|
|||
:data => {:confirm => l(:text_are_you_sure)},
|
||||
:class => 'icon icon-del'
|
||||
) if @message.destroyable_by?(User.current) %>
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
<div class="borad-title"><%= avatar(@topic.author, :size => "24") %><%=h @topic.subject %></div>
|
||||
<!-- <div class="borad-title"><%= avatar(@topic.author, :size => "24") %><%=h @topic.subject %></div>
|
||||
|
||||
<div class="borad-topic-count-message">
|
||||
<%= textilizable(@topic, :content) %>
|
||||
<%= authoring @topic.created_on, @topic.author %>
|
||||
<%= link_to_attachments @topic, :author => false %>
|
||||
</div>
|
||||
<br />
|
||||
<br /> -->
|
||||
<style type="text/css">
|
||||
/** {
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
-box-sizing: border-box;
|
||||
}*/
|
||||
.lz {
|
||||
position:relative;
|
||||
min-height: 200px;
|
||||
margin: 10px 2px;
|
||||
border-radius: 5px;
|
||||
box-shadow: 1px 1px 6px #97EBF4;
|
||||
}
|
||||
.lz-left{
|
||||
float: left;
|
||||
margin: 2%;
|
||||
padding: 0;
|
||||
}
|
||||
.memo-section{
|
||||
width: auto;
|
||||
margin-left: 15%;
|
||||
padding-top: 1%;
|
||||
border-left: 2px dotted #EEE;/*#8BE9F3;*/
|
||||
}
|
||||
.memo-title{
|
||||
margin: 1em 0;
|
||||
padding-left: 1%;
|
||||
border-bottom: 1px dashed
|
||||
}
|
||||
.memo-content{
|
||||
padding: 1%;
|
||||
margin: 1%;
|
||||
margin-bottom: 40px;
|
||||
background-color: #F6F6F6;
|
||||
}
|
||||
.memo-timestamp{
|
||||
position: absolute;
|
||||
bottom: 0px;
|
||||
right: 0;
|
||||
margin: 20px;
|
||||
}
|
||||
.replies{
|
||||
float: right;
|
||||
/*max-width: 90%;*/
|
||||
}
|
||||
.reply-box{
|
||||
float: right;
|
||||
width: 640px;
|
||||
padding: 3%;
|
||||
/*border: 2px solid #C6F3F9;*/
|
||||
border-top: 2px double #C6F3F9;
|
||||
/*border-radius: 10px;*/
|
||||
}
|
||||
</style>
|
||||
|
||||
<div class="lz">
|
||||
<div class="lz-left">
|
||||
<div class=""><%= link_to image_tag(url_to_avatar(@topic.author), :class => "avatar"), user_path(@topic.author) %></div>
|
||||
<p class=""><%=h @topic.author %></p>
|
||||
</div>
|
||||
<div class="memo-section">
|
||||
<div class="memo-title"><%= label_tag l(:field_subject) %>: <%=h @topic.subject %></div>
|
||||
<div class="memo-content"><%= textilizable(@topic, :content) %></div>
|
||||
<div class="memo-timestamp"> <%= authoring @topic.created_on, @topic.author %></div>
|
||||
</div>
|
||||
<br />
|
||||
</div>
|
||||
|
||||
<% unless @replies.empty? %>
|
||||
<h3 class="comments"><%= l(:label_reply_plural) %> (<%= @reply_count %>)</h3>
|
||||
<% reply_count = 0 %>
|
||||
<% @replies.each do |message| %>
|
||||
<div class="message reply" id="<%= "message-#{message.id}" %>">
|
||||
<div class="contextual-borad">
|
||||
|
@ -58,14 +126,14 @@
|
|||
</div>
|
||||
|
||||
<table class="borad-text-list">
|
||||
<tr><td class="font_lighter"><%= reply_count += 1 %>楼 </td></tr>
|
||||
<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>
|
||||
</td></tr>
|
||||
<tr><td class="font_lighter" style="float: right"><%= authoring message.created_on, message.author %></td></tr>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
<!-- <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}" } %>
|
||||
|
@ -74,7 +142,7 @@
|
|||
</h4>
|
||||
<div class="wiki"><%= textilizable message, :content, :attachments => message.attachments %></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 %>
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 2.2 KiB |
|
@ -12,18 +12,59 @@ h4 {border-bottom: 1px dotted #bbb;}
|
|||
/*new by huang*/
|
||||
/**/
|
||||
/*new code reconstruction*/
|
||||
div.sidebar-content{
|
||||
div.sidebar-forums{
|
||||
padding-left: 8px;
|
||||
padding-right: 8px;
|
||||
width: 214px;
|
||||
}
|
||||
div.sidebar-content div.info-course{
|
||||
font-family: 微软雅黑;
|
||||
|
||||
div.forums-tags{
|
||||
border-bottom: solid 1px #15bccf;
|
||||
width: 214px;
|
||||
}
|
||||
|
||||
div.forums-line{
|
||||
border-bottom: solid 1px #15bccf;
|
||||
}
|
||||
|
||||
div.forums-info{
|
||||
background-image: url(../images/sidebar/forums.png);
|
||||
border-bottom: solid 1px #15bccf;
|
||||
height: 100px;
|
||||
width: 214px;
|
||||
padding-left: 5px;
|
||||
|
||||
}
|
||||
|
||||
div.forums-title{
|
||||
font-family: 微软雅黑;
|
||||
font-weight: bold;
|
||||
font-size: 16px;
|
||||
color: #4d4d4d;
|
||||
color: rgb(237, 137, 36);
|
||||
word-wrap: break-word;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
div.forums-description{
|
||||
color: rgb(145, 146, 148);
|
||||
}
|
||||
|
||||
span.forums-avatar-left{
|
||||
float:left;
|
||||
width: 23%;
|
||||
}
|
||||
|
||||
span.forums-avatar-right{
|
||||
float: right;
|
||||
width: 70%;
|
||||
}
|
||||
|
||||
.formus-first-title{
|
||||
font-family:微软雅黑;
|
||||
font-weight:bold;
|
||||
padding-top:3px;
|
||||
padding-bottom:3px;
|
||||
font-size:16px;
|
||||
}
|
||||
/*end*/
|
||||
.welcome-index{
|
||||
width: 290px;
|
||||
|
@ -68,7 +109,7 @@ div.sidebar-content div.info-course{
|
|||
.borad-topic-count{
|
||||
padding-top: 10px;
|
||||
padding-left: 5px;
|
||||
border-bottom:solid 1px #848282;
|
||||
border-bottom: 1px dashed rgb(204, 204, 204);
|
||||
}
|
||||
|
||||
.borad-topic-count-message{
|
||||
|
|
Loading…
Reference in New Issue