From 88b26c8521f8cb3dbf53625a7f1fff9d698b89fa Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Fri, 13 Mar 2020 16:10:06 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B5=84=E6=BA=90=E6=8E=A5=E5=8F=A3=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/courses/attahcment_category_list.json.jbuilder | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/app/views/courses/attahcment_category_list.json.jbuilder b/app/views/courses/attahcment_category_list.json.jbuilder index 217b1092e..b9acdfe68 100644 --- a/app/views/courses/attahcment_category_list.json.jbuilder +++ b/app/views/courses/attahcment_category_list.json.jbuilder @@ -3,8 +3,11 @@ json.course_modules do json.array! @course_modules do |course_module| json.id course_module.id json.module_name course_module.module_name - json.course_second_categories do - json.array! course_module.course_second_categories, :id, :name + json.course_second_categories course_module.first_categories do |category| + json.(category, :id, :name) + json.course_third_categories category.children do |child| + json.(child, :id, :name) + end end end end