dev_jupyter
jingquan huang 5 years ago
parent 66d6760860
commit 95635d2073

@ -8,24 +8,24 @@ class MainController < ApplicationController
end
def index
# domain_session = params[:_educoder_session]
# if domain_session
# uid_logger("main start domain_session is #{domain_session}")
# if cookies[:_educoder_session] != domain_session
# cookies[:_educoder_session] = nil
# cookies[:_educoder_session] = domain_session
# end
#
#
# uid_logger("main start is #{cookies[:_educoder_session]}")
# end
#
# # TODO: 这块之后需要整合者架构重新变化统一跳转到index后再路由分发
# if params[:path] && params[:path]&.include?("h5educoderbuild") && params[:path].split("/").first == "h5educoderbuild"
# render file: 'public/h5educoderbuild/index.html', :layout => false
# else
# render file: 'public/react/build/index.html', :layout => false
# end
domain_session = params[:_educoder_session]
if domain_session
uid_logger("main start domain_session is #{domain_session}")
if cookies[:_educoder_session] != domain_session
cookies[:_educoder_session] = nil
cookies[:_educoder_session] = domain_session
end
uid_logger("main start is #{cookies[:_educoder_session]}")
end
# TODO: 这块之后需要整合者架构重新变化统一跳转到index后再路由分发
if params[:path] && params[:path]&.include?("h5educoderbuild") && params[:path].split("/").first == "h5educoderbuild"
render file: 'public/h5educoderbuild/index.html', :layout => false
else
render file: 'public/react/build/index.html', :layout => false
end
end
end
Loading…
Cancel
Save