competition = current_competition json.enroll_ended competition.enroll_ended? json.enrolled competition.enrolled?(current_user) # 教师报名设置 if competition.teacher_staff.present? json.teacher_staff do json.minimum competition.teacher_staff.minimum json.maximum competition.teacher_staff.maximum json.mutiple_limited competition.teacher_staff.mutiple_limited end else json.teacher_staff nil end # 教师报名设置 if competition.member_staff.present? json.member_staff do json.minimum competition.member_staff.minimum json.maximum competition.member_staff.maximum json.mutiple_limited competition.member_staff.mutiple_limited end else json.member_staff nil end