From b9de59fdcfb1152930bac7d5ba818ab037df58dd Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Mon, 9 Mar 2020 20:44:57 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B5=84=E6=BA=90=E5=A4=96=E9=93=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/files_controller.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/controllers/files_controller.rb b/app/controllers/files_controller.rb index fbf798c64..b4604892d 100644 --- a/app/controllers/files_controller.rb +++ b/app/controllers/files_controller.rb @@ -195,6 +195,8 @@ class FilesController < ApplicationController attachment = Attachment.new attachment.container = @course attachment.course_second_category_id = course_second_category_id + attachment.filename = params[:name] + attachment.link = params[:link] attachment.description = params[:description] attachment.is_public = params[:is_public] && @course.is_public == 1 ? 1 : 0 attachment.is_publish = @atta_is_publish