Skip to content
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

[Feat] 목표 체계 개편 #211

Merged
merged 9 commits into from
Jan 6, 2024
Merged

[Feat] 목표 체계 개편 #211

merged 9 commits into from
Jan 6, 2024

Conversation

funnysunny08
Copy link
Contributor

🚩 관련 이슈

📋 구현 기능 명세

  • 목표 enum 클래스 생성
  • 목표 테이블 변경
    -- targetMoney, targetDate nullable
    -- goal_type 추가
  • 신규 유저 가입 시 COMMONER_GOAL로 목표 자동 설정 로직 추가
  • 피드 생성 : FeedService.java createFeed 참고..
  • 피드 삭제 : FeedService.java deleteFeed 참고..
  • 마이페이지에서 targetMoney, targetDate 반환값 제거, goal_type 반환

📌 PR Point

  • 무슨 이유로 어떻게 코드를 변경했는지

  • 어떤 부분에 리뷰어가 집중해야 하는지

  • 개발하면서 어떤 점이 궁금했는지

📸 결과물 스크린샷

@Pattern(regexp = "^[\\S][가-힣a-zA-Z0-9\\s]{0,20}$", message = "위니 피드 제목 형식에 맞지 않습니다.")

🛠️ 테스트

  • 테스트

🚀 API Endpoint

  • /

@funnysunny08 funnysunny08 added Sunny Feat important things labels Jan 4, 2024
@funnysunny08 funnysunny08 self-assigned this Jan 4, 2024
private Long targetMoney;

@Column(nullable = false)
@Column
private LocalDate targetDate;
Copy link
Contributor

Choose a reason for hiding this comment

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

Q) targetDate, duringGoalCount는 개편 목표체계에서는 필요없지만
컬럼을 없애버리면 현재 서비스에 지장이 갈 수 있어서 일부러 남긴거 맞을까요?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

넵! targetDate, targetMoney는 더 이상 사용하지 않는 컬럼이라서 null 허용으로 바꿔주었습니다! duringGoalCount는 사용할 예정입니다 :)

Copy link
Contributor

Choose a reason for hiding this comment

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

이 코드들을 머지하고 -> iOS/AOS 작업 -> 스토어 업데이트 과정이라고 생각해서 질문했었습니다!
머지하게 되면 스토어 업데이트 전까지 클라작업할동안, 기존 버전으로 우리 앱을 사용하는 유저들이 목표설정을 할때 에러가 날꺼 같다는 생각이 들어서 ㅠ

@@ -47,14 +68,12 @@ public class Goal extends AuditingTimeEntity {
private List<Feed> feeds = new ArrayList<>();

@Builder
public Goal(Long targetMoney, LocalDate targetDate, User user) {
this.targetMoney = targetMoney;
this.targetDate = targetDate;
Copy link
Contributor

Choose a reason for hiding this comment

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

Q) 위의 질문과 연관지었을때, 빌더에서 targetDate가 사라진 이유가 궁금합니다~

Copy link
Contributor Author

Choose a reason for hiding this comment

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

저희 새로운 목표 체계에서는 목표에 대해 따로 기한을 두지 않고 있어 삭제하였습니다!

private Boolean isAttained;

public static UserResponseGoalDto of(Long duringGoalAmount, Long duringGoalCount, Long targetMoney, int targetDay, int dDay, boolean isOver, boolean isAttained) {
return new UserResponseGoalDto(duringGoalAmount, duringGoalCount, targetMoney, targetDay, dDay, isOver, isAttained);
public static UserResponseGoalDto of(
Copy link
Contributor

@alpha-kwhn alpha-kwhn Jan 5, 2024

Choose a reason for hiding this comment

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

Q) 현재 운영서버에서는 필요한 targetDay, targetMoney와 같은 값들이 response에서 제외되었는데
혹시 의도가 있을까요?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

현재 목표 달성 기한은 사라졌고, targetMoney는 goalType이 대체할 수 있다 생각하여 제외하였습니다! 추후에 클라 파트와 명세서 공유하며 상의해 볼 예정입니다!

Copy link
Contributor

@alpha-kwhn alpha-kwhn left a comment

Choose a reason for hiding this comment

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

고생하셨읍니다~~

@funnysunny08 funnysunny08 merged this pull request into dev Jan 6, 2024
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feat important things Sunny
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feat] 목표 체계 개편
2 participants