diff --git a/app/views/news/index.html.erb b/app/views/news/index.html.erb index e977ba8ca..a558c4840 100644 --- a/app/views/news/index.html.erb +++ b/app/views/news/index.html.erb @@ -44,13 +44,13 @@ <%= image_tag(url_to_avatar(news.author), :class => "avatar") %> - + - +
<%=link_to_user(news.author)if news.respond_to?(:author) %> <%= l(:label_project_newshare)%> <%= link_to h(news.title), news_path(news) %><%=link_to_user(news.author)if news.respond_to?(:author) %> <%= l(:label_project_newshare)%> <%= link_to h(news.title), news_path(news) %>
<%= textilizable(news, :description) %>
<%= news.created_on %> <%= news.created_on %> <%= link_to l(:label_project_newother),news_path(news)%><%= "(#{l(:label_x_comments, :count => news.comments_count)})" if news.comments_count >= 0 %>
diff --git a/app/views/news/show.html.erb b/app/views/news/show.html.erb index 6380cf0c1..9e9e46e41 100644 --- a/app/views/news/show.html.erb +++ b/app/views/news/show.html.erb @@ -8,7 +8,7 @@ <%= delete_link news_path(@news) if User.current.allowed_to?(:manage_news, @project) %> -

<%=h @news.title %>

+

<%=h @news.title %>

<% if authorize_for('news', 'edit') %> -->
-

<%= l(:label_comment_plural) %>

-<% @comments.each do |comment| %> - <% next if comment.new_record? %> - - - - - -
<%= image_tag(url_to_avatar(comment.author), :class => "avatar")%> - - - - - - - - - - -
<%=link_to_user(comment.author) if comment.respond_to?(:author) %> - <%= l(:label_project_newadd) %><%= l(:label_comment_plural) %>

<%= textilizable(comment.comments) %>

<%= @news.created_on %><%= link_to_if_authorized image_tag('delete.png'), {:controller => 'comments', :action => 'destroy', :id => @news, :comment_id => comment}, - :data => {:confirm => l(:text_are_you_sure)}, :method => :delete, :title => l(:button_delete) %>
-<% end if @comments.any? %> -
- +
+<%= @news.description %> + + <% if @news.commentable? %>

<%= toggle_link l(:label_comment_add), "add_comment_form", :focus => "comment_comments" %>

<%= form_tag({:controller => 'comments', :action => 'create', :id => @news}, :id => "add_comment_form", :style => "display:none;") do %> @@ -77,4 +56,33 @@ <% content_for :header_tags do %> <%= stylesheet_link_tag 'scm' %> -<% end %> \ No newline at end of file +<% end %> + + +
+
+

<%= l(:label_comment_plural) %>

+<% comments = @comments.reverse %> +<% comments.each do |comment| %> + <% next if comment.new_record? %> + + + + + +
<%= image_tag(url_to_avatar(comment.author), :class => "avatar")%> + + + + + + + + + + +
<%=link_to_user(comment.author) if comment.respond_to?(:author) %> + <%= l(:label_project_newadd) %><%= l(:label_comment_plural) %>

<%= textilizable(comment.comments) %>

<%= @news.created_on %><%= link_to_if_authorized image_tag('delete.png'), {:controller => 'comments', :action => 'destroy', :id => @news, :comment_id => comment}, + :data => {:confirm => l(:text_are_you_sure)}, :method => :delete, :title => l(:button_delete) %>
+<% end if @comments.any? %> + diff --git a/public/stylesheets/application.css b/public/stylesheets/application.css index 91b74e767..e27baa660 100644 --- a/public/stylesheets/application.css +++ b/public/stylesheets/application.css @@ -253,6 +253,15 @@ ul.tool li{list-style-type:none; .line_under{ border-bottom: 1px dashed rgb(204, 204, 204); } +.line_heng{ + width: 670px; + height: 1px; + margin-top:5px; + border: 0px; + background-color:#D5D5D5; + color: #D5D5D5; +} + ul.user_project_sort{margin:0px; padding-left:0em;} ul.user_project_sort li{list-style-type:none; height:auto;}