admin界面的留言列表过滤掉新用户的留言
This commit is contained in:
parent
f4632c432f
commit
6e36418201
|
@ -777,8 +777,15 @@ class AdminController < ApplicationController
|
|||
|
||||
#留言列表
|
||||
def leave_messages
|
||||
notes1, notes2, notes3 = '', '', ''
|
||||
begin
|
||||
notes1 = Message.find(19292).content
|
||||
notes2 = Message.find(19291).content
|
||||
notes3 = Message.find(19504).content
|
||||
rescue => e
|
||||
end
|
||||
@jour = JournalsForMessage.find_by_sql("SELECT * FROM journals_for_messages AS j1
|
||||
WHERE j1.jour_type IN ('Course','Principal') AND (j1.m_parent_id IS NULL OR (j1.m_parent_id IN (SELECT id FROM journals_for_messages WHERE jour_type IN ('Course','Principal')))) order by created_on desc")
|
||||
WHERE j1.jour_type IN ('Course','Principal') AND (j1.m_parent_id IS NULL OR (j1.m_parent_id IN (SELECT id FROM journals_for_messages WHERE jour_type IN ('Course','Principal')))) AND j1.notes !='#{notes1}' AND j1.notes !='#{notes2}' AND j1.notes !='#{notes3}' order by created_on desc")
|
||||
@jour = paginateHelper @jour,30
|
||||
@page = (params['page'] || 1).to_i - 1
|
||||
respond_to do |format|
|
||||
|
|
Loading…
Reference in New Issue