dev_jupyter
daiao 5 years ago
parent 6d2500e253
commit 0094e94b03

@ -162,7 +162,7 @@ class ChallengesController < ApplicationController
#@pass_games_map = @shixun.challenges.joins(:games).where(games: {status:2}).group(:challenge_id).reorder(nil).count #@pass_games_map = @shixun.challenges.joins(:games).where(games: {status:2}).group(:challenge_id).reorder(nil).count
#@play_games_map = @shixun.challenges.joins(:games).where(games: {status:[0,1]}).group(:challenge_id).reorder(nil).count #@play_games_map = @shixun.challenges.joins(:games).where(games: {status:[0,1]}).group(:challenge_id).reorder(nil).count
@challenges = @shixun.challenges.joins(join_sql).select(base_columns).uniq @challenges = @shixun.challenges.joins(join_sql).select(base_columns)
#@challenges = @shixun.challenges.fields_for_list #@challenges = @shixun.challenges.fields_for_list
@editable = @shixun.status == 0 # before_action有判断权限如果没发布则肯定是管理人员 @editable = @shixun.status == 0 # before_action有判断权限如果没发布则肯定是管理人员

Loading…
Cancel
Save