Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
✏️ 작업 개요
어드민에 공지(Notice) 관리 탭을 추가했습니다. 기존
notice도메인은 조회 API만 있고 데이터를 넣을 수단이 없었는데, 이번에 어드민 화면에서 직접 관리할 수 있게 했습니다.관리 대상은 세 가지입니다.
작업 중 필수 버전을 Android / iOS로 분리했습니다. 스토어 심사 주기가 달라 한쪽만 먼저 배포되는 경우를 기존 단일 컬럼으로는 감당할 수 없었습니다.
🔨 작업 상세 내용
공지사항 CRUD
GET/POST/PATCH/DELETE /admin/notice/announcement추가Expired뱃지로 남습니다필수 앱 버전 OS별 분리
system_info.version→android_version/ios_versionGET/PATCH /admin/notice/system추가POST /api/notice/personal에platform파라미터 필수 추가 (ANDROID/IOS). 어느 쪽 버전과 비교할지 서버가 알아야 합니다version필드는 그대로 두고 해당 OS의 요구 버전을 담습니다. 응답 구조 변경 없음AppPlatformenum 신설 (global/common/domain)개인 알림 발송
GET /admin/notice/user— 이메일 또는 닉네임 정확 일치로 수신자 조회POST /admin/notice/personal— 메시지 발송어드민 화면 (
/admin/notices)네비게이션 프래그먼트 정리
siteNav(hidePackList, hidePackCreate, hidePuzzleCache, hideCommunityPuzzles)→siteNav(active)hidePackCreate인자를 제거하고 문자열 하나로 바꿨습니다보안 설정
/admin/notices,/admin/notice/**에ADMIN권한 적용.anyRequest().authenticated()라 명시하지 않으면 일반 로그인 유저도 접근 가능합니다테스트
NoticeServiceTest— 언어별 행 분리, 중복 언어 거부, 플랫폼별 버전 게이트 교차 검증 등AdminTemplateRenderTest— Spring 없이 Thymeleaf 엔진만 띄워 어드민 템플릿 12개 전체 렌더링. 프래그먼트 시그니처를 바꿨기 때문에 회귀 방지용으로 추가했습니다💡 생각해볼 문제
배포 시 마이그레이션이 필요합니다.
ddl-auto: update는 컬럼을 추가만 하고 값은 복사하지 않습니다. 기존 DB에 그대로 배포하면 새 컬럼이 빈 문자열이 되고, 모든 유저가 강제 업데이트 화면에 갇힙니다. 로컬에서 재현해 확인했습니다.배포 직후 위 SQL을 실행하거나, 어드민 화면에서 버전을 입력하고 저장해도 동일하게 복구됩니다. 신규 DB는
DataInitializer가 채우므로 해당 없습니다.기존
version컬럼은 남겨뒀습니다.ddl-auto가 컬럼을 지우지 못해NOT NULL인 채로 남습니다. 롤백 여지를 고려해DROP COLUMN은 미뤘는데, 정리 시점을 정하면 좋겠습니다.