Merge branches 'dev_item_bank' and 'dev_jupyter' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_item_bank

dev_jupyter
杨树明 5 years ago
commit 7d76fb5646

@ -888,12 +888,14 @@ class ShixunsController < ApplicationController
def upload_git_file
upload_file = params["file"]
uid_logger("#########################file_params####{params["#{params[:file]}"]}")
uid_logger("#########################file_params##: #{params["file"]}")
raise "未上传文件" unless upload_file
content = upload_file.tempfile.read
uid_logger("#########################content####{content}")
author_name = current_user.real_name
author_email = current_user.git_mail
message = params[:message] || "upload file by browser"
uid_logger("-----author_email: #{author_email}")
update_file_content(content, @repo_path, @path, author_email, author_name, message)
render_ok
end

Loading…
Cancel
Save