forked from Gitlink/forgeplus
fixed 后台查询打榜分
This commit is contained in:
parent
24b03d1713
commit
f3ca02f92e
|
@ -203,6 +203,10 @@ class CompetitionInfosController < ApplicationController
|
|||
end
|
||||
|
||||
def enroll_list
|
||||
@stage = params[:stage] || params[:ext5]
|
||||
if @competition_info.identifier.to_s == "zstp2025" && @stage.blank?
|
||||
@stage = 1
|
||||
end
|
||||
competition_users = CompetitionUser.where(competition_info: @competition_info.id).order("updated_at desc")
|
||||
zones = @competition_info.manager_zones(current_user)
|
||||
if params[:zone].present?
|
||||
|
|
|
@ -10,6 +10,9 @@ json.data do
|
|||
json.user_real_name c_user.user&.real_name
|
||||
json.members c_user.members
|
||||
json.apply_status c_user&.apply_status
|
||||
json.score @stage.present? ? c_user.stage_score(@stage) : c_user.score
|
||||
json.last_score @stage.present? ? c_user.stage_last_score(@stage) : c_user.last_score
|
||||
json.other_score_json c_user.api_result_data["data"].present? ? c_user.api_result_data["data"] : c_user.api_result_data
|
||||
json.enroll_template do
|
||||
file = Attachment.where_id_or_uuid(c_user.enroll_template_id).first
|
||||
json.partial! 'attachments/attachment_simple', attachment: file if file.present?
|
||||
|
|
Loading…
Reference in New Issue