diff --git a/app/controllers/games_controller.rb b/app/controllers/games_controller.rb index c93e4c2ca..3031dccbc 100644 --- a/app/controllers/games_controller.rb +++ b/app/controllers/games_controller.rb @@ -156,12 +156,13 @@ class GamesController < ApplicationController shixun_tomcat = Redmine::Configuration['shixun_tomcat'] uri = "#{shixun_tomcat}/bridge/game/getWaitingTime" params = {:tpiID => "#{@myshixun.id}"} + resubmit = @_params['resubmit'] res = uri_exec uri, params if (res && res['code'] != 0) @message = "实训云平台繁忙(繁忙等级:94)" raise("实训云平台繁忙(繁忙等级:94)") end - render :json => {:result => "success", :onRun => res['onRun'], :waitNum => res['waitNum'], :waitingTime => res['waitingTime'] } + render :json => {:result => "success", :onRun => res['onRun'], :waitNum => res['waitNum'], :waitingTime => res['waitingTime'], :resubmit => resubmit } #render :json => {:result => "success", :onRun => 1, :waitNum => 12, :waitingTime => 546 } rescue Exception => e render :json => {:result => "failed"} diff --git a/app/views/challenges/_content_list.html.erb b/app/views/challenges/_content_list.html.erb index f425f70ab..5f331cfed 100644 --- a/app/views/challenges/_content_list.html.erb +++ b/app/views/challenges/_content_list.html.erb @@ -1,4 +1,4 @@ -
+

全部任务

<% if @challenges.count != 0 %> diff --git a/app/views/challenges/index.html.erb b/app/views/challenges/index.html.erb index 56affc61d..57f1913fc 100644 --- a/app/views/challenges/index.html.erb +++ b/app/views/challenges/index.html.erb @@ -10,7 +10,7 @@ <% if @shixun.status == 1 && (User.current.manager_of_shixun?(@shixun) || User.current.admin?) %>
正在等待管理员的审核。如果需要编辑更新,请先撤销发布
<% end %> -
+

简介

diff --git a/app/views/games/_code_actions.html.erb b/app/views/games/_code_actions.html.erb index 9044a7fa0..c1bd54ac9 100644 --- a/app/views/games/_code_actions.html.erb +++ b/app/views/games/_code_actions.html.erb @@ -180,6 +180,7 @@ timeID = setInterval(function(){ $.ajax({ url: '<%= get_waiting_time_myshixun_game_path(@game, :myshixun_id => @myshixun) %>', + data:{resubmit:data.resubmit}, async: false, success: function(data){ console.log(data); diff --git a/app/views/layouts/base_shixun.html.erb b/app/views/layouts/base_shixun.html.erb index 8e2e16f05..aa188b0b6 100644 --- a/app/views/layouts/base_shixun.html.erb +++ b/app/views/layouts/base_shixun.html.erb @@ -24,7 +24,7 @@
<%= render :partial => 'shixuns/shixun_top' %>
-
+
  • " id="shixun_tab">实训
  • " >背景知识
  • diff --git a/app/views/repositories/_shixun_dir_list.html.erb b/app/views/repositories/_shixun_dir_list.html.erb index f248cc678..037d6afec 100644 --- a/app/views/repositories/_shixun_dir_list.html.erb +++ b/app/views/repositories/_shixun_dir_list.html.erb @@ -1,5 +1,5 @@
    - +
    <% unless @path.blank? %> diff --git a/app/views/repositories/shixun_show.html.erb b/app/views/repositories/shixun_show.html.erb index 27ccaa746..287b74392 100644 --- a/app/views/repositories/shixun_show.html.erb +++ b/app/views/repositories/shixun_show.html.erb @@ -9,7 +9,7 @@

    -
      +
      • <%=link_to "#{choise_commit_count(@changesets_all_count, @g_project.commit_count.to_i)}", {:action => 'commits', :path => to_path_param(@path), :id => @shixun, :repository_id => @repository.identifier_param, diff --git a/app/views/shixuns/_form.html.erb b/app/views/shixuns/_form.html.erb index fef674277..3429f1b81 100644 --- a/app/views/shixuns/_form.html.erb +++ b/app/views/shixuns/_form.html.erb @@ -1,6 +1,6 @@ <%= stylesheet_link_tag '/editormd/css/editormd' %> <%= javascript_include_tag '/editormd/editormd' %> -
        +
          diff --git a/app/views/shixuns/_shixun_list.html.erb b/app/views/shixuns/_shixun_list.html.erb index 184a19a98..92ab5dbe6 100644 --- a/app/views/shixuns/_shixun_list.html.erb +++ b/app/views/shixuns/_shixun_list.html.erb @@ -1,4 +1,11 @@ - +
          <% if @shixuns.blank? %>
          diff --git a/app/views/shixuns/collaborators.html.erb b/app/views/shixuns/collaborators.html.erb index e181d1b6c..51e692ece 100644 --- a/app/views/shixuns/collaborators.html.erb +++ b/app/views/shixuns/collaborators.html.erb @@ -1,4 +1,4 @@ -
          +
          <%= image_tag(url_to_avatar(@shixun.owner), :width => 60, :height => 60, :class => 'panel-list-img mr15 mt5') %>
            diff --git a/app/views/shixuns/index.html.erb b/app/views/shixuns/index.html.erb index 900b16976..a6583fef3 100644 --- a/app/views/shixuns/index.html.erb +++ b/app/views/shixuns/index.html.erb @@ -179,17 +179,7 @@
            - -
            <%= render "shixun_list" %> -
          @@ -197,6 +187,12 @@ <%= render :partial => 'layouts/public_left_info' %>