-
Notifications
You must be signed in to change notification settings - Fork 0
Feat/#31 : 제휴게시글 관련 기능 구현(재구현) #49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
2ef0e34
96fdaca
a4c7516
83879e6
c3bf6c7
feb08c2
cf46c06
728920a
2c81df0
dd2e976
4a6552c
62c7b68
8061987
7b17169
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -22,7 +22,7 @@ public record GetPostResponse( | |
| PostCategory category, | ||
| String title, | ||
| String content, | ||
| String place, | ||
| String placeName, | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: # Search for response DTOs with 'place' field to check current state
rg -n --type=java -B2 -A2 'String place[,;)]' src/main/java/com/campus/campus/domain/councilpost/application/dto/response/Repository: our-campUS/our-campUS-BE Length of output: 3621 🏁 Script executed: # Also check for placeName to see which DTOs have been updated
rg -n --type=java -B2 -A2 'String placeName[,;)]' src/main/java/com/campus/campus/domain/councilpost/application/dto/response/Repository: our-campUS/our-campUS-BE Length of output: 1301 🏁 Script executed: # List all response DTOs in councilpost domain to ensure comprehensive check
fd -e java "Response\.java" src/main/java/com/campus/campus/domain/councilpost/application/dto/response/Repository: our-campUS/our-campUS-BE Length of output: 922 응답 DTO들의 필드명
모든 응답 DTO의 필드명을 🤖 Prompt for AI Agents |
||
| LocalDate startDate, | ||
| LocalDate endDate, | ||
| LocalDateTime startDateTime, | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -9,7 +9,7 @@ public record PostListItemResponse( | |
| Long id, | ||
| PostCategory category, | ||
| String title, | ||
| String place, | ||
| String placeName, | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Search for place field usage in response DTOs
echo "=== Searching for 'place' field ==="
rg -n --type=java 'String place[,;)]' src/main/java/com/campus/campus/domain/councilpost/application/dto/response/
echo -e "\n=== Searching for 'placeName' field ==="
rg -n --type=java 'String placeName[,;)]' src/main/java/com/campus/campus/domain/councilpost/application/dto/response/
echo -e "\n=== List all response DTO files ==="
fd --type f --extension java 'Response\.java$' src/main/java/com/campus/campus/domain/councilpost/application/dto/response/Repository: our-campUS/our-campUS-BE Length of output: 1927 응답 DTO의 장소명 필드 일관성 문제를 해결해주세요. 응답 DTO들에서 동일한 개념의 필드가 서로 다른 이름으로 정의되어 있습니다:
API 일관성을 위해 모든 응답 DTO가 동일한 필드명을 사용하도록 통일해야 합니다. 🤖 Prompt for AI Agents |
||
| LocalDateTime endDateTime, | ||
| String thumbnailImageUrl, | ||
| ThumbnailIcon thumbnailIcon, | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| package com.campus.campus.domain.councilpost.application.exception; | ||
|
|
||
| import com.campus.campus.global.common.exception.ApplicationException; | ||
|
|
||
| public class AcademicInfoNotSetException extends ApplicationException { | ||
| public AcademicInfoNotSetException() { | ||
| super(ErrorCode.ACADEMIC_INFO_NOT_SET); | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,34 +1,38 @@ | ||
| package com.campus.campus.domain.councilpost.application.exception; | ||
|
|
||
| import com.campus.campus.global.common.exception.ErrorCodeInterface; | ||
|
|
||
| import lombok.AllArgsConstructor; | ||
| import lombok.Getter; | ||
|
|
||
| import org.springframework.http.HttpStatus; | ||
|
|
||
| @Getter | ||
| @AllArgsConstructor | ||
| public enum ErrorCode implements ErrorCodeInterface { | ||
|
|
||
| POST_NOT_FOUND(2401, HttpStatus.NOT_FOUND, "게시글을 찾을 수 없습니다."), | ||
| NOT_POST_WRITER(2402, HttpStatus.FORBIDDEN, "작성자만 해당 작업을 수행할 수 있습니다."), | ||
| THUMBNAIL_REQUIRED(2403, HttpStatus.BAD_REQUEST, "썸네일(이미지 또는 아이콘)은 반드시 필요합니다."), | ||
| POST_IMAGE_LIMIT_EXCEEDED(2404, HttpStatus.BAD_REQUEST, "게시글 이미지는 최대 10개까지 등록할 수 있습니다."), | ||
| POST_OCI_IMAGE_DELETE_FAILED(2405, HttpStatus.INTERNAL_SERVER_ERROR, "OCI 이미지 삭제에 실패했습니다."), | ||
| POST_NOT_FOUND(2401, HttpStatus.NOT_FOUND, "게시글을 찾을 수 없습니다."), | ||
| NOT_POST_WRITER(2402, HttpStatus.FORBIDDEN, "작성자만 해당 작업을 수행할 수 있습니다."), | ||
| THUMBNAIL_REQUIRED(2403, HttpStatus.BAD_REQUEST, "썸네일(이미지 또는 아이콘)은 반드시 필요합니다."), | ||
| POST_IMAGE_LIMIT_EXCEEDED(2404, HttpStatus.BAD_REQUEST, "게시글 이미지는 최대 10개까지 등록할 수 있습니다."), | ||
| POST_OCI_IMAGE_DELETE_FAILED(2405, HttpStatus.INTERNAL_SERVER_ERROR, "OCI 이미지 삭제에 실패했습니다."), | ||
|
|
||
| // EVENT 관련 | ||
| EVENT_START_DATETIME_REQUIRED(2406, HttpStatus.BAD_REQUEST, "행사는 시작 일시가 필요합니다."), | ||
| EVENT_END_DATETIME_NOT_ALLOWED(2407, HttpStatus.BAD_REQUEST, "행사는 종료 일시를 가질 수 없습니다."), | ||
| // EVENT 관련 | ||
| EVENT_START_DATETIME_REQUIRED(2406, HttpStatus.BAD_REQUEST, "행사는 시작 일시가 필요합니다."), | ||
| EVENT_END_DATETIME_NOT_ALLOWED(2407, HttpStatus.BAD_REQUEST, "행사는 종료 일시를 가질 수 없습니다."), | ||
|
|
||
| // PARTNERSHIP 관련 | ||
| PARTNERSHIP_DATE_REQUIRED(2408, HttpStatus.BAD_REQUEST, "제휴는 시작일과 종료일이 필요합니다."), | ||
| // PARTNERSHIP 관련 | ||
| PARTNERSHIP_DATE_REQUIRED(2408, HttpStatus.BAD_REQUEST, "제휴는 시작일과 종료일이 필요합니다."), | ||
|
|
||
| // 학생의 학생회 게시글 조회 관련 | ||
| POST_ACCESS_DENIED(2409, HttpStatus.FORBIDDEN, "해당 게시글에 접근할 권한이 없습니다."), | ||
| COLLEGE_NOT_SET(2410, HttpStatus.BAD_REQUEST, "단과대 정보가 설정되지 않았습니다."), | ||
| MAJOR_NOT_SET(2411, HttpStatus.BAD_REQUEST, "학과 정보가 설정되지 않았습니다."); | ||
| // 학생의 학생회 게시글 조회 관련 | ||
| POST_ACCESS_DENIED(2409, HttpStatus.FORBIDDEN, "해당 게시글에 접근할 권한이 없습니다."), | ||
| COLLEGE_NOT_SET(2410, HttpStatus.BAD_REQUEST, "단과대 정보가 설정되지 않았습니다."), | ||
| MAJOR_NOT_SET(2411, HttpStatus.BAD_REQUEST, "학과 정보가 설정되지 않았습니다."), | ||
| ACADEMIC_INFO_NOT_SET(2412, HttpStatus.BAD_REQUEST, "학적 정보가 설정되지 않았습니다."), | ||
|
|
||
| PLACE_INFO_NOT_FOUND(2413, HttpStatus.NOT_FOUND, "해당 게시글의 장소 정보를 찾을 수 없습니다."); | ||
|
|
||
| private final int code; | ||
| private final HttpStatus status; | ||
| private final String message; | ||
| private final int code; | ||
| private final HttpStatus status; | ||
| private final String message; | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| package com.campus.campus.domain.councilpost.application.exception; | ||
|
|
||
| import com.campus.campus.global.common.exception.ApplicationException; | ||
|
|
||
| public class PlaceInfoNotFoundException extends ApplicationException { | ||
| public PlaceInfoNotFoundException() { | ||
| super(ErrorCode.PLACE_INFO_NOT_FOUND); | ||
| } | ||
| } |
Uh oh!
There was an error while loading. Please reload this page.