Merge branch 'dev_course' of http://bdgit.educoder.net/Hjqreturn/educoder into dev_course

dev_course
cxt 6 years ago
commit 21d61a1c50

@ -45,16 +45,6 @@ class GraduationTopicsController < ApplicationController
end
## 分页参数
@current_user = current_user
course_group_ids = @course.course_members.where(user_id: current_user.id, role: [1,2,3]).pluck(:course_group_id).uniq
#6.11 -hs
if course_group_ids.present?
if course_group_ids.include?(0)
course_group_ids = @course.course_groups.pluck(:id)
end
end
@group_list = CourseGroup.where(id: course_group_ids)
page = params[:page] || 1
limit = params[:limit] || 50
@users_count = @student_graduation_topics.try(:count).to_i

@ -7,13 +7,7 @@ json.edit_url edit_course_graduation_topic_path(@course, graduation_topic_id: @g
json.users_count @users_count
json.course_identity @current_user.course_identity(@course)
json.user_selected_topic @graduation_topic.user_status(current_user.id)
json.group_list do
json.array! @group_list do |group|
json.course_group_id group.id
json.group_name group.name
end
end
json.group_list @course.teacher_group(current_user.id)
# 列表数据
json.users_list do

Loading…
Cancel
Save