You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
2.2 KiB
41 lines
2.2 KiB
<% if params[:update_rep] == "1" %>
|
|
hide_tip_content();
|
|
<% end %>
|
|
<% if params[:test_sets_view] == "true" %>
|
|
notice_box("解锁成功!");
|
|
<% end %>
|
|
<% if params[:choose].present? %>
|
|
clearInterval(cm); // tpi关闭耗时
|
|
$("#game_show_content").html('<%= escape_javascript(render :partial => 'games/game_show') %>');
|
|
// 选择题
|
|
<% if params[:choose] == "true" %>
|
|
<% if @game_challenge.position != @myshixun.games.count %>
|
|
$("#code_estimate").html("<a href='<%= next_step_myshixun_game_path(@game, :myshixun_id => @myshixun) %>' class='task-btn task-btn-orange mr15 mt8' id='next_step'>下一关</a>");
|
|
<% end %>
|
|
<% if @had_done == 0 %>
|
|
var htmlvalue = "<%= j (render :partial => 'games/pass_game_show', :locals => { :game=> @game, :myshixun => @myshixun, :had_done => 0}) %>";
|
|
<% else %>
|
|
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 %>
|
|
<% elsif params[:index].nil? %>
|
|
clearInterval(cm); // tpi关闭耗时
|
|
$("#picture_display").hide(); // 图片类实训通关后,点击下一关需要隐藏图片显示层
|
|
<% if @type == "root" || !params[:path].nil? %>
|
|
$("#games_repository_contents").html('<%= escape_javascript(render :partial => 'games/repository') %>');
|
|
<% else %>
|
|
$("#game_show_content").html('<%= escape_javascript(render :partial => 'games/game_show') %>');
|
|
<% end %>
|
|
$("#myshixun_top").html('<%= escape_javascript(render :partial => 'myshixuns/myshixun_top') %>');
|
|
$("#current_task_tab").attr('href','<%= myshixun_game_path(@myshixun.current_task, :myshixun_id => @myshixun) %>');
|
|
$("#all_task_show").html("<%= j (render :partial => "games_list") %>");
|
|
$("#all_task_show").hide();
|
|
fadein = 0;
|
|
clearInterval(sh);
|
|
<% else %>
|
|
$("#all_task_show").html("<%= j (render :partial => "games_list") %>");
|
|
$("#all_task_tab").trigger("click"); // 模拟全部任务点击事件
|
|
<% end %>
|