作业详情接口添加留言列表
This commit is contained in:
parent
b9643390a6
commit
411d201fc3
|
@ -52,6 +52,10 @@ module Mobile
|
||||||
homework_expose :created_on
|
homework_expose :created_on
|
||||||
homework_expose :deadline
|
homework_expose :deadline
|
||||||
|
|
||||||
|
expose :jours,using: Mobile::Entities::Jours do |f, opt|
|
||||||
|
f[:jours] if f.is_a?(Hash) && f.key?(:jours)
|
||||||
|
end
|
||||||
|
|
||||||
expose :homework_for_anonymous_comments,using: Mobile::Entities::HomeworkAttach do |f, opt|
|
expose :homework_for_anonymous_comments,using: Mobile::Entities::HomeworkAttach do |f, opt|
|
||||||
f[:homework_for_anonymous_comments] if f.is_a?(Hash) && f.key?(:homework_for_anonymous_comments)
|
f[:homework_for_anonymous_comments] if f.is_a?(Hash) && f.key?(:homework_for_anonymous_comments)
|
||||||
end
|
end
|
||||||
|
|
|
@ -26,8 +26,9 @@ class HomeworkService
|
||||||
state = @bid.comment_status
|
state = @bid.comment_status
|
||||||
#end
|
#end
|
||||||
open_anonymous_evaluation = @bid.open_anonymous_evaluation
|
open_anonymous_evaluation = @bid.open_anonymous_evaluation
|
||||||
|
jours = @bid.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC')
|
||||||
{:course_name => course.name,:course_id => course.id,:id => @bid.id, :author => @bid.author,:author_real_name =>author, :homework_times => many_times, :homework_name => name, :homework_count => homework_count,:student_questions_count => student_questions_count,
|
{:course_name => course.name,:course_id => course.id,:id => @bid.id, :author => @bid.author,:author_real_name =>author, :homework_times => many_times, :homework_name => name, :homework_count => homework_count,:student_questions_count => student_questions_count,
|
||||||
:description => description, :homework_state => state,:open_anonymous_evaluation => open_anonymous_evaluation,:created_on => @bid.created_on,:deadline => @bid.deadline}
|
:description => description, :homework_state => state,:open_anonymous_evaluation => open_anonymous_evaluation,:created_on => @bid.created_on,:deadline => @bid.deadline,:jours => jours}
|
||||||
end
|
end
|
||||||
|
|
||||||
# 启动作业匿评前提示信息
|
# 启动作业匿评前提示信息
|
||||||
|
|
Loading…
Reference in New Issue