diff --git a/app/controllers/journals_controller.rb b/app/controllers/journals_controller.rb index aa3a7e0ea..d8cd8eeec 100644 --- a/app/controllers/journals_controller.rb +++ b/app/controllers/journals_controller.rb @@ -74,6 +74,7 @@ class JournalsController < ApplicationController text = text.to_s.strip.gsub(%r{
((.|\s)*?)}m, '[...]') @content = "> #{ll(Setting.default_language, :text_user_wrote, user)}\n> " @content << text.gsub(/(\r?\n|\r\n?)/, "\n> ") + "\n\n" + @content = "
" << @content @id = user.id rescue ActiveRecord::RecordNotFound render_404 diff --git a/app/models/mailer.rb b/app/models/mailer.rb index 340559828..0d0b82752 100644 --- a/app/models/mailer.rb +++ b/app/models/mailer.rb @@ -186,7 +186,7 @@ class Mailer < ActionMailer::Base @course_journal_messages = JournalsForMessage.find_by_sql("select DISTINCT jfm.* from journals_for_messages jfm, members m, courses c where m.user_id = '#{user.id}' and c.id = m.course_id and jfm.jour_id = c.id and jfm.jour_type='Course' and (jfm.created_on between '#{date_from}' and '#{date_to}') order by created_on desc") - + @user_journal_messages = user.journals_for_messages.where("jour_type='Principal' and (created_on between '#{date_from}' and '#{date_to}')").order('created_on DESC') # 查询user在项目中留言(用户反馈) diff --git a/app/views/issues/_edit.html.erb b/app/views/issues/_edit.html.erb index f7594d000..444016db8 100644 --- a/app/views/issues/_edit.html.erb +++ b/app/views/issues/_edit.html.erb @@ -20,8 +20,10 @@ <%= render :partial => 'history', :locals => {:issue => @issue, :journals => @journals} %> <% end %> + + diff --git a/app/views/issues/_history.html.erb b/app/views/issues/_history.html.erb index 04c46ed39..a5b1661eb 100644 --- a/app/views/issues/_history.html.erb +++ b/app/views/issues/_history.html.erb @@ -3,9 +3,9 @@-+-++ + + <%= l(:button_submit) %> diff --git a/app/views/journals/new.js.erb b/app/views/journals/new.js.erb index ae2574595..d02568426 100644 --- a/app/views/journals/new.js.erb +++ b/app/views/journals/new.js.erb @@ -1,11 +1,11 @@ -$('#issue_notes').val("<%= raw escape_javascript(@content) %>"); +$('#journal_issue_note').html("<%= raw escape_javascript(@content.html_safe) %>"); +$("input[name='issue_quote_new']").val("<%= raw escape_javascript(@content.html_safe) %>"); <% # when quoting a private journal, check the private checkbox - if @journal && @journal.private_notes? + if @journal && @journal.private_notes? %> $('#issue_private_notes').attr('checked', true); <% end %> - showAndScrollTo("update", "notes"); $('#notes').scrollTop = $('#notes').scrollHeight - $('#notes').clientHeight;<%= journal.user %><%= format_time journal.created_on %> @@ -20,7 +20,9 @@diff --git a/app/views/issues/show.html.erb b/app/views/issues/show.html.erb index 1bd956074..c008e78f2 100644 --- a/app/views/issues/show.html.erb +++ b/app/views/issues/show.html.erb @@ -109,6 +109,9 @@ <%= render :partial => 'edit' %><%= render_links_easy(issue, journal, :reply_links => reply_links) unless journal.notes.blank? %>-<%= render_notes_issue(issue, journal, :reply_links => reply_links) unless journal.notes.blank? %>
++ <%= render_notes_issue(issue, journal, :reply_links => reply_links) unless journal.notes.blank? %> +