头部信息加上学校

chromesetting
cxt 5 years ago
parent a705fcf93a
commit 87e0aa098b

@ -21,7 +21,7 @@ class CollegesController < ApplicationController
# 实训总数 # 实训总数
@shixuns_count = Shixun.visible.joins('left join user_extensions on user_extensions.user_id = shixuns.user_id') @shixuns_count = Shixun.visible.joins('left join user_extensions on user_extensions.user_id = shixuns.user_id')
.where(user_extensions: { school_id: current_school.id }).count .where(user_extensions: { school_id: current_school.id }).count
render json: { teachers_count: @teachers_count, students_count: @students_count, courses_count: @courses_count, shixuns_count: @shixuns_count } render json: { teachers_count: @teachers_count, students_count: @students_count, courses_count: @courses_count, shixuns_count: @shixuns_count, school: current_school.name }
end end
def shixun_time def shixun_time

Loading…
Cancel
Save