Skip to content

Commit 6bf4cd9

Browse files
limeheemingmingmongwansikk
authored
Develop old (#314)
* refactor(Board): 게시글 생성 로직 일부를 도메인으로 이전 및 메소드 분리 * refactor(Board): 게시글 상세 조회 로직 일부를 도메인으로 이전 및 메소드 분리 * refactor(Board): 게시글 수정/삭제 권한 로직을 도메인으로 이전 * refactor(Blog): 블로그 포스트 목록 조회, 블로그 포스트 검색 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(Blog): 일부 서비스 로직을 도메인으로 이전 * refactor(BlacklistIp): 블랙리스트 IP 추가 로직 개선 * refactor(Award): 수상 이력 검색 로직을 QueryDSL을 통해 처리하도록 변경 * refactor(Award): 수상 이력 등록 로직 간소화 * refactor(Award): 수상 이력 수정/삭제 권한 로직을 도메인으로 이전 * refactor(Application): 지원자 목록 조회 repository 코드 분리 및 path명 변경 * refactor(Application): 지원자 합격/취소 로직을 도메인으로 이전 * refactor(Application): 동아리 지원 API 로직 간소화 및 일부 로직 도메인으로 이전 * refactor(Application): 합격 여부 조회 로직 개선 * refactor(ActivityPhoto): 활동 사진 목록 조회, 공개된 활동 사진 목록 조회 API 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(ActivityPhoto): 활동 사진 등록 로직 개선 * refactor(ActivityPhoto): 활동 사진 고정/해제 로직 도메인으로 이전 * refactor(toggle): 메소드명 변경 * refactor(Accuse): 신고 내역 조회, 유형/상태별 신고 내역 조회 API 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(Accuse): 신고하기 및 신고 상태 변경 API 로직 개선 * refactor(QueryDSL): JPAQueryFactory을 스프링 빈으로 등록하여 주입받도록 변경 * refactor(WorkExperience): 권한 검사 로직 도메인으로 이전 및 경력사항 생성 오류 수정 * refactor(Schedule): 일정 생성 로직 개선 * refactor(Schedule): 일부 로직 도메인으로 이전 * refactor(Schedule): 일정 조회 로직을 QueryDSL을 통해 처리하도록 변경 * refactor(Schedule): 일정 조회시 LocalDate를 입력받도록 변경 * refactor(Schedule): 일부 로직을 도메인으로 이전 * refactor(Review): 일부 로직을 도메인으로 이전 * refactor(Schedule): 모집 공고 등록 로직 개선 * refactor(Recruitment): 모집 공고 등록 로직 개선 * refactor(Position): 직책 등록 로직 개선 * refactor(Notification): 알림 삭제 권한 로직을 도메인으로 이전 * refactor(News): 메소드명 변경(of -> create) * refactor(MembershipFee): 회비 수정/삭제 권한 로직을 도메인으로 이전 * refactor(MemberCloud): 클라우드 접근 권한 로직을 도메인으로 이전 * refactor(Member): 일부 로직 도메인으로 이전 * fix(Email): 계정 발급시 비밀번호가 보이지 않는 오류 수정 * refactor(Member): 비밀번호 생성 로직 verificationCodeService로 이동 * refactor(Authenticator): GoogleAuthenticator를 스프링 빈으로 등록하여 주입받도록 변경 * refactor(Authenticator): Authenticator 정적 팩토리 메소드를 이용하여 인스턴스화 로직을 캡슐화 * refactor(LoginAttemptLog): LoginAttemptLog 생성 로직 간소화 * refactor(RedisToken): RedisToken 생성 로직 간소화 * refactor(RedisToken): IP 비교 메소드 도메인으로 이전 * refactor(Comment): 댓글 수정/삭제 권한 로직을 도메인으로 이전 * refactor(ActivityPhoto): 업로드 파일 가져오는 로직 메소드로 분리 * refactor(SharedAccount): 공동계정 생성 로직 간소화 * refactor(SharedAccountUsage): 공동 계정 이용 신청 로직 일부를 도메인으로 이전 * refactor(SharedAccountUsage): 조건 검사 메소드 분리 세분화 * refactor(SharedAccountUsage): 공동 계정 이용 상태 변경 로직 일부를 도메인으로 이전 * refactor(SharedAccountUsage): 기능별 메소드 분리 * refactor(ActivityGroup): 활동 생성 일부 로직을 도메인으로 이동 * refactor(ActivityGroup): 일부 로직을 도메인으로 이동 * refactor(Validation): 컨트롤러에서 예외를 추가로 처리하지 않기로 변경 * refactor(Validation): 유효성 검사 로그 상세화 * refactor(Attendance): static 변수 및 불필요 메소드 제거 * refactor(Attendance): 기능별 메소드 분리 * refactor(ActivityGroupReport): 기능별 메소드 분리 * refactor(ActivityGroupMember): 일부 로직을 도메인으로 이전 * refactor(ActivityGroupMember): 활동 전체 목록 조회 최적화 * refactor(ActivityGroupMember): 활동 상태별 조회 조회 최적화 * refactor(ActivityGroupMember): 활동 상태별 조회 최적화 * refactor(ActivityGroupMember): 일부 로직 도메인으로 이전 * refactor(ActivityGroupBoard): 활동 그룹 게시판 생성 일부 로직 도메인으로 이전 및 메소드 분리 * refactor(ActivityGroupBoard): 활동 그룹 게시판 계층 구조적 조회 일부 로직 도메인으로 이전 * refactor(ActivityGroupBoard): 나의 제출 과제 및 피드백 조회, 활동 그룹 게시판 수정/삭제 로직 최적화 및 도메인 이전 * refactor(ActivityGroupBoard): getChildBoards() 로직 간소화 * refactor(ActivityGroupBoard): validateParentBoard() 로직 최적화 * refactor(ActivityGroupBoard): 신청 멤버 상태 변경 일부 로직 도메인 이전 * refactor(ActivityGroupAdmin): 신청 멤버 상태 변경 일부 로직 도메인 이전 * refactor(VerificationCode): 일부 로직 도메인 이전 * refactor(RedisIpAccessMonitor): 일부 로직 도메인 이전 * refactor(Repository): Custom Repository에서 where 조건을 BooleanBuilder를 통해 표현하도록 수정 * refactor(Repository): Custom Repository에서 where 조건을 BooleanBuilder를 통해 표현하도록 수정 * Delete config directory * refactor(Optimize): 조회 API의 트랜젠션을 readOnly로 변경 * refactor(Optimize): 조회 API의 트랜젠션을 readOnly로 변경 * refactor(Validation): 비즈니스 로직에서 중앙집중적으로 유효성을 검사할 수 있도록 함, ExceptionHandler에 ConstraintViolationException 추가 * refactor(Validation): 비즈니스 로직에서 중앙집중적으로 유효성을 검사할 수 있도록 함, ExceptionHandler에 ConstraintViolationException 추가 * refactor(Validation): 도메인 지식에 대한 유효성 검사를 비즈니스 로직에서 하도록 변경 * refactor(Validation): 도메인 지식에 대한 유효성 검사를 비즈니스 로직에서 하도록 변경 * refactor(DB): updateTime -> updatedAt 칼럼명 변경 및 수정일자 갱신 누락 추가 * refactor(DB): updateTime -> updatedAt 칼럼명 변경 및 수정일자 갱신 누락 추가 * refactor(Entity): BaseEntity를 통해 생성 및 수정일자를 관리할 수 있도록 함 * refactor(Entity): BaseEntity를 통해 생성 및 수정일자를 관리할 수 있도록 함 * refactor(DDD): 도메인 계층으로부터 객체 변환 로직을 분리하여 표현 계층(DTO)으로 이동 * refactor(DDD): 도메인 계층으로부터 객체 변환 로직을 분리하여 표현 계층(DTO)으로 이동 * refactor(FileUpload): UploadedFile 로직 분리 및 출석 QR 코드 생성 로직 개선 * refactor(FileUpload): UploadedFile 로직 분리 및 출석 QR 코드 생성 로직 개선 * refactor(FileUpload): 파일 업로드 메소드 통합 * refactor(FileUpload): 파일 업로드 메소드 통합 * refactor(FileUpload): 파일 저장 메소드 개선 * refactor(FileUpload): 파일 저장 메소드 개선 * refactor(FileUpload): 파일 삭제 로직을 FileHandler로 이동 * refactor(FileUpload): 파일 삭제 로직을 FileHandler로 이동 * refactor(Verification): 패키지명 변경 * refactor(Verification): 패키지명 변경 * refactor(AutoDeleteService): 파일 자동 삭제 로직 가독성 개선 * refactor(AutoDeleteService): 파일 자동 삭제 로직 가독성 개선 * refactor(EncryptionUtil): EncryptionUtil 빈 주입 개선 * refactor(EncryptionUtil): EncryptionUtil 빈 주입 개선 * refactor(API): URI Versioning 추가 (/api/{version}) * refactor(API): URI Versioning 추가 (/api/{version}) * refactor(MembershipFee): 회비 상태 추가(대기/보류/승인/반려) * refactor(MembershipFee): 회비 상태 추가(대기/보류/승인/반려) * refactor(memberServie): 프로필 사진 빈 문자열로 업데이트 시 기존 파일 삭제와 DB내 null 처리 #299 * refactor(memberServie): 프로필 사진 빈 문자열로 업데이트 시 기존 파일 삭제와 DB내 null 처리 #299 * refactor(autoDeleteService) : 파일 자동 삭제 시 DB에 등록되지 않은 unknown 파일 삭제 #299 * refactor(autoDeleteService) : 파일 자동 삭제 시 DB에 등록되지 않은 unknown 파일 삭제 #299 * fix(autoDeleteService): 스케쥴링 cron 설정 원래대로 수정 #299 * fix(autoDeleteService): 스케쥴링 cron 설정 원래대로 수정 #299 * refactor(Member): 프로필 사진 업데이트 리팩토링 * refactor(Member): 프로필 사진 업데이트 리팩토링 * refactor(Member): 프로필 사진 업데이트 리팩토링 #299 * refactor(Member): 프로필 사진 업데이트 리팩토링 #299 * refactor(DeleteFileRequestDto): 변수명 복구 * refactor(DeleteFileRequestDto): 변수명 복구 * refactor(ActivityGroup): 나의 활동 목록 조회 API 추가 * refactor(ActivityGroup): 나의 활동 목록 조회 API 추가 * refactor(BookLoanRecord): 도서 대출 내역 조회시 책 제목, 사진을 함께 반환하도록 변경 * refactor(BookLoanRecord): 도서 대출 내역 조회시 책 제목, 사진을 함께 반환하도록 변경 * refactor(MembershipFee): 회비 신청시 상태를 입력받지않고 PENDING을 기본값으로 설정 * refactor(MembershipFee): 회비 신청시 상태를 입력받지않고 PENDING을 기본값으로 설정 * refactor(Book): 도서에 출판사 후기 URL 칼럼 추가(JSON 저장) * refactor(Book): 도서에 출판사 후기 URL 칼럼 추가(JSON 저장) * refactor(MembershipFee): 회비에 계좌 칼럼 추가 * refactor(MembershipFee): 회비에 계좌 칼럼 추가 * fix(FileUpload): 파일 업로드시 게시글, 회비 등에 대해 구분자가 없어지면서 기존 파일이 삭제되는 문제 수정 * fix(FileUpload): 파일 업로드시 게시글, 회비 등에 대해 구분자가 없어지면서 기존 파일이 삭제되는 문제 수정 * refactor(MembershipFee): 회비 조회시 관리자에게만 계좌 정보가 보이도록 설정 * refactor(MembershipFee): 회비 조회시 관리자에게만 계좌 정보가 보이도록 설정 * refactor(MembershipFee): 회비 정보 조회 설명 추가 * refactor(MembershipFee): 회비 정보 조회 설명 추가 * refactor(Book): 도서 상세 정보 조회시에만 리뷰 링크를 반환하도록 변경 * refactor(Book): 도서 상세 정보 조회시에만 리뷰 링크를 반환하도록 변경 * fix(Book): 도서 목록 조회 페이지네이션 누락 수정 * fix(Book): 도서 목록 조회 페이지네이션 누락 수정 * fix(Book): 도서 목록 조회 totalPages 미작동 문제 수정 * fix(Book): 도서 목록 조회 totalPages 미작동 문제 수정 * chore: Create README.md * chore: Create CONTRIBUTING.md * Update README.md * refactor(Board): Dto 필드명 상세화 * refactor(Board): Dto 필드명 상세화 * refactor(Board): 게시글 목록 조회 반환 정보 추가 * refactor(Board): 게시글 목록 조회 반환 정보 추가 * Update README.md * refactor(WorkExperience): 검색 API 엔드포인트 변경 * refactor(WorkExperience): 검색 API 엔드포인트 변경 * refactor(DTO): 불필요한 Lombok 어노테이션 제거 * refactor(DTO): 불필요한 Lombok 어노테이션 제거 * refactor(EqualsAndHashCode): 일부 Entity에서 저장할 때 데이터가 중복되던 문제 수정 * refactor(EqualsAndHashCode): 일부 Entity에서 저장할 때 데이터가 중복되던 문제 수정 * refactor(Constructor): Entity 생성자에 대한 접근 제한 설정 * refactor(Constructor): Entity 생성자에 대한 접근 제한 설정 * refactor(Util): 불필요한 어노테이션 제거 * refactor(Util): 불필요한 어노테이션 제거 * refactor(CompositeKey): 복합키 캡슐화 * refactor(CompositeKey): 복합키 캡슐화 * refactor(DTO): ResponseDto 불변성을 위한 Setter 제거 * refactor(DTO): ResponseDto 불변성을 위한 Setter 제거 * refactor(ResponseModel): ResponseModel DDD에 맞게 재설계 및 그에 따른 관련 로직 수정 * refactor(ResponseModel): ResponseModel DDD에 맞게 재설계 및 그에 따른 관련 로직 수정 * refactor(RedisIpAccessMonitor): 비정상 접근 IP 기록 초기화시 초기화된 IP 리스트를 반환하도록 변경 * refactor(RedisIpAccessMonitor): 비정상 접근 IP 기록 초기화시 초기화된 IP 리스트를 반환하도록 변경 * refactor(Email): 이메일 전송시 전송 완료된 이메일 주소를 반환하도록 변경 * refactor(Email): 이메일 전송시 전송 완료된 이메일 주소를 반환하도록 변경 * refactor(BlacklistIp): 블랙리스트 IP 초기화시 초기화된 IP 리스트를 반환하도록 변경 * refactor(BlacklistIp): 블랙리스트 IP 초기화시 초기화된 IP 리스트를 반환하도록 변경 * refactor(Member): 멤버 비밀번호 재발급/요청시 멤버 ID를 반환하도록 변경 * refactor(Member): 멤버 비밀번호 재발급/요청시 멤버 ID를 반환하도록 변경 * refactor(Member): 내 프로필 조회시 재학 상태를 반환하도록 변경 * refactor(Member): 내 프로필 조회시 재학 상태를 반환하도록 변경 * refactor(Enum): 운영진 Enum값 수정 * refactor(Enum): 운영진 Enum값 수정 * refactor(Board): 게시글 카테고리 Enum으로 고정 * refactor(Board): 게시글 카테고리 Enum으로 고정 * refactor(BlacklistIp): 슬랙 메시지 오타 수정 * refactor(BlacklistIp): 슬랙 메시지 오타 수정 * refactor(BlacklistIp): 의심스러운 활동으로 인한 차단시 블랙리스트 추가 사유를 기록하도록 수정 * refactor(BlacklistIp): 의심스러운 활동으로 인한 차단시 블랙리스트 추가 사유를 기록하도록 수정 * fix(GeoIp): GeoIp DB를 불러오지 못할 경우 Unknown을 반환하도록 수정 * fix(GeoIp): GeoIp DB를 불러오지 못할 경우 Unknown을 반환하도록 수정 * refactor(Board): BoardCategory GRADUATE -> GRADUATED 변경 * refactor(Board): BoardCategory GRADUATE -> GRADUATED 변경 * refactor(Board): BoardCategory 정보를 소문자로 반환하도록 변경 * refactor(Board): BoardCategory 정보를 소문자로 반환하도록 변경 * refactor(Job,News): 채용 공고, IT 뉴스 반환 정보에 생성일자 추가 * refactor(Job,News): 채용 공고, IT 뉴스 반환 정보에 생성일자 추가 * feat(Login): 현재 로그인 중인 멤버 조회 API 추가 * feat(Login): 현재 로그인 중인 멤버 조회 API 추가 * refactor(Accuse): 확장성을 고려한 신고 시스템 재설계 * refactor(Accuse): 확장성을 고려한 신고 시스템 재설계 * refactor(Accuse): 신고하기 로직 리팩토링 * refactor(Accuse): 신고하기 로직 리팩토링 * refactor(Accuse): 신고 테이블 구조 및 신고 내역 조회 응답 변경, 누적 횟수 기준으로 정렬할 수 있도록 함. * refactor(Accuse): 신고 테이블 구조 및 신고 내역 조회 응답 변경, 누적 횟수 기준으로 정렬할 수 있도록 함. * refactor(Accuse): 신고 시스템 재설계에 따른 신고 상태 변경 API 수정 및 리팩토링 * refactor(Accuse): 신고 시스템 재설계에 따른 신고 상태 변경 API 수정 및 리팩토링 * refactor(Board): 게시글 상세 조회시 익명 유저일 경우 권한 정보를 반환하지 않도록 변경 * refactor(Board): 게시글 상세 조회시 익명 유저일 경우 권한 정보를 반환하지 않도록 변경 * refactor(Board): 게시글 상세 조회 및 댓글 조회시 작성자의 ID, 이름을 모두 반환하도록 변경 * refactor(Board): 게시글 상세 조회 및 댓글 조회시 작성자의 ID, 이름을 모두 반환하도록 변경 * feat(Schedule): 일정 중요도 및 조건별 검색 API 추가 * feat(Schedule): 일정 중요도 및 조건별 검색 API 추가 * feat(Schedule): 일정 모아보기 API 추가 * feat(Schedule): 일정 모아보기 API 추가 * feat(Board): 게시판 카테고리에 동아리 소식 추가 * feat(Board): 게시판 카테고리에 동아리 소식 추가 * ci: add spring boot gradle ci (#304) * docs: add gradle ci badge (#304) * ci: update spring-boot-gradle-ci (#304) * refactor(Actuator): 헬스 체크를 위한 권한 설정 변경 * refactor(Actuator): 헬스 체크를 위한 권한 설정 변경 * refactor(test): Test 환경 설정 * refactor(test): Test 환경 설정 * chore: 배포 환경 설정 * chore: 배포 환경 변경(prod->stage) * chore: gradle build시 프로필을 유동적으로 사용할 수 있도록 변경 * chore: gradle build시 프로필을 유동적으로 사용할 수 있도록 변경 * chore: Dockerfile 수정 * chore: Dockerfile 수정 * chore: Dockerfile 수정(JDK 21 강제화) * chore: Dockerfile 수정(JDK 21 강제화) * chore: Dockerfile 롤백 * chore: Dockerfile 롤백 * Develop (#313) * refactor(Schedule): 일정 조회시 기간 내 진행중인 일정 모든 일정에 대해 조회하도록 변경 * refactor(Book): 도서 대출 내역 조회시 대출자의 이름을 같이 반환하도록 수정 * fix(Member): 멤버 정보 수정시 Optional로 인해 발생하는 오류 수정 * feat(Book): 도서 연체자 조회 API 추가 * fix: 이메일 전송 시 html 파일 경로 지정용 ThymeleafConfig 추가 #299 * refactor(Board): 커뮤니티 게시글 카테고리별 조회시 writerId를 반환하도록 변경 * refactor(Board): 커뮤니티 게시글 카테고리별 조회 엔드포인트 변경 * refactor(Board): 썸네일 이미지 URL 컬럼 추가 * fix(Board): 썸네일 이미지 URL 업데이트 로직 누락 수정 * refactor(File): 게시글 사진 업로드 -> 게시글 파일 업로드 Operation 수정 * refactor(Accuse): 자신의 콘텐츠에 대해 신고할 수 없도록 변경 * feat(Accuse): 나의 신고 내역 조회 API 추가 * feat(Book): 도서 대여 승인 제도 추가 * refactor(Book): 도서 대여 승인 제도 추가에 따른 도서 연체자 조회 로직 수정 * refactor(Book): 도서 대출 내역 조회시 대출 여부 대신 대출 상태를 기준으로 조회 가능하도록 변경 * refactor: 유효성 검사 및 트랙젝션 누락 수정 * feat(Book): 최대 도서 대여 개수 정책 추가 * refactor(Book): 도서 대출 내역, 연체자 조회시 대출 상태를 같이 반환하도록 변경 * refactor(Exception): 미사용 예외 삭제 * refactor(Exception): 예외 재분류 * refactor(Book): 도서 대출 내역 조회시 borrowedAt이 없는 경우를 고려하여 createdAt을 두 번째 정렬 기준으로 추가 * refactor(Exception): 409 예외 처리 및 응답 변경 * fix(Book): 중복 도서 대출 요청 수정 * refactor(Book): 대출 중인 도서도 대출 요청 가능하도록 변경 * refactor(Exception): ErrorResponse 분리 * refactor(Response): ResponseModel -> ApiResponse 이름 변경 * refactor(GeoIP): GeoIP2 -> IPInfo 서비스 대체 * refactor(IPInfo): 필터링 국가 정보 수정 * refactor(GeoIP): GeoIP 삭제 * chore: CI/CD 환경 설정 * fix(gradle): } 누락 수정 * refactor(IPInfo): RestClient 호출 개선 * refactor(BookLoanRecord): 도서 대출 정보 조회시 대출 ID 반환하도록 변경 * refactor(IPInfo): IPInfo 호출 개선 * refactor(LoginAttemptLog): 로그인시 위치 정보를 '시' 단위만 기록하도록 변경 * refactor(IpAuthenticationFilter): 해외 로그인 차단 로직 개선 * refactor(IpAuthenticationFilter): IPInfo Interceptor를 제거하고 Filter에서 역할을 수행하도록 변경 * Feat/entity delete (#312) * refactor(Login): 멤버 로그인 로직을 기능별로 모듈화 * refactor(JobPosting): 채용 공고 목록 조회, 채용 공고 검색 API 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(JobPosting): 채용 공고 등록 로직 개선 * refactor(Donation): 후원 정보, 후원 검색 API 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(Donation): 후원 생성 로직 간소화 및 수정/삭제 조건 검사 로직 메소드로 분리 * refactor(Comment): 댓글 생성 로직 간소화 및 조건 검사 로직 메소드로 분리 * refactor(Comment): 댓글 생성 로직 간소화 * refactor(Comment): 댓글 좋아요 및 소유자 확인 로직을 도메인으로 이전 * refactor(Comment): 댓글 좋아요 로직 수정 * refactor(Comment): 댓글 좋아요 메소드명 변경 * refactor(Comment): 댓글 생성 로직 모듈화 * refactor(Comment): 댓글 조회 로직 모듈화 * refactor(Book): 도서 목록, 도서 검색 API 통합 * refactor(Book): 도서 조회 공통 로직 메소드로 분리 * refactor(BookLoanRecord): 불필요 예외 제거 및 메소드명 변경 * refactor(Review): 메소드명 변경 * refactor(BookLoanRecord): 도서 대출 로직 일부를 도메인으로 이전 * refactor(Review): 메소드명 변경 * refactor(BookLoanRecord): 도서 반납 로직 일부를 도메인으로 이전 * refactor(BookLoanRecord): 도서 연장 로직 일부를 도메인으로 이전 * refactor(Board): 게시글 좋아요 로직 일부를 도메인으로 이전 * refactor(Board): 주석 제거 * refactor(Board): 게시글 생성 로직 일부를 도메인으로 이전 및 메소드 분리 * refactor(Board): 게시글 상세 조회 로직 일부를 도메인으로 이전 및 메소드 분리 * refactor(Board): 게시글 수정/삭제 권한 로직을 도메인으로 이전 * refactor(Blog): 블로그 포스트 목록 조회, 블로그 포스트 검색 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(Blog): 일부 서비스 로직을 도메인으로 이전 * refactor(BlacklistIp): 블랙리스트 IP 추가 로직 개선 * refactor(Award): 수상 이력 검색 로직을 QueryDSL을 통해 처리하도록 변경 * refactor(Award): 수상 이력 등록 로직 간소화 * refactor(Award): 수상 이력 수정/삭제 권한 로직을 도메인으로 이전 * refactor(Application): 지원자 목록 조회 repository 코드 분리 및 path명 변경 * refactor(Application): 지원자 합격/취소 로직을 도메인으로 이전 * refactor(Application): 동아리 지원 API 로직 간소화 및 일부 로직 도메인으로 이전 * refactor(Application): 합격 여부 조회 로직 개선 * refactor(ActivityPhoto): 활동 사진 목록 조회, 공개된 활동 사진 목록 조회 API 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(ActivityPhoto): 활동 사진 등록 로직 개선 * refactor(ActivityPhoto): 활동 사진 고정/해제 로직 도메인으로 이전 * refactor(toggle): 메소드명 변경 * refactor(Accuse): 신고 내역 조회, 유형/상태별 신고 내역 조회 API 통합 및 QueryDSL을 통해 처리하도록 변경 * refactor(Accuse): 신고하기 및 신고 상태 변경 API 로직 개선 * refactor(QueryDSL): JPAQueryFactory을 스프링 빈으로 등록하여 주입받도록 변경 * refactor(WorkExperience): 권한 검사 로직 도메인으로 이전 및 경력사항 생성 오류 수정 * refactor(Schedule): 일정 생성 로직 개선 * refactor(Schedule): 일부 로직 도메인으로 이전 * refactor(Schedule): 일정 조회 로직을 QueryDSL을 통해 처리하도록 변경 * refactor(Schedule): 일정 조회시 LocalDate를 입력받도록 변경 * refactor(Schedule): 일부 로직을 도메인으로 이전 * refactor(Review): 일부 로직을 도메인으로 이전 * refactor(Schedule): 모집 공고 등록 로직 개선 * refactor(Recruitment): 모집 공고 등록 로직 개선 * refactor(Position): 직책 등록 로직 개선 * refactor(Notification): 알림 삭제 권한 로직을 도메인으로 이전 * refactor(News): 메소드명 변경(of -> create) * refactor(MembershipFee): 회비 수정/삭제 권한 로직을 도메인으로 이전 * refactor(MemberCloud): 클라우드 접근 권한 로직을 도메인으로 이전 * refactor(Member): 일부 로직 도메인으로 이전 * fix(Email): 계정 발급시 비밀번호가 보이지 않는 오류 수정 * refactor(Member): 비밀번호 생성 로직 verificationCodeService로 이동 * refactor(Authenticator): GoogleAuthenticator를 스프링 빈으로 등록하여 주입받도록 변경 * refactor(Authenticator): Authenticator 정적 팩토리 메소드를 이용하여 인스턴스화 로직을 캡슐화 * refactor(LoginAttemptLog): LoginAttemptLog 생성 로직 간소화 * refactor(RedisToken): RedisToken 생성 로직 간소화 * refactor(RedisToken): IP 비교 메소드 도메인으로 이전 * refactor(Comment): 댓글 수정/삭제 권한 로직을 도메인으로 이전 * refactor(ActivityPhoto): 업로드 파일 가져오는 로직 메소드로 분리 * refactor(SharedAccount): 공동계정 생성 로직 간소화 * refactor(SharedAccountUsage): 공동 계정 이용 신청 로직 일부를 도메인으로 이전 * refactor(SharedAccountUsage): 조건 검사 메소드 분리 세분화 * refactor(SharedAccountUsage): 공동 계정 이용 상태 변경 로직 일부를 도메인으로 이전 * refactor(SharedAccountUsage): 기능별 메소드 분리 * refactor(ActivityGroup): 활동 생성 일부 로직을 도메인으로 이동 * refactor(ActivityGroup): 일부 로직을 도메인으로 이동 * refactor(Validation): 컨트롤러에서 예외를 추가로 처리하지 않기로 변경 * refactor(Validation): 유효성 검사 로그 상세화 * refactor(Attendance): static 변수 및 불필요 메소드 제거 * refactor(Attendance): 기능별 메소드 분리 * refactor(ActivityGroupReport): 기능별 메소드 분리 * refactor(ActivityGroupMember): 일부 로직을 도메인으로 이전 * refactor(ActivityGroupMember): 활동 전체 목록 조회 최적화 * refactor(ActivityGroupMember): 활동 상태별 조회 조회 최적화 * refactor(ActivityGroupMember): 활동 상태별 조회 최적화 * refactor(ActivityGroupMember): 일부 로직 도메인으로 이전 * refactor(ActivityGroupBoard): 활동 그룹 게시판 생성 일부 로직 도메인으로 이전 및 메소드 분리 * refactor(ActivityGroupBoard): 활동 그룹 게시판 계층 구조적 조회 일부 로직 도메인으로 이전 * refactor(ActivityGroupBoard): 나의 제출 과제 및 피드백 조회, 활동 그룹 게시판 수정/삭제 로직 최적화 및 도메인 이전 * refactor(ActivityGroupBoard): getChildBoards() 로직 간소화 * refactor(ActivityGroupBoard): validateParentBoard() 로직 최적화 * refactor(ActivityGroupBoard): 신청 멤버 상태 변경 일부 로직 도메인 이전 * refactor(ActivityGroupAdmin): 신청 멤버 상태 변경 일부 로직 도메인 이전 * refactor(VerificationCode): 일부 로직 도메인 이전 * refactor(RedisIpAccessMonitor): 일부 로직 도메인 이전 * refactor(Repository): Custom Repository에서 where 조건을 BooleanBuilder를 통해 표현하도록 수정 * Delete config directory * refactor(Optimize): 조회 API의 트랜젠션을 readOnly로 변경 * refactor(Validation): 비즈니스 로직에서 중앙집중적으로 유효성을 검사할 수 있도록 함, ExceptionHandler에 ConstraintViolationException 추가 * refactor(Validation): 도메인 지식에 대한 유효성 검사를 비즈니스 로직에서 하도록 변경 * refactor(DB): updateTime -> updatedAt 칼럼명 변경 및 수정일자 갱신 누락 추가 * refactor(Entity): BaseEntity를 통해 생성 및 수정일자를 관리할 수 있도록 함 * refactor(DDD): 도메인 계층으로부터 객체 변환 로직을 분리하여 표현 계층(DTO)으로 이동 * refactor(FileUpload): UploadedFile 로직 분리 및 출석 QR 코드 생성 로직 개선 * refactor(FileUpload): 파일 업로드 메소드 통합 * refactor(FileUpload): 파일 저장 메소드 개선 * refactor(FileUpload): 파일 삭제 로직을 FileHandler로 이동 * refactor(Verification): 패키지명 변경 * refactor(AutoDeleteService): 파일 자동 삭제 로직 가독성 개선 * refactor(EncryptionUtil): EncryptionUtil 빈 주입 개선 * refactor(API): URI Versioning 추가 (/api/{version}) * refactor(MembershipFee): 회비 상태 추가(대기/보류/승인/반려) * refactor(memberServie): 프로필 사진 빈 문자열로 업데이트 시 기존 파일 삭제와 DB내 null 처리 #299 * refactor(autoDeleteService) : 파일 자동 삭제 시 DB에 등록되지 않은 unknown 파일 삭제 #299 * fix(autoDeleteService): 스케쥴링 cron 설정 원래대로 수정 #299 * refactor(Member): 프로필 사진 업데이트 리팩토링 * refactor(Member): 프로필 사진 업데이트 리팩토링 #299 * refactor(DeleteFileRequestDto): 변수명 복구 * refactor(ActivityGroup): 나의 활동 목록 조회 API 추가 * refactor(BookLoanRecord): 도서 대출 내역 조회시 책 제목, 사진을 함께 반환하도록 변경 * refactor(MembershipFee): 회비 신청시 상태를 입력받지않고 PENDING을 기본값으로 설정 * refactor(Book): 도서에 출판사 후기 URL 칼럼 추가(JSON 저장) * refactor(MembershipFee): 회비에 계좌 칼럼 추가 * fix(FileUpload): 파일 업로드시 게시글, 회비 등에 대해 구분자가 없어지면서 기존 파일이 삭제되는 문제 수정 * refactor(MembershipFee): 회비 조회시 관리자에게만 계좌 정보가 보이도록 설정 * refactor(MembershipFee): 회비 정보 조회 설명 추가 * refactor(Book): 도서 상세 정보 조회시에만 리뷰 링크를 반환하도록 변경 * fix(Book): 도서 목록 조회 페이지네이션 누락 수정 * fix(Book): 도서 목록 조회 totalPages 미작동 문제 수정 * chore: Create README.md * chore: Create CONTRIBUTING.md * Update README.md * refactor(Board): Dto 필드명 상세화 * refactor(Board): 게시글 목록 조회 반환 정보 추가 * Update README.md * refactor(WorkExperience): 검색 API 엔드포인트 변경 * refactor(DTO): 불필요한 Lombok 어노테이션 제거 * refactor(EqualsAndHashCode): 일부 Entity에서 저장할 때 데이터가 중복되던 문제 수정 * refactor(Constructor): Entity 생성자에 대한 접근 제한 설정 * refactor(Util): 불필요한 어노테이션 제거 * refactor(CompositeKey): 복합키 캡슐화 * refactor(DTO): ResponseDto 불변성을 위한 Setter 제거 * refactor(ResponseModel): ResponseModel DDD에 맞게 재설계 및 그에 따른 관련 로직 수정 * refactor(RedisIpAccessMonitor): 비정상 접근 IP 기록 초기화시 초기화된 IP 리스트를 반환하도록 변경 * refactor(Email): 이메일 전송시 전송 완료된 이메일 주소를 반환하도록 변경 * refactor(BlacklistIp): 블랙리스트 IP 초기화시 초기화된 IP 리스트를 반환하도록 변경 * refactor(Member): 멤버 비밀번호 재발급/요청시 멤버 ID를 반환하도록 변경 * refactor(Member): 내 프로필 조회시 재학 상태를 반환하도록 변경 * refactor(Enum): 운영진 Enum값 수정 * refactor(Board): 게시글 카테고리 Enum으로 고정 * refactor(BlacklistIp): 슬랙 메시지 오타 수정 * refactor(BlacklistIp): 의심스러운 활동으로 인한 차단시 블랙리스트 추가 사유를 기록하도록 수정 * fix(GeoIp): GeoIp DB를 불러오지 못할 경우 Unknown을 반환하도록 수정 * refactor(Board): BoardCategory GRADUATE -> GRADUATED 변경 * refactor(Board): BoardCategory 정보를 소문자로 반환하도록 변경 * refactor(Job,News): 채용 공고, IT 뉴스 반환 정보에 생성일자 추가 * feat(Login): 현재 로그인 중인 멤버 조회 API 추가 * refactor(Accuse): 확장성을 고려한 신고 시스템 재설계 * refactor(Accuse): 신고하기 로직 리팩토링 * refactor(Accuse): 신고 테이블 구조 및 신고 내역 조회 응답 변경, 누적 횟수 기준으로 정렬할 수 있도록 함. * refactor(Accuse): 신고 시스템 재설계에 따른 신고 상태 변경 API 수정 및 리팩토링 * refactor(Board): 게시글 상세 조회시 익명 유저일 경우 권한 정보를 반환하지 않도록 변경 * refactor(Board): 게시글 상세 조회 및 댓글 조회시 작성자의 ID, 이름을 모두 반환하도록 변경 * feat(Schedule): 일정 중요도 및 조건별 검색 API 추가 * feat(Schedule): 일정 모아보기 API 추가 * feat(Board): 게시판 카테고리에 동아리 소식 추가 * ci: add spring boot gradle ci (#304) * docs: add gradle ci badge (#304) * ci: update spring-boot-gradle-ci (#304) * refactor(Actuator): 헬스 체크를 위한 권한 설정 변경 * refactor(test): Test 환경 설정 * refactor(Schedule): 일정 조회시 기간 내 진행중인 일정 모든 일정에 대해 조회하도록 변경 * refactor(Book): 도서 대출 내역 조회시 대출자의 이름을 같이 반환하도록 수정 * fix(Member): 멤버 정보 수정시 Optional로 인해 발생하는 오류 수정 * feat(Book): 도서 연체자 조회 API 추가 * fix: 이메일 전송 시 html 파일 경로 지정용 ThymeleafConfig 추가 #299 * chore: 배포 환경 설정 * chore: 배포 환경 변경(prod->stage) * chore: gradle build시 프로필을 유동적으로 사용할 수 있도록 변경 * refactor(Board): 커뮤니티 게시글 카테고리별 조회시 writerId를 반환하도록 변경 * refactor(Board): 커뮤니티 게시글 카테고리별 조회 엔드포인트 변경 * refactor(Board): 썸네일 이미지 URL 컬럼 추가 * fix(Board): 썸네일 이미지 URL 업데이트 로직 누락 수정 * refactor(File): 게시글 사진 업로드 -> 게시글 파일 업로드 Operation 수정 * refactor(Accuse): 자신의 콘텐츠에 대해 신고할 수 없도록 변경 * feat(Accuse): 나의 신고 내역 조회 API 추가 * feat(Book): 도서 대여 승인 제도 추가 * refactor(Book): 도서 대여 승인 제도 추가에 따른 도서 연체자 조회 로직 수정 * refactor(Book): 도서 대출 내역 조회시 대출 여부 대신 대출 상태를 기준으로 조회 가능하도록 변경 * refactor: 유효성 검사 및 트랙젝션 누락 수정 * feat(Book): 최대 도서 대여 개수 정책 추가 * refactor(Book): 도서 대출 내역, 연체자 조회시 대출 상태를 같이 반환하도록 변경 * refactor(Exception): 미사용 예외 삭제 * refactor(Exception): 예외 재분류 * refactor(Book): 도서 대출 내역 조회시 borrowedAt이 없는 경우를 고려하여 createdAt을 두 번째 정렬 기준으로 추가 * refactor(Exception): 409 예외 처리 및 응답 변경 * fix(Book): 중복 도서 대출 요청 수정 * refactor(Book): 대출 중인 도서도 대출 요청 가능하도록 변경 * feat: Board soft delete 구현 #299 * refactor(Exception): ErrorResponse 분리 * refactor(Response): ResponseModel -> ApiResponse 이름 변경 * chore: Dockerfile 수정 * chore: Dockerfile 수정(JDK 21 강제화) * chore: Dockerfile 롤백 * fix: Board 관련 소프트 딜리트, 조회 로직 수정, 삭제한 Board 조회 api 작성 #299 * fix: board 소프트 딜리트 @where과 nativeQuery를 사용해 구현 #299 * fix: award 소프트 딜리트 구현, where 어노테이션 deprecated 이슈로 SQLRestriction 사용 #299 * fix: Blog 소프트 딜리트 구현 #299 * fix: Book 소프트 딜리트 구현 #299 * fix: Donation 소프트 딜리트 구현 #299 * fix : JobPosting 소프트 딜리트 구현 #299 * fix: MembershipFee 소프트 딜리트 구현 #299 * fix: News 소프트 딜리트 구현 #299 * fix: Notification 소프트 딜리트 구현 #299 * fix: Position 소프트 딜리트 구현 #299 * fix: Product 소프트 딜리트 #299 * fix: Recruitment 소프트 딜리트 구현 #299 * fix: Review 소프트 딜리트 구현 #299 * fix: Schedule 소프트 딜리트 #299 * fix: SharedAccount 소프트 딜리트 구현 #299 * fix: WorkExperience 소프트 딜리트 구현 #299 * fix: Application 소프트 딜리트 방식 수정 및 Book 하드 딜리트 전환. 버그 발견 #299 * feat: Comment 자체 소프트 딜리트 구현과 삭제된 댓글입니다를 구현할 수 있도록 응답 로직 수정 #299 * feat(IPInfo): IPInfo 라이브러리에 누락된 Context 관련 파일 작성 * refactor(IpAuthenticationFilter): 해외 접속시 국가 코드가 아닌 국가명이 출력되도록 변경 * fix: ActivityGroup 소프트 딜리트 작성 #299 * fix: ActivityGroupBoard 소프트 딜리트 작성 #299 * fix: ActivityGroupReport 소프트 딜리트 작성 #299 * fix: Book 커스텀 소프트 딜리트 재작성 #299 * feat(Slack): 보안 경고 알림에 클라이언트의 위치 정보 추가 * refactor(LoginAttemptLog): 로그인 기록에 국가 정보 추가 * refactor(IpAuthenticationFilter): 로깅 강화 * refactor: 삭제된 데이터 조회에 대한 transactional read only 설정 * refactor: GeoIP2 제거 --------- Co-authored-by: mingmingmon <mingmingmon@naver.com> Co-authored-by: 김관식 <39869096+gwansikk@users.noreply.github.com> --------- Co-authored-by: mingmingmon <mingmingmon@naver.com> Co-authored-by: 김관식 <39869096+gwansikk@users.noreply.github.com> --------- Co-authored-by: mingmingmon <mingmingmon@naver.com> Co-authored-by: 김관식 <39869096+gwansikk@users.noreply.github.com>
1 parent 331baec commit 6bf4cd9

File tree

353 files changed

+6679
-4629
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

353 files changed

+6679
-4629
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
FROM openjdk:21
22
EXPOSE 8080
3-
COPY build/libs/clab-prod.jar /clab.jar
3+
COPY build/libs/clab.jar /clab.jar
44
ENTRYPOINT ["java", "-jar", "-Dspring.profiles.active=stage", "/clab.jar"]

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
- **PostgreSQL**: 주 데이터베이스로 사용.
1616
- **Redis**: 캐싱 및 JWT 관리를 위해 사용.
1717
- **Thymeleaf**: 메일 전송을 위한 템플릿 엔진.
18-
- **GeoIP2**: IP 주소 기반 위치 정보 조회.
18+
- **IPInfo**: IP 주소 기반 위치 정보 조회.
1919
- **Google Authenticator**: 2단계 인증을 위한 라이브러리.
2020
- **Slack API**: 각종 보안 알림을 위해 사용.
2121
- **Swagger**: API 문서 자동화.

build.gradle

Lines changed: 77 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -1,113 +1,112 @@
11
plugins {
2-
id 'java'
3-
id 'org.springframework.boot' version '3.2.1'
4-
id 'io.spring.dependency-management' version '1.1.4'
2+
id 'java'
3+
id 'org.springframework.boot' version '3.2.1'
4+
id 'io.spring.dependency-management' version '1.1.4'
55
}
66

77
group = 'page.clab'
88
version = '0.0.1-SNAPSHOT'
99

1010
jar {
11-
enabled = false
11+
enabled = false
1212
}
1313

1414
bootJar {
15-
archivesBaseName = "clab"
16-
archiveVersion = "1.0.0"
17-
18-
from("/src/main/resources") {
19-
into 'BOOT-INF/classes'
20-
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
21-
}
22-
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
23-
24-
if (project.hasProperty('prod')) {
25-
archiveFileName = "clab-prod.jar"
26-
} else if (project.hasProperty('stage')) {
27-
archiveFileName = "clab-stage.jar"
28-
} else {
29-
archiveFileName = "clab.jar"
30-
}
15+
archivesBaseName = "clab"
16+
archiveFileName = "clab.jar"
17+
archiveVersion = "1.0.0"
18+
19+
if (project.hasProperty('prod')) {
20+
archiveFileName = "clab-prod.jar"
21+
} else if (project.hasProperty('stage')) {
22+
archiveFileName = "clab-stage.jar"
23+
} else {
24+
archiveFileName = "clab.jar"
25+
}
26+
}
27+
28+
test {
29+
systemProperty 'spring.profiles.active', findProperty('env') ?: 'dev'
3130
}
3231

3332

3433
java {
35-
sourceCompatibility = '21'
34+
sourceCompatibility = '21'
3635
}
3736

3837
repositories {
39-
mavenCentral()
40-
maven { url 'https://jitpack.io' }
38+
mavenCentral()
39+
maven { url 'https://jitpack.io' }
4140
}
4241

4342
dependencies {
44-
// Spring Project
45-
implementation 'org.springframework.boot:spring-boot-starter-actuator' // 모니터링
46-
implementation 'org.springframework.boot:spring-boot-starter-web' // 웹 MVC
47-
implementation 'org.springframework.boot:spring-boot-starter-validation' // 유효성 검사
48-
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf' // 템플릿 엔진
49-
implementation 'org.springframework.boot:spring-boot-starter-webflux' // WebFlux
50-
developmentOnly 'org.springframework.boot:spring-boot-devtools' // 개발 도구
51-
52-
// Util
53-
compileOnly 'org.projectlombok:lombok' // 롬복
54-
annotationProcessor 'org.projectlombok:lombok' // 롬복
55-
implementation 'com.google.code.gson:gson:2.10.1' // JSON 라이브러리
56-
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.3.0' // Swagger
57-
implementation 'org.modelmapper:modelmapper:3.2.0' // ModelMapper
58-
implementation 'commons-io:commons-io:2.15.1' // Apache Commons IO
59-
implementation 'com.google.guava:guava:33.0.0-jre' // Google Core Libraries For Java
60-
implementation 'org.springframework.boot:spring-boot-starter-mail' // Spring Mail
61-
implementation 'com.google.zxing:core:3.4.1' // QR 코드
62-
implementation 'com.google.zxing:javase:3.4.1' // QR 코드
63-
implementation 'com.slack.api:slack-api-client:1.38.0' // Slack API
64-
65-
// DB
66-
implementation 'org.postgresql:postgresql:42.7.1' // PostgreSQL JDBC Driver
67-
implementation 'org.springframework.boot:spring-boot-starter-data-redis' // Redis
68-
implementation 'org.springframework.boot:spring-boot-starter-data-jpa' // Spring Data JPA
69-
implementation 'org.springframework.boot:spring-boot-starter-validation' // Hibernate Validator
70-
implementation 'org.hibernate.validator:hibernate-validator:8.0.1.Final' // Bean Validation
71-
implementation 'jakarta.validation:jakarta.validation-api:3.0.2' // Jakarta Bean Validation
72-
implementation 'com.maxmind.geoip2:geoip2:4.2.0' // GeoIP2
73-
74-
// QueryDSL
75-
implementation 'com.querydsl:querydsl-jpa:5.1.0:jakarta'
76-
annotationProcessor "com.querydsl:querydsl-apt:5.1.0:jakarta"
77-
annotationProcessor "jakarta.annotation:jakarta.annotation-api"
78-
annotationProcessor "jakarta.persistence:jakarta.persistence-api"
79-
80-
// Security
81-
implementation 'org.springframework.boot:spring-boot-starter-security' // Spring Security
82-
implementation 'com.warrenstrange:googleauth:1.5.0' // Google Authenticator
83-
implementation 'io.jsonwebtoken:jjwt-api:0.11.5' // JWT 라이브러리
84-
runtimeOnly 'io.jsonwebtoken:jjwt-impl:0.11.5' // JWT 구현체
85-
runtimeOnly 'io.jsonwebtoken:jjwt-jackson:0.11.5' // JWT Jackson 모듈
86-
87-
// XSS Filter
88-
implementation 'com.navercorp.lucy:lucy-xss-servlet:2.0.1' // Lucy XSS Servlet Filter
89-
implementation 'com.navercorp.lucy:lucy-xss:1.6.3' // Lucy XSS Filter
90-
implementation 'org.apache.commons:commons-text:1.11.0' // Apache Commons Text
91-
92-
// Test
93-
testImplementation 'org.springframework.boot:spring-boot-starter-test' // Spring Boot Test
94-
testImplementation 'org.springframework.security:spring-security-test' // Spring Security Test
43+
// Spring Project
44+
implementation 'org.springframework.boot:spring-boot-starter-actuator' // 모니터링
45+
implementation 'org.springframework.boot:spring-boot-starter-web' // 웹 MVC
46+
implementation 'org.springframework.boot:spring-boot-starter-validation' // 유효성 검사
47+
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf' // 템플릿 엔진
48+
implementation 'org.springframework.boot:spring-boot-starter-webflux' // WebFlux
49+
developmentOnly 'org.springframework.boot:spring-boot-devtools' // 개발 도구
50+
51+
// Util
52+
compileOnly 'org.projectlombok:lombok' // 롬복
53+
annotationProcessor 'org.projectlombok:lombok' // 롬복
54+
implementation 'com.google.code.gson:gson:2.10.1' // JSON 라이브러리
55+
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.3.0' // Swagger
56+
implementation 'commons-io:commons-io:2.15.1' // Apache Commons IO
57+
implementation 'com.google.guava:guava:33.0.0-jre' // Google Core Libraries For Java
58+
implementation 'org.springframework.boot:spring-boot-starter-mail' // Spring Mail
59+
implementation 'com.google.zxing:core:3.4.1' // QR 코드
60+
implementation 'com.google.zxing:javase:3.4.1' // QR 코드
61+
implementation 'com.slack.api:slack-api-client:1.38.0' // Slack API
62+
implementation 'io.ipinfo:ipinfo-spring:0.3.1' // IPInfo
63+
64+
65+
// DB
66+
implementation 'org.postgresql:postgresql:42.7.1' // PostgreSQL JDBC Driver
67+
implementation 'org.springframework.boot:spring-boot-starter-data-redis' // Redis
68+
implementation 'org.springframework.boot:spring-boot-starter-data-jpa' // Spring Data JPA
69+
implementation 'org.springframework.boot:spring-boot-starter-validation' // Hibernate Validator
70+
implementation 'org.hibernate.validator:hibernate-validator:8.0.1.Final' // Bean Validation
71+
implementation 'jakarta.validation:jakarta.validation-api:3.0.2' // Jakarta Bean Validation
72+
73+
// QueryDSL
74+
implementation 'com.querydsl:querydsl-jpa:5.1.0:jakarta'
75+
annotationProcessor "com.querydsl:querydsl-apt:5.1.0:jakarta"
76+
annotationProcessor "jakarta.annotation:jakarta.annotation-api"
77+
annotationProcessor "jakarta.persistence:jakarta.persistence-api"
78+
79+
// Security
80+
implementation 'org.springframework.boot:spring-boot-starter-security' // Spring Security
81+
implementation 'com.warrenstrange:googleauth:1.5.0' // Google Authenticator
82+
implementation 'io.jsonwebtoken:jjwt-api:0.11.5' // JWT 라이브러리
83+
runtimeOnly 'io.jsonwebtoken:jjwt-impl:0.11.5' // JWT 구현체
84+
runtimeOnly 'io.jsonwebtoken:jjwt-jackson:0.11.5' // JWT Jackson 모듈
85+
86+
// XSS Filter
87+
implementation 'com.navercorp.lucy:lucy-xss-servlet:2.0.1' // Lucy XSS Servlet Filter
88+
implementation 'com.navercorp.lucy:lucy-xss:1.6.3' // Lucy XSS Filter
89+
implementation 'org.apache.commons:commons-text:1.11.0' // Apache Commons Text
90+
91+
// Test
92+
testImplementation 'org.springframework.boot:spring-boot-starter-test' // Spring Boot Test
93+
testImplementation 'org.springframework.security:spring-security-test' // Spring Security Test
9594
}
9695

9796
tasks.named('test') {
98-
useJUnitPlatform()
97+
useJUnitPlatform()
9998
}
10099

101100
def querydslDir = "$buildDir/generated/querydsl"
102101

103102
sourceSets {
104-
main.java.srcDirs += [ querydslDir ]
103+
main.java.srcDirs += [ querydslDir ]
105104
}
106105

107106
tasks.withType(JavaCompile) {
108-
options.generatedSourceOutputDirectory = file(querydslDir)
107+
options.generatedSourceOutputDirectory = file(querydslDir)
109108
}
110109

111110
clean.doLast {
112-
file(querydslDir).deleteDir()
111+
file(querydslDir).deleteDir()
113112
}

src/main/java/page/clab/api/ApiApplication.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@
22

33
import org.springframework.boot.SpringApplication;
44
import org.springframework.boot.autoconfigure.SpringBootApplication;
5+
import org.springframework.data.jpa.repository.config.EnableJpaAuditing;
56
import org.springframework.scheduling.annotation.EnableScheduling;
67

78
@SpringBootApplication
89
@EnableScheduling
10+
@EnableJpaAuditing
911
public class ApiApplication {
1012

1113
public static void main(String[] args) {

src/main/java/page/clab/api/domain/accuse/api/AccuseController.java

Lines changed: 34 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,13 @@
2020
import page.clab.api.domain.accuse.domain.AccuseStatus;
2121
import page.clab.api.domain.accuse.domain.TargetType;
2222
import page.clab.api.domain.accuse.dto.request.AccuseRequestDto;
23+
import page.clab.api.domain.accuse.dto.response.AccuseMyResponseDto;
2324
import page.clab.api.domain.accuse.dto.response.AccuseResponseDto;
2425
import page.clab.api.global.common.dto.PagedResponseDto;
25-
import page.clab.api.global.common.dto.ResponseModel;
26+
import page.clab.api.global.common.dto.ApiResponse;
2627

2728
@RestController
28-
@RequestMapping("/accuses")
29+
@RequestMapping("/api/v1/accuses")
2930
@RequiredArgsConstructor
3031
@Tag(name = "Accuse", description = "신고")
3132
@Slf4j
@@ -36,44 +37,53 @@ public class AccuseController {
3637
@Operation(summary = "[U] 신고하기", description = "ROLE_USER 이상의 권한이 필요함")
3738
@Secured({"ROLE_USER", "ROLE_ADMIN", "ROLE_SUPER"})
3839
@PostMapping("")
39-
public ResponseModel createAccuse(
40-
@Valid @RequestBody AccuseRequestDto accuseRequestDto
40+
public ApiResponse<Long> createAccuse(
41+
@Valid @RequestBody AccuseRequestDto requestDto
4142
) {
42-
Long id = accuseService.createAccuse(accuseRequestDto);
43-
ResponseModel responseModel = ResponseModel.builder().build();
44-
responseModel.addData(id);
45-
return responseModel;
43+
Long id = accuseService.createAccuse(requestDto);
44+
return ApiResponse.success(id);
4645
}
4746

4847
@Operation(summary = "[A] 신고 내역 조회(신고 대상, 처리 상태 기준)", description = "ROLE_ADMIN 이상의 권한이 필요함<br>" +
4948
"2개의 파라미터를 자유롭게 조합하여 필터링 가능<br>" +
50-
"신고 대상, 처리 상태 중 하나라도 입력하지 않으면 전체 조회됨")
49+
"신고 대상, 처리 상태 중 하나라도 입력하지 않으면 전체 조회됨<br>" +
50+
"누적 횟수 기준으로 정렬할지 여부를 선택할 수 있음")
5151
@Secured({"ROLE_ADMIN", "ROLE_SUPER"})
5252
@GetMapping("")
53-
public ResponseModel getAccusesByConditions(
54-
@RequestParam(name = "targetType", required = false) TargetType targetType,
55-
@RequestParam(name = "accuseStatus", required = false) AccuseStatus accuseStatus,
53+
public ApiResponse<PagedResponseDto<AccuseResponseDto>> getAccusesByConditions(
54+
@RequestParam(name = "targetType", required = false) TargetType type,
55+
@RequestParam(name = "accuseStatus", required = false) AccuseStatus status,
56+
@RequestParam(name = "countOrder", defaultValue = "false") boolean countOrder,
5657
@RequestParam(name = "page", defaultValue = "0") int page,
5758
@RequestParam(name = "size", defaultValue = "20") int size
5859
) {
5960
Pageable pageable = PageRequest.of(page, size);
60-
PagedResponseDto<AccuseResponseDto> accuses = accuseService.getAccusesByConditions(targetType, accuseStatus, pageable);
61-
ResponseModel responseModel = ResponseModel.builder().build();
62-
responseModel.addData(accuses);
63-
return responseModel;
61+
PagedResponseDto<AccuseResponseDto> accuses = accuseService.getAccusesByConditions(type, status, countOrder, pageable);
62+
return ApiResponse.success(accuses);
63+
}
64+
65+
@Operation(summary = "[U] 나의 신고 내역 조회", description = "ROLE_USER 이상의 권한이 필요함")
66+
@Secured({"ROLE_USER", "ROLE_ADMIN", "ROLE_SUPER"})
67+
@GetMapping("/my")
68+
public ApiResponse<PagedResponseDto<AccuseMyResponseDto>> getMyAccuses(
69+
@RequestParam(name = "page", defaultValue = "0") int page,
70+
@RequestParam(name = "size", defaultValue = "20") int size
71+
) {
72+
Pageable pageable = PageRequest.of(page, size);
73+
PagedResponseDto<AccuseMyResponseDto> accuses = accuseService.getMyAccuses(pageable);
74+
return ApiResponse.success(accuses);
6475
}
6576

6677
@Operation(summary = "[A] 신고 상태 변경", description = "ROLE_ADMIN 이상의 권한이 필요함")
6778
@Secured({"ROLE_ADMIN", "ROLE_SUPER"})
68-
@PatchMapping("/{accuseId}")
69-
public ResponseModel updateAccuseStatus(
70-
@PathVariable(name = "accuseId") Long accuseId,
71-
@RequestParam(name = "accuseStatus") AccuseStatus accuseStatus
79+
@PatchMapping("/{targetType}/{targetId}")
80+
public ApiResponse<Long> updateAccuseStatus(
81+
@PathVariable(name = "targetType") TargetType type,
82+
@PathVariable(name = "targetId") Long targetId,
83+
@RequestParam(name = "accuseStatus") AccuseStatus status
7284
) {
73-
Long id = accuseService.updateAccuseStatus(accuseId, accuseStatus);
74-
ResponseModel responseModel = ResponseModel.builder().build();
75-
responseModel.addData(id);
76-
return responseModel;
85+
Long id = accuseService.updateAccuseStatus(type, targetId, status);
86+
return ApiResponse.success(id);
7787
}
7888

7989
}

0 commit comments

Comments
 (0)