留言引用样式调整
This commit is contained in:
parent
554b8356ac
commit
8d64114c58
|
@ -36,8 +36,7 @@ class JournalsController < ApplicationController
|
||||||
sort_update(@query.sortable_columns)
|
sort_update(@query.sortable_columns)
|
||||||
|
|
||||||
if @query.valid?
|
if @query.valid?
|
||||||
@journals = @query.journals(:order => "#{Journal.table_name}.created_on DESC",
|
@journals = @query.journals(:order => "#{Journal.table_name}.created_on DESC", :limit => 25)
|
||||||
:limit => 25)
|
|
||||||
end
|
end
|
||||||
@title = (@project ? @project.name : Setting.app_title) + ": " + (@query.new_record? ? l(:label_changes_details) : @query.name)
|
@title = (@project ? @project.name : Setting.app_title) + ": " + (@query.new_record? ? l(:label_changes_details) : @query.name)
|
||||||
render :layout => false, :content_type => 'application/atom+xml'
|
render :layout => false, :content_type => 'application/atom+xml'
|
||||||
|
@ -72,9 +71,9 @@ class JournalsController < ApplicationController
|
||||||
end
|
end
|
||||||
# Replaces pre blocks with [...]
|
# Replaces pre blocks with [...]
|
||||||
text = text.to_s.strip.gsub(%r{<pre>((.|\s)*?)</pre>}m, '[...]')
|
text = text.to_s.strip.gsub(%r{<pre>((.|\s)*?)</pre>}m, '[...]')
|
||||||
@content = "> #{ll(Setting.default_language, :text_user_wrote, user)}\n> "
|
@content = "#{ll(Setting.default_language, :text_user_wrote, user)}\n"
|
||||||
@content << text.gsub(/(\r?\n|\r\n?)/, "\n> ") + "\n\n"
|
@content << text.gsub(/(\r?\n|\r\n?)/, "\n ") + "\n"
|
||||||
# @content = "<blockquote style='word-break: break-all;word-wrap: break-word;'>" << @content
|
@content = "<blockquote style='word-break: break-all;word-wrap: break-word;'>" << @content << "</blockquote>"
|
||||||
@id = user.id
|
@id = user.id
|
||||||
rescue ActiveRecord::RecordNotFound
|
rescue ActiveRecord::RecordNotFound
|
||||||
render_404
|
render_404
|
||||||
|
|
|
@ -20,12 +20,8 @@
|
||||||
</p><br/>
|
</p><br/>
|
||||||
|
|
||||||
<div class="cl"></div>
|
<div class="cl"></div>
|
||||||
<p>由<a href="javascript:void(0)" class="problem_name"><%= @issue.author %></a>
|
由<a href="javascript:void(0)" class="problem_name"><%= @issue.author %></a>
|
||||||
<%# if @issue.created_on != @issue.updated_on %>
|
添加于 <%= format_time(@issue.created_on).html_safe %>
|
||||||
添加于 <%= format_time(@issue.created_on).html_safe %>
|
|
||||||
<%# else %>
|
|
||||||
<%#= format_time(@issue.updated_on).html_safe %>
|
|
||||||
<%# end %>
|
|
||||||
</div>
|
</div>
|
||||||
<!--talk_txt end-->
|
<!--talk_txt end-->
|
||||||
<a href="javascript:void(0)" class="talk_edit fr"<%= render :partial => 'action_menu' %></a>
|
<a href="javascript:void(0)" class="talk_edit fr"<%= render :partial => 'action_menu' %></a>
|
||||||
|
|
Loading…
Reference in New Issue