修改memo对应的memo_messages的viewed字段

This commit is contained in:
ouyangxuhua 2015-08-25 17:41:59 +08:00
parent 0056fa9db3
commit 24f26749c0
1 changed files with 2 additions and 0 deletions

View File

@ -115,6 +115,8 @@ class MemosController < ApplicationController
REPLIES_PER_PAGE = 20 unless const_defined?(:REPLIES_PER_PAGE) REPLIES_PER_PAGE = 20 unless const_defined?(:REPLIES_PER_PAGE)
def show def show
#更新贴吧帖子留言对应的memo_messages的viewed字段
query_memo_messages = @memo.memo_messages
pre_count = REPLIES_PER_PAGE pre_count = REPLIES_PER_PAGE
@memo = @memo.root # 取出楼主防止输入帖子id让回复作为主贴显示 @memo = @memo.root # 取出楼主防止输入帖子id让回复作为主贴显示