sparta-tigers / sparta-tigers/backend
[FEATURE] 팀 순위 조회 기능 구현
Open
Nobody has claimed this yet.
feature
- Dominant language
- Java
- Stars
- 0
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
🧩 작업 목적
[ 시범경기, 정규리그 ]
- 특정 일자별 팀 순위 조회
- 시즌 연도별 팀 순위 조회
[ 포스트 시즌 ]
- stage별 경기 디테일 조회 (연도별, 우승팀 조회)
- postSeasonStage : 와일드 카드, 준플레이오프, 플레이오프, 한국시리즈
✅ 할 일 목록
- matches 테이블 수정, 마이그레이션 생성
- 크롤러 수정 (seasonYear, leagueType) 추가
- 응답용, 내부 계산용 Dto 설계 - 시범경기, 정규리그
- match.matchResult 기반으로 경기결과를 teamRankingStat으로 집계
- 특정 날짜까지의 teamRankingStat을 누적 합산해 Rank 부여
- 일자별 조회 / 년도별 조회 컨트롤러 분리
- 응답용, match엔티티 파싱용 Dto 설계 - 포스트 시즌
- leagueType이 POST_SEASON인 match에 대해 postSeasonStage 분류하기 (날짜별 정렬 후 인덱스마다 순차적으로 부여)
- 4승 선승제 적용해 우승팀 집계
- 연도별 포스트 시즌 경기 디테일 + 우승팀 조회 컨트롤러
📌 참고 사항 (선택)
[ KBO 순위 집계 특이사항 ]
- 시범경기, 정규리그는 승률 순 집계, 승률이 같은 경우 공동 순위로 한다.
- 공동순위 문서상 표기 기준 : 전체 전적 다승 -> 다득점 -> 전년도 성적
- 포스트 시즌 경기는 정규시즌 순위에 가산하지 않고 별도 취급한다. - 포스트 시즌 경기는 4승 선승제로 우승팀 결정된다.
[ 구현 특이사항 ]
- 최종 구현 목표
| 순위 | 팀명 | 경기 | 승 | 패 | 무 | 승률 | 게임차 | 최근10경기 | 연속 | 홈 | 방문 |
|---|
- 1차 구현은 승률까지 구현 예정입니다.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No file paths or tests are named. Start by tracing the match entity, ranking DTOs, and the separate date/year and postseason controllers described in the checklist. Verify that regular-season rankings use cumulative results and win percentage, while postseason stages and the four-win champion are returned separately; confirm the available endpoints and tests before changing anything.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, backend, database
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100