资源上传跳转问题
This commit is contained in:
parent
5fd36c0e78
commit
8815e99db5
|
@ -2283,20 +2283,17 @@ class UsersController < ApplicationController
|
|||
@save_message = attach_copied_obj.errors.full_messages
|
||||
end
|
||||
end
|
||||
if params[:mul_type] == "Course"
|
||||
respond_to do |format|
|
||||
redirect_to course_files_url(mul_container)
|
||||
end
|
||||
elsif params[:mul_type] == "Project"
|
||||
respond_to do |format|
|
||||
redirect_to project_files_url(mul_container)
|
||||
end
|
||||
elsif params[:mul_type] == "SubfieldFile"
|
||||
respond_to do |format|
|
||||
redirect_to org_subfield_files_url(mul_container)
|
||||
end
|
||||
respond_to do |format|
|
||||
format.html {
|
||||
if params[:mul_type] == "Course"
|
||||
redirect_to course_files_url(mul_container)
|
||||
elsif params[:mul_type] == "Project"
|
||||
redirect_to project_files_url(mul_container)
|
||||
elsif params[:mul_type] == "SubfieldFile"
|
||||
redirect_to org_subfield_files_url(mul_container)
|
||||
end
|
||||
}
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
# 根据资源关键字进行搜索
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
<%= form_tag( url_for({:controller => 'users', :action => 'import_into_container',
|
||||
:mul_id => params[:project_id].nil? ? (params[:course_id].nil? ? params[:subfield_file_id] : params[:course_id]) : params[:project_id],
|
||||
:mul_type => params[:project_id].nil? ? (params[:course_id].nil? ? "SubfieldFile" : "Course") : "Project"}),
|
||||
:remote => true , :method => 'post', :id => 'resource_import_container_form') do %>
|
||||
:method => 'post', :id => 'resource_import_container_form') do %>
|
||||
<% @attachments.each do |attach| %>
|
||||
<ul class="subjectRow">
|
||||
<li class="subjectName fl hidden">
|
||||
|
|
Loading…
Reference in New Issue