Skip to content

[mypage] 원서 접수 기간 판별식의 isTimeBefore 인자 순서 수정 - #588

Merged
s2yeons merged 4 commits into
developfrom
fix/572-mypage-oneseo-submission-period
Nov 19, 2026
Merged

s2yeons merged 4 commits into
developfrom
fix/572-mypage-oneseo-submission-period

Conversation

@s2yeons

@s2yeons s2yeons commented Nov 18, 2026

Copy link
Copy Markdown
Member

개요

마이페이지의 원서 접수 기간 판별식에서 isTimeBefore의 인자가 뒤바뀌어, 접수 기간 중에는 "원서 작성하기" 버튼과 "원서를 아직 작성하지 않았습니다." 문구가 숨겨지고 마감 후에는 노출되던 문제를 수정하였습니다.

isTimeBefore({ baseTime, compareTime })는 compareTime < baseTime을 반환하므로, 기존 코드는 "현재가 마감 전인가"가 아니라 "마감이 현재보다 이전인가"를 검사하고 있었습니다. 2025-06-18 커밋 36d7ec5e에서 비교식을 util 함수로 바꾸는 과정에서 인자 순서가 뒤바뀐 것으로 확인되었습니다.

작업내용

  • apps/client/src/app/mypage/page.tsx의 isTimeBefore 호출 인자를 baseTime: oneseoSubmissionEnd, compareTime: currentTime 순서로 수정하였습니다.
  • guide/page.tsx, register/page.tsx의 접수 기간 판별식과 동일한 형태가 되었습니다.
// 변경 전
isTimeBefore({ baseTime: currentTime, compareTime: new Date(dateList.oneseoSubmissionEnd) });

// 변경 후
isTimeBefore({ baseTime: new Date(dateList.oneseoSubmissionEnd), compareTime: currentTime });

관련 이슈

리뷰 요청사항

  • 이슈에서 권장한 e2e/mypage.spec.ts의 접수 기간 안/밖 케이스는 추가하지 않았습니다. getDate()가 서버 컴포넌트에서 실제 API로 호출되어 Playwright의 page.route로 응답을 고정할 수 없고, 결과가 실제 서버의 전형 일정에 따라 달라지기 때문입니다.
  • 재발 방지가 필요하다면 접수 기간 판별식을 순수 함수로 분리하여 mypage, guide, register에서 공유하고 tsx --test 단위 테스트로 검증하는 방안을 후속 작업으로 고려하고 있습니다. 의견 부탁드립니다.

@vercel
vercel Bot temporarily deployed to Preview – hellogsm-client-26-admin November 18, 2026 09:22 Inactive
@vercel

vercel Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
hellogsm-client-26 Ready Ready Preview Nov 18, 2026 10:38am UTC
1 Skipped Deployment
Project Deployment Actions Updated
hellogsm-client-26-admin Skipped Skipped Nov 18, 2026 10:38am UTC

Request Review

@pr-agent-demo pr-agent-demo Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overview

마이페이지의 원서 접수 기간 판별식에서 isTimeBefore 인자 순서를 수정해, 접수 기간 중/마감 후 조건이 반대로 적용되던 문제를 바로잡습니다.

Intent

isTimeBefore의 비교 방향에 맞게 currentTime과 접수 마감일 인자를 교체하여, 접수 기간 동안에는 원서 작성 UI가 정상 노출되도록 하는 것이 목적입니다.

Risk

변경 범위는 한 줄의 날짜 비교 로직으로 제한적이지만, 실제 서버 시간 기반 조건과 UI 노출에 영향을 줍니다. isTimeBefore의 의미와 mypage, guide, register 간 비교식 일관성, 시간대·서버 시간 처리 여부를 중점적으로 확인해야 합니다.


2 inline comment(s)

Comment thread apps/client/src/app/mypage/page.tsx Resolved
Comment thread apps/client/src/app/mypage/page.tsx Resolved
@s2yeons
s2yeons merged commit c83fc32 into develop Nov 19, 2026
4 checks passed
@s2yeons
s2yeons deleted the fix/572-mypage-oneseo-submission-period branch November 19, 2026 01:16

This branch was successfully deployed

1 active and 1 inactive deployments
Preview – hellogsm-client-26 — c0df18e7 Deployed Nov 18, 2026 by vercel[bot]
Preview – hellogsm-client-26-admin — c0df18e7 Deployed Nov 18, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants