Merge branch 'develop' into dev_xucheng
Conflicts: app/controllers/managements_controller.rb app/helpers/application_helper.rb app/views/subjects/_subject_list.html.erb config/routes.rb
This commit is contained in:
commit
ac28f83271
|
@ -2,13 +2,16 @@
|
|||
class ChallengesController < ApplicationController
|
||||
layout "base_shixun"
|
||||
before_filter :check_authentication
|
||||
before_filter :find_shixun, :only => [:index, :new, :create, :destroy, :challenge_build, :update_evaluation]
|
||||
before_filter :find_challenge, :only => [:show, :edit, :update, :challenge_build, :index_up, :index_down, :destroy, :update_evaluation]
|
||||
before_filter :find_shixun, :only => [:index, :new, :create, :destroy, :challenge_build, :update_evaluation, :add_choose_question, :new_choose_question, :choose_type_show, :edit_choose_question, :update_choose_question, :destroy_challenge_choose]
|
||||
before_filter :find_challenge, :only => [:show, :edit, :update, :challenge_build, :index_up, :index_down, :destroy, :update_evaluation, :add_choose_question, :new_choose_question, :choose_type_show, :edit_choose_question, :update_choose_question, :destroy_challenge_choose]
|
||||
before_filter :build_challege_from_params, :only => [:new, :create]
|
||||
before_filter :tpi_manager_allowed, :only => [:challenge_build, :destroy, :edit, :new, :create]
|
||||
before_filter :allowed_view, :only => [:show]
|
||||
before_filter :query_challeges, :only => [:show, :edit, :update, :update_evaluation]
|
||||
before_filter :find_shixun_language, :only => [:show, :new, :edit]
|
||||
#before_filter :default_format_js, only: :new_or_edit_choose_question
|
||||
|
||||
#skip_before_filter :verify_authenticity_token, :only => [:new_or_edit_choose_question]
|
||||
|
||||
include ApplicationHelper
|
||||
|
||||
|
@ -30,6 +33,8 @@ class ChallengesController < ApplicationController
|
|||
@challenge.shixun = @shixun
|
||||
@challenge.user = User.current
|
||||
@challenge.st = params[:st].to_i
|
||||
@challenge.save!
|
||||
=begin
|
||||
if @challenge.save!
|
||||
if params[:st].to_i != 0
|
||||
#创建选项
|
||||
|
@ -39,6 +44,7 @@ class ChallengesController < ApplicationController
|
|||
end
|
||||
end
|
||||
end
|
||||
=end
|
||||
# 实训是否需要重启
|
||||
# 非实践任务创建第一个阶段时调用 publishGame, 避免不包含实践任务的实训进行模拟实战时报错
|
||||
if @challenge.position == 1 && params[:st].to_i != 0
|
||||
|
@ -91,9 +97,117 @@ class ChallengesController < ApplicationController
|
|||
if challenge_pos < challenge_num
|
||||
@next_challenge = Challenge.where(:shixun_id => @shixun, :position => challenge_pos+1).first
|
||||
end
|
||||
@prev_challenge = Challenge.where(:shixun_id => @shixun, :position => challenge_pos - 1).first if challenge_pos - 1 > 0
|
||||
@prev_challenge = Challenge.where(:shixun_id => @shixun, :position => challenge_pos - 1).first if (challenge_pos - 1) > 0
|
||||
@tab = params[:tab].blank? ? 1 : params[:tab].to_i
|
||||
@editor = params[:editor] # 编辑模式
|
||||
respond_to do |format|
|
||||
format.html
|
||||
format.js
|
||||
end
|
||||
end
|
||||
|
||||
def new_choose_question
|
||||
ActiveRecord::Base.transaction do
|
||||
begin
|
||||
@challenge_choose = ChallengeChoose.new
|
||||
@challenge_choose.challenge_id = @challenge.id
|
||||
@challenge_choose.subject = params[:choose][:subject]
|
||||
@challenge_choose.answer = params[:choose][:answer]
|
||||
@challenge_choose.standard_answer = params[:standard_answer]
|
||||
@challenge_choose.score = params[:challenge][:score].to_i
|
||||
@challenge_choose.difficult = params[:challenge][:difficulty].to_i
|
||||
@challenge_choose.position = params[:position].to_i
|
||||
@challenge_choose.category = params[:category].to_i
|
||||
if @challenge_choose.save!
|
||||
# 创建选项
|
||||
params[:question][:cnt].each_with_index do |test, index|
|
||||
answer = params[:choice][:answer][index] == "0" ? false : true
|
||||
ChallengeQuestion.create(:option_name => test, :challenge_choose_id => @challenge_choose.id, :position => index, :right_key => answer)
|
||||
end
|
||||
# 创建单选多选的技能标签
|
||||
unless params[:knowledge].blank?
|
||||
params[:knowledge][:input].each do |input|
|
||||
ChallengeTag.create(:name => input, :challenge_choose_id => @challenge_choose.id, :challenge_id => @challenge.id)
|
||||
end
|
||||
end
|
||||
end
|
||||
@index = params[:position].to_i - 1
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
rescue Exception => e
|
||||
flash[:error] = "#{e.message}"
|
||||
redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun)
|
||||
raise ActiveRecord::Rollback
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def update_choose_question
|
||||
@challenge_choose = ChallengeChoose.where(:id => params[:choose_id]).first
|
||||
ActiveRecord::Base.transaction do
|
||||
@challenge_choose.update_attributes(:subject => params[:choose][:subject],
|
||||
:answer => params[:choose][:answer],
|
||||
:standard_answer => params[:standard_answer],
|
||||
:score => params[:challenge][:score].to_i,
|
||||
:difficult => params[:challenge][:difficulty].to_i)
|
||||
begin
|
||||
@challenge_choose.challenge_questions.delete_all
|
||||
params[:question][:cnt].each_with_index do |test, index|
|
||||
answer = params[:choice][:answer][index] == "0" ? false : true
|
||||
ChallengeQuestion.create(:option_name => test, :challenge_choose_id => @challenge_choose.id, :position => index, :right_key => answer)
|
||||
end
|
||||
@challenge_choose.challenge_tags.delete_all unless @challenge_choose.challenge_tags.blank?
|
||||
unless params[:knowledge].blank?
|
||||
params[:knowledge][:input].each do |input|
|
||||
ChallengeTag.create(:name => input, :challenge_choose_id => @challenge_choose.id, :challenge_id => @challenge.id)
|
||||
end
|
||||
end
|
||||
@challenge_choose = ChallengeChoose.where(:id => params[:choose_id]).first
|
||||
@index = params[:index].to_i
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
rescue Exception => e
|
||||
flash[:error] = "#{e.message}"
|
||||
format.html{redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun)}
|
||||
raise ActiveRecord::Rollback
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def edit_choose_question
|
||||
@challenge_choose = ChallengeChoose.where(:id => params[:choose_id]).first
|
||||
@category = @challenge_choose.category
|
||||
@position = @challenge_choose.position.to_i
|
||||
@index = params[:index].to_i
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
end
|
||||
|
||||
def choose_type_show
|
||||
@challenge_choose = ChallengeChoose.where(:id => params[:choose_id]).first
|
||||
@index = params[:index].to_i
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
end
|
||||
|
||||
def destroy_challenge_choose
|
||||
@challenge_choose = ChallengeChoose.where(:id => params[:choose_id]).first
|
||||
@challenge_choose.destroy
|
||||
|
||||
redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun)
|
||||
end
|
||||
|
||||
def add_choose_question
|
||||
@category = params[:category].to_i
|
||||
@position = params[:position]
|
||||
#@challenge_choose = @challenge.challenge_chooses
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
end
|
||||
|
||||
def destroy
|
||||
|
@ -108,22 +222,22 @@ class ChallengesController < ApplicationController
|
|||
def update
|
||||
ActiveRecord::Base.transaction do
|
||||
@challenge.update_attributes(params[:challenge])
|
||||
if (params[:tab] == "1" || params[:tab].nil?) && @challenge.st != 0
|
||||
begin
|
||||
@challenge.challenge_questions.delete_all
|
||||
params[:question][:cnt].each_with_index do |test, index|
|
||||
answer = params[:choice][:answer][index] == "0" ? false : true
|
||||
ChallengeQuestion.create(:option_name => test, :challenge_id => @challenge.id, :position => index, :right_key => answer)
|
||||
end
|
||||
redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => params[:tab])
|
||||
rescue Exception => e
|
||||
flash[:error] = "#{e.message}"
|
||||
format.html{redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun)}
|
||||
raise ActiveRecord::Rollback
|
||||
end
|
||||
else
|
||||
#if (params[:tab] == "1" || params[:tab].nil?) && @challenge.st != 0
|
||||
# begin
|
||||
# @challenge.challenge_questions.delete_all
|
||||
# params[:question][:cnt].each_with_index do |test, index|
|
||||
# answer = params[:choice][:answer][index] == "0" ? false : true
|
||||
# ChallengeQuestion.create(:option_name => test, :challenge_id => @challenge.id, :position => index, :right_key => answer)
|
||||
# end
|
||||
# redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => params[:tab])
|
||||
# rescue Exception => e
|
||||
# flash[:error] = "#{e.message}"
|
||||
# format.html{redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun)}
|
||||
# raise ActiveRecord::Rollback
|
||||
# end
|
||||
#else
|
||||
redirect_to edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => params[:tab])
|
||||
end
|
||||
#end
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -272,4 +386,8 @@ class ChallengesController < ApplicationController
|
|||
@language = language_switch language
|
||||
end
|
||||
|
||||
def default_format_js
|
||||
response.headers['content--type'] = 'text/javascript'
|
||||
request.format = 'js'
|
||||
end
|
||||
end
|
||||
|
|
|
@ -49,7 +49,7 @@ class GamesController < ApplicationController
|
|||
@type = params[:type]
|
||||
challenge_path = @game_challenge.path
|
||||
# 用户选项
|
||||
@user_answer = @game.outputs.first.actual_output.split("") unless @st == 0 || @game.outputs.blank?
|
||||
#@user_answer = @game.outputs.first.actual_output.split("") unless @st == 0 || @game.outputs.blank?
|
||||
# 默认打开文件
|
||||
logger.info("repository id is #{@repository.try(:id)}, repository's shixun_id =#{@repository.try(:myshixun_id)} shixun_id =#{@repository.try(:shixun_id)}, project_id => #{@repository.try(:project_id)}")
|
||||
# 验证challenge文件名的合法性
|
||||
|
@ -300,53 +300,42 @@ class GamesController < ApplicationController
|
|||
end
|
||||
|
||||
# 选择题评测(选择题不需要重新评测)
|
||||
# score 获得金币数 tag_count 技能数 right用户是否全对 answer_right全部选择题的正确性
|
||||
def evaluating_choice
|
||||
@game_challenge = @game.challenge
|
||||
user_answer = params[:answer]
|
||||
correct = true
|
||||
@challenges = Challenge.where(:shixun_id => @myshixun.shixun_id)
|
||||
@shixun = @myshixun.shixun
|
||||
score = 0
|
||||
tag_count = 0
|
||||
if !user_answer.blank?
|
||||
if user_answer.split("").count != @game_challenge.challenge_questions.where(:right_key => true).count
|
||||
correct = false
|
||||
else
|
||||
user_answer.split("").each do |answer|
|
||||
question = @game_challenge.challenge_questions.where(:position => answer.to_i).first
|
||||
unless question.right_key
|
||||
correct = false
|
||||
break
|
||||
end
|
||||
end
|
||||
@right = true
|
||||
answer_right = []
|
||||
@game_challenge.challenge_chooses.each_with_index do |choose, index|
|
||||
correct = (params[:answer][index] == choose.standard_answer) ? true : false
|
||||
if choose.choose_outputs.blank?
|
||||
ChooseOutputs.create(:challenge_choose_id => choose.id, :user_id => User.current.id, :answer => params[:answer][index], :correct => correct)
|
||||
end
|
||||
else
|
||||
correct = false
|
||||
if @shixun.status > 1 && !@game.answer_open
|
||||
if correct
|
||||
score += choose.score
|
||||
tag_count += choose.challenge_tags.count
|
||||
end
|
||||
elsif @shixun.status > 1 && @game.answer_open
|
||||
score -= choose.score
|
||||
end
|
||||
unless correct
|
||||
@right = false
|
||||
end
|
||||
answer_right << correct
|
||||
end
|
||||
@game.update_attributes(:status => 2, :end_time => Time.now)
|
||||
had_done = @game.had_done
|
||||
shixun = @myshixun.shixun
|
||||
if shixun.status > 1 && !@game.answer_open
|
||||
if correct
|
||||
#User.current.update_attributes(:grade => (User.current.grade + @game.challenge.score), :experience => (User.current.experience + @game.challenge.score))
|
||||
reward_grade(@game.user, @game.id, 'Game', @game_challenge.score)
|
||||
reward_experience(@game.user, @game.id, 'Game', @game_challenge.score)
|
||||
@game.update_attribute(:final_score, @game_challenge.score)
|
||||
score = @game_challenge.score
|
||||
tag_count = @game_challenge.challenge_tags.count
|
||||
else
|
||||
score = "+0"
|
||||
tag_count = 0
|
||||
end
|
||||
elsif shixun.status > 1 && @game.answer_open
|
||||
score = -@game_challenge.score.to_i
|
||||
tag_count = 0
|
||||
else
|
||||
score = "+0"
|
||||
tag_count = 0
|
||||
@had_done = @game.had_done
|
||||
reward_grade(@game.user, @game.id, 'Game', score)
|
||||
reward_experience(@game.user, @game.id, 'Game', score)
|
||||
@game.update_attribute(:final_score, score)
|
||||
|
||||
respond_to do |format|
|
||||
format.js{redirect_to myshixun_game_path(@game, :myshixun_id => @myshixun, :choose => 1)}
|
||||
end
|
||||
if @game.outputs.blank?
|
||||
Output.create(:game_id => @game.id, :actual_output => user_answer, :result => correct)
|
||||
end
|
||||
render :json => {correct: correct, had_done: had_done, :grade => User.where(:id => User.current.id).first.grade, score: score, tag_count: tag_count, position: @game_challenge.position}
|
||||
end
|
||||
|
||||
|
||||
|
@ -407,9 +396,19 @@ class GamesController < ApplicationController
|
|||
def answer
|
||||
challenge = @game.challenge
|
||||
@challenge_score = challenge.score.to_i
|
||||
@answer = ""
|
||||
# 已经开启过
|
||||
@score = User.current.grade.to_i - @challenge_score
|
||||
@answer = challenge.answer
|
||||
if(params[:choose] == "true")
|
||||
challenge.challenge_chooses.each_with_index do |choose, index|
|
||||
@answer += "第"+ ((index + 1).to_s) +"题:<br />"
|
||||
@answer += choose.answer
|
||||
@answer += "<br /><br /><br />"
|
||||
end
|
||||
else
|
||||
@answer = challenge.answer
|
||||
end
|
||||
|
||||
if challenge.shixun.status < 2 || @game.answer_open
|
||||
@viewed = 1
|
||||
else
|
||||
|
|
|
@ -251,7 +251,7 @@ class HomeworkCommonController < ApplicationController
|
|||
@homework_detail_programing.ta_proportion = 0 if @homework_detail_programing
|
||||
end
|
||||
if @homework_detail_manual.comment_status < 4
|
||||
if params[:homework_anonymous_appeal]
|
||||
if params[:homework_anonymous_comment] && params[:homework_anonymous_appeal]
|
||||
@homework.anonymous_appeal = 1
|
||||
@homework_detail_manual.appeal_time = params[:homework_appeal_time] if params[:homework_appeal_time]
|
||||
@homework_detail_manual.appeal_penalty = params[:homework_appeal_penalty] if params[:homework_appeal_penalty]
|
||||
|
@ -338,7 +338,6 @@ class HomeworkCommonController < ApplicationController
|
|||
if @homework.end_time < Time.now
|
||||
@homework.student_works.each do |student_work|
|
||||
set_shixun_final_score @homework, student_work, @homework_detail_manual.answer_open_evaluation
|
||||
student_work.save
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -700,7 +700,7 @@ end
|
|||
@courses = @courses.where(:homepage_show => params[:homepage_show].to_i)
|
||||
end
|
||||
|
||||
if params[:course_list]&& params[:course_list]!=''
|
||||
if params[:course_list] && params[:course_list] != ''
|
||||
@courses = @courses.where(:course_list_id => courselist)
|
||||
end
|
||||
|
||||
|
@ -826,6 +826,18 @@ end
|
|||
end
|
||||
end
|
||||
|
||||
# 导出excel
|
||||
def export_excel
|
||||
@course = params[:course]
|
||||
respond_to do |format|
|
||||
format.xls {
|
||||
@course = @course.reorder("#{Tracker.table_name}.position, #{Course.table_name}.id").all
|
||||
filename = "#{l(:label_course_list_xls)}.xls"
|
||||
send_data(course_list_xls(@course), :type => 'application/octet-stream', :filename => filename_for_content_disposition(filename))
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
# 0 全部;1 活动的; 2 已注册; 3 锁定
|
||||
def users
|
||||
@menu_type
|
||||
|
@ -1076,16 +1088,16 @@ end
|
|||
user_id = s_user_id & d_user_id & apply_user_id
|
||||
|
||||
if params[:research_condition] == "name"
|
||||
@users = User.where(:id => user_id).where("concat(lastname, firstname) like '%#{params[:research_contents]}%'").order("created_on desc")
|
||||
@users = User.where(:id => user_id).where("concat(lastname, firstname) like '%#{params[:research_contents]}%'").order("last_login_on desc")
|
||||
elsif params[:research_condition] == "email"
|
||||
@users = User.where(:id => user_id).where("mail like '%#{params[:research_contents]}%'").order("created_on desc")
|
||||
@users = User.where(:id => user_id).where("mail like '%#{params[:research_contents]}%'").order("last_login_on desc")
|
||||
elsif params[:research_condition] == "phone"
|
||||
@users = User.where(:id => user_id).where("phone like '%#{params[:research_contents]}%'").order("created_on desc")
|
||||
@users = User.where(:id => user_id).where("phone like '%#{params[:research_contents]}%'").order("last_login_on desc")
|
||||
elsif params[:research_condition] == "nickname"
|
||||
if params[:research_contents].blank?
|
||||
@users = User.where(:id => user_id).order("created_on desc")
|
||||
@users = User.where(:id => user_id).order("last_login_on desc")
|
||||
else
|
||||
@users = User.where(:id => user_id).where("nickname like '%#{params[:research_contents]}%'").order("created_on desc")
|
||||
@users = User.where(:id => user_id).where("nickname like '%#{params[:research_contents]}%'").order("last_login_on desc")
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -1367,4 +1379,32 @@ end
|
|||
render_404
|
||||
end
|
||||
|
||||
def course_list_xls course
|
||||
xls_report = StringIO.new
|
||||
book = Spreadsheet::Workbook.new
|
||||
sheet1 = book.create_worksheet :name => "course"
|
||||
blue = Spreadsheet::Format.new :color => :blue, :weight => :bold, :size => 10
|
||||
sheet1.row(0).default_format = blue
|
||||
sheet1.row(0).concat([l(:issue_xls_id),l(:issue_xls_tracker_id),l(:issue_xls_title),l(:issue_xls_description),l(:issue_xls_status),l(:issue_xls_assign),l(:issue_xls_priority),l(:issue_xls_author),l(:issue_xls_created_at),l(:milestone),l(:issue_xls_start),l(:issue_xls_due),l(:issue_xls_ratio)])
|
||||
count_row = 1
|
||||
issues.each do |issue|
|
||||
sheet1[count_row,0] = issue.id
|
||||
sheet1[count_row,1] = issue_tracker_change(issue.tracker_id)
|
||||
sheet1[count_row,2] = issue.subject
|
||||
sheet1[count_row,3] = (issue.description.gsub(/<\/?.*?>/,"")).html_safe
|
||||
sheet1[count_row,4] = issue_status_change(issue.status_id)
|
||||
sheet1[count_row,5] = issue.assigned_to.try(:show_name)
|
||||
sheet1[count_row,6] = issue_priority_change(issue.priority_id)
|
||||
sheet1[count_row,7] = issue.author.show_name
|
||||
sheet1[count_row,8] = issue.created_on.nil? ? issue.created_on : issue.created_on.strftime('%Y-%m-%d %H:%M:%S')
|
||||
sheet1[count_row,9] = issue.fixed_version.try(:name)
|
||||
sheet1[count_row,10] = issue.start_date.nil? ? issue.start_date : issue.start_date.strftime('%Y-%m-%d')
|
||||
sheet1[count_row,11] = issue.due_date.nil? ? issue.due_date : issue.due_date.strftime('%Y-%m-%d')
|
||||
sheet1[count_row,12] = issue_ratio_change(issue.done_ratio, issue.status_id)
|
||||
count_row += 1
|
||||
end
|
||||
book.write xls_report
|
||||
xls_report.string
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
@ -14,6 +14,10 @@ class ShixunsController < ApplicationController
|
|||
CODES = %W(2 3 4 5 6 7 8 9 A B C D E F G H J K L N M O P Q R S T U V W X Y Z)
|
||||
DCODES = %W(2 3 4 5 6 7 8 9 a b c f e f g h i j k l m n o p q r s t u v w x y z)
|
||||
|
||||
|
||||
def statistics_students
|
||||
|
||||
end
|
||||
# push代码的时候会触发gitlab hook
|
||||
def ghook
|
||||
shixun_modify_status_without_publish(@shixun, 1)
|
||||
|
@ -562,11 +566,14 @@ class ShixunsController < ApplicationController
|
|||
# end
|
||||
# @shixun.major_id = params[:major_id]
|
||||
@shixun.shixun_major_courses.destroy_all
|
||||
if CourseList.where(:name => params[:course_list].strip).count > 0
|
||||
@shixun.shixun_major_courses << ShixunMajorCourse.new(:major_id => -1, :course_list_id => CourseList.where(:name => params[:course_list].strip).first.id)
|
||||
else
|
||||
course_list = CourseList.create(:name => params[:course_list].strip, :user_id => User.current.id, :is_admin => 0)
|
||||
@shixun.shixun_major_courses << ShixunMajorCourse.new(:major_id => -1, :course_list_id => course_list.id)
|
||||
course_lists = params[:course_list].strip.split(",")
|
||||
course_lists.each do |course|
|
||||
if CourseList.where(:name => course).count > 0
|
||||
@shixun.shixun_major_courses << ShixunMajorCourse.new(:major_id => -1, :course_list_id => CourseList.where(:name => course.strip).first.id)
|
||||
else
|
||||
course_list = CourseList.create(:name => course.strip, :user_id => User.current.id, :is_admin => 0)
|
||||
@shixun.shixun_major_courses << ShixunMajorCourse.new(:major_id => -1, :course_list_id => course_list.id)
|
||||
end
|
||||
end
|
||||
params[:shixun][:is_public] == "on" ? @shixun.is_public = 1 : @shixun.is_public = 0
|
||||
ActiveRecord::Base.transaction do
|
||||
|
@ -686,9 +693,9 @@ class ShixunsController < ApplicationController
|
|||
@user = User.current
|
||||
if !params[:search].nil?
|
||||
search = "%#{params[:search].to_s.strip.downcase}%"
|
||||
@courses = @user.courses.not_deleted_not_end.where("#{Course.table_name}.name like :p",:p=>search).select{|course| @user.allowed_to?(:as_teacher,course)}
|
||||
@courses = @user.courses.not_deleted_not_end.where("#{Course.table_name}.name like :p",:p=>search).select{|course| @user.has_teacher_role(course)}
|
||||
else
|
||||
@courses = @user.courses.not_deleted_not_end.select{|course| @user.allowed_to?(:as_teacher,course)}
|
||||
@courses = @user.courses.not_deleted_not_end.select{|course| @user.has_teacher_role(course)}
|
||||
end
|
||||
@pages = Paginator.new @courses.count, 8, params['page'] || 1
|
||||
@offset ||= @pages.offset
|
||||
|
@ -718,11 +725,11 @@ class ShixunsController < ApplicationController
|
|||
homework_detail_manual.evaluation_num = 0
|
||||
homework_detail_manual.absence_penalty = 0
|
||||
homework.homework_detail_manual = homework_detail_manual
|
||||
if homework.save
|
||||
if homework.save!
|
||||
homework_detail_manual.save if homework_detail_manual
|
||||
HomeworkCommonsShixuns.create(:homework_common_id => homework.id, :shixun_id => @shixun.id)
|
||||
redirect_to setting_homework_common_path(homework, :is_new => 1)
|
||||
end
|
||||
redirect_to setting_homework_common_path(homework, :is_new => 1)
|
||||
end
|
||||
private
|
||||
# REDO: 新增类型copy的时候
|
||||
|
|
|
@ -377,11 +377,11 @@ class StudentWorkController < ApplicationController
|
|||
end
|
||||
|
||||
#开放作品 || 老师 || 超级管理员 || 禁用匿评&&作业截止&&已提交作品 显示所有列表
|
||||
if (@homework.is_open == 1 && User.current.member_of_course?(@course) && @homework.homework_detail_manual.comment_status == 6) || @is_teacher || User.current.admin?
|
||||
if (@homework.work_public && User.current.member_of_course?(@course) && @homework.homework_detail_manual.comment_status == 6) || @is_teacher || User.current.admin?
|
||||
@stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").joins(:user).where("users.id in #{student_in_group}").order("#{@order} #{@b_sort}")
|
||||
@show_all = true
|
||||
elsif User.current.member_of_course?(@course)
|
||||
if @homework.homework_detail_manual.comment_status == 1 || @homework.homework_detail_manual.comment_status == 2 #学生 && 未开启匿评 只看到自己的
|
||||
if @homework.homework_detail_manual.comment_status == 1 || @homework.homework_detail_manual.comment_status == 2 || @homework.homework_detail_manual.comment_status == 5 || @homework.homework_detail_manual.comment_status == 6 #学生 && 未开启匿评 只看到自己的
|
||||
if @homework.homework_type == 3
|
||||
my_work = @homework.student_works.where(:user_id => User.current.id)
|
||||
@stundet_works = !my_work.balnk? ? (my_work.first.group_id != 0 ? @homework.student_works.select("student_works.*,student_works.work_score as score").where(:group_id => my_work.first.group_id) : my_work) : []
|
||||
|
@ -389,16 +389,16 @@ class StudentWorkController < ApplicationController
|
|||
@stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id)
|
||||
end
|
||||
elsif @homework.homework_detail_manual.comment_status == 3 || @homework.homework_detail_manual.comment_status == 4 #学生 && 开启匿评 看到匿评列表
|
||||
my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id).first
|
||||
my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id)
|
||||
@stundet_works = my_work + User.current.student_works_evaluation_distributions.map(&:student_work).select { |work| work.homework_common_id == @homework.id}
|
||||
elsif @homework.homework_detail_manual.comment_status == 5 #学生 && 关闭匿评 未提交作品之前列表为空,提交了作品看到所有的
|
||||
my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id).first
|
||||
if !my_work || my_work.status == 0
|
||||
@stundet_works = []
|
||||
else
|
||||
@stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").joins(:user).where("users.id in #{student_in_group}").order("#{@order} #{@b_sort}")
|
||||
@show_all = true
|
||||
end
|
||||
# elsif @homework.homework_detail_manual.comment_status == 5 || @homework.homework_detail_manual.comment_status == 6 #学生 && 关闭匿评 未提交作品之前列表为空,提交了作品看到所有的
|
||||
# my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id).first
|
||||
# if !my_work || my_work.status == 0
|
||||
# @stundet_works = []
|
||||
# else
|
||||
# @stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").joins(:user).where("users.id in #{student_in_group}").order("#{@order} #{@b_sort}")
|
||||
# @show_all = true
|
||||
# end
|
||||
else
|
||||
@stundet_works = []
|
||||
end
|
||||
|
@ -408,11 +408,11 @@ class StudentWorkController < ApplicationController
|
|||
end
|
||||
|
||||
else
|
||||
if (@homework.is_open == 1 && User.current.member_of_course?(@course) && @homework.homework_detail_manual.comment_status == 6) || @is_teacher || User.current.admin?
|
||||
if (@homework.work_public && User.current.member_of_course?(@course) && @homework.homework_detail_manual.comment_status == 6) || @is_teacher || User.current.admin?
|
||||
@stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").includes(:user => {:user_extensions => []}, :project => {}, :student_works_scores => {}).order("#{@order} #{@b_sort}")
|
||||
@show_all = true
|
||||
elsif User.current.member_of_course?(@course)
|
||||
if @homework.homework_detail_manual.comment_status == 1 || @homework.homework_detail_manual.comment_status == 2 #学生 && 未开启匿评 只看到自己的
|
||||
if @homework.homework_detail_manual.comment_status == 1 || @homework.homework_detail_manual.comment_status == 2 || @homework.homework_detail_manual.comment_status == 5 || @homework.homework_detail_manual.comment_status == 6 #学生 && 未开启匿评 只看到自己的
|
||||
if @homework.homework_type == 3
|
||||
my_work = @homework.student_works.where(:user_id => User.current.id)
|
||||
@stundet_works = !my_work.blank? ? (my_work.first.group_id != 0 ? @homework.student_works.select("student_works.*,student_works.work_score as score").where(:group_id => my_work.first.group_id) : my_work) : []
|
||||
|
@ -420,16 +420,16 @@ class StudentWorkController < ApplicationController
|
|||
@stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id)
|
||||
end
|
||||
elsif @homework.homework_detail_manual.comment_status == 3 || @homework.homework_detail_manual.comment_status == 4 #学生 && 开启匿评 看到匿评列表
|
||||
my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id).first
|
||||
my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id)
|
||||
@stundet_works = my_work + User.current.student_works_evaluation_distributions.map(&:student_work).select { |work| work.homework_common_id == @homework.id}
|
||||
elsif @homework.homework_detail_manual.comment_status == 5 #学生 && 关闭匿评 未提交作品之前列表为空,提交了作品看到所有的
|
||||
my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id).first
|
||||
if !my_work || my_work.status == 0
|
||||
@stundet_works = []
|
||||
else
|
||||
@stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").order("#{@order} #{@b_sort}")
|
||||
@show_all = true
|
||||
end
|
||||
# elsif @homework.homework_detail_manual.comment_status == 5 #学生 && 关闭匿评 未提交作品之前列表为空,提交了作品看到所有的
|
||||
# my_work = @homework.student_works.select("student_works.*,student_works.work_score as score").where(:user_id => User.current.id).first
|
||||
# if !my_work || my_work.work_status == 0
|
||||
# @stundet_works = []
|
||||
# else
|
||||
# @stundet_works = @homework.student_works.select("student_works.*,student_works.work_score as score").order("#{@order} #{@b_sort}")
|
||||
# @show_all = true
|
||||
# end
|
||||
else
|
||||
@stundet_works = []
|
||||
end
|
||||
|
|
|
@ -283,7 +283,7 @@ module ApplicationHelper
|
|||
if myshixun.nil?
|
||||
0
|
||||
else
|
||||
myshixun.games.select{|game| game.status == 2 && game.answer_open == 0}.count
|
||||
myshixun.games.select{|game| game.status == 2 && !game.answer_open}.count
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -358,18 +358,23 @@ module ApplicationHelper
|
|||
day = time / 86400
|
||||
hour = time % (24*60*60) / (60*60)
|
||||
min = time % (24*60*60) % (60*60) / 60
|
||||
sec = time % (24*60*60) % (60*60) % 60
|
||||
if day < 1
|
||||
if hour < 1
|
||||
if time < 1
|
||||
time = time == 0 ? "--" : "小于1分钟"
|
||||
if min < 1
|
||||
if sec < 1
|
||||
time = "--"
|
||||
else
|
||||
time = "#{sec}秒"
|
||||
end
|
||||
else
|
||||
time = "#{min} 分钟"
|
||||
time = "#{min}分钟 #{sec}秒"
|
||||
end
|
||||
else
|
||||
time = "#{hour}小时 #{min}分"
|
||||
time = "#{hour}小时 #{min}分钟 #{sec}秒"
|
||||
end
|
||||
else
|
||||
time = "#{day}天 #{hour}小时 #{min}分"
|
||||
time = "#{day}天 #{hour}小时 #{min}分钟 #{sec}秒"
|
||||
end
|
||||
return time
|
||||
end
|
||||
|
@ -4736,6 +4741,7 @@ end
|
|||
|
||||
def get_hw_index(hw,is_teacher,type=0)
|
||||
homework_commons = hw.course.homework_commons
|
||||
Rails.logger.info("----------------------------------------------"+hw.course.to_s)
|
||||
if is_teacher
|
||||
if type != 0
|
||||
homeworks = homework_commons.where("homework_commons.homework_type = #{type}").order("created_at asc")
|
||||
|
@ -4749,7 +4755,8 @@ def get_hw_index(hw,is_teacher,type=0)
|
|||
homeworks = homework_commons.where("publish_time <= '#{Time.now}'").order("created_at asc")
|
||||
end
|
||||
end
|
||||
hw_ids = homeworks.map{|hw| hw.id} if !homeworks.empty?
|
||||
Rails.logger.info("----------------------------------------------"+homeworks.count.to_s)
|
||||
hw_ids = homeworks.map{|hw| hw.id} if !homeworks.blank?
|
||||
index = hw_ids.index(hw.id)
|
||||
return index
|
||||
end
|
||||
|
@ -5224,9 +5231,9 @@ def set_shixun_final_score homework, student_work, answer_open_evaluation
|
|||
shixun = homework.homework_commons_shixuns.shixun
|
||||
passed_count = answer_open_evaluation ? had_passed_changllenge_num(shixun, student_work.user) : had_passed_no_ans_changllenge_num(shixun, student_work.user)
|
||||
final_score =(passed_count.to_f / shixun.challenges.count) * 100
|
||||
student_work.final_score = format("%.2f",final_score.to_f)
|
||||
student_work.update_column("final_score", format("%.2f",final_score.to_f))
|
||||
score = student_work.final_score - student_work.late_penalty
|
||||
student_work.work_score = format("%.2f",(score < 0 ? 0 : score).to_f) if score
|
||||
student_work.update_column("work_score", format("%.2f",(score < 0 ? 0 : score).to_f)) if score
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#coding=utf-8
|
||||
# st 0:实践任务;1:多选任务;2:单选任务
|
||||
# st 0:实践任务;1:选择题任务
|
||||
class Challenge < ActiveRecord::Base
|
||||
default_scope :order => 'position'
|
||||
belongs_to :shixun,:touch=> true
|
||||
|
@ -8,7 +8,7 @@ class Challenge < ActiveRecord::Base
|
|||
has_many :test_sets, :dependent => :destroy
|
||||
has_many :challenge_tags, :dependent => :destroy
|
||||
has_many :games, :dependent => :destroy
|
||||
has_many :challenge_questions, :dependent => :destroy
|
||||
has_many :challenge_chooses, :dependent => :destroy
|
||||
|
||||
validates_presence_of :subject
|
||||
# validates_presence_of :score
|
||||
|
@ -28,6 +28,35 @@ class Challenge < ActiveRecord::Base
|
|||
str
|
||||
end
|
||||
|
||||
def choose_correct_num
|
||||
num = 0
|
||||
self.challenge_chooses.each do |choose|
|
||||
outputs = ChooseOutputs.where(:challenge_choose_id => choose.id).first
|
||||
if outputs.nil?
|
||||
num = nil
|
||||
else
|
||||
num += (outputs.correct ? 1 : 0)
|
||||
end
|
||||
end
|
||||
return num
|
||||
end
|
||||
|
||||
def choose_score
|
||||
score = 0
|
||||
self.challenge_chooses.each do |choose|
|
||||
score += choose.score
|
||||
end
|
||||
return score
|
||||
end
|
||||
|
||||
def choose_tags_num
|
||||
num = 0
|
||||
self.challenge_chooses.each do |choose|
|
||||
num += choose.challenge_tags.count
|
||||
end
|
||||
return num
|
||||
end
|
||||
|
||||
def next_challenge
|
||||
challenge_count = Challenge.where(:shixun_id => self.shixun_id).count
|
||||
render_404 if self.position ==challenge_count
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
class ChallengeChoose < ActiveRecord::Base
|
||||
# attr_accessible :title, :body
|
||||
# category 1 单选, 2,多选
|
||||
# standard_answer 正确答案 answer: 答题的思路
|
||||
default_scope :order => 'position'
|
||||
belongs_to :challenge
|
||||
has_many :challenge_tags, :dependent => :destroy
|
||||
has_many :challenge_questions, :dependent => :destroy
|
||||
has_one :choose_outputs, :dependent => :destroy
|
||||
|
||||
validates_presence_of :subject
|
||||
|
||||
end
|
|
@ -1,4 +1,6 @@
|
|||
class ChallengeQuestion < ActiveRecord::Base
|
||||
belongs_to :challenge
|
||||
attr_accessible :challenge_id, :option_name, :position, :right_key
|
||||
# 选择题的选项内容
|
||||
belongs_to :challenge_choose
|
||||
# right_key 选项是否是答案, position 选项的位置
|
||||
attr_accessible :challenge_choose_id, :option_name, :position, :right_key
|
||||
end
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
class ChallengeTag < ActiveRecord::Base
|
||||
attr_accessible :challenge_id, :name
|
||||
attr_accessible :challenge_id, :name, :challenge_choose_id
|
||||
belongs_to :challenge
|
||||
belongs_to :challenge_choose
|
||||
end
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
class ChooseOutputs < ActiveRecord::Base
|
||||
# attr_accessible :title, :body
|
||||
# user_id 与 challenge_choose_id 唯一确定用户此题的选项
|
||||
belongs_to :challenge_choose
|
||||
end
|
|
@ -20,7 +20,7 @@
|
|||
<p id="e_tip_in" style="margin-left: 10%" class="c_grey"></p>
|
||||
<p id="e_tips_in" style="margin-left: 10%" class="c_grey"></p>
|
||||
</li>
|
||||
<li class="clearfix">
|
||||
<li class="clearfix">
|
||||
<a href="javascript:void(0);" class="task-btn task-btn-green fr" onclick="$('#challenge_shixun_answer_update').submit();">保存</a>
|
||||
<% if @challenge.answer %>
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 3) %>" class="task-btn fr mr10" id="answer_cancel">取消</a>
|
||||
|
@ -30,7 +30,7 @@
|
|||
<script>
|
||||
answer_editormd = editormd("challenge_answer", {
|
||||
width : "89.6%",
|
||||
height : 600,
|
||||
height : 400,
|
||||
syncScrolling : "single",
|
||||
//你的lib目录的路径,我这边用JSP做测试的
|
||||
path : "/editormd/lib/",
|
||||
|
|
|
@ -0,0 +1,10 @@
|
|||
<li class="fl <%= @index.nil? ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun) %>" class="color-black">本关任务</a>
|
||||
</li>
|
||||
<% @challenge.challenge_chooses.each_with_index do |choose, index| %>
|
||||
<li class="fl <%= @index == index ? "check_nav" : "" %>">
|
||||
<a href="<%= choose_type_show_shixun_challenge_path(@challenge, :shixun_id => @shixun, :choose_id => choose.id, :index => index) %>" class="color-black" data-remote="true">
|
||||
<%= (index + 1).to_s + (choose.category == 1 ? ".单选题" : ".多选题") %>
|
||||
</a>
|
||||
</li>
|
||||
<% end %>
|
|
@ -0,0 +1,105 @@
|
|||
<div class="stage-part-2 mt20" id="">
|
||||
<ul class="nav_check_item border-bottom-orange clearfix">
|
||||
<div id="challenge_choose_tab">
|
||||
<%= render :partial => "challenges/choose_tab" %>
|
||||
</div>
|
||||
<a href="javascript:void(0)" class="fr white-btn green-btn white_bg addoption-btn">+ 多选题</a>
|
||||
<a href="javascript:void(0)" class="fr mr10 white-btn green-btn white_bg addoption-btn">+ 单选题</a>
|
||||
</ul>
|
||||
<div id="task_content" class="task-pm-box mh550 user_bg_shadow">
|
||||
<div class="panel-form" id="task_show_page">
|
||||
<div id="task_pass_show">
|
||||
<div class="clearfix mb20">
|
||||
<p class="fr">
|
||||
<% if User.current.manager_of_shixun?(@shixun) %>
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun) %>" class="shixun-task-btn task-btn-green fr" data-remote="true">编辑</a>
|
||||
<% end %>
|
||||
</p>
|
||||
</div>
|
||||
<ul>
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl">名称:</label>
|
||||
<div class="fl task-bg-grey panel-box-sizing panel-form-width-690">
|
||||
<%= @challenge.subject %>
|
||||
</div>
|
||||
</li>
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl"><span class="c_red mr5">*</span>过关任务:</label>
|
||||
<div class="fl task-bg-grey panel-box-sizing panel-form-width-690 new_li" id="challenge_task_pass_show" style="width: 90%;background: #fff!important;">
|
||||
<textarea style="display:none;"><%= @challenge.task_pass %></textarea>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="set_content" class="task-pm-box mh550 user_bg_shadow undis">
|
||||
<%#= render :partial => "single_or_multiple_question" %>
|
||||
</div>
|
||||
|
||||
<%#= render :partial => 'single_or_multiple_question_show'%>
|
||||
</div>
|
||||
<script>
|
||||
editormd.loadKaTeX(function() {
|
||||
var taskPassMD = editormd.markdownToHTML("challenge_task_pass_show", {
|
||||
htmlDecode: "style,script,iframe", // you can filter tags decode
|
||||
taskList: true,
|
||||
tex: true, // 默认不解析
|
||||
flowChart: true, // 默认不解析
|
||||
sequenceDiagram: true // 默认不解析
|
||||
});
|
||||
});
|
||||
//添加单选、多选tab
|
||||
$(".addoption-btn").on("click",function(){
|
||||
var length= $(".stage-part-2").find(".nav_check_item li").length;
|
||||
if(length<11){
|
||||
var title=$(this).html();
|
||||
var category = title.indexOf("多选")>0 ? 2 : 1;
|
||||
if(title.indexOf("多选")>0){//多选
|
||||
title="多选题";
|
||||
}else{
|
||||
title="单选题";
|
||||
}
|
||||
var li_con=length+".<span>"+title+"</span>";
|
||||
var html="<li class=\"fl check_nav\"><a href=\"javascript:void(0)\" class=\"color-black\">"+li_con+"</a></li>";
|
||||
$(".stage-part-2").find(".nav_check_item li").removeClass("check_nav");
|
||||
$(".stage-part-2").find(".nav_check_item li").eq(length-1).after(html);
|
||||
$.ajax({
|
||||
url: "<%= add_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun) %>",
|
||||
dateType: "script",
|
||||
data: {category: category, position: length},
|
||||
success: function(){
|
||||
}
|
||||
})
|
||||
}
|
||||
// editor_tigan();
|
||||
});
|
||||
//删除单选、多选tab
|
||||
$(".deloption-btn").on("click",function(){
|
||||
var index=0;
|
||||
for(var i=1;i<$(".stage-part-2").find(".nav_check_item li").length;i++){
|
||||
var length=$(".stage-part-2").find(".nav_check_item li").length;
|
||||
var item=$(".stage-part-2").find(".nav_check_item li");
|
||||
if(item.eq(i).hasClass("check_nav")){
|
||||
if(length>1){
|
||||
item.eq(0).addClass("check_nav");
|
||||
item.eq(i).remove();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
for(var i=1;i<$(".stage-part-2").find(".nav_check_item li").length;i++){
|
||||
var item=$(".stage-part-2").find(".nav_check_item li");
|
||||
item.eq(i).html(i+".<span>"+item.eq(i).find("span").html()+"</span>");
|
||||
}
|
||||
})
|
||||
//第二个ul tab的切换事件
|
||||
$(".stage-part-2").find(".nav_check_item li a").live("click",function(){
|
||||
if($(".nav_check_item li").length>1){
|
||||
$(".nav_check_item li").removeClass("check_nav");
|
||||
$(this).parent().addClass("check_nav");
|
||||
}
|
||||
})
|
||||
|
||||
</script>
|
|
@ -6,10 +6,11 @@
|
|||
<% end %>
|
||||
<% if User.current.manager_of_shixun?(@shixun) && @shixun.status == 0 %>
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 0) %>" class="shixun-task-btn task-btn-green fr mt5">+实践任务</a>
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 1) %>" class="shixun-task-btn task-btn-green fr mr10 mt5">+多选任务</a>
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 2) %>" class="shixun-task-btn task-btn-green fr mr10 mt5">+单选任务</a>
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 1) %>" class="shixun-task-btn task-btn-green fr mr10 mt5">+选择题任务</a>
|
||||
<!-- <a href="<%#= new_shixun_challenge_path(@shixun, :st => 2) %>" class="shixun-task-btn task-btn-green fr mr10 mt5">+单选任务</a>-->
|
||||
<!--<a href="<%#= new_shixun_challenge_path(@shixun, :st => 0) %>" class="shixun-task-btn task-btn-green fr mr5" style="margin: 5px 0;">新建阶段</a>-->
|
||||
<% end %> </div>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="panel-list shixun-panel-list">
|
||||
<% @challenges.each_with_index do |challenge, index| -%>
|
||||
<div class="clearfix shixun-panel-inner" id="shixun_index_<%= index %>">
|
||||
|
@ -17,10 +18,8 @@
|
|||
<span class="panel-inner-icon mr10 fl mt5">
|
||||
<% if challenge.st == 0 %>
|
||||
<i class="fa fa-code font-16 color_white" data-tip-down="实践任务"></i>
|
||||
<% elsif challenge.st == 1 %>
|
||||
<% else %>
|
||||
<i class="fa fa-th-list color_white" data-tip-down="多选任务"></i>
|
||||
<% elsif challenge.st == 2 %>
|
||||
<img src="/images/bigdata/singel.png" style="margin-bottom: 3px" data-tip-down="单选任务">
|
||||
<% end%>
|
||||
</span>
|
||||
<!-- <i class="fa fa-dot-circle-o font-18 color-green mr10"></i>-->
|
||||
|
|
|
@ -27,7 +27,16 @@
|
|||
输入输出
|
||||
</div>
|
||||
</li>
|
||||
<li class="clearfix">
|
||||
<li class="clearfix" style="position:relative;">
|
||||
<div class="popup_tip_box fontGrey2" style="right:-315px; top:68px;position: absolute">
|
||||
<em></em>
|
||||
<span></span>
|
||||
<p class="font-12">
|
||||
提交:<br/>
|
||||
1、每个黑色小方块代表一个空格,<br/>
|
||||
2、向下的黑色箭头代表测试集末尾的换行。
|
||||
</p>
|
||||
</div>
|
||||
<label class="panel-form-label fl">测试集设置:</label>
|
||||
<ul class="fl task-bg-grey panel-box-sizing panel-form-width-690">
|
||||
<% if @test_sets.count > 0 %>
|
||||
|
@ -39,8 +48,8 @@
|
|||
<i class="fa fa-lock font-grey ml5" ></i>
|
||||
<% end %>
|
||||
</p>
|
||||
<div class="clearfix"><span class="fl fb">输入:</span><p class="fl"><%= test.input.gsub("\r\n", "<br />").html_safe unless test.input.blank? %></p></div>
|
||||
<div class="clearfix"><span class="fl fb">输出:</span><p class="fl"><%= test.output.gsub("\r\n", "<br />").html_safe unless test.output.blank? %></div>
|
||||
<div class="clearfix"><span class="fl fb">输入:</span><p class="fl"><%= test.input.gsub(" ", "<span class=\"empty\"></span>").gsub(/\r\n$/, "<br/><i class=\"fa fa-level-down\" aria-hidden=\"true\"></i>").html_safe unless test.input.blank? %></p></div>
|
||||
<div class="clearfix"><span class="fl fb">输出:</span><p class="fl"><%= test.output.gsub(" ", "<span class=\"empty\"></span>").gsub(/\r\n$/, "<br/><i class=\"fa fa-level-down\" aria-hidden=\"true\"></i>").html_safe unless test.output.blank? %></div>
|
||||
</li>
|
||||
<% end %>
|
||||
<% else %>
|
||||
|
|
|
@ -23,30 +23,32 @@
|
|||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<% if @challenge.st == 1 %>
|
||||
<ul id="select_more">
|
||||
<% @challenge.challenge_questions.each_with_index do |question, index| %>
|
||||
<li class="clearfix mb10">
|
||||
<label class="panel-form-label fl <%= question.right_key ? 'color-orange03' : '' %>"><span class="mr10"><%= (question.position+ 65).chr %>.</span></label>
|
||||
<div class="fl panel-box-sizing panel-form-width-690 task-bg-grey break_full_word">
|
||||
<!--<input type="checkbox" name="select_more[]" value="" class="ml-3 mr5 magic-checkbox" >-->
|
||||
<label><%= question.option_name %></label>
|
||||
</div>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% elsif @challenge.st == 2 %>
|
||||
<ul id="select_single">
|
||||
<% @challenge.challenge_questions.each_with_index do |question, index| %>
|
||||
<li class="clearfix mb10">
|
||||
<label class="panel-form-label fl <%= question.right_key ? 'color-orange03' : '' %>"><span class="mr10"><%= (question.position+ 65).chr %>.</span></label>
|
||||
<div class="fl panel-box-sizing panel-form-width-690 task-bg-grey break_full_word">
|
||||
<!--<input name="select_single[]" value="" type="radio" class="ml-3 mr5 magic-radio" >-->
|
||||
<label><%= question.option_name %></label>
|
||||
</div>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% if false%>
|
||||
<% if @challenge.st == 1 %>
|
||||
<ul id="select_more">
|
||||
<% @challenge.challenge_questions.each_with_index do |question, index| %>
|
||||
<li class="clearfix mb10">
|
||||
<label class="panel-form-label fl <%= question.right_key ? 'color-orange03' : '' %>"><span class="mr10"><%= (question.position+ 65).chr %>.</span></label>
|
||||
<div class="fl panel-box-sizing panel-form-width-690 task-bg-grey break_full_word">
|
||||
<!--<input type="checkbox" name="select_more[]" value="" class="ml-3 mr5 magic-checkbox" >-->
|
||||
<label><%= question.option_name %></label>
|
||||
</div>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% elsif @challenge.st == 2 %>
|
||||
<ul id="select_single">
|
||||
<% @challenge.challenge_questions.each_with_index do |question, index| %>
|
||||
<li class="clearfix mb10">
|
||||
<label class="panel-form-label fl <%= question.right_key ? 'color-orange03' : '' %>"><span class="mr10"><%= (question.position+ 65).chr %>.</span></label>
|
||||
<div class="fl panel-box-sizing panel-form-width-690 task-bg-grey break_full_word">
|
||||
<!--<input name="select_single[]" value="" type="radio" class="ml-3 mr5 magic-radio" >-->
|
||||
<label><%= question.option_name %></label>
|
||||
</div>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if @challenge.subject.blank? || !@editor.blank? %>
|
||||
|
|
|
@ -190,8 +190,5 @@
|
|||
$("#challenge_execfile_path").hide();
|
||||
});
|
||||
|
||||
/* $("#evaluating_cancel").click(function(){
|
||||
$("#evaluating_edit").hide();
|
||||
$("#evaluating_show").show();
|
||||
})*/
|
||||
|
||||
</script>
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
<span style="display: none" class="c_red ml90" id="new_shixun_score">分值设定不能为空</span>
|
||||
</li>
|
||||
|
||||
<div class="prop-notice-info mb10 ml95">
|
||||
<div class="prop-notice-info mb10" style="margin-left: 10%">
|
||||
<ol>
|
||||
<% if @st == 0 %>
|
||||
<li>如果学员查看了参考答案,则不能得到相应的经验值</li>
|
||||
|
|
|
@ -0,0 +1,507 @@
|
|||
<%= stylesheet_link_tag '/editormd/css/editormd','/editormd/css/editormd.min.css' %>
|
||||
<%= javascript_include_tag '/editormd/editormd.min.js','/editormd/examples/js/jquery.min.js' %>
|
||||
<script id="t:set-option-list" type="text/html">
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @category %>);" name="option_span" title="点击设置答案">A</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
</script>
|
||||
<%= form_for("", :url => "", :html => {:id => 'challenge_choose_update'}) do |f| %>
|
||||
<%#= form_tag(url_for(new_or_edit_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :type => @type, :position => @position)), :remote => true, :id => 'challenge_choose_update') do |f| %>
|
||||
<li class="clearfix pt30 pr30">
|
||||
<a href="javascript:void(0);" class="task-btn task-btn-green fr" >编辑</a>
|
||||
<a href="javascript:void(0)" class="task-btn fr mr10 deloption-btn" id="skill_cancel">删除</a>
|
||||
</li>
|
||||
<div class="panel-form">
|
||||
<div id="shixun_form">
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl"><span class="c_red mr5">*</span>题干:</label>
|
||||
<div id="challenge_choose_subject" class="fl task-bg-grey panel-box-sizing panel-form-width-690 new_li">
|
||||
<textarea name="choose[subject]"><%= @challenge_choose.try(:subject) %></textarea>
|
||||
</div>
|
||||
<span style="display: none;margin-left: 10%;" class="c_red" id="new_shixun_name">题干不能为空</span>
|
||||
</li>
|
||||
<% if @challenge_choose.blank? %>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @category %>);" name="option_span" title="点击设置答案">A</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @category %>);" name="option_span" title="点击设置答案">B</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @category %>);" name="option_span" title="点击设置答案">C</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @category %>);" name="option_span" title="点击设置答案">D</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<% else%>
|
||||
<% @challenge_choose.challenge_questions.each_with_index do |question, index| %>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice <%= question.right_key ? "check-option-bg" : "" %>" onclick="selectchoice(this, <%= @challenge_choose.category %>);" name="option_span" title="点击设置答案"><%= (question.try(:position) + 65).chr %></span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"><%= question.try(:option_name) %></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<ul>
|
||||
<li class="clearfix mb10" >
|
||||
<label class="panel-form-label fl"><span class="add-option-item fr mr10 color-grey border-dash-orange" name="option_span"><%= @challenge_choose.blank? ? "E" : (@challenge_choose.challenge_questions.count + 65).chr %></span></label>
|
||||
<div class="fl panel-box-sizing add-option-input border-dash-orange"><a title="新增" class="option_icon_add">新增选项</a></div>
|
||||
</li>
|
||||
<span style="display: none" class="c_red ml95" id="choice_error_tip"></span>
|
||||
<li class="clearfix" ><label class="fl" style="margin-left: 10%">温馨提示:点击选项,可以直接设置答案</label><label class="fr">标准答案:<span id="current-option" class="color-orange"><%= @challenge_choose.blank? ? "请点击正确选项" : @challenge_choose.try(:standard_answer) %></span></label></li>
|
||||
<input type="hidden" name="standard_answer" value="<%= @challenge_choose.try(:standard_answer) %>">
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<p class="bor-bottom-greyE"></p>
|
||||
<!--参考答案-->
|
||||
<li class="clearfix" style="line-height:1.9;">
|
||||
<label class=" panel-form-label fl"> 参考答案:</label>
|
||||
<div id="challenge_choose_answer" class="new_li">
|
||||
<textarea name="choose[answer]"><%= @challenge_choose.try(:answer) %></textarea>
|
||||
</div>
|
||||
<p id="e_tip_in" style="margin-left: 10%" class="c_grey"></p>
|
||||
<p id="e_tips_in" style="margin-left: 10%" class="c_grey"></p>
|
||||
</li>
|
||||
<p class="bor-bottom-greyE"></p>
|
||||
<!--经验值设置-->
|
||||
<div class="panel-form">
|
||||
<div id="shixun_form">
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl"><span class="c_red mr5">*</span>难易度:</label>
|
||||
<span class="fl mt3 mr10">
|
||||
<input id="challenge_difficulty_1" class="magic-radio" name="challenge[difficulty]" type="radio" value="1" <%= ((@challenge_choose.try(:difficult) == 1 || @challenge_choose.nil?) ? "checked" : "")%> >
|
||||
<label for="challenge_difficulty_1">简单</label>
|
||||
</span>
|
||||
<span class="fl mt3 mr10">
|
||||
<input id="challenge_difficulty_2" class="magic-radio" name="challenge[difficulty]" type="radio" value="2" <%= (@challenge_choose.try(:difficult)== 2 ? "checked" : "")%> >
|
||||
<label for="challenge_difficulty_2">中等</label>
|
||||
</span>
|
||||
<span class="fl mt3">
|
||||
<input id="challenge_difficulty_3" class="magic-radio" name="challenge[difficulty]" type="radio" value="3" <%= (@challenge_choose.try(:difficult) == 3 ? "checked" : "")%> >
|
||||
<label for="challenge_difficulty_3">困难</label>
|
||||
</span>
|
||||
</li>
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl"><span class="c_red mr5">*</span>奖励经验值:</label>
|
||||
<%= select_tag :challenge_score, options_for_select([100, 200]), :name => 'challenge[score]', :class => " fl", :style => "height: 40px; width:170px;" %>
|
||||
<div class="clear"></div>
|
||||
<span style="display: none" class="c_red ml90" id="new_shixun_score">分值设定不能为空</span>
|
||||
</li>
|
||||
|
||||
<div class="prop-notice-info mb10" style="margin-left: 10%">
|
||||
<ol>
|
||||
<li>如果学员答题错误,则不能得到相应的经验值</li>
|
||||
<li>如果学员成功得到经验值,那么将同时获得等值的金币奖励,如:+10经验值、+10金币</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<p class="bor-bottom-greyE"></p>
|
||||
<!--技能标签-->
|
||||
<div class="panel-form">
|
||||
<div id="shixun_form">
|
||||
<li class="clearfix" style="margin-bottom: 0;">
|
||||
<label class=" panel-form-label fl"> 技能标签:</label>
|
||||
<div class="fl task-bd-grey">
|
||||
<% unless @challenge_choose.blank? %>
|
||||
<% @challenge_choose.challenge_tags.each do |tag| %>
|
||||
<div class="task-tag tag-grey mt5 mr10 fl">
|
||||
<button data-dismiss="alert" class="close fr mt3 ml5" type="button" onclick="close_tag(this)">×</button>
|
||||
<input class='knowledge_frame' name='knowledge[input][]' value="<%= tag.try(:name)%>" />
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<div class="task-tag tag-grey mt5 mr10 fl" id="add_shixun_skill">
|
||||
<button data-dismiss="alert" class="close fr mt3 ml5" type="button" onclick="$('#add_shixun_skill').slideToggle();">×</button>
|
||||
<input type="text" class="task-tag-input" onblur="add_tag();" id="shixun_skill_input" placeholder="请输入技能标签" />
|
||||
</div>
|
||||
<a href="javascript:void(0);" onclick="$('#add_shixun_skill').slideToggle();" id="add_knowledge" style="color: #627bfd;float: left;margin-top: 5px">+添加</a>
|
||||
</div>
|
||||
</li>
|
||||
<p class="color-red" style="height: 25px;margin-left: 10%"><span id="stage_name_notice" style="display: none;"><i class="fa fa-exclamation-circle color-red mr5"></i>技能标签不能为空</span></p>
|
||||
<div class="prop-notice-info mb10" style="margin-left: 10%">
|
||||
<ol>
|
||||
<li>学员答题正确将获得技能,否则不能获得技能</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<li class="clearfix pr30 pb30">
|
||||
<a href="javascript:void(0);" class="task-btn task-btn-green fr" onclick="challenge_choose_update(<%= @category %>, '<%= @challenge_choose.blank? ? "new" : 'edit' %>')">保存</a>
|
||||
<a href="javascript:void(0)" class="task-btn fr mr10" id="skill_cancel">取消</a>
|
||||
</li>
|
||||
<% end %>
|
||||
<script>
|
||||
subject_editormd = editormd("challenge_choose_subject", {
|
||||
width : "89.6%",
|
||||
height : 400,
|
||||
syncScrolling : "single",
|
||||
//你的lib目录的路径,我这边用JSP做测试的
|
||||
path : "/editormd/lib/",
|
||||
tex : true,
|
||||
autoFocus: false,
|
||||
toolbarIcons : function() {
|
||||
// Or return editormd.toolbarModes[name]; // full, simple, mini
|
||||
// Using "||" set icons align right.
|
||||
return ["bold", "italic", "|", "list-ul", "list-ol", "|", "code", "code-block", "|", "testIcon", "testIcon1", '|', "image", "table", '|', "watch", "clear" ]
|
||||
},
|
||||
toolbarCustomIcons : {
|
||||
testIcon : "<a type=\"inline\" class=\"latex\" ><div class='zbg'></div></a>",
|
||||
testIcon1 : "<a type=\"latex\" class=\"latex\" ><div class='zbg_latex'></div></a>"
|
||||
},
|
||||
//这个配置在simple.html中并没有,但是为了能够提交表单,使用这个配置可以让构造出来的HTML代码直接在第二个隐藏的textarea域中,方便post提交表单。
|
||||
saveHTMLToTextarea : true,
|
||||
// 用于增加自定义工具栏的功能,可以直接插入HTML标签,不使用默认的元素创建图标
|
||||
dialogMaskOpacity : 0.6,
|
||||
placeholder: "请输入选择题的题干内容" ,
|
||||
imageUpload : true,
|
||||
imageFormats : ["jpg", "jpeg", "gif", "png", "bmp", "webp", "JPG", "JPEG", "GIF", "PNG", "BMP", "WEBP"],
|
||||
imageUploadURL : "<%= upload_with_markdown_path(:container_id => @shixun.id, :container_type => @shixun.class) %>"//url
|
||||
});
|
||||
|
||||
choose_answer_editormd = editormd("challenge_choose_answer", {
|
||||
width : "89.6%",
|
||||
height : 400,
|
||||
syncScrolling : "single",
|
||||
//你的lib目录的路径,我这边用JSP做测试的
|
||||
path : "/editormd/lib/",
|
||||
tex : true,
|
||||
autoFocus: false,
|
||||
toolbarIcons : function() {
|
||||
// Or return editormd.toolbarModes[name]; // full, simple, mini
|
||||
// Using "||" set icons align right.
|
||||
return ["bold", "italic", "|", "list-ul", "list-ol", "|", "code", "code-block", "|", "testIcon", "testIcon1", '|', "image", "table", '|', "watch", "clear" ]
|
||||
},
|
||||
toolbarCustomIcons : {
|
||||
testIcon : "<a type=\"inline\" class=\"latex\" ><div class='zbg'></div></a>",
|
||||
testIcon1 : "<a type=\"latex\" class=\"latex\" ><div class='zbg_latex'></div></a>"
|
||||
},
|
||||
//这个配置在simple.html中并没有,但是为了能够提交表单,使用这个配置可以让构造出来的HTML代码直接在第二个隐藏的textarea域中,方便post提交表单。
|
||||
saveHTMLToTextarea : true,
|
||||
// 用于增加自定义工具栏的功能,可以直接插入HTML标签,不使用默认的元素创建图标
|
||||
dialogMaskOpacity : 0.6,
|
||||
placeholder: "请输入各个选项的具体解析或其他相关信息",
|
||||
imageUpload : true,
|
||||
imageFormats : ["jpg", "jpeg", "gif", "png", "bmp", "webp", "JPG", "JPEG", "GIF", "PNG", "BMP", "WEBP"],
|
||||
imageUploadURL : "<%= upload_with_markdown_path(:container_id => @shixun.id, :container_type => @shixun.class) %>"//url
|
||||
});
|
||||
//技能标签
|
||||
var SnSkill = $(".knowledge_frame").length;
|
||||
function add_tag(){
|
||||
var num = $(".task-bd-grey").children('div').length;
|
||||
var val = $(".task-tag-input").val().trim();
|
||||
if (val != ""){
|
||||
testLength = $(".task-tag-input").val().trim().length;
|
||||
$("#add_shixun_skill").before("<div class='task-tag tag-grey mt5 mr10 fl' id='knowledge_" + num + "'>" +
|
||||
"<button data-dismiss='alert' class='close fr mt3 ml5' type='button' onclick='close_tag(this)'>×</button>" +
|
||||
"<input style='width:"+ testLength*12 +"px' class='knowledge_frame' name='knowledge[input][]' value='" + val +"'>" +
|
||||
" </div>");
|
||||
$(".task-tag-input").attr("value","");
|
||||
}
|
||||
$("#shixun_skill_input").val("");
|
||||
$("#add_shixun_skill").hide();
|
||||
var nSkill = $(".knowledge_frame");
|
||||
console.log(nSkill.length);
|
||||
if (nSkill.length > 0){
|
||||
//$("#challenge_skill_update").submit(); //当增加或者保存技能标签以后执行保存操作
|
||||
}else{
|
||||
$("#stage_name_notice").show();
|
||||
}
|
||||
}
|
||||
|
||||
function close_tag(thisObj){
|
||||
// 获取父节点的id
|
||||
var obj = $(thisObj).parent();
|
||||
$(obj).remove();
|
||||
//$("#challenge_skill_update").submit();
|
||||
}
|
||||
|
||||
|
||||
$(function(){
|
||||
var bt = baidu.template;
|
||||
bt.LEFT_DELIMITER = '<!';
|
||||
bt.RIGHT_DELIMITER = '!>';
|
||||
$(".option_icon_add").on('click', function () {
|
||||
var html = bt('t:set-option-list', null);
|
||||
$(this).parent().parent('.clearfix').before(html);
|
||||
var inputs = document.getElementsByName("question[cnt][]");
|
||||
var inputs_spans = document.getElementsByName("option_span");
|
||||
for (var j = 0; j < inputs_spans.length; j++) {
|
||||
if(j >= 0 && j <= 26){
|
||||
$(inputs_spans[j]).html(String.fromCharCode(65 + j));
|
||||
}
|
||||
}
|
||||
for (var i = 0; i < inputs.length; i++) {
|
||||
autoTextarea(inputs[i], 0, 140);
|
||||
}
|
||||
$(inputs[inputs.length - 1]).focus();
|
||||
});
|
||||
$(".option_icon_add").on('click', function () {
|
||||
$(this).parent('.clearfix').remove();
|
||||
var inputs_spans = document.getElementsByName("option_span");
|
||||
for (var j = 0; j < inputs_spans.length; j++) {
|
||||
if(j >= 0 && j <= 26){
|
||||
if(j >= 0 && j <= 26){
|
||||
$(inputs_spans[j]).html(String.fromCharCode(65 + j));
|
||||
}
|
||||
}
|
||||
}
|
||||
$("#current-option").html("");
|
||||
if($(".check-option-bg").length>0){
|
||||
for(var i=0;i<$(".check-option-bg").length;i++){
|
||||
$("#current-option").html($("#current-option").html()+$(".check-option-bg").eq(i).html());
|
||||
}
|
||||
}else{
|
||||
$("#current-option").html("请点击正确选项");
|
||||
}
|
||||
});
|
||||
$("#shixun_form").on('click', 'a.option_icon_remove', function () {
|
||||
$(this).parent('.clearfix').remove();
|
||||
var inputs_spans = document.getElementsByName("option_span");
|
||||
for (var j = 0; j < inputs_spans.length; j++) {
|
||||
if(j >= 0 && j <= 26){
|
||||
if(j >= 0 && j <= 26){
|
||||
$(inputs_spans[j]).html(String.fromCharCode(65 + j));
|
||||
}
|
||||
}
|
||||
}
|
||||
$("#current-option").html("");
|
||||
if($(".check-option-bg").length>0){
|
||||
for(var i=0;i<$(".check-option-bg").length;i++){
|
||||
$("#current-option").html($("#current-option").html()+$(".check-option-bg").eq(i).html());
|
||||
}
|
||||
}else{
|
||||
$("#current-option").html("请点击正确选项");
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
//设置选项答案
|
||||
function selectchoice(item, st){
|
||||
//判断是否选中,如果选中,再次点击的时候取消选中
|
||||
if($(item).hasClass('check-option-bg')){
|
||||
$(item).removeClass('check-option-bg');
|
||||
}else{
|
||||
if(st == 1){
|
||||
//单选
|
||||
$(".select-choice").removeClass('check-option-bg');
|
||||
$(item).addClass('check-option-bg');
|
||||
}else{
|
||||
//多选
|
||||
$(item).addClass('check-option-bg');
|
||||
}
|
||||
}
|
||||
$("#current-option").html("");
|
||||
if($(".check-option-bg").length>0){
|
||||
for(var i=0;i<$(".check-option-bg").length;i++){
|
||||
$("#current-option").html($("#current-option").html()+$(".check-option-bg").eq(i).html());
|
||||
$("input[name='standard_answer']").val($("#current-option").html())
|
||||
}
|
||||
}else{
|
||||
$("#current-option").html("请点击正确选项");
|
||||
}
|
||||
}
|
||||
// 判断选择题的答案
|
||||
function set_choice_answer(){
|
||||
var answer = document.getElementsByName("choice[answer][]");
|
||||
var choice = document.getElementsByName("option_span");
|
||||
for(var o = 0; o < choice.length; o++){
|
||||
if($(choice[o]).hasClass("check-option-bg")){
|
||||
$(answer[o]).val(String.fromCharCode(65 + o));
|
||||
}else{
|
||||
$(answer[o]).val(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 判断选择题内容是否为空
|
||||
function judge_choice_contents(){
|
||||
var answer = document.getElementsByName("choice[answer][]");
|
||||
var contents = document.getElementsByName("question[cnt][]");
|
||||
var lens = contents.length;
|
||||
for(var i = 0; i < lens; i++){
|
||||
if($(contents[i]).val().trim() == ""){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// 判断选择题选择答案的个数
|
||||
function judge_choice_answer(){
|
||||
var answer = document.getElementsByName("choice[answer][]");
|
||||
var lens = answer.length;
|
||||
var num = 0;
|
||||
for(var i= 0; i < lens; i++){
|
||||
if($(answer[i]).val() != "0"){
|
||||
num += 1;
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
// 选择题选项的个数
|
||||
function choice_num(){
|
||||
var answer = document.getElementsByName("choice[answer][]");
|
||||
var lens = answer.length;
|
||||
return lens;
|
||||
}
|
||||
// 根据难易程度设置不同的奖励经验值(适用新建与编辑模式)
|
||||
var list = $('input:radio[name="challenge[difficulty]"]:checked').val(); // 获取select的索引值
|
||||
var index = parseInt(<%= @st == 0 ? 1 : 10 %>); // 单选 与 多选分数系数
|
||||
if(list == 1){
|
||||
$("#challenge_score").empty();
|
||||
for(var i = 100; i <= 200; i += 100){
|
||||
$("#challenge_score").append("<option value="+ i/index + ">"+ i/index +"</option>");
|
||||
}
|
||||
}else if(list == 2){
|
||||
$("#challenge_score").empty();
|
||||
for(var i = 300; i <= 600; i += 100){
|
||||
$("#challenge_score").append("<option value="+ i/index + ">"+ i/index +"</option>");
|
||||
}
|
||||
}else if(list == 3){
|
||||
$("#challenge_score").empty();
|
||||
for(var i= 700; i <= 1000; i += 100){
|
||||
$("#challenge_score").append("<option value="+ i/index + ">"+ i/index +"</option>");
|
||||
}
|
||||
}
|
||||
$("#challenge_score").find("option[value='<%= @challenge.score %>']").attr("selected",true); // 设置option默认值
|
||||
$("#challenge_difficulty_1").click(function(){
|
||||
$("#challenge_score").empty();
|
||||
for(var i = 100; i <= 200; i += 100){
|
||||
$("#challenge_score").append("<option value="+ i/index + ">"+ i/index +"</option>");
|
||||
}
|
||||
});
|
||||
$("#challenge_difficulty_2").click(function(){
|
||||
$("#challenge_score").empty();
|
||||
for(var i = 300; i <= 600; i += 100){
|
||||
$("#challenge_score").append("<option value="+ i/index + ">"+ i/index +"</option>");
|
||||
}
|
||||
});
|
||||
$("#challenge_difficulty_3").click(function(){
|
||||
$("#challenge_score").empty();
|
||||
for(var i= 700; i <= 1000; i += 100){
|
||||
$("#challenge_score").append("<option value="+ i/index + ">"+ i/index +"</option>");
|
||||
}
|
||||
});
|
||||
/* function challenge_score_update(){
|
||||
if($("#challenge_score").val().trim()==""){
|
||||
$("#challenge_score").focus();
|
||||
$("#new_shixun_score").show();
|
||||
}else{
|
||||
$('#challenge_score_update').submit();
|
||||
}
|
||||
}*/
|
||||
|
||||
$("#score_cancel").click(function(){
|
||||
$("#scoring_edit").hide();
|
||||
$("#scroe_show").show();
|
||||
});
|
||||
|
||||
function challenge_choose_update(st, action){
|
||||
set_choice_answer();
|
||||
var error = $("#choice_error_tip");
|
||||
if($('#challenge_choose_subject textarea').val().trim() == ""){
|
||||
$("#challenge_choose_subject textarea").focus();
|
||||
$("#new_shixun_name").show();
|
||||
}else if(judge_choice_contents()){
|
||||
error.html("选项不能为空").show();
|
||||
}else{
|
||||
if(st == "1"){
|
||||
if(judge_choice_contents()) {
|
||||
error.html("选项内容不能为空").show();
|
||||
}else if(choice_num() < 2){
|
||||
error.html("单选题选项不能少于2个").show();
|
||||
}else if(judge_choice_answer() == 0){
|
||||
error.html("请设置答案").show();
|
||||
}else{
|
||||
if(action == "new"){
|
||||
$.ajax({
|
||||
url: "<%= new_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :category => @category, :position => @position) %>",
|
||||
data: $("#challenge_choose_update").serialize(),
|
||||
type: 'POST',
|
||||
dataType: "script",
|
||||
success: function(){
|
||||
|
||||
}
|
||||
});
|
||||
}else{
|
||||
$.ajax({
|
||||
url: "<%= update_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :choose_id => @challenge_choose.try(:id), :index => @position ) %>",
|
||||
data: $("#challenge_choose_update").serialize(),
|
||||
type: 'POST',
|
||||
dataType: "script",
|
||||
success: function(){
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}else if(st == "2"){
|
||||
if(judge_choice_contents()) {
|
||||
error.html("选项内容不能为空").show();
|
||||
}else if(choice_num() < 3){
|
||||
error.html("多选题选项不能少于3个").show();
|
||||
}else if(judge_choice_answer() < 2){
|
||||
error.html("答案不能少于2个").show();
|
||||
}else{
|
||||
if(action == "new"){
|
||||
$.ajax({
|
||||
url: "<%= new_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :category => @category, :position => @position) %>",
|
||||
data: $("#challenge_choose_update").serialize(),
|
||||
type: 'POST',
|
||||
dataType: "script",
|
||||
success: function(){
|
||||
}
|
||||
});
|
||||
}else{
|
||||
$.ajax({
|
||||
url: "<%= update_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :choose_id => @challenge_choose.try(:id), :index => @position) %>",
|
||||
data: $("#challenge_choose_update").serialize(),
|
||||
type: 'POST',
|
||||
dataType: "script",
|
||||
success: function(){
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(action == "new"){
|
||||
$.ajax({
|
||||
url: "<%= new_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :category => @category, :position => @position) %>",
|
||||
data: $("#challenge_choose_update").serialize(),
|
||||
type: 'POST',
|
||||
dataType: "script",
|
||||
success: function(){
|
||||
}
|
||||
});
|
||||
}else{
|
||||
$.ajax({
|
||||
url: "<%= update_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :choose_id => @challenge_choose.try(:id), :index => @position) %>",
|
||||
data: $("#challenge_choose_update").serialize(),
|
||||
type: 'POST',
|
||||
dataType: "script",
|
||||
success: function(){
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
|
@ -0,0 +1,109 @@
|
|||
<div class="white_bg">
|
||||
<div class="panel-form">
|
||||
<li class="clearfix pr30">
|
||||
<a href="<%= edit_choose_question_shixun_challenge_path(@challenge, :shixun_id => @shixun, :choose_id => @challenge_choose.id, :index => @index) %>" data-remote="true" class="task-btn task-btn-green fr">编辑</a>
|
||||
<a href="<%= destroy_challenge_choose_shixun_challenge_path(@challenge, :shixun_id => @shixun, :choose_id => @challenge_choose.id) %>" data-method="delete" class="task-btn fr mr10 deloption-btn">删除</a>
|
||||
</li>
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl">题干: </label>
|
||||
<div class="fl panel-box-sizing panel-form-width-690 new_li white_bg bor-grey-e" id="challenge_choose_subject_show" style="width: 90%;">
|
||||
<textarea name="choose[subject]"><%= @challenge_choose.subject %></textarea>
|
||||
</div>
|
||||
</li>
|
||||
<% @challenge_choose.challenge_questions.each_with_index do |option, index| %>
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl <%= option.right_key ? 'color-orange03' : '' %>"><%= (option.position+ 65).chr %>: </label>
|
||||
<div class="fl task-bg-grey panel-box-sizing panel-form-width-690 color-grey3">
|
||||
<%= option.option_name %>
|
||||
</div>
|
||||
</li>
|
||||
<% end %>
|
||||
</div>
|
||||
<p class="bor-bottom-greyE"></p>
|
||||
<div class="panel-form">
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl">参考答案: </label>
|
||||
<div class="fl panel-box-sizing panel-form-width-690 new_li white_bg bor-grey-e" id="choose_task_pass_show" style="width: 90%;">
|
||||
<textarea name="choose[subject]"><%= @challenge_choose.answer %></textarea>
|
||||
</div>
|
||||
</li>
|
||||
</div>
|
||||
<p class="bor-bottom-greyE"></p>
|
||||
<div class="panel-form">
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl">难易度: </label>
|
||||
<div class="fl task-bg-grey panel-box-sizing panel-form-width-690 color-grey3">
|
||||
<%= difficulty_type @challenge_choose.difficult %>
|
||||
</div>
|
||||
</li>
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl">奖励经验值: </label>
|
||||
<div class="fl task-bg-grey panel-box-sizing panel-form-width-690 color-grey3">
|
||||
<%= @challenge_choose.score.nil? ? 0 : @challenge_choose.score %>分
|
||||
</div>
|
||||
</li>
|
||||
</div>
|
||||
<p class="bor-bottom-greyE"></p>
|
||||
<div class="panel-form">
|
||||
<li class="clearfix">
|
||||
<label class="panel-form-label fl">技能标签: </label>
|
||||
<div class="fl task-inputs">
|
||||
<% if @challenge_choose.challenge_tags.blank? %>
|
||||
无
|
||||
<% else %>
|
||||
<% @challenge_choose.challenge_tags.each do |tag| %>
|
||||
<div class="task-tag tag-grey mb10 mr10 fl">
|
||||
<%= tag.name %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
</li>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
editormd.loadKaTeX(function() {
|
||||
var taskPassMD = editormd.markdownToHTML("challenge_choose_subject_show", {
|
||||
htmlDecode: "style,script,iframe", // you can filter tags decode
|
||||
taskList: true,
|
||||
tex: true, // 默认不解析
|
||||
flowChart: true, // 默认不解析
|
||||
sequenceDiagram: true // 默认不解析
|
||||
});
|
||||
var taskPassMD = editormd.markdownToHTML("choose_task_pass_show", {
|
||||
htmlDecode: "style,script,iframe", // you can filter tags decode
|
||||
taskList: true,
|
||||
tex: true, // 默认不解析
|
||||
flowChart: true, // 默认不解析
|
||||
sequenceDiagram: true // 默认不解析
|
||||
});
|
||||
});
|
||||
});
|
||||
/* //技能标签
|
||||
var SnSkill = $(".knowledge_frame").length;
|
||||
|
||||
function add_tag(){
|
||||
var num = $(".task-inputs").children('div').length;
|
||||
var val = $(".tags").val().trim();
|
||||
if (val != ""){
|
||||
testLength = $(".tags").val().trim().length;
|
||||
$("#add_shixuns_skill").before("<div class='task-tag tag-grey mt5 mr10 fl' id='knowledge_" + num + "'>" +
|
||||
"<button data-dismiss='alert' class='close fr mt3 ml5' type='button' onclick='close_tag(this)'>×</button>" +
|
||||
"<input style='width:"+ testLength*12 +"px' class='knowledge_frame' name='knowledge[input][]' value='" + val +"'>" +
|
||||
" </div>");
|
||||
$(".tags").attr("value","");
|
||||
}
|
||||
$("#shixuns_skill_input").val("");
|
||||
$("#add_shixuns_skill").hide();
|
||||
var nSkill = $(".knowledge_frame");
|
||||
console.log(nSkill.length);
|
||||
}
|
||||
|
||||
function close_tag(thisObj){
|
||||
// 获取父节点的id
|
||||
var obj = $(thisObj).parent();
|
||||
$(obj).remove();
|
||||
}*/
|
||||
</script>
|
|
@ -11,15 +11,15 @@
|
|||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<div class="task-tag tag-grey mt5 mr10 fl <%#= @challenge_tags.count > 0 ? "undis" : "" %>" id="add_shixun_skill">
|
||||
<div class="task-tag tag-grey mt5 mr10 fl <%= @challenge_tags.count > 0 ? "undis" : "" %>" id="add_shixun_skill">
|
||||
<button data-dismiss="alert" class="close fr mt3 ml5" type="button" onclick="$('#add_shixun_skill').slideToggle();">×</button>
|
||||
<input type="text" class="task-tag-input" onblur="add_tag();" id="shixun_skill_input" placeholder="请输入技能标签" />
|
||||
</div>
|
||||
<a href="javascript:void(0);" onclick="$('#add_shixun_skill').slideToggle();" id="add_knowledge" style="color: #627bfd;float: left;margin-top: 5px">+添加</a>
|
||||
</div>
|
||||
</li>
|
||||
<p class="color-red ml95" style="height: 25px;"><span id="stage_name_notice" style="display: none;"><i class="fa fa-exclamation-circle color-red mr5"></i>技能标签不能为空</span></p>
|
||||
<div class="prop-notice-info mb10 ml40">
|
||||
<p class="color-red" style="height: 25px;margin-left: 10%"><span id="stage_name_notice" style="display: none;"><i class="fa fa-exclamation-circle color-red mr5"></i>技能标签不能为空</span></p>
|
||||
<div class="prop-notice-info mb10" style="margin-left: 10%">
|
||||
<ol>
|
||||
<% if @st == 0 %>
|
||||
<li>学员未参考答案通过了本阶段的评测时将获得技能,否则不能获得技能</li>
|
||||
|
@ -29,10 +29,10 @@
|
|||
</ol>
|
||||
</div>
|
||||
|
||||
<!--<li class="clearfix">-->
|
||||
<!--<a href="javascript:void(0);" class="task-btn task-btn-green fr" onclick="challenge_skill_update();">保存</a>-->
|
||||
<!--<a href="<%#= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 5) %>" class="task-btn fr mr10" id="skill_cancel">取消</a>-->
|
||||
<!--</li>-->
|
||||
<li class="clearfix">
|
||||
<a href="javascript:void(0);" class="task-btn task-btn-green fr" onclick="challenge_skill_update();">保存</a>
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 5) %>" class="task-btn fr mr10" id="skill_cancel">取消</a>
|
||||
</li>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
<ul class="" id="task_pass_edit">
|
||||
<%= labelled_form_for @challenge, :url => shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 1), :html => {:id => "challenge_shixun_update"} do |f| %>
|
||||
<%= render :partial => "task_pass_form", :locals => {:f => f} %>
|
||||
<% end %>
|
||||
</ul>
|
|
@ -34,66 +34,8 @@
|
|||
<p id="e_tips_in" style="margin-left: 10%" class="c_grey"></p>
|
||||
<span style="display: none;margin-left: 10%;" class="c_red" id="new_shixun_pass">过关任务不能为空</span>
|
||||
</li>
|
||||
<% if @st != 0 %>
|
||||
<% if params[:action] == "edit" && @challenge.challenge_questions.count > 0 %>
|
||||
<% @challenge.challenge_questions.each_with_index do |question, index| %>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice <%= question.right_key ? "check-option-bg" : "" %>" onclick="selectchoice(this, <%= @st %>);" name="option_span" title="点击设置答案"><%= (question.position+ 65).chr %></span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"><%= question.option_name %></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<% end %>
|
||||
<% elsif @st == 2 %>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @st %>);" name="option_span" title="点击设置答案">A</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @st %>);" name="option_span" title="点击设置答案">B</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<% else %>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @st %>);" name="option_span" title="点击设置答案">A</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @st %>);" name="option_span" title="点击设置答案">B</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @st %>);" name="option_span" title="点击设置答案">C</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<li class="clearfix pr">
|
||||
<label class="panel-form-label fl"><span class="option-item fr mr10 color-grey select-choice" onclick="selectchoice(this, <%= @st %>);" name="option_span" title="点击设置答案">D</span></label>
|
||||
<input type="hidden" name="choice[answer][]">
|
||||
<textarea class="panel-form-width2-690 fl panel-box-sizing" name="question[cnt][]" placeholder="请输入选项内容"></textarea>
|
||||
<a title="移除" class="position-delete option_icon_remove"><i class="fa fa-times-circle color-orange font-16 fl"></i></a>
|
||||
</li>
|
||||
<% end %>
|
||||
<ul>
|
||||
<li class="clearfix mb10" >
|
||||
<label class="panel-form-label fl"><span class="add-option-item fr mr10 color-grey border-dash-orange" name="option_span"><%= params[:action] == "edit" ? (@challenge.challenge_questions.count + 65).chr : (@st == 1 ? "E" : "C") %></span></label>
|
||||
<div class="fl panel-box-sizing add-option-input border-dash-orange"><a title="新增" class="option_icon_add">新增选项</a></div>
|
||||
</li>
|
||||
<span style="display: none" class="c_red ml95" id="choice_error_tip"></span>
|
||||
<li class="clearfix" ><label class="fl" style="margin-left: 46px">温馨提示:点击选项,可以直接设置答案</label><label class="fr">标准答案:<span id="current-option" class="color-orange"><%= @challenge.right_answers.blank? ? "请点击正确选项" : @challenge.right_answers %></span></label></li>
|
||||
</ul>
|
||||
<% end %>
|
||||
<li class="clearfix">
|
||||
<a href="javascript:void(0);" class="task-btn task-btn-green fr" onclick="challenge_update(<%= @st %>)">保存</a>
|
||||
<a href="javascript:void(0);" class="task-btn task-btn-green fr" onclick="challenge_update()">保存</a>
|
||||
<% if params[:action] == "new" %>
|
||||
<a href="<%= shixun_challenges_url(@shixun) %>" class="task-btn fr mr10" id="task_pass_cancel">取消</a>
|
||||
<% else %>
|
||||
|
@ -128,7 +70,26 @@
|
|||
placeholder: "<%= @st == 0 ? "请输入完成当前任务依赖的知识点或者其它相关信息" : "请输入选择题的题干内容" %>",
|
||||
imageUpload : true,
|
||||
imageFormats : ["jpg", "jpeg", "gif", "png", "bmp", "webp", "JPG", "JPEG", "GIF", "PNG", "BMP", "WEBP"],
|
||||
imageUploadURL : "<%= upload_with_markdown_path(:container_id => @shixun.id, :container_type => @shixun.class) %>"//url
|
||||
imageUploadURL : "<%= upload_with_markdown_path(:container_id => @shixun.id, :container_type => @shixun.class) %>",//url
|
||||
onload: function(){
|
||||
$("#challenge_task_pass [type=\"latex\"]").bind("click", function(){
|
||||
taskpass_editormd.cm.replaceSelection("```latex");
|
||||
taskpass_editormd.cm.replaceSelection("\n");
|
||||
taskpass_editormd.cm.replaceSelection("\n");
|
||||
taskpass_editormd.cm.replaceSelection("```");
|
||||
var __Cursor = taskpass_editormd.cm.getDoc().getCursor();
|
||||
taskpass_editormd.cm.setCursor(__Cursor.line-1, 0);
|
||||
});
|
||||
|
||||
$("#challenge_task_pass [type=\"inline\"]").bind("click", function(){
|
||||
taskpass_editormd.cm.replaceSelection("$$$$");
|
||||
var __Cursor = taskpass_editormd.cm.getDoc().getCursor();
|
||||
taskpass_editormd.cm.setCursor(__Cursor.line, __Cursor.ch-2);
|
||||
taskpass_editormd.cm.focus();
|
||||
});
|
||||
$("[type=\"inline\"]").attr("title", "行内公式");
|
||||
$("[type=\"latex\"]").attr("title", "多行公式");
|
||||
}
|
||||
});
|
||||
|
||||
var bt = baidu.template;
|
||||
|
@ -250,27 +211,6 @@
|
|||
var lens = answer.length;
|
||||
return lens;
|
||||
}
|
||||
|
||||
window.onload = function(){
|
||||
$("#challenge_task_pass [type=\"latex\"]").bind("click", function(){
|
||||
taskpass_editormd.cm.replaceSelection("```latex");
|
||||
taskpass_editormd.cm.replaceSelection("\n");
|
||||
taskpass_editormd.cm.replaceSelection("\n");
|
||||
taskpass_editormd.cm.replaceSelection("```");
|
||||
var __Cursor = taskpass_editormd.cm.getDoc().getCursor();
|
||||
taskpass_editormd.cm.setCursor(__Cursor.line-1, 0);
|
||||
});
|
||||
|
||||
$("#challenge_task_pass [type=\"inline\"]").bind("click", function(){
|
||||
taskpass_editormd.cm.replaceSelection("$$$$");
|
||||
var __Cursor = taskpass_editormd.cm.getDoc().getCursor();
|
||||
taskpass_editormd.cm.setCursor(__Cursor.line, __Cursor.ch-2);
|
||||
taskpass_editormd.cm.focus();
|
||||
});
|
||||
$("[type=\"inline\"]").attr("title", "行内公式");
|
||||
$("[type=\"latex\"]").attr("title", "多行公式");
|
||||
|
||||
};
|
||||
$("#challenge_subject").keydown(function(){
|
||||
$("#new_shixun_name").hide();
|
||||
});
|
||||
|
@ -282,7 +222,20 @@
|
|||
$("#task_pass_show").show();
|
||||
$("#task_pass_edit").hide();
|
||||
});
|
||||
function challenge_update(st){
|
||||
|
||||
function challenge_update(){
|
||||
if($('#challenge_subject').val().trim() == ""){
|
||||
$("#challenge_subject").focus();
|
||||
$("#new_shixun_name").show();
|
||||
}else if($("#challenge_task_pass textarea").val().trim() == ""){
|
||||
$("#challenge_task_pass textarea").focus();
|
||||
$("#new_shixun_pass").show();
|
||||
}else{
|
||||
$('#challenge_shixun_update').submit();
|
||||
}
|
||||
}
|
||||
|
||||
/* function challenge_update(st){
|
||||
set_choice_answer();
|
||||
var error = $("#choice_error_tip");
|
||||
if($('#challenge_subject').val().trim() == ""){
|
||||
|
@ -318,6 +271,6 @@
|
|||
$('#challenge_shixun_update').submit();
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
|
||||
</script>
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
$("#task_content").html("<%= j(render :partial => "single_or_multiple_question") %>");
|
|
@ -0,0 +1,2 @@
|
|||
$("#task_content").html("<%= j(render :partial => 'single_or_multiple_question_show')%>");
|
||||
$("#challenge_choose_tab").html("<%= j(render :partial => "challenges/choose_tab") %>");
|
|
@ -22,13 +22,9 @@
|
|||
<span class="panel-inner-icon mr10 fl mt5">
|
||||
<i class="fa fa-code font-16 color_white" data-tip-down="实践任务"></i>
|
||||
</span>
|
||||
<% elsif @st == 1 %>
|
||||
<% else %>
|
||||
<span class="panel-inner-icon mr10 fl mt5">
|
||||
<i class="fa fa-th-list color_white" data-tip-down="多选任务"></i>
|
||||
</span>
|
||||
<% elsif @st == 2%>
|
||||
<span class="panel-inner-icon mr10 fl mt5">
|
||||
<img src="/images/bigdata/singel.png" style="margin-bottom: 3px" data-tip-down="单选任务">
|
||||
<i class="fa fa-th-list color_white" data-tip-down="选择题任务"></i>
|
||||
</span>
|
||||
<% end %>
|
||||
<h3 class="fl mt3">阶段详情(第<%= @challenge.position %>关)</h3>
|
||||
|
@ -40,51 +36,55 @@
|
|||
<% end %>
|
||||
<% if @shixun.status == 0 && User.current.manager_of_shixun?(@shixun) %>
|
||||
<!-- <a href="<%#= new_shixun_challenge_path(@shixun) %>" class="shixun-task-btn task-btn-green fr">新建阶段</a>-->
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 0) %>" class="shixun-task-btn task-btn-green fr">+实践任务</a>
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 1) %>" class="shixun-task-btn task-btn-green fr mr10">+多选任务</a>
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 2) %>" class="shixun-task-btn task-btn-green fr mr10">+单选任务</a>
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 0) %>" class="shixun-task-btn task-btn-green fr" data-tip-down="新增代码编辑类型的任务">+实践任务</a>
|
||||
<!--<a href="<%#= new_shixun_challenge_path(@shixun, :st => 1) %>" class="shixun-task-btn task-btn-green fr mr10">+多选任务</a>
|
||||
<a href="<%#= new_shixun_challenge_path(@shixun, :st => 2) %>" class="shixun-task-btn task-btn-green fr mr10">+单选任务</a>-->
|
||||
|
||||
<a href="<%= new_shixun_challenge_path(@shixun, :st => 1) %>" class="shixun-task-btn task-btn-green fr mr10" data-tip-down="新增选择题类型的任务">+选择题任务</a>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
<ul class="nav_check_item clearfix mt30" style="margin-bottom: 0;">
|
||||
<li class="fl <%= @tab == 1 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 1) %>" class="color-black">本关任务</a>
|
||||
</li>
|
||||
<% if @challenge.st == 0 %>
|
||||
<li class="fl <%= @tab == 2 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 2) %>" class="color-black">评测设置</a>
|
||||
<% if @challenge.st == 0 %>
|
||||
<div class="stage-part mt20">
|
||||
<ul class="nav_check_item border-bottom-orange clearfix">
|
||||
<li class="fl <%= @tab == 1 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 1) %>" class="color-black">本关任务</a>
|
||||
</li>
|
||||
<li class="fl <%= @tab == 2 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 2) %>" class="color-black">评测设置</a>
|
||||
</li>
|
||||
<li class="fl <%= @tab == 3 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 3) %>" class="color-black">参考答案</a>
|
||||
</li>
|
||||
<li class="fl <%= @tab == 6 ? "check_nav" : "" %>
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 6) %>" class="color-black">预备知识</a>
|
||||
</li>
|
||||
<% end %>
|
||||
<li class="fl <%= @tab == 3 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 3) %>" class="color-black">参考答案</a>
|
||||
</li>
|
||||
<% unless @challenge.ready_knowledge.blank? %>
|
||||
<li class="fl <%= @tab == 6 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 6) %>" class="color-black">背景知识</a>
|
||||
</li>
|
||||
<% end %>
|
||||
<li class="fl <%= @tab == 4 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 4) %>" class="color-black">评分设置</a>
|
||||
</li>
|
||||
<li class="fl <%= @tab == 5 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 5) %>" class="color-black">技能标签</a>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="task-pm-box mh550 user_bg_shadow">
|
||||
<% if @tab == 1 || @tab.blank? %>
|
||||
<%= render :partial => "edit_task_pass" %>
|
||||
<% elsif @tab == 2 %>
|
||||
<%= render :partial => "edit_evaluating" %>
|
||||
<% elsif @tab == 3 %>
|
||||
<%= render :partial => "edit_answer" %>
|
||||
<% elsif @tab == 4 %>
|
||||
<%= render :partial => "edit_scoring" %>
|
||||
<% elsif @tab == 5 %>
|
||||
<%= render :partial => "edit_skill" %>
|
||||
<% elsif @tab == 6 %>
|
||||
<%= render :partial => "edit_propaedeutics" %>
|
||||
<% end %>
|
||||
</div>
|
||||
<li class="fl <%= @tab == 4 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 4) %>" class="color-black">评分设置</a>
|
||||
</li>
|
||||
<li class="fl <%= @tab == 5 ? "check_nav" : "" %>">
|
||||
<a href="<%= edit_shixun_challenge_path(@challenge, :shixun_id => @shixun, :tab => 5) %>" class="color-black">技能标签</a>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="task-pm-box mh550 user_bg_shadow">
|
||||
<% if @tab == 1 || @tab.blank? %>
|
||||
<%= render :partial => "edit_task_pass" %>
|
||||
<% elsif @tab == 2 %>
|
||||
<%= render :partial => "edit_evaluating" %>
|
||||
<% elsif @tab == 3 %>
|
||||
<%= render :partial => "edit_answer" %>
|
||||
<% elsif @tab == 4 %>
|
||||
<%= render :partial => "edit_scoring" %>
|
||||
<% elsif @tab == 5 %>
|
||||
<%= render :partial => "edit_skill" %>
|
||||
<% elsif @tab == 6 %>
|
||||
<%= render :partial => "edit_propaedeutics" %>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
<% else %>
|
||||
<%= render :partial => "choose_type" %>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="save-tip">
|
||||
<div class="save-tip-content">已保存</div>
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
$("#task_show_page").html('<%= j(render :partial => "task_edit_page") %>');
|
|
@ -0,0 +1,2 @@
|
|||
$("#task_content").html("<%= j(render :partial => "single_or_multiple_question") %>");
|
||||
$("#challenge_choose_tab").html("<%= j(render :partial => "challenges/choose_tab") %>");
|
|
@ -0,0 +1,2 @@
|
|||
$("#task_content").html("<%= j(render :partial => 'single_or_multiple_question_show')%>");
|
||||
$("#challenge_choose_tab").html("<%= j(render :partial => "challenges/choose_tab") %>");
|
|
@ -0,0 +1 @@
|
|||
$("#task_content").html("<%= j(render :partial => 'single_or_multiple_question_show')%>");
|
|
@ -0,0 +1,2 @@
|
|||
$("#task_content").html("<%= j(render :partial => 'single_or_multiple_question_show')%>");
|
||||
$("#challenge_choose_tab").html("<%= j(render :partial => "challenges/choose_tab") %>");
|
|
@ -10,9 +10,15 @@
|
|||
<% sy_author = User.find(sy.tea_id) %>
|
||||
<div class="task-index-list-box-top">
|
||||
<a href="<%= course_path(sy) %>" target="_blank">
|
||||
<p class="font-14 task-index-list-title two_lines_show">
|
||||
<% if sy.name.length > 32 %>
|
||||
<p class="font-14 task-index-list-title two_lines_show" data-tip-down = "<%= sy.name %>">
|
||||
<%= sy.name %>
|
||||
</p>
|
||||
<% else %>
|
||||
<p class="font-14 task-index-list-title two_lines_show">
|
||||
<%= sy.name %>
|
||||
</p>
|
||||
<% end %>
|
||||
</a>
|
||||
<div class="clearfix task-index-list-user">
|
||||
<%= link_to image_tag(url_to_avatar(sy_author), :width => "60", :height => "60", :class => "panel-warp-img mr10 fl", :alt => "用户"), user_path(sy_author), :target => '_blank' %>
|
||||
|
@ -65,6 +71,11 @@
|
|||
<% end %>
|
||||
|
||||
<script>
|
||||
//var Line = "<%#= sy.name %>";
|
||||
// $(".task-index-list-title").mouseenter(function(){
|
||||
// console.log(Line);
|
||||
// })
|
||||
|
||||
var timer="";
|
||||
$(".sub-con").hover(function(ev){
|
||||
this.fn = function(){
|
||||
|
|
|
@ -7,8 +7,8 @@
|
|||
<input id="add_student_<%= user.id %>" type="checkbox" class="fl mt7 mr5 magic-checkbox" name="membership[user_ids][]" value="<%= user.id %>">
|
||||
<label for="add_student_<%= user.id %>" style="top:0px">
|
||||
<a href="<%= user_path(user) %>" target="_blank" class="task-hide fl span1 edu-name-dark edu-txt-w100"><%= user.show_real_name %>(<%= user.login %>)</a>
|
||||
<span class="fl color-grey span2 ml10"><%= user.user_extensions.user_technical_title %></span>
|
||||
<span class="span3 fl ml10 edu-txt-w140 task-hide" style="width: 189px"><%= user.user_extensions.school ? user.user_extensions.school.name : "" %></span>
|
||||
<span class="fl color-grey span2 ml10 task-hide" style="width: 56px"><%= user.user_extensions.user_technical_title %></span>
|
||||
<span class="span3 fl ml10 edu-txt-w140 task-hide" style="width: 161px"><%= user.user_extensions.school ? user.user_extensions.school.name : "" %></span>
|
||||
</label>
|
||||
</li>
|
||||
<% end %>
|
||||
|
|
|
@ -1,32 +1,147 @@
|
|||
<!-- 编程题 -->
|
||||
<div class="-layout -stretch -fit -vertical centerH">
|
||||
<div class="-layout -vertical -flex -relative -bg-black -flex-basic70" id="games_repository_contents" style="overflow:hidden;">
|
||||
<ul id="blacktab_nav">
|
||||
<li id="codetab_nav_1" class="blacktab_hover" onclick="HoverLi_new(1);">
|
||||
<a href="javascript:void(0);" class="tab_type tab_color" >答题</a>
|
||||
</li>
|
||||
<div class="fr mt5 -horizontal mr15">
|
||||
<a href="javascript:void(0);" onclick="repository_extend_and_zoom();" id="extend_and_zoom"><i class="fa fa-expand font-16"></i></a>
|
||||
</div>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
<div id="codotab_con_1" class="white_bg" style="overflow-y: auto;height: 100%">
|
||||
<div class="panel-header clearfix" id="top_repository" style="border-bottom:0;padding:15px;">
|
||||
<% @game_challenge.challenge_chooses.each_with_index do |choose, index| %>
|
||||
<p class="font-bd font-18 color-grey3"><%= (index + 1).to_s + "." + (choose.category == 1 ? "单选题" : "多选题") %></p>
|
||||
<div class="font-15 color-grey3 mb10 new_li read_only" unselectable="on" id="choose_subject_<%= index + 1 %>" style="padding: 10px 0px 10px 10px">
|
||||
<textarea style="display:none;"><%= choose.subject %></textarea>
|
||||
</div>
|
||||
<div class="problem_single">
|
||||
<% choose.challenge_questions.each_with_index do |question, i| %>
|
||||
<p class="ml10 mb10 ">
|
||||
<span>
|
||||
<% if choose.category == 1 %>
|
||||
<input type="radio" <%= (choose.choose_outputs.try(:answer) == (i + 65).chr) ? "checked" : "" %> name="answer[<%= index + 1 %>]" category="<%= choose.category %>" value="<%= (question.position + 65).chr %>" id="result_<%= index %>_<%= i %>" class="ml-3 mr5 magic-radio ml5">
|
||||
<% else %>
|
||||
<!--多选-->
|
||||
<input type="checkbox" <%= (!choose.choose_outputs.try(:answer).nil? && (choose.choose_outputs.try(:answer).include? ((i + 65).chr))) ? "checked" : "" %> name="answer[]" category="<%= choose.category %>" value="<%= (question.position + 65).chr %>" id="result_<%= index %>_<%= i %>" class="ml-3 mr5 magic-checkbox ml5">
|
||||
<% end %>
|
||||
<label for="result_<%= index %>_<%= i %>" style="top: 0px"><span><%= (question.position + 65).chr %></span>.<%= question.option_name %></label>
|
||||
</span>
|
||||
</p>
|
||||
<% end %>
|
||||
<input type="hidden" name="user_answer">
|
||||
</div>
|
||||
<% end %>
|
||||
<!--<div class="pl5 pr5 pt10 pb10 bor-grey-e">
|
||||
<div for="result_<%#= question.position %>" class="card -elevation-1 mt10 mb5 <%#= (@user_answer.nil? || @user_answer.index(i.to_s).nil?) ? "" : "card-check color_white" %>" onclick="">
|
||||
<!–单选–>
|
||||
<%# if choose.category == 1 %>
|
||||
<input type="radio" name="answer[]" value="<%#= (question.position + 65).chr %>" id="result_<%#= question.position %>" class="ml-3 mr5 magic-radio ml5">
|
||||
<%# else %>
|
||||
<!–多选–>
|
||||
<input type="checkbox" name="answer[]" value="<%#= (question.position + 65).chr %>" id="result_<%#= question.position %>" class="ml-3 mr5 magic-checkbox ml5">
|
||||
<%# end %>
|
||||
<div class="-layout-h -center break_word" for="result_<%#= question.position %>">
|
||||
<span class="mr10"><%#= (question.position + 65).chr %>.</span>
|
||||
<div class="markdown">
|
||||
<p><code class="font-16"><%#= question.option_name %></code></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>-->
|
||||
<h3 id="save_status" class="ml15 fl" style="font-weight: normal"></h3>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!--拖拽增加结构---------------------------------------->
|
||||
<div class="h-center">
|
||||
<div class="-changebg -bg-black" id="-bg-change-color"></div>
|
||||
</div>
|
||||
<!------------------------------------------------------>
|
||||
<div class="split-panel--second -layout -vertical -flex -relative -bg-black -flex-basic60" id="games_valuation_contents">
|
||||
<%= render :partial => 'games/game_choose_results', :locals => { :game_challenge => @game_challenge} %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
editormd.loadKaTeX(function() {
|
||||
var lens = $("#top_repository .read_only").length;
|
||||
for(i = 1; i <= lens; i++){
|
||||
editormd.markdownToHTML("choose_subject_" + i, {
|
||||
htmlDecode: "style,script,iframe", // you can filter tags decode
|
||||
taskList: true,
|
||||
tex: true, // 数学公式
|
||||
flowChart: true, // 默认不解析
|
||||
sequenceDiagram: true // 默认不解析
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
$(function(){
|
||||
$(".problem_single p input").live("change",function(event){
|
||||
var $this=$(this).parents(".problem_single").find("input[name='user_answer']");
|
||||
var value="";
|
||||
if($(this).attr("category")=="1"){
|
||||
value="";
|
||||
//alert($(this).siblings("label").find("span").html());
|
||||
if($(this).attr("checked")=="checked"){
|
||||
value=$(this).siblings("label").find("span").html();
|
||||
}
|
||||
}else{
|
||||
var p=$(this).parents(".problem_single").find("p");
|
||||
value="";
|
||||
for(var i=0;i< p.length;i++){
|
||||
if(p.eq(i).find("input").attr("checked")=="checked"){
|
||||
//alert(p.eq(i).find("input").siblings("label").find("span").html());
|
||||
value+=p.eq(i).find("input").siblings("label").find("span").html();
|
||||
}
|
||||
}
|
||||
}
|
||||
$this.val(value);
|
||||
})
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
<% if false %>
|
||||
<div class="-layout -stretch -fit -vertical centerH">
|
||||
<div class="split-panel--second -layout -vertical -flex -relative -bg-black" id="answer">
|
||||
<ul id="blacktab_nav">
|
||||
<li id="codetab_nav_1" class="blacktab_hover" onclick="HoverLi_new(1);">
|
||||
<a href="javascript:void(0);" class="tab_type tab_color" >答题选项</a>
|
||||
<a href="javascript:void(0);" class="tab_type tab_color" >答题</a>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
<div id="codotab_con_1" style="overflow-y: auto;height: 100%">
|
||||
<div id="codotab_con_1" class="white_bg" style="overflow-y: auto;height: 100%">
|
||||
<div class="panel-header clearfix" id="top_repository" style="border-bottom:0;padding:15px;">
|
||||
<p class="mb10 color-light-green font-16 <%= @game.outputs.blank? || !@game.outputs.first.result ? "undis" : "" %>" id="correct_tip">
|
||||
<i class="fa fa-check-circle font-16"></i> 正确
|
||||
</p>
|
||||
<p class="mb10 color-red font-16 <%= @game.outputs.blank? || @game.outputs.first.result ? "undis" : "" %>" id="error_tip">
|
||||
<i class="fa fa-exclamation-circle font-16"></i> 错误
|
||||
</p>
|
||||
<% @game_challenge.challenge_questions.each_with_index do |question, i| %>
|
||||
<div class="card quiz-task-options -elevation-1 mb20 color-grey-bf <%= (@user_answer.nil? || @user_answer.index(i.to_s).nil?) ? "" : "card-check color_white" %>" onclick="choice_answer('<%= @st %>', this)">
|
||||
<input type="hidden" name="answer" value="<%= question.position %>">
|
||||
<div class="-layout-h -center break_word">
|
||||
<span class="mr10"><%= (question.position + 65).chr %>.</span>
|
||||
<div class="markdown">
|
||||
<p><code class="font-16"><%= question.option_name %></code></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<p class="font-bd font-18 color-grey3">1.单选题</p>
|
||||
<p class="font-15 color-grey3 mb10">应在下列程序划线处填入的语句是()</p>
|
||||
<pre class="mb10 back-f6-grey"></pre>
|
||||
<div class="pl5 pr5 pt10 pb10 bor-grey-e">
|
||||
<% @game_challenge.challenge_chooses.each do |choose| %>
|
||||
<% choose.challenge_questions.each_with_index do |question, i| %>
|
||||
<div for="result_<%= question.position %>" class="card -elevation-1 mt10 mb5 <%= (@user_answer.nil? || @user_answer.index(i.to_s).nil?) ? "" : "card-check color_white" %>" onclick="choice_answer('<%= @st %>', this)">
|
||||
<!--单选-->
|
||||
<input type="radio" name="answer[]" value="<%= question.position %>" id="result_<%= question.position %>" class="ml-3 mr5 magic-radio ml5">
|
||||
<!--多选-->
|
||||
<input type="checkbox" name="answer[]" value="<%= question.position %>" id="result_<%= question.position %>" class="ml-3 mr5 magic-checkbox ml5">
|
||||
<div class="-layout-h -center break_word">
|
||||
<span class="mr10"><%= (question.position + 65).chr %>.</span>
|
||||
<div class="markdown">
|
||||
<p><code class="font-16"><%= question.option_name %></code></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
<h3 id="save_status" class="ml15 fl" style="font-weight: normal"></h3>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
|
@ -5,6 +5,12 @@
|
|||
<a href="javascript:void(0)" class="shixun-task-btn task-btn-green mr15 mt8" onclick="delete_confirm_box('<%= reset_new_code_myshixun_game_path(@game, :myshixun_id => @myshixun, :path => @path) %>', '你在本关中修改的内容将丢失<br />是否确定重新加载上次通过的代码');">加载上次通过的代码</a>
|
||||
</div>
|
||||
<% end %>
|
||||
<div id="prev_step_area">
|
||||
<% if @game.challenge.position > 1 %>
|
||||
<%= link_to "上一关 ", {:controller => 'games', :action => "prev_step", :id => @game, :myshixun_id => @myshixun},
|
||||
:class => "shixun-task-btn task-btn-blue mr15 mt8", :id => "prev_step", :remote => true %>
|
||||
<% end %>
|
||||
</div>
|
||||
<div id="code_test">
|
||||
<% if @st == 0 %>
|
||||
<a href="javascript:void(0)" class="shixun-task-btn task-btn-blue mr15 mt8" onclick="training_task_submmit();">评测</a>
|
||||
|
@ -12,25 +18,19 @@
|
|||
<a href="javascript:void(0)" class="shixun-task-btn task-btn-blue mr15 mt8" onclick="choice_submmit();">评测</a>
|
||||
<% end %>
|
||||
</div>
|
||||
<div id="prev_step_area">
|
||||
<% if @game.challenge.position > 1 %>
|
||||
<%= link_to "上一关 ", {:controller => 'games', :action => "prev_step", :id => @game, :myshixun_id => @myshixun},
|
||||
:class => "shixun-task-btn task-btn-blue mr15 mt8", :id => "prev_step", :remote => true %>
|
||||
<% end %>
|
||||
</div>
|
||||
<div id="code_estimate">
|
||||
<% if @game.status == 1 %>
|
||||
<a class="shixun-task-btn mt8 mr15" id="code_testing">评测中..</a>
|
||||
<% end %>
|
||||
<% if show_next_stage?(@game, @myshixun.shixun.try(:status)) %>
|
||||
<% if @had_done == 0 %>
|
||||
<% if show_next_stage?(@game, @myshixun.shixun.try(:status)) %>
|
||||
<%= link_to "下一关 ", {:controller => 'games', :action => "next_step", :id => @game, :myshixun_id => @myshixun},
|
||||
:class => "shixun-task-btn task-btn-blue mr15 mt8", :id => "next_step", :remote => true %>
|
||||
<!--<a href="javascript:void(0);" onclick="shixun_next_step();" class="task-btn task-btn-blue mr15 mt8">下 一 步</a>-->
|
||||
<% else %>
|
||||
<a href="<%= shixun_path(@myshixun.shixun) %>" id="exit_shixun" class="shixun-task-btn task-btn-blue mt8 mr15">退出实训</a>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<a href="<%= shixun_path(@myshixun.shixun) %>" id="exit_shixun" class="shixun-task-btn task-btn-blue mt8 mr15">离开</a>
|
||||
<% end %>
|
||||
</div>
|
||||
<script>
|
||||
// 如果是HTML实训,则在效果显示栏实时渲染code
|
||||
|
@ -81,57 +81,25 @@
|
|||
// 选择题提交评测
|
||||
// answer 选择的答案
|
||||
function choice_submmit(){
|
||||
var answer = "";
|
||||
var nBtn = $(".card-check");
|
||||
var choice = nBtn.find("input[name='answer']");
|
||||
for(var i = 0; i < choice.length; i++){
|
||||
answer += $(choice[i]).val();
|
||||
}
|
||||
if(answer == ""){
|
||||
notice_sure_box("答案不能为空!");
|
||||
return;
|
||||
var user_answer = [];
|
||||
var input_answer = $("input[name='user_answer']");
|
||||
var lens = input_answer.length;
|
||||
for(i = 0; i < lens; i++ ){
|
||||
var answer = $(input_answer[i]).val();
|
||||
if(answer == ""){
|
||||
notice_sure_box("第"+ (i+1) + "题未答,请确认!");
|
||||
return;
|
||||
}
|
||||
user_answer.push(answer)
|
||||
}
|
||||
console.log(user_answer);
|
||||
$("#code_test").html("<a class='task-btn mt8 mr15'>评测中..</a>");
|
||||
$.ajax({
|
||||
type: "post",
|
||||
type: "POST",
|
||||
url: '<%= evaluating_choice_myshixun_game_path(@game, :myshixun_id => @myshixun) %>',
|
||||
data: {answer: answer},
|
||||
dataType: "json",
|
||||
data: {answer:user_answer},
|
||||
dataType: "script",
|
||||
success: function(data){
|
||||
console.log(data);
|
||||
clearInterval(cm);
|
||||
var icon = $("#game_status_<%= @game_challenge.id %>"); // 实训列表的icon
|
||||
icon.find("i").attr("class", "fa fa-unlock fr font-18 mt5 color-light-green w20_center");
|
||||
icon.find("a:last").attr("title", "已完成");
|
||||
$("#code_test").remove();
|
||||
if(data.correct){
|
||||
$("#correct_tip").show();
|
||||
$("#user_grade").html(data.grade);
|
||||
$("#shixun_exp_<%=@game_challenge.id %>").html("经验值<span class='color-light-green mr5'>+"+ data.score + "</span>");
|
||||
$("#shixun_grade_<%=@game_challenge.id %>").html("金币<span class='color-light-green mr5'>+"+ data.score + "</span>");
|
||||
$("#shixun_tag_<%=@game_challenge.id %>").html("技能标签<span class='color-light-green mr5'>+"+ data.tag_count + "</span>");
|
||||
if( data.had_done == 0 ) {
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a>");
|
||||
var htmlvalue = "<%= j (render :partial => 'games/pass_game_show', :locals => { :game=> @game, :myshixun => @myshixun, :had_done => 0}) %>";
|
||||
}else{
|
||||
$("#code_estimate").html("<a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >退出实训</a>");
|
||||
var htmlvalue = "<%= j (render :partial => 'games/pass_game_show', :locals => { :game => @game, :myshixun => @myshixun, :had_done => 1}) %>";
|
||||
}
|
||||
// 传递具体屏幕的宽高,实现不同浏览器与不同分辨率都能撑满屏幕
|
||||
pop_box_new2(htmlvalue, window.innerWidth, window.innerHeight);
|
||||
}else{
|
||||
$("#error_tip").show();
|
||||
var span_class = parseInt(data.score) < 0 ? "u-color-light-red" : "color-light-green";
|
||||
$("#shixun_exp_<%=@game_challenge.id %>").html("经验值<span class='color-light-green mr5'>+0</span>");
|
||||
$("#shixun_grade_<%=@game_challenge.id %>").html("金币<span class='"+ span_class +" mr5'>"+ data.score + "</span>");
|
||||
$("#shixun_tag_<%=@game_challenge.id %>").html("技能标签<span class='color-light-green mr5'>+0</span>");
|
||||
if(0 == data.had_done){
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a>");
|
||||
}else if(1 == data.had_done ){
|
||||
$("#code_estimate").html("<a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >退出实训</a>");
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
error: function(){
|
||||
console.log("错了");
|
||||
|
@ -159,7 +127,7 @@
|
|||
if($("#next_step").length > 0){
|
||||
$("#code_estimate").html("<a href='javascript:void(0);' class='task-btn mr15 mt8'>下一关</a>");
|
||||
} else if($("#exit_shixun").length > 0){
|
||||
$("#code_estimate").html("<a href='javascript:void(0);' class='task-btn mr15 mt8'>退出实训</a>");
|
||||
$("#code_estimate").html("<a href='javascript:void(0);' class='task-btn mr15 mt8'>下一关</a><a href='javascript:void(0);' class='task-btn mr15 mt8'>离开</a>");
|
||||
}
|
||||
if($("#prev_step").length > 0){
|
||||
$("#prev_step_area").html("<a href='javascript:void(0);' class='task-btn mr15 mt8'>上一关</a>");
|
||||
|
@ -241,10 +209,10 @@
|
|||
icon.find("i").attr("class", "fa fa-unlock fr font-18 mt5 color-light-green w20_center");
|
||||
icon.find("a:last").attr("title", "已完成");
|
||||
if( data.had_done == 0 ) {
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a>");
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a><a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >离开</a>");
|
||||
var htmlvalue = "<%= j (render :partial => 'games/pass_game_show', :locals => { :game=> @game, :myshixun => @myshixun, :had_done => 0}) %>";
|
||||
}else{
|
||||
$("#code_estimate").html("<a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >退出实训</a>");
|
||||
$("#code_estimate").html("<a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >离开</a>");
|
||||
var htmlvalue = "<%= j (render :partial => 'games/pass_game_show', :locals => { :game=> @game, :myshixun => @myshixun, :had_done => 1}) %>";
|
||||
}
|
||||
// 传递具体屏幕的宽高,实现不同浏览器与不同分辨率都能撑满屏幕
|
||||
|
@ -260,9 +228,9 @@
|
|||
if(codeEstimate == undefined){
|
||||
return;
|
||||
}else if(codeEstimate.trim() == "下一关"){
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a>");
|
||||
} else if(codeEstimate.trim() == "退出实训"){
|
||||
$("#code_estimate").html("<a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >退出实训</a>");
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a><a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >离开</a>");
|
||||
} else if(codeEstimate.trim() == "离开"){
|
||||
$("#code_estimate").html("<a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >离开</a>");
|
||||
}
|
||||
}
|
||||
// 访问60次,即120s后后台还未改变状态即执行
|
||||
|
@ -281,7 +249,7 @@
|
|||
$("#prev_step_area").html("<a href='<%= prev_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='prev_step' data-remote='true'>上一关</a>")
|
||||
}
|
||||
if( data.had_done == 0 ) {
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a>");
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a><a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >离开</a>");
|
||||
}
|
||||
var html = "<a href='javascript:void(0)' class='task-btn task-btn-blue mr15 mt8' onclick='training_task_submmit();'>评测</a>";
|
||||
|
||||
|
|
|
@ -0,0 +1,57 @@
|
|||
<ul id="blacktab_nav">
|
||||
<li class="blacktab_con blacktab_hover">
|
||||
<a href="javascript:void(0);" class="tab_type tab_color">测试结果</a>
|
||||
</li>
|
||||
<a href="javascript:void(0);" onclick="valuation_extend_and_zoom();" id="valuation_extend_and_zoom"><i class="fa fa-expand font-16 color-grey fr mt10 mr15 fa-arrows-alt" ></i></a>
|
||||
<div class="cl"></div>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
<div id="game_test_set_results" class="-flex -relative blacktab-inner">
|
||||
<div id="blacktab_con_1" class="" >
|
||||
<div class="fit -scroll">
|
||||
<div class="-layout-v -fit">
|
||||
<div class="-flex -scroll task-padding16">
|
||||
<% unless game_challenge.choose_correct_num == nil %>
|
||||
<% if game_challenge.choose_correct_num != game_challenge.challenge_chooses.count %>
|
||||
<p class="-text-danger mb10">
|
||||
<i class="fa fa-exclamation-circle font-16" ></i><span class="ml5 mr5 -text-danger"><%= game_challenge.choose_correct_num %>/<%= game_challenge.challenge_chooses.count %></span>错误
|
||||
</p>
|
||||
<% else %>
|
||||
<p class="color-light-green mb10">
|
||||
<i class="fa fa-check-circle font-16" ></i><span class="ml5 mr5"><%= game_challenge.challenge_chooses.count %>/<%= game_challenge.challenge_chooses.count %></span> 全部通过
|
||||
</p>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% game_challenge.challenge_chooses.each_with_index do |choose, index| %>
|
||||
<div class="-task-ces-box mb15 clearfix">
|
||||
<div class="-task-ces-top" onclick="toggle_test_case('0', '<%= index %>')" style="cursor:pointer">
|
||||
<i class="fa fa-caret-right mr5 font-16" ></i>
|
||||
<span class="font-14">题目<%= index + 1 %></span>
|
||||
<%# outputs = ChooseOutputs.where(:challenge_choose_id => choose.id).first %>
|
||||
<% unless choose.choose_outputs.blank? %>
|
||||
<% if choose.choose_outputs.try(:answer) != choose.standard_answer %>
|
||||
<i class="fa fa-exclamation-circle -text-danger fr mt8 ml5" ></i>
|
||||
<% else %>
|
||||
<i class="fa fa-check-circle color-light-green fr mt8 ml5 f14" ></i>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<i class="fa fa-lock fr mt8" ></i>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="-task-ces-info undis" id="test_case_<%= index %>">
|
||||
<ul class=" font-14">
|
||||
<% if choose.choose_outputs.blank? %>
|
||||
<li><span class="ml30">尚未提交,暂不支持查看</span></li>
|
||||
<% else %>
|
||||
<li><span class="-task-ces-info-left color-blue">正确选项:</span><span><%= choose.standard_answer %></span></li>
|
||||
<li><span class="-task-ces-info-left color-blue">你的选项:</span><span class="color-orange"><%= choose.choose_outputs.try(:answer).nil? ? "无" : choose.choose_outputs.try(:answer) %></span></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -17,19 +17,30 @@
|
|||
<a href="javascript:void(0);" class="tab_type" style="font-size: 16px">过关任务</a>
|
||||
</li>
|
||||
<% unless @myshixun.shixun.try(:propaedeutics).blank? %>
|
||||
<li id="tab_nav_2" onclick="HoverLi1(2);">
|
||||
<a href="javascript:void(0);" class="tab_type" style="font-size: 16px">背景知识</a>
|
||||
</li>
|
||||
<li id="tab_nav_2" onclick="HoverLi1(2);">
|
||||
<a href="javascript:void(0);" class="tab_type" style="font-size: 16px">背景知识</a>
|
||||
</li>
|
||||
<% end %>
|
||||
<% unless @game_challenge.answer.blank? %>
|
||||
<li id="tab_nav_3" onclick="open_answer('<%= @game.identifier %>', '<%= @myshixun.identifier %>')">
|
||||
<% if @st == 0 %>
|
||||
<% unless @game_challenge.answer.blank? %>
|
||||
<li id="tab_nav_3" onclick="open_answer('<%= @game.identifier %>', '<%= @myshixun.identifier %>', false)">
|
||||
<a href="javascript:void(0);" class="tab_type" style="font-size: 16px">参考答案</a>
|
||||
</li>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<li id="tab_nav_3" onclick="open_answer('<%= @game.identifier %>', '<%= @myshixun.identifier %>', true)">
|
||||
<a href="javascript:void(0);" class="tab_type" style="font-size: 16px">参考答案</a>
|
||||
</li>
|
||||
<% end %>
|
||||
<li id="tab_nav_4">
|
||||
<%= link_to '评论', shixun_discuss_shixun_path(@myshixun.shixun), :class => "tab_type", :style => "font-size: 16px", :remote => true %>
|
||||
</li>
|
||||
<span class="btn-cir-big fr mt8 mr15" >经验值:<%= @game_challenge.score %></span>
|
||||
<% if @st == 0 %>
|
||||
<span class="btn-cir-big fr mt8 mr15" >经验值:<%= @game_challenge.score %></span>
|
||||
<% else %>
|
||||
<span class="btn-cir-big fr mt8 mr15" >经验值:<%= @game_challenge.choose_score %></span>
|
||||
<% end %>
|
||||
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
<div class="-flex -relative greytab-inner" >
|
||||
|
@ -94,7 +105,7 @@
|
|||
<% if @st != 0 %>
|
||||
<!-- 单选多选题 -->
|
||||
<%= render :partial => "games/choice_question" %>
|
||||
<% else %>
|
||||
<% else %>
|
||||
<!-- 编程题 -->
|
||||
<div class="-layout -stretch -fit -vertical centerH">
|
||||
<div class="-layout -vertical -flex -relative -bg-black -flex-basic70" id="games_repository_contents" style="overflow:hidden;">
|
||||
|
|
|
@ -37,10 +37,16 @@
|
|||
|
||||
<div class="cl"></div>
|
||||
<div style="display: flex;" class="with80 ml30">
|
||||
<% if game.try(:status) == 0 || game.try(:status) == 1 || game.try(:status) == 3 %>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_exp_<%=challenge.id %>">经验值<span class="ml5"><%= challenge.score %></span></span>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_grade_<%=challenge.id %>">金币<span class="ml5"><%= challenge.score %></span></span>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_tag_<%=challenge.id %>">技能标签<span class="ml5"><%= challenge.challenge_tags.count %></span></span>
|
||||
<% if game.try(:status) != 2 %>
|
||||
<% if challenge.st == 0 %>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_exp_<%=challenge.id %>">经验值<span class="ml5"><%= challenge.score %></span></span>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_grade_<%=challenge.id %>">金币<span class="ml5"><%= challenge.score %></span></span>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_tag_<%=challenge.id %>">技能标签<span class="ml5"><%= challenge.challenge_tags.count %></span></span>
|
||||
<% else %>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_exp_<%=challenge.id %>">经验值<span class="ml5"><%= challenge.choose_score %></span></span>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_grade_<%=challenge.id %>">金币<span class="ml5"><%= challenge.choose_score %></span></span>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_tag_<%=challenge.id %>">技能标签<span class="ml5"><%= challenge.choose_tags_num %></span></span>
|
||||
<% end %>
|
||||
<% elsif game.try(:status) == 2 %>
|
||||
<% final_score = (game.answer_open? || @myshixun.shixun.status <= 1) ? 0 : game.final_score.to_i %>
|
||||
<% gold_score = @myshixun.shixun.status <= 1 ? 0 : (game.answer_open? ? -challenge.score.to_i : game.final_score.to_i) %>
|
||||
|
@ -48,6 +54,7 @@
|
|||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_grade_<%=challenge.id %>">金币<span class="<%= gold_score < 0 ? "u-color-light-red" : "color-light-green" %> ml5"><%= gold_score < 0 ? gold_score : "+"+gold_score.to_s %></span></span>
|
||||
<span class="color-dark-grey font-12 mr15 info-partly" id="shixun_tag_<%=challenge.id %>">技能标签<span class="color-light-green ml5">+<%= (game.answer_open? || @myshixun.shixun.status <= 1) ? 0 : challenge.challenge_tags.count %></span></span>
|
||||
<% end %>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -126,7 +126,7 @@
|
|||
var line_h = (navigator.userAgent.indexOf('Firefox') >= 0 ? 19 : 18);
|
||||
var rows = parseInt(h / line_h);
|
||||
// 测试版
|
||||
var html = "<iframe src='<%= Redmine::Configuration['tomcat_webssh'] %>/?Host=" + data.host + "&Port=" + data.port + "&Username=" + data.username + "&Password=" + data.password + "&Gameid=" + data.game_id + "&Rows=" + rows + "'" + " style='width:100%;border:0;' scrolling='no' class='game_webssh'></iframe><div class='-brother undis'></div>";
|
||||
var html = "<iframe src='<%= Redmine::Configuration['tomcat_webssh'] %>/?Host=" + data.host + "&Port=" + data.port + "&Username=" + data.username + "&Password=" + data.password + "&Gameid=" + data.game_id + "&Rows=" + rows + "'" + " style='width:100%;border:0;' scrolling='no' class='game_webssh'></iframe>";
|
||||
// 本地版
|
||||
var html_local ="<iframe src='http://127.0.0.1:9527?Host=106.75.96.108&Port=40054&Username=root&Password=123123&Gameid=" +data.game_id + "&Rows=" + rows + "'" + " style='width:100%;border:0;' scrolling='no' class='game_webssh'></iframe><div class='undis'></div>";
|
||||
console.log(html);
|
||||
|
|
|
@ -10,6 +10,18 @@
|
|||
$("#all_task_show").html("<%= j (render :partial => "games_list") %>");
|
||||
$("#all_task_show").hide();
|
||||
fadein = 0;
|
||||
// 选择题
|
||||
<% if params[:choose] == "1" %>
|
||||
<% if @had_done == 0 %>
|
||||
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-blue mr15 mt8' id='next_step' data-remote='true'>下一关</a>");
|
||||
var htmlvalue = "<%= j (render :partial => 'games/pass_game_show', :locals => { :game=> @game, :myshixun => @myshixun, :had_done => 0}) %>";
|
||||
<% else %>
|
||||
$("#code_estimate").html("<a href='<%= shixun_path(@myshixun.shixun) %>' class='task-btn task-btn-blue mt8 mr15' >退出实训</a>");
|
||||
var htmlvalue = "<%= j (render :partial => 'games/pass_game_show', :locals => { :game => @game, :myshixun => @myshixun, :had_done => 1}) %>";
|
||||
<% end %>
|
||||
// 传递具体屏幕的宽高,实现不同浏览器与不同分辨率都能撑满屏幕
|
||||
pop_box_new2(htmlvalue, window.innerWidth, window.innerHeight);
|
||||
<% end %>
|
||||
<% else %>
|
||||
$("#all_task_show").html("<%= j (render :partial => "games_list") %>");
|
||||
$("#all_task_tab").trigger("click"); // 模拟全部任务点击事件
|
||||
|
|
|
@ -76,8 +76,8 @@
|
|||
</div>
|
||||
<ul class="sy_classlist clearfix" style="border: none">
|
||||
<input class="magic-checkbox" type="checkbox" name="layout" id="homework_bank_all_select" class="fl">
|
||||
<label for="homework_bank_all_select" class="fl mr15">全选</label>
|
||||
<div class="fl resource_btns_bottom pt5">
|
||||
<label for="homework_bank_all_select" class="fl mr15 mt10">全选</label>
|
||||
<div class="fl resource_btns_bottom pt15">
|
||||
<a href="javascript:void(0);" onclick="choose_course_to_send_hb();" class="fl mr10">发送</a>
|
||||
<% if @type.to_i == 1 %>
|
||||
<a href="javascript:void(0);" onclick="destroy_all_hb('<%= destroy_all_homework_bank_index_path() %>')" class="fl">删除</a>
|
||||
|
|
|
@ -7,8 +7,8 @@
|
|||
<div class="list">
|
||||
<i class="fa fa-plus-circle color-light-green font-20 pl15 pr10 pt5" aria-hidden="true"></i><span>教学</span>
|
||||
<ul class="color-grey">
|
||||
<li><a href="<%= syllabuses_path() %>" target="_blank" >我的课堂</a></li>
|
||||
<li><a href="<%= new_course_path(:host=> Setting.host_course) %>" target="_blank" >新建课堂</a></li>
|
||||
<li><a href="<%= syllabuses_path() %>" target="_self" >我的课堂</a></li>
|
||||
<li><a href="<%= new_course_path(:host=> Setting.host_course) %>" target="_self" >新建课堂</a></li>
|
||||
<li><%= link_to "加入课堂", join_private_courses_courses_path, :remote => true, :method => "post" %></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
@ -29,12 +29,12 @@
|
|||
<div class="list">
|
||||
<i class="fa fa-gamepad color-light-green font-20 pl15 pr10 pt5" aria-hidden="true"></i><span>实训</span>
|
||||
<ul class="color-grey">
|
||||
<li><%= link_to "我的实训", shixuns_user_path(User.current), :target => "_blank" %></li>
|
||||
<li><%= link_to "我的实训", shixuns_user_path(User.current), :target => "_self" %></li>
|
||||
<!-- <li><%#= link_to "新建实训", new_shixun_path, :target => "_blank" %></li>-->
|
||||
<% if User.current.mail.blank? %>
|
||||
<li><a href="javascript:void(0)" onclick="shixun_valication()">新建实训</a></li>
|
||||
<% else %>
|
||||
<li><%= link_to "新建实训", new_shixun_path, :target => "_blank" %></li>
|
||||
<li><%= link_to "新建实训", new_shixun_path, :target => "_self" %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
});
|
||||
</script>
|
||||
</head>
|
||||
<body onload="prettyPrint();" style="height: 100%">
|
||||
<body onload="prettyPrint();" style="height: 100%;background:#fff;">
|
||||
<div class="newContainer pr"> <!-- 页面全部内容 -->
|
||||
<div class="newHeader">
|
||||
<% if User.current.logged? %>
|
||||
|
@ -48,7 +48,7 @@
|
|||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<div id="Container" class="panel-content clearfix user_bg_shadow">
|
||||
<div id="Container" class="panel-content clearfix box_bg_shandow" style="margin-top:30px;">
|
||||
<div class="panel-user-left fl">
|
||||
<ul class="panel-user-leftnav">
|
||||
<h3 class="mb15 ml15 mt15">账户管理</h3>
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<%= favicon %>
|
||||
<%= javascript_heads %>
|
||||
<%= heads_for_theme %>
|
||||
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2','css/font-awesome','css/taskstyle', 'css/project','css/popup','repository','css/gantt','css/cssPlus-v.0.2-build', 'css/edu-common','css/edu-public', 'css/edu-popup', 'css/edu-tooltipster' %>
|
||||
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2','css/font-awesome','css/taskstyle', 'css/project','css/popup','repository','css/gantt','css/cssPlus-v.0.2-build', 'css/edu-common','css/edu-public', 'css/edu-popup', 'css/edu-tooltipster', 'css/magic-check' %>
|
||||
<%= javascript_include_tag 'edu/application', 'edu/edu_tpi' %>
|
||||
<%= call_hook :view_layouts_base_html_head %>
|
||||
<!-- page specific tags -->
|
||||
|
|
|
@ -35,11 +35,13 @@
|
|||
:action => 'shixun_show',
|
||||
:id => @shixun,
|
||||
:repository_id => shixun_repository(@shixun).try(:identifier)}),
|
||||
:class => (params[:controller] == 'repositories' ? 'active' : ''),
|
||||
:target => "_blank" %>
|
||||
:class => (params[:controller] == 'repositories' ? 'active' : '') %>
|
||||
</li>
|
||||
<li><a href="<%= collaborators_shixun_path(@shixun) %>" class="<%= params[:action] == "collaborators" ? "active" : "" %>">合作者</a></li>
|
||||
<li><a href="<%= settings_shixun_path(@shixun) %>" class="<%= params[:action] == "settings" ? "active" : "" %>">配置</a></li>
|
||||
<% end %>
|
||||
<li><a href="<%= collaborators_shixun_path(@shixun) %>" class="<%= params[:action] == "collaborators" ? "active" : "" %>">合作者</a></li>
|
||||
<!--<li><a href="<%#= statistics_students_shixun_path(@shixun) %>"class="<%#= params[:action] == "statistics_students" ? "active" : "" %>">学员统计</a></li>-->
|
||||
<% if User.current.manager_of_shixun?(@shixun) %>
|
||||
<li><a href="<%= settings_shixun_path(@shixun) %>" class="<%= params[:action] == "settings" ? "active" : "" %>">配置</a></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
@ -34,6 +34,7 @@
|
|||
|
||||
</select>
|
||||
<input name="sx_order" type="hidden">
|
||||
<%#= link_to "导出Excel", export_excel_managements_path(:format => "xls"), :class => "task-btn task-btn-blue ml5 mt3 fr mb5 mr30" %>
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="edu-con-bg01 mt15" id="managements_classroom_classment">
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<div class="pro_new_info">
|
||||
<div class="pro_new_info box_bg_shandow bor-grey-e">
|
||||
<div class="icons_tishi"><img src="/images/new_project/icons_smile.png" width="110" height="110" alt=""></div>
|
||||
<p class="sy_tab_con_p ">没有数据可以显示!</p>
|
||||
</div>
|
|
@ -1,4 +1,4 @@
|
|||
<div class="new_roadmap_conbox mb10" >
|
||||
<div class="new_roadmap_conbox mb10 mt15">
|
||||
<div class=" clear">
|
||||
<ul class="reply-container-branch fl" >
|
||||
<%= render :partial => 'shixun_navigation' %>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<div class="container-big">
|
||||
<div class="container-big mt15">
|
||||
<div class="new_roadmap_conbox mb10" >
|
||||
<div class="new_roadmap_info_top clear ">
|
||||
<%=link_to "<span class='new_roadmap_icons_back mr5'></span>返回提交历史".html_safe,
|
||||
|
|
|
@ -3,9 +3,14 @@
|
|||
<em></em>
|
||||
<span></span>
|
||||
<p class="font-12">
|
||||
使用Git提交代码时,请在Git客户端填写如下信息:<br/>
|
||||
* 用户名:请使用您绑定的邮箱<br/>
|
||||
* 口令:请使用您的登录口令<br/>
|
||||
提交代码的方法:<br/>
|
||||
1、在你自己的电脑安装Git tortoise客户端,<br/>
|
||||
或者其他你熟悉的Git客户端;<br/>
|
||||
2、在Git客户端向左侧的地址提交代码。<br/>
|
||||
注意:<br/>
|
||||
请务必在Git客户端填写如下信息:<br/>
|
||||
* 用户名:使用您在本平台绑定的邮箱<br/>
|
||||
* 口令:使用您在本平台的登录口令<br/>
|
||||
</p>
|
||||
</div>
|
||||
<div class="repository_con" style="line-height:1.9;">
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<div class="task-pm-content mb20">
|
||||
<div class="mt20">
|
||||
<div class="task-pm-content">
|
||||
<div class="">
|
||||
<div class="panel-form">
|
||||
<div class="clearfix mb20">
|
||||
<p class="fr">
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<ul class="nav_check_item clearfix">
|
||||
<ul class="nav_check_item border-bottom-orange clearfix mb15">
|
||||
<li class="fl <%= @order == 'myshixun_count' ? 'check_nav' : "" %>">
|
||||
<%= link_to "最热", search_shixuns_path(:order => "myshixun_count", :shixun_status => @shixun_status, :status => @status, :language => @language, :search => @search, :trainee => @trainee, :major =>@major, :course => @course, :sort => @sort), :remote => true %>
|
||||
</li>
|
||||
|
|
|
@ -1,19 +1,20 @@
|
|||
<%= stylesheet_link_tag '/editormd/css/editormd','/editormd/css/editormd.min.css' %>
|
||||
<%= javascript_include_tag '/editormd/lib/marked.min.js','/editormd/lib/prettify.min.js','/editormd/lib/raphael.min.js','/editormd/lib/underscore.min.js','/editormd/lib/sequence-diagram.min.js',
|
||||
'/editormd/lib/flowchart.min.js','/editormd/lib/jquery.flowchart.min.js','/editormd/editormd.js'%>
|
||||
<ul id="tab_nav" class="nav_check_item mt30" style="background:#fff;margin-bottom:0">
|
||||
<div class=" box_bg_shandow mt30 mb30">
|
||||
<ul id="tab_nav" style="background:#fff;border-bottom:1px solid #eee;">
|
||||
<li id="tab_nav_1" class="tab_hover_setting" onclick="HoverLi(1);">
|
||||
<a href="javascript:void(0);" class="tab_type">实训</a>
|
||||
</li>
|
||||
<li id="tab_nav_2" onclick="HoverLi(2);">
|
||||
<a href="javascript:void(0);" class="tab_type" >版本库</a>
|
||||
<a href="javascript:void(0);" class="tab_type">配置</a>
|
||||
</li>
|
||||
<!--<li id="tab_nav_2" onclick="HoverLi(2);">-->
|
||||
<!--<a href="javascript:void(0);" class="tab_type" >版本库</a>-->
|
||||
<!--</li>-->
|
||||
<!--<li id="tab_nav_3" onclick="HoverLi(3);">-->
|
||||
<!--<a href="javascript:void(0);" class="tab_type" >测试脚本</a>-->
|
||||
<!--</li>-->
|
||||
</ul>
|
||||
<div class="task-pm-content box_bg_shandow ">
|
||||
<div class="task-pm-box mb30">
|
||||
<div class="task-pm-content">
|
||||
<div class="task-pm-box" style="border:0;">
|
||||
<div class="tab_content clearfix" >
|
||||
|
||||
<div class="cl"></div>
|
||||
|
@ -25,26 +26,26 @@
|
|||
<%= render :partial => "shixuns/settings_show" %>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab_con_2" class="undis" >
|
||||
<%= render :partial=>"shixuns/settings_repository" %>
|
||||
</div>
|
||||
<!--<div id="tab_con_2" class="undis" >-->
|
||||
<!--<%#= render :partial=>"shixuns/settings_repository" %>-->
|
||||
<!--</div>-->
|
||||
<!--<div id="tab_con_3" class="undis" >-->
|
||||
<!--<%#= render :partial=>"shixuns/settings_challenges" %>-->
|
||||
<!--</div>-->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
function g(o){return document.getElementById(o);}
|
||||
function HoverLi(n){
|
||||
for(var i=1;i<=2;i++){
|
||||
g('tab_nav_'+i).className='tab_nomal';
|
||||
g('tab_con_'+i).className='undis';
|
||||
}
|
||||
g('tab_con_'+n).className='dis';
|
||||
g('tab_nav_'+n).className='tab_hover_setting';
|
||||
}
|
||||
// function HoverLi(n){
|
||||
// for(var i=1;i<=2;i++){
|
||||
// g('tab_nav_'+i).className='tab_nomal';
|
||||
// g('tab_con_'+i).className='undis';
|
||||
// }
|
||||
// g('tab_con_'+n).className='dis';
|
||||
// g('tab_nav_'+n).className='tab_hover_setting';
|
||||
// }
|
||||
function close_waring_frame(){
|
||||
$("#warning_frame").hide();
|
||||
}
|
||||
|
|
|
@ -0,0 +1,197 @@
|
|||
<div class="task-pm-content ">
|
||||
<div class="task-pm-box mt20 mb20">
|
||||
<div class="panel-header clearfix">
|
||||
<h3 class="fl mt5">学员广场</h3>
|
||||
<div class="fr panel-search">
|
||||
<input type="text" class="panel-search-input" placeholder="输入学员登录名、姓名进行搜索"/>
|
||||
<a href="#" class="panel-search-btn"><i class="fa fa-search font-16"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<table class="panel-new-table panel-table-pd15" cellpadding="0" cellspacing="0">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="table-num">1</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner03 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第3关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">2</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">3</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner03 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第3关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">4</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">4</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">4</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">4</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">4</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">4</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="table-num">4</td>
|
||||
<td >
|
||||
<a href="#" class="panel-table-name hide fl">胡莎莎学员 </a>
|
||||
<span class="ml5 mr5 fl">/</span>
|
||||
<a href="#" class="panel-table-title hide fl">Helloworld:Java入门实训项目Helloworld:Java入门实训项目</a>
|
||||
<div class="cl"></div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="panel-slider-bg fl mt15">
|
||||
<span class="panel-slider-inner06 "></span>
|
||||
</div>
|
||||
<span class="panel-slider-txt fl ml10">第6关/共10关</span>
|
||||
</td>
|
||||
<td><span class=" mr20">100分</span></td>
|
||||
<td ><a href="#" class="link-color-grey02 font-14 mr15"><span class="fa-icons-flower mr5"></span>给TA送花</a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="panel-pages ">
|
||||
<a href="javascript:void(0);" class="pages-big">上一页</a>
|
||||
<a href="javascript:void(0);" class="active ">1</a>
|
||||
<a href="javascript:void(0);">2</a>
|
||||
<a href="javascript:void(0);">3</a>
|
||||
<a href="javascript:void(0);">...</a>
|
||||
<a href="javascript:void(0);">31</a>
|
||||
<a href="javascript:void(0);" class="pages-big">下一页</a>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
|
@ -1,4 +1,4 @@
|
|||
<ul class="nav_check_item clearfix">
|
||||
<ul class="nav_check_item border-bottom-orange clearfix mb15">
|
||||
<li class="fl <%= @order == 'updated_at' ? 'check_nav' : "" %>">
|
||||
<%= link_to "最热", subjects_path(:order => "updated_at", :search => @search, :sort => @sort), :remote => true %>
|
||||
</li>
|
||||
|
|
|
@ -309,12 +309,12 @@
|
|||
} else{
|
||||
$("#stage_name_notice").hide();
|
||||
}
|
||||
if($("input[name='shixun_id[]']").length == 0){
|
||||
status = false;
|
||||
$("#sx_none_notice").show();
|
||||
} else{
|
||||
$("#sx_none_notice").hide();
|
||||
}
|
||||
// if($("input[name='shixun_id[]']").length == 0){
|
||||
// status = false;
|
||||
// $("#sx_none_notice").show();
|
||||
// } else{
|
||||
// $("#sx_none_notice").hide();
|
||||
// }
|
||||
if(status && flag){
|
||||
flag = false;
|
||||
$("#new_stage_form").submit();
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
<p class="edu-con-top clearfix" style="height: 50px; border: none;">
|
||||
<a href="<%= syllabuses_path(:type => 1, :tab => @tab) %>" class="fl ml15 edu-filter-cir-grey mr5 font-12 active mt12" data-remote="true" id="syllabuses_processing">正在进行</a>
|
||||
<a href="<%= syllabuses_path(:type => 2, :tab => @tab) %>" class="fl edu-filter-cir-grey mr5 font-12 mt12" data-remote="true" id="syllabuses_end">已结束</a>
|
||||
<a href="/courses/new" class="color-light-green fr font-14 mr30 mt12" >+ 新建</a>
|
||||
<a href="/courses/join_private_courses" class="color-light-green fr mr20 font-14 mt12" data-method="post" data-remote="true" rel="nofollow" >+ 加入</a>
|
||||
<a href="/courses/new" class="white-btn orange-btn fr font-14 mr30 " style="margin-top:10px">+ 新建</a>
|
||||
<a href="/courses/join_private_courses" class="white-btn orange-btn fr mr20 font-14 " style="margin-top:10px" data-method="post" data-remote="true" rel="nofollow" >+ 加入课堂</a>
|
||||
</p>
|
||||
<div id="my_syllabuses">
|
||||
<%= render :partial => "syllabuses/my_syllabuses" %>
|
||||
|
|
|
@ -7,13 +7,13 @@
|
|||
<div class="edu-tab clearfix mb20">
|
||||
<ul id="edu-tab-nav" class="border-bottom-orange">
|
||||
<li id="edu-tab-nav-1" class="new-tab-nav background-orange">
|
||||
<%=link_to "全部", syllabuses_path(:tab => 1), :class => "tab_type", :remote => true %>
|
||||
<%=link_to "全部", syllabuses_path(:tab => 1), :class => "tab_type font-16", :remote => true %>
|
||||
</li>
|
||||
<li id="edu-tab-nav-2" class="new-tab-nav">
|
||||
<%=link_to "我管理的", syllabuses_path(:tab => 2), :class => "tab_type", :remote => true %>
|
||||
<%=link_to "我管理的", syllabuses_path(:tab => 2), :class => "tab_type font-16", :remote => true %>
|
||||
</li>
|
||||
<li id="edu-tab-nav-3" class="new-tab-nav">
|
||||
<%=link_to "我参与的", syllabuses_path(:tab => 3), :class => "tab_type", :remote => true %>
|
||||
<%=link_to "我参与的", syllabuses_path(:tab => 3), :class => "tab_type font-16", :remote => true %>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
|
|
|
@ -7,11 +7,11 @@
|
|||
<% else %>
|
||||
<table class="edu-pop-table-all" cellpadding="0" cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<tr class="edu-bg-grey">
|
||||
<th width="15%">操作</th>
|
||||
<th width="15%">变更</th>
|
||||
<th width="55%">详情</th>
|
||||
<th width="15%">操作时间</th>
|
||||
<th width="58%">详情</th>
|
||||
<th width="12%">操作时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
|
@ -7,11 +7,11 @@
|
|||
<% else %>
|
||||
<table class="edu-pop-table-all" cellpadding="0" cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<tr class="edu-bg-grey">
|
||||
<th width="15%">操作</th>
|
||||
<th width="15%" class="edu-txt-center">变更</th>
|
||||
<th width="55%">详情</th>
|
||||
<th width="15%" class="edu-txt-center">操作时间</th>
|
||||
<th width="58%">详情</th>
|
||||
<th width="12%" class="edu-txt-center">操作时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<div class="eduResources mb10" id="user_activity_<%= user_activity_id%>">
|
||||
<div class="eduResources box_bg_shandow bor-grey-e" style="margin-bottom:20px;" id="user_activity_<%= user_activity_id%>">
|
||||
<div class="eduHomepagePostBrief">
|
||||
<div class="homepagePostPortrait">
|
||||
<%= link_to image_tag(url_to_avatar(activity.user), :width => "50", :height => "50"), user_path(activity.user), :alt => "用户头像" %>
|
||||
|
|
|
@ -112,7 +112,7 @@
|
|||
</div>
|
||||
</div>
|
||||
<% else %>
|
||||
<div class="edu-tab-con-box box_bg_shandow bor-grey-e">
|
||||
<div class="edu-tab-con-box box_bg_shandow bor-grey-e mt20">
|
||||
<img src="../images/bigdata/edu-class/edu-nodata.png" class="edu-nodata-img">
|
||||
<p class="edu-nodata-p mb30">没有数据可以显示!</p>
|
||||
</div>
|
||||
|
|
|
@ -6,18 +6,18 @@
|
|||
<div class="edu-tab clearfix mb20">
|
||||
<ul id="edu-tab-nav" class="border-bottom-orange">
|
||||
<li id="shixun_all" class="new-tab-nav background-orange">
|
||||
<a href="javascript:void(0);" class="tab_type">全部</a>
|
||||
<a href="javascript:void(0);" class="tab_type font-16">全部</a>
|
||||
</li>
|
||||
<li id="shixun_create" class="new-tab-nav">
|
||||
<a href="javascript:void(0);" class="tab_type">我创建的</a>
|
||||
<a href="javascript:void(0);" class="tab_type font-16">我创建的</a>
|
||||
</li>
|
||||
<li id="shixun_cooperative" class="new-tab-nav">
|
||||
<a href="javascript:void(0);" class="tab_type" >我合作的</a>
|
||||
<a href="javascript:void(0);" class="tab_type font-16" >我合作的</a>
|
||||
</li>
|
||||
<li id="shixun_challenge" class="new-tab-nav">
|
||||
<a href="javascript:void(0);" class="tab_type">我挑战的</a>
|
||||
<a href="javascript:void(0);" class="tab_type font-16">我挑战的</a>
|
||||
</li>
|
||||
<a href="javascript:void(0);" class="color-light-green fr font-16 mr30 mt10" onclick="shixun_new(<%= @mail %>)">+ 新建</a>
|
||||
<a href="javascript:void(0);" class="white-btn orange-btn fr font-16 mr30" style = "margin-top:8px" onclick="shixun_new(<%= @mail %>)">+ 新建</a>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
<div id="edu-tab-con-1" class="box_bg_shandow">
|
||||
|
|
|
@ -153,15 +153,14 @@
|
|||
:class => "fr font-14 user_watch link-color-orange",
|
||||
:id => "cancel_watch",
|
||||
:method => "delete",
|
||||
:remote => "true",
|
||||
:title => "取消关注" %>
|
||||
:remote => "true" %>
|
||||
<% else %>
|
||||
<%= link_to "添加关注",
|
||||
watch_path(:object_type => 'user', :object_id => @user.id, :target_id => @user.id),
|
||||
:class => "fr font-14 user_watch link-color-orange",
|
||||
:class => "fr font-14 user_watch link-color-orange ",
|
||||
:method => "post",
|
||||
:remote => "true",
|
||||
:title => "添加关注" %>
|
||||
:remote => "true"%>
|
||||
|
||||
<% end %>
|
||||
<span class="fr mr20 color-grey-8 mt3">经验值 <span class="ml5 color-orange03"><%= @user.experience %></span> </span>
|
||||
<span class="fr mr20 color-grey-8 mt3">金币<span class="ml5 color-orange03"><%= @user.grade %></span></span>
|
||||
|
@ -221,9 +220,9 @@
|
|||
<a href="<%= shixuns_or_courses_filter_user_path(@user, :index => "shixun", :filter => "cooperative") %>" class="user_course_filtrate fl mt20 mr30" data-remote="true"><span class="user_filtrate_span1"><%= str %>合作的</span><span class="user_filtrate_span2 ml10"><%= @cooperative_num %></span></a>
|
||||
<a href="<%= shixuns_or_courses_filter_user_path(@user, :index => "shixun", :filter => "challenge") %>" class="user_course_filtrate fl mt20 mr30" data-remote="true"><span class="user_filtrate_span1"><%= str %>挑战的</span><span class="user_filtrate_span2 ml10"><%= @challenge_num %></span></a>
|
||||
<% if User.current.mail.blank? %>
|
||||
<li><a href="javascript:void(0)" class="color-light-green fr font-14 mr20" style="line-height:56px" onclick="shixun_valication()">+ 新建</a></li>
|
||||
<li><a href="javascript:void(0)" class="white-btn orange-btn fr font-14 mr20 mt20" style="" onclick="shixun_valication()">+ 新建</a></li>
|
||||
<% else %>
|
||||
<li><%= link_to "+ 新建", new_shixun_path, :target => "_blank", :class => "color-light-green fr font-14 mr20", :style => "line-height:56px" %></li>
|
||||
<li><%= link_to "+ 新建", new_shixun_path, :target => "_blank", :class => "white-btn orange-btn fr font-14 mr20 mt20", :style => "" %></li>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="lesson clearfix homepage-list-show" id="my_shixuns_list">
|
||||
|
@ -246,8 +245,8 @@
|
|||
<a href="<%= shixuns_or_courses_filter_user_path(@user, :index => "course", :filter => "all") %>" class="user_course_filtrate fl mt20 mr30" data-remote="true"><span class="user_filtrate_span1 user_filtrate_span1_bg">全部</span><span class="user_filtrate_span2 user_filtrate_span2_bg ml10"><%= @all_courses_count %></span></a>
|
||||
<a href="<%= shixuns_or_courses_filter_user_path(@user, :index => "course", :filter => "manage") %>" class="user_course_filtrate fl mt20 mr30" data-remote="true"><span class="user_filtrate_span1"><%= str %>管理的</span><span class="user_filtrate_span2 ml10"><%= @create_courses_count %></span></a>
|
||||
<a href="<%= shixuns_or_courses_filter_user_path(@user, :index => "course", :filter => "join") %>" class="user_course_filtrate fl mt20 mr30" data-remote="true"><span class="user_filtrate_span1"><%= str %>参与的</span><span class="user_filtrate_span2 ml10"><%= @join_courses_count %></span></a>
|
||||
<a href="/courses/new" class="color-light-green fr font-14 mr30" style="line-height:56px">+ 新建</a>
|
||||
<a href="/courses/join_private_courses" class="color-light-green fr mr20 font-14" data-method="post" data-remote="true" rel="nofollow" style="line-height:56px">+ 加入</a>
|
||||
<a href="/courses/new" class="white-btn orange-btn fr font-14 mr30 mt20">+ 新建</a>
|
||||
<a href="/courses/join_private_courses" class="white-btn orange-btn fr mr20 font-14 mt20" data-method="post" data-remote="true" rel="nofollow">+ 加入课堂</a>
|
||||
</div>
|
||||
<div class="lesson clearfix homepage-list-show" id="my_courses_list">
|
||||
<%#= render :partial => "my_homepage_courses_list" %>
|
||||
|
@ -268,8 +267,10 @@
|
|||
<!-------------------侧边提示区域-------------------------->
|
||||
<div class="-task-sidebar">
|
||||
<div class="feedback" tooltips="意见反馈">
|
||||
<i class="fa fa-envelope-o" aria-hidden="true"></i>
|
||||
<a target="_blank" class="color_white" href="<%= shixun_feedback_managements_path()%>"><i class="fa fa-envelope-o" aria-hidden="true"></i></a>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="scan" tooltips="快来扫一扫">
|
||||
<i class="fa fa-qrcode" aria-hidden="true"></i>
|
||||
</div>
|
||||
|
|
|
@ -1,8 +1,11 @@
|
|||
<style>
|
||||
body{background:#fff!important;}
|
||||
</style>
|
||||
<div class="-task-con">
|
||||
<div class="-task-con-int">
|
||||
<div class="favour">
|
||||
<% str = (current_user == @user) ? '我' : 'TA' %>
|
||||
<ul id="edu-user-tab-nav">
|
||||
<ul id="edu-user-tab-nav" style="background:#fff">
|
||||
<li class=" new-tab-nav">
|
||||
<a href="<%= user_watchlist_user_path(@user) %>" class="font-16 tab_type" id="user_watcher_cout" ><%= str %>的关注 <%= @user_watchlist_count %></a>
|
||||
</li>
|
||||
|
@ -10,7 +13,7 @@
|
|||
<a href="<%= user_fanslist_user_path(@user) %>" class="font-16 tab_type" id="user_fans_count"><%= str %>的粉丝 <%= @user_fanlist_count %></a>
|
||||
</li>
|
||||
</ul>
|
||||
<div id="edu-tab-con-1" class="user_bg_shadow">
|
||||
<div id="edu-tab-con-1" class="box_bg_shandow">
|
||||
<div class="clearfix mt20" id="user_fans_list">
|
||||
<%= render :partial => "user_watcher_or_fans_list", :locals => {:users => @user_fanlist, :user_count => @user_fanlist_count, :user_pages => @fans_pages} %>
|
||||
</div>
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
<style>
|
||||
body{height:100%;background:#fff;}
|
||||
</style>
|
||||
<div>
|
||||
<div class="eduhomepageRightBanner mb10">
|
||||
<div class="eduhomepageRightBanner box_bg_shandow bor-grey-e" style="margin:20px auto;">
|
||||
<div class="NewsBannerName pr"><span id="mesLabel">留言</span></div>
|
||||
<ul class="resourcesSelect">
|
||||
<li class="resourcesSelected"><a href="javascript:void(0);" class="resourcesIcon"></a>
|
||||
|
@ -15,7 +18,7 @@
|
|||
|
||||
<div id="messageContent">
|
||||
<% unless is_current_user %>
|
||||
<div class="eduResources mb10" style="height: 160px"><%= link_to image_tag(url_to_avatar(User.current),:class=>"fl mr10", :width => "50", :height => "50"), :alt => "用户头像" %>
|
||||
<div class="eduResources box_bg_shandow bor-grey-e" style="height: 160px;margin-bottom:20px;"><%= link_to image_tag(url_to_avatar(User.current),:class=>"fl mr10", :width => "50", :height => "50"), :alt => "用户头像" %>
|
||||
<div class="fl" style="width:92%" >
|
||||
<%= form_for('new_form',:url => leave_user_message_path(@user.id), :html =>{:id => "user_feedback_new"}, :method => "post") do |f|%>
|
||||
<%= render :partial => "jour_form", :locals => {:f => f, :object => @user} %>
|
||||
|
|
|
@ -1,8 +1,11 @@
|
|||
<style>
|
||||
body{background:#fff!important;}
|
||||
</style>
|
||||
<div class="-task-con">
|
||||
<div class="-task-con-int">
|
||||
<div class="favour">
|
||||
<% str = (current_user == @user) ? '我' : 'TA' %>
|
||||
<ul id="edu-user-tab-nav">
|
||||
<ul id="edu-user-tab-nav" style="background:#fff">
|
||||
<li id="edu-tab-nav-1" class="edu-user-tab-hover new-tab-nav">
|
||||
<a href="<%= user_watchlist_user_path(@user) %>" class="font-16 tab_type" id="user_watcher_cout" ><%= str %>的关注 <%= @user_watchlist_count %></a>
|
||||
</li>
|
||||
|
@ -10,7 +13,7 @@
|
|||
<a href="<%= user_fanslist_user_path(@user) %>" class="font-16 tab_type" id="user_fans_count"><%= str %>的粉丝 <%= @user_fanlist_count %></a>
|
||||
</li>
|
||||
</ul>
|
||||
<div id="edu-tab-con-1" class="user_bg_shadow mh650">
|
||||
<div id="edu-tab-con-1" class="box_bg_shandow mh650">
|
||||
<div class="clearfix mt20" id="user_watch_list">
|
||||
<%= render :partial => "user_watcher_or_fans_list", :locals => {:users => @user_watchlist, :user_count => @user_watchlist_count, :user_pages => @watchlist_pages} %>
|
||||
</div>
|
||||
|
|
|
@ -202,6 +202,7 @@ zh:
|
|||
label_issue_new: 新建问题
|
||||
label_query: 自定义查询
|
||||
label_issue_list_xls: Issue列表
|
||||
label_course_list_xls: 课程列表
|
||||
label_per_week: 每周
|
||||
label_per_month: 每月
|
||||
label_per_all: 所有
|
||||
|
|
|
@ -104,6 +104,7 @@ RedmineApp::Application.routes.draw do
|
|||
match 'ghook'
|
||||
get 'search_user_courses'
|
||||
post 'send_to_course'
|
||||
get 'statistics_students'
|
||||
end
|
||||
collection do
|
||||
get 'shixun_courses'
|
||||
|
@ -118,6 +119,12 @@ RedmineApp::Application.routes.draw do
|
|||
get 'index_up'
|
||||
get 'index_down'
|
||||
match 'update_evaluation', :via => [:get, :post, :put]
|
||||
match 'add_choose_question', :via => [:get, :post]
|
||||
post 'new_choose_question'
|
||||
match 'choose_type_show', :via => [:get, :post]
|
||||
match 'edit_choose_question', :via => [:get, :post]
|
||||
match 'update_choose_question', :via => [:get, :post]
|
||||
delete 'destroy_challenge_choose'
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -232,6 +239,7 @@ RedmineApp::Application.routes.draw do
|
|||
get 'shixun_feedback'
|
||||
match 'update_user',:via=>[:get,:post]
|
||||
post 'support_shixuns_search'
|
||||
match 'export_excel', :via => [:get, :post]
|
||||
get 'add_departments_part'
|
||||
post 'save_school'
|
||||
end
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
class CreateChallengeChooses < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :challenge_chooses do |t|
|
||||
t.string :subject
|
||||
t.integer :challenge_id
|
||||
t.string :standard_answer
|
||||
t.text :answer
|
||||
t.integer :score
|
||||
t.integer :difficult
|
||||
t.integer :type
|
||||
t.string :position, :default => 1
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
end
|
||||
end
|
|
@ -0,0 +1,12 @@
|
|||
class CreateChooseOutputs < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :choose_outputs do |t|
|
||||
t.integer :challenge_choose_id
|
||||
t.integer :user_id
|
||||
t.string :answer
|
||||
t.string :correct
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
end
|
||||
end
|
|
@ -0,0 +1,8 @@
|
|||
class ModifyChallengeIdForChallgengeQuestion < ActiveRecord::Migration
|
||||
def up
|
||||
rename_column :challenge_questions, :challenge_id, :challenge_choose_id
|
||||
end
|
||||
|
||||
def down
|
||||
end
|
||||
end
|
|
@ -0,0 +1,5 @@
|
|||
class AddChallengeChooseIdToChallengeTags < ActiveRecord::Migration
|
||||
def change
|
||||
add_column :challenge_tags, :challenge_question_id, :integer
|
||||
end
|
||||
end
|
|
@ -0,0 +1,8 @@
|
|||
class ModifyChallengeQuestionIdForChallengeTags < ActiveRecord::Migration
|
||||
def up
|
||||
rename_column :challenge_tags, :challenge_question_id, :challenge_choose_id
|
||||
end
|
||||
|
||||
def down
|
||||
end
|
||||
end
|
|
@ -0,0 +1,8 @@
|
|||
class ModifyTypeForChallengeChooses < ActiveRecord::Migration
|
||||
def up
|
||||
rename_column :challenge_chooses, :type, :category
|
||||
end
|
||||
|
||||
def down
|
||||
end
|
||||
end
|
|
@ -0,0 +1,8 @@
|
|||
class ModifyCorrectTypeForChooseOutputs < ActiveRecord::Migration
|
||||
def up
|
||||
change_column :choose_outputs, :correct, :boolean
|
||||
end
|
||||
|
||||
def down
|
||||
end
|
||||
end
|
|
@ -86,10 +86,10 @@ namespace :homework_publishtime do
|
|||
homework.student_works.where("work_status != 0").each do |student_work|
|
||||
passed_count = homework.homework_detail_manual.answer_open_evaluation ? had_passed_changllenge_num_rake(student_work.myshixun) : had_passed_no_ans_changllenge_num_rake(student_work.myshixun)
|
||||
final_score =(passed_count.to_f / shixun.challenges.count) * 100
|
||||
student_work.final_score = format("%.2f",final_score.to_f)
|
||||
student_work.update_column("final_score", format("%.2f",final_score.to_f))
|
||||
score = student_work.final_score - student_work.late_penalty
|
||||
student_work.work_score = format("%.2f",(score < 0 ? 0 : score).to_f) if score
|
||||
student_work.save
|
||||
student_work.update_column("work_score", format("%.2f",(score < 0 ? 0 : score).to_f))
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -3,23 +3,23 @@
|
|||
*/
|
||||
//---------------侧边固定提示功能---------------//
|
||||
$(function(){
|
||||
var $desc = $("<div class='-task-desc'></div>").appendTo("body");
|
||||
var $descSide = $("<div class='-task-desc'></div>").appendTo("body");
|
||||
$(".-task-sidebar>div").hover(function(){
|
||||
var $tool = $(this).attr("tooltips");
|
||||
$desc.html($tool+"<div><img src='../images/edu_user/jt.png'></div>");
|
||||
$desc.css({
|
||||
left:$(this).offset().left - $desc.width()-30,
|
||||
$descSide.html($tool+"<div><img src='../images/edu_user/jt.png'></div>");
|
||||
$descSide.show().css({
|
||||
left:$(this).offset().left - $descSide.width()-30,
|
||||
opacity:0,
|
||||
top:$(this).offset().top
|
||||
}).stop().animate({
|
||||
left:$(this).offset().left - $desc.width()-5,
|
||||
left:$(this).offset().left - $descSide.width()-5,
|
||||
opacity:1
|
||||
},400);
|
||||
},function(){
|
||||
$desc.stop().animate({
|
||||
left:$(this).offset().left - $desc.width()-30,
|
||||
$descSide.stop().animate({
|
||||
left:$(this).offset().left - $descSide.width()-30,
|
||||
opacity:0
|
||||
},200);
|
||||
},200).hide();
|
||||
});
|
||||
$(window).scroll(function(){
|
||||
if($(document).scrollTop()>0){
|
||||
|
@ -34,60 +34,6 @@ $(function(){
|
|||
|
||||
});
|
||||
//平台tip的样式优化js
|
||||
|
||||
// var $desc = $("<div class=\"-task-title\">"+
|
||||
// "<div class=\"-title-zhixiang tip-down\">"+"<i class=\"fa fa-sort-up\"></i>"+"</div>"+
|
||||
// "<div class=\"-title-zhixiang tip-left\">"+"<i class=\"fa fa-caret-left\"></i>"+"</div>"+
|
||||
// "<div class=\"-title-zhixiang tip-right\">"+"<i class=\"fa fa-caret-right\"></i>"+"</div>"+
|
||||
// "<div class=\"-task-desc-title\"></div>"+
|
||||
// "</div>").appendTo("body");
|
||||
// var $desc1 = $(".-task-desc-title");
|
||||
// $("[data-tip-right]").hover(function(){
|
||||
// $(".tip-left").show();
|
||||
// var $tool = $(this).attr("data-tip-right");
|
||||
// $desc1.html($tool);
|
||||
// $desc.show().css({
|
||||
// left:$(this).offset().left +30,
|
||||
// opacity:0.7,
|
||||
// top:$(this).offset().top-$desc.height()/4
|
||||
// });
|
||||
// },function(){
|
||||
// $(".tip-left").hide();
|
||||
// $desc.css({
|
||||
// opacity:0
|
||||
// }).hide();
|
||||
// });
|
||||
// $("[data-tip-down]").hover(function(){
|
||||
// $(".tip-down").show();
|
||||
// var $tool = $(this).attr("data-tip-down");
|
||||
// $desc1.html($tool);
|
||||
// $desc.show().css({
|
||||
// left:$(this).offset().left -($desc.width()-$(this).width())/2,
|
||||
// opacity:0.7,
|
||||
// top:$(this).offset().top+30
|
||||
// });
|
||||
// },function(){
|
||||
// $(".tip-down").hide();
|
||||
// $desc.css({
|
||||
// opacity:0
|
||||
// }).hide();
|
||||
// });
|
||||
// $("[data-tip-left]").hover(function(){
|
||||
// console.log(1);
|
||||
// $(".tip-right").show();
|
||||
// var $tool = $(this).attr("data-tip-left");
|
||||
// $desc1.html($tool);
|
||||
// $desc.show().css({
|
||||
// left:$(this).offset().left-$desc.width()-10,
|
||||
// opacity:0.7,
|
||||
// top:$(this).offset().top-$desc.height()/4
|
||||
// });
|
||||
// },function(){
|
||||
// $(".tip-right").hide();
|
||||
// $desc.css({
|
||||
// opacity:0
|
||||
// }).hide();
|
||||
// });
|
||||
var $desc = $("<div class=\"-task-title\">"+
|
||||
"<div class=\"data-tip-down\"></div>"+
|
||||
"<div class=\"data-tip-left\"></div>"+
|
||||
|
@ -111,7 +57,7 @@ $(function(){
|
|||
$desc.show().css({
|
||||
left:$(this).offset().left -($desc.width()-$(this).width())/2,
|
||||
opacity:0.7,
|
||||
top:$(this).offset().top+30
|
||||
top:$(this).offset().top + $(this).height() +10
|
||||
});
|
||||
});
|
||||
$("[data-tip-right]").live("mouseenter",function(){
|
||||
|
|
|
@ -275,11 +275,13 @@ $(function(){
|
|||
$(this).parent().parent('ul').find('input[type="text"]').removeAttr('disabled');
|
||||
$(this).parent().parent('ul').find('input[type="text"]').removeClass('disabled-bg');
|
||||
$("#anon_relate_setting_ul").show();
|
||||
var my_date = new Date();
|
||||
var end_date = new Date(Date.parse($("input[name='homework_end_time']").val().replace(/-/g, "/")));
|
||||
var max_date = my_date > end_date ? my_date : end_date;
|
||||
$("input[name='homework_evaluation_start']").val(formate_time(new Date(max_date.setDate(max_date.getDate()+7))));
|
||||
$("input[name='homework_evaluation_end']").val(formate_time(new Date(max_date.setDate(max_date.getDate()+14))));
|
||||
if($("input[name='homework_end_time']").val().trim() != ""){
|
||||
var my_date = new Date();
|
||||
var end_date = new Date(Date.parse($("input[name='homework_end_time']").val().replace(/-/g, "/")));
|
||||
var max_date = my_date > end_date ? my_date : end_date;
|
||||
$("input[name='homework_evaluation_start']").val(formate_time(new Date(max_date.setDate(max_date.getDate()+7))));
|
||||
$("input[name='homework_evaluation_end']").val(formate_time(new Date(max_date.setDate(max_date.getDate()+14))));
|
||||
}
|
||||
$("input[name='homework_evaluation_num']").val("3");
|
||||
$("input[name='homework_absence_penalty']").val("2");
|
||||
$("select[name='st_proportion']").removeAttr('disabled').removeClass('disabled-bg');
|
||||
|
@ -305,10 +307,12 @@ $(function(){
|
|||
if($(this).is(':checked')){
|
||||
$(this).parent().parent('ul').find('input[type="text"]').removeAttr('disabled');
|
||||
$(this).parent().parent('ul').find('input[type="text"]').removeClass('disabled-bg');
|
||||
var my_date = new Date();
|
||||
var end_date = new Date(Date.parse($("input[name='homework_evaluation_end']").val().replace(/-/g, "/")));
|
||||
var max_date = my_date > end_date ? my_date : end_date;
|
||||
$("input[name='homework_appeal_time']").val(formate_time(new Date(max_date.setDate(max_date.getDate()+2))));
|
||||
if($("input[name='homework_evaluation_end']").val().trim() != ""){
|
||||
var my_date = new Date();
|
||||
var end_date = new Date(Date.parse($("input[name='homework_evaluation_end']").val().replace(/-/g, "/")));
|
||||
var max_date = my_date > end_date ? my_date : end_date;
|
||||
$("input[name='homework_appeal_time']").val(formate_time(new Date(max_date.setDate(max_date.getDate()+2))));
|
||||
}
|
||||
$("input[name='homework_appeal_penalty']").val("2");
|
||||
} else{
|
||||
$(this).parent().parent('ul').find('input[type="text"]').attr('disabled', 'disabled');
|
||||
|
@ -435,36 +439,37 @@ $(function(){
|
|||
$("#homework_absence_penalty_notice").hide();
|
||||
}
|
||||
}
|
||||
}
|
||||
if($("input[name='homework_anonymous_appeal']").is(':checked')){
|
||||
if($.trim($("input[name='homework_appeal_time']").val()) == ""){
|
||||
$("#homework_appeal_time_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>申诉结束时间不能为空").show();
|
||||
result = false;
|
||||
} else{
|
||||
var archive_time = Date.parse($("input[name='homework_archive_time']").val());
|
||||
var eva_end = Date.parse($("input[name='homework_evaluation_end']").val());
|
||||
var appeal_time = Date.parse($("input[name='homework_appeal_time']").val());
|
||||
if(eva_end >= appeal_time){
|
||||
$("#homework_appeal_time_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>申诉结束时间应晚于匿评结束时间").show();
|
||||
|
||||
if($("input[name='homework_anonymous_appeal']").is(':checked')){
|
||||
if($.trim($("input[name='homework_appeal_time']").val()) == ""){
|
||||
$("#homework_appeal_time_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>申诉结束时间不能为空").show();
|
||||
result = false;
|
||||
} else if(archive_time <= appeal_time){
|
||||
$("#homework_appeal_time_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>申诉结束时间应早于作业结束时间").show();
|
||||
result = false;
|
||||
} else {
|
||||
$("#homework_appeal_time_notice").hide();
|
||||
}
|
||||
}
|
||||
if($.trim($("input[name='homework_appeal_penalty']").val()) == ""){
|
||||
result = false;
|
||||
$("#homework_appeal_penalty_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>违规匿评扣分不能为空").show();
|
||||
} else{
|
||||
var str = $.trim($("input[name='homework_appeal_penalty']").val());
|
||||
var regex = /^\d+$/;
|
||||
if(!regex.test(str) || parseInt(str) < 0 || parseInt(str) > 50) {
|
||||
result = false;
|
||||
$("#homework_appeal_penalty_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>请输入0-50之间的正整数").show();
|
||||
} else{
|
||||
$("#homework_appeal_penalty_notice").hide();
|
||||
var archive_time = Date.parse($("input[name='homework_archive_time']").val());
|
||||
var eva_end = Date.parse($("input[name='homework_evaluation_end']").val());
|
||||
var appeal_time = Date.parse($("input[name='homework_appeal_time']").val());
|
||||
if(eva_end >= appeal_time){
|
||||
$("#homework_appeal_time_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>申诉结束时间应晚于匿评结束时间").show();
|
||||
result = false;
|
||||
} else if(archive_time <= appeal_time){
|
||||
$("#homework_appeal_time_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>申诉结束时间应早于作业结束时间").show();
|
||||
result = false;
|
||||
} else {
|
||||
$("#homework_appeal_time_notice").hide();
|
||||
}
|
||||
}
|
||||
if($.trim($("input[name='homework_appeal_penalty']").val()) == ""){
|
||||
result = false;
|
||||
$("#homework_appeal_penalty_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>违规匿评扣分不能为空").show();
|
||||
} else{
|
||||
var str = $.trim($("input[name='homework_appeal_penalty']").val());
|
||||
var regex = /^\d+$/;
|
||||
if(!regex.test(str) || parseInt(str) < 0 || parseInt(str) > 50) {
|
||||
result = false;
|
||||
$("#homework_appeal_penalty_notice").html("<i class='fa fa-exclamation-circle mr5 color-orange'></i>请输入0-50之间的正整数").show();
|
||||
} else{
|
||||
$("#homework_appeal_penalty_notice").hide();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -121,9 +121,10 @@ $(function(){
|
|||
});
|
||||
|
||||
// 查看参考答案
|
||||
function open_answer(game, myshixun){
|
||||
function open_answer(game, myshixun, choose){
|
||||
$.ajax({
|
||||
url: "/myshixuns/" + myshixun + "/stages/" + game + "/answer",
|
||||
data:{choose: choose},
|
||||
dataType: "script"
|
||||
})
|
||||
}
|
||||
|
@ -150,11 +151,11 @@ function open_answer(game, myshixun){
|
|||
|
||||
// 选择题选择答案
|
||||
function choice_answer(st, nThis){
|
||||
if(st == "1"){
|
||||
if(st == "2"){
|
||||
//$(nThis).hasClass("card-check") ? $(nThis).removeClass("card-check") : $(nThis).addClass("card-check");
|
||||
$(nThis).toggleClass("card-check");
|
||||
$(nThis).toggleClass("color_white");
|
||||
} else if (st == "2"){
|
||||
} else if (st == "1"){
|
||||
var choice = $(".color_white");
|
||||
choice.removeClass("card-check");
|
||||
choice.removeClass("color_white");
|
||||
|
@ -388,7 +389,6 @@ function code_evaluation(test_sets,
|
|||
"</form>" +
|
||||
"<iframe frameborder=\"0\" name=\"myFrame\" style='background: #fff;height: 100%;'>" +
|
||||
"</iframe>" +
|
||||
"<div class='-brother undis'></div>" +
|
||||
"</div>" +
|
||||
"</div>";
|
||||
|
||||
|
@ -437,13 +437,13 @@ function code_evaluation(test_sets,
|
|||
"<li class=\"clearfix\">" +
|
||||
"<div class=\"clearfix\">" +
|
||||
" <span class=\"-task-ces-info-left color-blue fl fb\">预期输出:</span>" +
|
||||
"<p class=\"fl\">" + ( test_sets[i].output == null ? "空" : test_sets[i].output.replace(/\r\n/g, "<br>").replace(/\t/g, " ").replace(/ /g, "<span class=\"empty\"></span>") ) + "</p>" +
|
||||
"<p class=\"fl\">" + ( test_sets[i].output == null ? "空" : test_sets[i].output.replace(/\r\n/g, "<br><i class=\"fa fa-level-down\" aria-hidden=\"true\"></i>").replace(/\t/g, " ").replace(/ /g, "<span class=\"empty\"></span>") ) + "</p>" +
|
||||
"</div>" +
|
||||
"</li>" +
|
||||
"<li class=\"clearfix\">" +
|
||||
"<div class=\"clearfix\">" +
|
||||
"<span class=\"-task-ces-info-left color-blue fl fb\">实际输出:</span>" +
|
||||
"<p class=\"fl color-orange\">" + (test_sets[i].actual_output == null ? "空" : (test_sets[i].compile_success == "1" ? test_sets[i].actual_output.replace(/\r\n/g, "<br>").replace(/ /g, "<span class=\"empty\"></span>") : test_sets[i].actual_output.replace(/\r\n/g, "<br>"))) + "</p>" +
|
||||
"<p class=\"fl color-orange\">" + (test_sets[i].actual_output == null ? "空" : (test_sets[i].compile_success == "1" ? test_sets[i].actual_output.replace(/\r\n$/, "<br><i class=\"fa fa-level-down\" aria-hidden=\"true\"></i>").replace(/ /g, "<span class=\"empty\"></span>") : test_sets[i].actual_output.replace(/\r\n/g, "<br>"))) + "</p>" +
|
||||
"</div>" +
|
||||
"</li>" +
|
||||
"</ul>" +
|
||||
|
|
|
@ -1,333 +1,333 @@
|
|||
/* Focused windows */
|
||||
.overlay_mac_os_x {
|
||||
background-color: #85BBEF;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.mac_os_x_nw {
|
||||
background: transparent url(mac_os_x/TL_Main.png) no-repeat 0 0;
|
||||
width:24px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.mac_os_x_n {
|
||||
background: transparent url(mac_os_x/T_Main.png) repeat-x 0 0;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.mac_os_x_ne {
|
||||
background: transparent url(mac_os_x/TR_Main.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.mac_os_x_w {
|
||||
background: transparent url(mac_os_x/L_Main.png) repeat-y top left;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_e {
|
||||
background: transparent url(mac_os_x/R_Main.png) repeat-y top right;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_sw {
|
||||
background: transparent url(mac_os_x/BL_Main.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_s {
|
||||
background: transparent url(mac_os_x/B_Main.png) repeat-x 0 0;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_se, .mac_os_x_sizer {
|
||||
background: transparent url(mac_os_x/BR_Main.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.mac_os_x_close {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/close.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:25px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_minimize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/minimize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:45px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_maximize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/maximize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:65px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:12px;
|
||||
text-align:center;
|
||||
margin-top:8px;
|
||||
width:100%;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
.mac_os_x_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background:#FFF;
|
||||
}
|
||||
.mac_os_x_s .status_bar {
|
||||
padding-bottom:24px;
|
||||
}
|
||||
|
||||
/* FOR IE */
|
||||
* html .mac_os_x_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TL_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_n {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/T_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TR_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/L_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/R_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BL_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/B_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
|
||||
/* Focused windows */
|
||||
.overlay_blur_os_x {
|
||||
background-color: #85BBEF;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.blur_os_x_nw {
|
||||
background: transparent url(mac_os_x/TL.png) no-repeat 0 0;
|
||||
width:24px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.blur_os_x_n {
|
||||
background: transparent url(mac_os_x/T.png) repeat-x 0 0;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.blur_os_x_ne {
|
||||
background: transparent url(mac_os_x/TR.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.blur_os_x_w {
|
||||
background: transparent url(mac_os_x/L.png) repeat-y top left;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.blur_os_x_e {
|
||||
background: transparent url(mac_os_x/R.png) repeat-y top right;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.blur_os_x_sw {
|
||||
background: transparent url(mac_os_x/BL.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.blur_os_x_s {
|
||||
background: transparent url(mac_os_x/B.png) repeat-x 0 0;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.blur_os_x_se, .blur_os_x_sizer {
|
||||
background: transparent url(mac_os_x/BR.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.blur_os_x_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.blur_os_x_close {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/close.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:25px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.blur_os_x_minimize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/minimize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:45px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.blur_os_x_maximize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/maximize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:65px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.blur_os_x_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:12px;
|
||||
text-align:center;
|
||||
margin-top:8px;
|
||||
width:100%;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
.blur_os_x_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background:#FFF;
|
||||
}
|
||||
.blur_os_x_s .status_bar {
|
||||
padding-bottom:24px;
|
||||
}
|
||||
|
||||
/* FOR IE */
|
||||
* html .blur_os_x_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TL.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_n {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/T.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/L.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/R.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BL.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/B.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
/* Focused windows */
|
||||
.overlay_mac_os_x {
|
||||
background-color: #85BBEF;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.mac_os_x_nw {
|
||||
background: transparent url(mac_os_x/TL_Main.png) no-repeat 0 0;
|
||||
width:24px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.mac_os_x_n {
|
||||
background: transparent url(mac_os_x/T_Main.png) repeat-x 0 0;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.mac_os_x_ne {
|
||||
background: transparent url(mac_os_x/TR_Main.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.mac_os_x_w {
|
||||
background: transparent url(mac_os_x/L_Main.png) repeat-y top left;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_e {
|
||||
background: transparent url(mac_os_x/R_Main.png) repeat-y top right;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_sw {
|
||||
background: transparent url(mac_os_x/BL_Main.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_s {
|
||||
background: transparent url(mac_os_x/B_Main.png) repeat-x 0 0;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_se, .mac_os_x_sizer {
|
||||
background: transparent url(mac_os_x/BR_Main.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.mac_os_x_close {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/close.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:25px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_minimize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/minimize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:45px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_maximize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/maximize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:65px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:12px;
|
||||
text-align:center;
|
||||
margin-top:8px;
|
||||
width:100%;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
.mac_os_x_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background:#FFF;
|
||||
}
|
||||
.mac_os_x_s .status_bar {
|
||||
padding-bottom:24px;
|
||||
}
|
||||
|
||||
/* FOR IE */
|
||||
* html .mac_os_x_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TL_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_n {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/T_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TR_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/L_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/R_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BL_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/B_Main.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR_Main.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
|
||||
/* Focused windows */
|
||||
.overlay_blur_os_x {
|
||||
background-color: #85BBEF;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.blur_os_x_nw {
|
||||
background: transparent url(mac_os_x/TL.png) no-repeat 0 0;
|
||||
width:24px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.blur_os_x_n {
|
||||
background: transparent url(mac_os_x/T.png) repeat-x 0 0;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.blur_os_x_ne {
|
||||
background: transparent url(mac_os_x/TR.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:30px;
|
||||
}
|
||||
|
||||
.blur_os_x_w {
|
||||
background: transparent url(mac_os_x/L.png) repeat-y top left;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.blur_os_x_e {
|
||||
background: transparent url(mac_os_x/R.png) repeat-y top right;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.blur_os_x_sw {
|
||||
background: transparent url(mac_os_x/BL.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.blur_os_x_s {
|
||||
background: transparent url(mac_os_x/B.png) repeat-x 0 0;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.blur_os_x_se, .blur_os_x_sizer {
|
||||
background: transparent url(mac_os_x/BR.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.blur_os_x_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.blur_os_x_close {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/close.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:25px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.blur_os_x_minimize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/minimize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:45px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.blur_os_x_maximize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x/maximize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:65px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.blur_os_x_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:12px;
|
||||
text-align:center;
|
||||
margin-top:8px;
|
||||
width:100%;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
.blur_os_x_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background:#FFF;
|
||||
}
|
||||
.blur_os_x_s .status_bar {
|
||||
padding-bottom:24px;
|
||||
}
|
||||
|
||||
/* FOR IE */
|
||||
* html .blur_os_x_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TL.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_n {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/T.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/TR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/L.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/R.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BL.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/B.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .blur_os_x_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .blur_os_x_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
|
|
|
@ -1,160 +1,160 @@
|
|||
.overlay_mac_os_x_dialog {
|
||||
background-color: #FF7224;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_nw {
|
||||
background: transparent url(mac_os_x_dialog/L.png) repeat-y top left;
|
||||
width:16px;
|
||||
height:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_n {
|
||||
background: transparent url(mac_os_x_dialog/bg.gif) repeat 0 0;
|
||||
height:18px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_ne {
|
||||
background: transparent url(mac_os_x_dialog/R.png) repeat-y top left;
|
||||
width:16px;
|
||||
height:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_w {
|
||||
background: transparent url(mac_os_x_dialog/L.png) repeat-y top left;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_e {
|
||||
background: transparent url(mac_os_x_dialog/R.png) repeat-y top right;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_sw {
|
||||
background: transparent url(mac_os_x_dialog/BL.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_s {
|
||||
background: transparent url(mac_os_x_dialog/B.png) repeat-x 0 0;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_se, .mac_os_x_dialog_sizer {
|
||||
background: transparent url(mac_os_x_dialog/BR.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_close {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x_dialog/close.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:25px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_minimize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x_dialog/minimize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:45px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_maximize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x_dialog/maximize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:65px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:12px;
|
||||
text-align:center;
|
||||
margin-top:6px;
|
||||
width:100%;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background: transparent url(mac_os_x_dialog/bg.gif) repeat 0 0;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_buttons {
|
||||
text-align: center;
|
||||
}
|
||||
/* FOR IE */
|
||||
* html .mac_os_x_dialog_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/L.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
|
||||
* html .mac_os_x_dialog_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/R.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/L.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/R.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/BL.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/B.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
.overlay_mac_os_x_dialog {
|
||||
background-color: #FF7224;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_nw {
|
||||
background: transparent url(mac_os_x_dialog/L.png) repeat-y top left;
|
||||
width:16px;
|
||||
height:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_n {
|
||||
background: transparent url(mac_os_x_dialog/bg.gif) repeat 0 0;
|
||||
height:18px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_ne {
|
||||
background: transparent url(mac_os_x_dialog/R.png) repeat-y top left;
|
||||
width:16px;
|
||||
height:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_w {
|
||||
background: transparent url(mac_os_x_dialog/L.png) repeat-y top left;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_e {
|
||||
background: transparent url(mac_os_x_dialog/R.png) repeat-y top right;
|
||||
width:16px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_sw {
|
||||
background: transparent url(mac_os_x_dialog/BL.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_s {
|
||||
background: transparent url(mac_os_x_dialog/B.png) repeat-x 0 0;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_se, .mac_os_x_dialog_sizer {
|
||||
background: transparent url(mac_os_x_dialog/BR.png) no-repeat 0 0;
|
||||
width:31px;
|
||||
height:40px;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_close {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x_dialog/close.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:25px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_minimize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x_dialog/minimize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:45px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_maximize {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
background: transparent url(mac_os_x_dialog/maximize.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:12px;
|
||||
left:65px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:12px;
|
||||
text-align:center;
|
||||
margin-top:6px;
|
||||
width:100%;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background: transparent url(mac_os_x_dialog/bg.gif) repeat 0 0;
|
||||
}
|
||||
|
||||
.mac_os_x_dialog_buttons {
|
||||
text-align: center;
|
||||
}
|
||||
/* FOR IE */
|
||||
* html .mac_os_x_dialog_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/L.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
|
||||
* html .mac_os_x_dialog_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/R.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/L.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/R.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/BL.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/B.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .mac_os_x_dialog_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/mac_os_x_dialog/BR.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
|
|
|
@ -1,164 +1,164 @@
|
|||
.overlay_nuncio img { border: none; }
|
||||
|
||||
.overlay_nuncio {
|
||||
background-color: #666666;
|
||||
}
|
||||
|
||||
.nuncio_nw {
|
||||
width: 12px;
|
||||
height: 28px;
|
||||
background: url(nuncio/top_left.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_n {
|
||||
background: url(nuncio/top_mid.png) repeat-x;
|
||||
height: 28px;
|
||||
}
|
||||
|
||||
.nuncio_ne {
|
||||
width: 21px;
|
||||
height: 28px;
|
||||
background: url(nuncio/top_right.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_e {
|
||||
width: 21px;
|
||||
background: url(nuncio/center_right.png) repeat-y top right;
|
||||
}
|
||||
|
||||
.nuncio_w {
|
||||
width: 12px;
|
||||
background: url(nuncio/center_left.png) repeat-y top left;
|
||||
}
|
||||
|
||||
.nuncio_sw {
|
||||
width: 12px;
|
||||
height: 18px;
|
||||
background: url(nuncio/bottom_left.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_s {
|
||||
background: url(nuncio/bottom_mid.png) repeat-x 0 0;
|
||||
height: 18px;
|
||||
}
|
||||
|
||||
.nuncio_se, .nuncio_sizer {
|
||||
width: 21px;
|
||||
height: 18px;
|
||||
background: url(nuncio/bottom_right.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_close {
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
background: url(nuncio/close.png) no-repeat;
|
||||
position:absolute;
|
||||
top:10px;
|
||||
right:22px;
|
||||
cursor:pointer;
|
||||
z-index:2000;
|
||||
}
|
||||
|
||||
.nuncio_minimize {
|
||||
width: 14px;
|
||||
height: 15px;
|
||||
background: url(nuncio/minimize.png) no-repeat;
|
||||
position:absolute;
|
||||
top:10px;
|
||||
right:40px;
|
||||
cursor:pointer;
|
||||
z-index:2000;
|
||||
}
|
||||
|
||||
.nuncio_title {
|
||||
float:left;
|
||||
font-size:11px;
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
color: #fff;
|
||||
width: 100%
|
||||
}
|
||||
|
||||
.nuncio_content {
|
||||
background: url(nuncio/overlay.png) repeat;
|
||||
overflow:auto;
|
||||
color: #ddd;
|
||||
font-family: Tahoma, Arial, "sans-serif";
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.nuncio_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
|
||||
.top_draggable, .bottom_draggable {
|
||||
cursor:move
|
||||
}
|
||||
/* FOR IE */
|
||||
* html .nuncio_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/top_left.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_n {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/top_mid.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/top_right.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/center_left.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/center_right.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_left.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_mid.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_right.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_right.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_close {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/close.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_minimize {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/minimize.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
.overlay_nuncio img { border: none; }
|
||||
|
||||
.overlay_nuncio {
|
||||
background-color: #666666;
|
||||
}
|
||||
|
||||
.nuncio_nw {
|
||||
width: 12px;
|
||||
height: 28px;
|
||||
background: url(nuncio/top_left.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_n {
|
||||
background: url(nuncio/top_mid.png) repeat-x;
|
||||
height: 28px;
|
||||
}
|
||||
|
||||
.nuncio_ne {
|
||||
width: 21px;
|
||||
height: 28px;
|
||||
background: url(nuncio/top_right.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_e {
|
||||
width: 21px;
|
||||
background: url(nuncio/center_right.png) repeat-y top right;
|
||||
}
|
||||
|
||||
.nuncio_w {
|
||||
width: 12px;
|
||||
background: url(nuncio/center_left.png) repeat-y top left;
|
||||
}
|
||||
|
||||
.nuncio_sw {
|
||||
width: 12px;
|
||||
height: 18px;
|
||||
background: url(nuncio/bottom_left.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_s {
|
||||
background: url(nuncio/bottom_mid.png) repeat-x 0 0;
|
||||
height: 18px;
|
||||
}
|
||||
|
||||
.nuncio_se, .nuncio_sizer {
|
||||
width: 21px;
|
||||
height: 18px;
|
||||
background: url(nuncio/bottom_right.png) no-repeat;
|
||||
}
|
||||
|
||||
.nuncio_close {
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
background: url(nuncio/close.png) no-repeat;
|
||||
position:absolute;
|
||||
top:10px;
|
||||
right:22px;
|
||||
cursor:pointer;
|
||||
z-index:2000;
|
||||
}
|
||||
|
||||
.nuncio_minimize {
|
||||
width: 14px;
|
||||
height: 15px;
|
||||
background: url(nuncio/minimize.png) no-repeat;
|
||||
position:absolute;
|
||||
top:10px;
|
||||
right:40px;
|
||||
cursor:pointer;
|
||||
z-index:2000;
|
||||
}
|
||||
|
||||
.nuncio_title {
|
||||
float:left;
|
||||
font-size:11px;
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
color: #fff;
|
||||
width: 100%
|
||||
}
|
||||
|
||||
.nuncio_content {
|
||||
background: url(nuncio/overlay.png) repeat;
|
||||
overflow:auto;
|
||||
color: #ddd;
|
||||
font-family: Tahoma, Arial, "sans-serif";
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.nuncio_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
|
||||
.top_draggable, .bottom_draggable {
|
||||
cursor:move
|
||||
}
|
||||
/* FOR IE */
|
||||
* html .nuncio_nw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/top_left.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_n {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/top_mid.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_ne {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/top_right.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_w {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/center_left.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_e {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/center_right.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_sw {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_left.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_s {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_mid.png", sizingMethod="scale");
|
||||
}
|
||||
|
||||
* html .nuncio_se {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_right.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_sizer {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/bottom_right.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_close {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/close.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
* html .nuncio_minimize {
|
||||
background-color: transparent;
|
||||
background-image: none;
|
||||
filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../themes/nuncio/minimize.png", sizingMethod="crop");
|
||||
}
|
||||
|
||||
|
|
|
@ -1,108 +1,108 @@
|
|||
.overlay_spread {
|
||||
background-color: #85BBEF;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.spread_nw {
|
||||
background: transparent url(spread/left-top.gif) no-repeat 0 0;
|
||||
width:10px;
|
||||
height:25px;
|
||||
}
|
||||
|
||||
.spread_n {
|
||||
background: transparent url(spread/top-middle.gif) repeat-x 0 0;
|
||||
height:25px;
|
||||
}
|
||||
|
||||
.spread_ne {
|
||||
background: transparent url(spread/right-top.gif) no-repeat 0 0;
|
||||
width:10px;
|
||||
height:25px;
|
||||
}
|
||||
|
||||
.spread_w {
|
||||
background: transparent url(spread/frame-left.gif) repeat-y top left;
|
||||
width:7px;
|
||||
}
|
||||
|
||||
.spread_e {
|
||||
background: transparent url(spread/frame-right.gif) repeat-y top right;
|
||||
width:7px;
|
||||
}
|
||||
|
||||
.spread_sw {
|
||||
background: transparent url(spread/bottom-left-c.gif) no-repeat 0 0;
|
||||
width:7px;
|
||||
height:7px;
|
||||
}
|
||||
|
||||
.spread_s {
|
||||
background: transparent url(spread/bottom-middle.gif) repeat-x 0 0;
|
||||
height:7px;
|
||||
}
|
||||
|
||||
.spread_se, .spread_sizer {
|
||||
background: transparent url(spread/bottom-right-c.gif) no-repeat 0 0;
|
||||
width:7px;
|
||||
height:7px;
|
||||
}
|
||||
|
||||
.spread_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.spread_close {
|
||||
width: 23px;
|
||||
height: 23px;
|
||||
background: transparent url(spread/button-close-focus.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:0px;
|
||||
right:11px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.spread_minimize {
|
||||
width: 23px;
|
||||
height: 23px;
|
||||
background: transparent url(spread/button-min-focus.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:0px;
|
||||
right:55px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.spread_maximize {
|
||||
width: 23px;
|
||||
height: 23px;
|
||||
background: transparent url(spread/button-max-focus.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:0px;
|
||||
right:33px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.spread_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:14px;
|
||||
font-weight:bold;
|
||||
text-align:left;
|
||||
margin-top:2px;
|
||||
width:100%;
|
||||
color:#E47211;
|
||||
}
|
||||
|
||||
.spread_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background:#A9EA00;
|
||||
}
|
||||
|
||||
.overlay_spread {
|
||||
background-color: #85BBEF;
|
||||
filter:alpha(opacity=60);
|
||||
-moz-opacity: 0.6;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.spread_nw {
|
||||
background: transparent url(spread/left-top.gif) no-repeat 0 0;
|
||||
width:10px;
|
||||
height:25px;
|
||||
}
|
||||
|
||||
.spread_n {
|
||||
background: transparent url(spread/top-middle.gif) repeat-x 0 0;
|
||||
height:25px;
|
||||
}
|
||||
|
||||
.spread_ne {
|
||||
background: transparent url(spread/right-top.gif) no-repeat 0 0;
|
||||
width:10px;
|
||||
height:25px;
|
||||
}
|
||||
|
||||
.spread_w {
|
||||
background: transparent url(spread/frame-left.gif) repeat-y top left;
|
||||
width:7px;
|
||||
}
|
||||
|
||||
.spread_e {
|
||||
background: transparent url(spread/frame-right.gif) repeat-y top right;
|
||||
width:7px;
|
||||
}
|
||||
|
||||
.spread_sw {
|
||||
background: transparent url(spread/bottom-left-c.gif) no-repeat 0 0;
|
||||
width:7px;
|
||||
height:7px;
|
||||
}
|
||||
|
||||
.spread_s {
|
||||
background: transparent url(spread/bottom-middle.gif) repeat-x 0 0;
|
||||
height:7px;
|
||||
}
|
||||
|
||||
.spread_se, .spread_sizer {
|
||||
background: transparent url(spread/bottom-right-c.gif) no-repeat 0 0;
|
||||
width:7px;
|
||||
height:7px;
|
||||
}
|
||||
|
||||
.spread_sizer {
|
||||
cursor:se-resize;
|
||||
}
|
||||
|
||||
.spread_close {
|
||||
width: 23px;
|
||||
height: 23px;
|
||||
background: transparent url(spread/button-close-focus.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:0px;
|
||||
right:11px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.spread_minimize {
|
||||
width: 23px;
|
||||
height: 23px;
|
||||
background: transparent url(spread/button-min-focus.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:0px;
|
||||
right:55px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.spread_maximize {
|
||||
width: 23px;
|
||||
height: 23px;
|
||||
background: transparent url(spread/button-max-focus.gif) no-repeat 0 0;
|
||||
position:absolute;
|
||||
top:0px;
|
||||
right:33px;
|
||||
cursor:pointer;
|
||||
z-index:1000;
|
||||
}
|
||||
|
||||
.spread_title {
|
||||
float:left;
|
||||
height:14px;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size:14px;
|
||||
font-weight:bold;
|
||||
text-align:left;
|
||||
margin-top:2px;
|
||||
width:100%;
|
||||
color:#E47211;
|
||||
}
|
||||
|
||||
.spread_content {
|
||||
overflow:auto;
|
||||
color: #222;
|
||||
font-family: Tahoma, Arial, sans-serif;
|
||||
font-size: 10px;
|
||||
background:#A9EA00;
|
||||
}
|
||||
|
||||
|
|
|
@ -67,7 +67,7 @@ table.table-pa5 th,table.table-pa5 td{ padding:0 5px;}
|
|||
|
||||
/* 与课程通用框架和tab 17/05/11 bylinda*/
|
||||
.edu-class-con{ width:50%; margin:0px auto; font-size:14px; padding:50px 0;}
|
||||
.edu-con-bg01{ width: 100%; -background:#fff;}
|
||||
.edu-con-bg01{ width: 100%; background:#fff;}
|
||||
.edu-class-box{ width:100%;}
|
||||
.edu-class-container{ width: 1200px; margin:10px auto 20px;}
|
||||
.edu-class-top{ background:#fff; padding:20px;}
|
||||
|
|
|
@ -153,6 +153,8 @@ a:hover.task-btn-ver{background:#5f7cab;}
|
|||
.new_login_submit:hover{background: #19b17e;}
|
||||
a.task-btn-email{display: inline-block;font-weight: bold;border: none; width:185px;color: #666;background: #e1e1e1;letter-spacing: 1px;text-align: center;font-size: 14px;height: 40px;line-height: 40px;border-radius: 3px;}
|
||||
a:hover.task-btn-email {background: #c3c3c3; color: #666;}
|
||||
.white-btn{cursor: pointer;display: inline-block;padding: 0 12px;border: none;letter-spacing: 1px;font-size: 14px;height: 30px;line-height: 30px;border-radius: 3px;}
|
||||
a.white-btn.green-btn{color:#29bd8b;border:1px solid #29bd8b; }
|
||||
/*07-11 新添加的公用样式 cs*/
|
||||
a.course-btn{cursor: pointer;font-weight: bold;border-radius: 4px;display: inline-block;width: auto;padding: 0px 12px;background-color: #FFFFFF;color: #44bfa3;letter-spacing: 1px;height: 30px;line-height: 30px;}
|
||||
.bc-grey{background-color: #CCCCCC!important;}
|
||||
|
@ -348,7 +350,7 @@ html>body #ajax-indicator { position: fixed; }
|
|||
/*最新和最热导航条的公用样式*/
|
||||
|
||||
.nav_check_item{margin-bottom:13px;border-bottom: 2px solid #FC7033;}
|
||||
.nav_check_item li{width:auto;width: 80px;text-align: center;cursor: pointer;height: 38px;line-height: 38px;}
|
||||
.nav_check_item li{width:auto;width: 80px;text-align: center;cursor: pointer;height: 38px;line-height: 38px;border-top-right-radius:5px;border-top-left-radius:5px;}
|
||||
.nav_check_item li a{display: block;}
|
||||
|
||||
.check_nav{background: #FC7033;color: #ffffff;}
|
||||
|
@ -396,7 +398,7 @@ input::-ms-clear{display:none;}
|
|||
.background-orange{background: #FC7033!important;}
|
||||
.back-orange-main{background: #FC7500!important;}/*主流橙色*/
|
||||
.back-orange-01{background: #FF9e6a!important;}/*带背景标题、带色彩分割线和操作入口*/
|
||||
|
||||
.back-f6-grey{background: #F6F6F6;}
|
||||
.background-blue a{color:#ffffff!important;}
|
||||
.background-orange a{color: #ffffff!important;}
|
||||
/*---------------tab公用边框-----------------*/
|
||||
|
@ -408,7 +410,7 @@ input::-ms-clear{display:none;}
|
|||
.bor-gray-c{border:1px solid #ccc;}
|
||||
.bor-grey-e{border:1px solid #eee;}
|
||||
.bor-grey01{border:1px solid #E6EAEB;}
|
||||
/*-------------------------tip样式-------------------------*/
|
||||
.bor-blue{border:1px solid #5faee3;}/*-------------------------tip样式-------------------------*/
|
||||
/*.-task-title{opacity:0;position:absolute;left:0;top:0;display:none;}*/
|
||||
/*.-task-desc-title{background:#000;color:#fff;box-shadow:0px 0px 8px #194a81;max-width:300px;word-wrap: break-word;text-align:center;border-radius:10px;padding:0 10px;}*/
|
||||
/*.-title-zhixiang{color:#000;position:absolute;display:none;}*/
|
||||
|
@ -463,3 +465,6 @@ a.white-btn.orange-btn:hover{color: #FFFFFF;border: 1px solid #FF7500;background
|
|||
.white-btn{cursor: pointer;display: inline-block;padding: 0 12px;border: none;letter-spacing: 1px;font-size: 14px;height: 30px;line-height: 30px;border-radius: 3px;}
|
||||
.courseRefer{float:left; max-height:120px;margin-bottom:10px;overflow:auto; overflow-x:hidden;}
|
||||
.logo {width: 295px;height: 30px;border-style:none;position: absolute;top:50%;left:39%;}
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -263,7 +263,7 @@ img.edu-nodata-img{ width:200px; margin:50px auto 20px; display: block;}
|
|||
/* new tab */
|
||||
.edu-tab{ width: 100%; background:#fff;}
|
||||
#edu-tab-nav{height:47px;background: #fff;}
|
||||
#edu-tab-nav li.new-tab-nav {float:left; width: 150px; text-align:center;height:48px;line-height:48px; }
|
||||
#edu-tab-nav li.new-tab-nav {float:left; width: 150px; text-align:center;height:48px;line-height:48px;border-top-right-radius:5px;border-top-left-radius:5px; }
|
||||
#edu-tab-nav li a{font-size:14px; }
|
||||
#edu-user-tab-nav{height:40px;background: #f5f5f5; border-bottom:2px solid #FC7033;}
|
||||
#edu-user-tab-nav li.new-tab-nav {float:left; width: 120px; text-align:center;height:42px;line-height:42px;border-top-left-radius: 5px;border-top-right-radius:5px}
|
||||
|
|
|
@ -29,10 +29,10 @@
|
|||
/*.-task-con-data .top .top-right .itnew .p2{}*/
|
||||
.-task-con-data .top .top-right .itnew .p2{color:#ccc;}
|
||||
.-task-con-data .top .top-right .itnew .sub a{border:1px solid #e5e5e5;display:inline-block;padding:2px 10px;text-align:center;border-radius:5px;}
|
||||
.-task-con-data .top .top-right .itnew .sub a:hover{background:#FF7500!important;color:#fff;}
|
||||
.-task-con-data .top .top-right .itnew .sub a:hover{background:#FF7500!important;color:#fff;border:none;}
|
||||
.-task-con-data .top .top-right .itnew .sub{width:100%;}
|
||||
.-task-con-data .bot input{width:100%;height:40px;line-height:40px;border:none;outline:none;background:#fff;}
|
||||
.-task-con-data .bot p{width: 100%; height: 25px; background: #fff;}
|
||||
.-task-con-data .bot p{width: 100%; height: 40px;line-height:40px; background: #fff;}
|
||||
/*-----------------博客------------------------*/
|
||||
.-task-con-int .blog,.favour{width:100%;background:#fff;}
|
||||
.-task-con-int .blog .p1{width:100%;height:40px;background:#f2f2f2;line-height:40px;text-indent:10px;}
|
||||
|
@ -229,6 +229,7 @@ input.new_loggin_input_test{ -webkit-box-shadow: 0 0 0px 1000px white inset; ou
|
|||
|
||||
.edu-table{width: 100%;border: 1px solid #cccccc;background: #ffffff;border-collapse: collapse;}
|
||||
.panel-cer-content .edu-table thead{background: #f5f5f5}
|
||||
.panel-cer-content .edu-table tr th{padding: 6px 10px;}
|
||||
.panel-cer-content .edu-table tr td{padding: 0px;border: none;border: 1px solid #ccc;padding: 6px 10px;}
|
||||
.panel-cer-content .edu-table tr td:nth-child(1){text-align:right;width: 25%;color: #666666}
|
||||
.panel-cer-content .edu-table tr td:nth-child(2){text-align:left;color: #333333;}
|
||||
|
|
|
@ -48,9 +48,9 @@ a.rightbar-pause{ color:#29bd8b; font-size: 18px; margin-right:15px; margin-top:
|
|||
#tab_nav li {float:left; padding:0 30px;text-align:center;height: 40px;line-height: 40px; }
|
||||
#tab_nav li a{font-size:14px; }
|
||||
.tab_hover {border-bottom:1px solid #fff; background: #fff;}
|
||||
.tab_hover_setting{background:#FC7033;}
|
||||
/*.tab_hover_setting{background:#FC7033;}*/
|
||||
.tab_hover a{ color:#29bd8b;}
|
||||
.tab_hover_setting a{color:#fff;}
|
||||
/*.tab_hover_setting a{color:#fff;}*/
|
||||
.undis {display:none;}
|
||||
.dis {display:block;}
|
||||
.tab-info{ }
|
||||
|
@ -370,8 +370,8 @@ a.shixun-task-ban-btn{background-color: #c2c4c6;display: inline-block;font-weigh
|
|||
|
||||
/*--------TPI的答案选项卡------*/
|
||||
.quiz-task-options:not(.-compact) {padding:10px;}
|
||||
.card {position: relative;background: #515151;border-radius: 2px;overflow: hidden;}
|
||||
.card:hover{background: #3f3f3f;}
|
||||
.card {position: relative;border-radius: 2px;overflow: hidden;}
|
||||
/*.card:hover{background: #3f3f3f;}*/
|
||||
.card-check{background: #3498db!important;}
|
||||
.-justify {justify-content: space-between;}
|
||||
.-center { align-items: center;min-height: 66px;}
|
||||
|
@ -415,3 +415,5 @@ html>body #ajax-indicator-base { position: fixed; }
|
|||
.save-tip{display:none;position: fixed;top:0px;left: 0px;width: 100%;height: 100%;}
|
||||
.save-tip-content{position: absolute;top:50%;left: 50%;margin-left: -36px;margin-top:-19px;background: rgba(0,0,0,0.7);color:#fff;padding:5px 15px;border-radius: 4px}
|
||||
.empty{background: #494A4C;display: inline; margin: 0 2px; padding: 0 3px;}
|
||||
|
||||
.nav_check_item li{padding: 0px 17px!important;}
|
||||
|
|
Loading…
Reference in New Issue