Skip to content

Commit

Permalink
Merge pull request #180 from a-romantic-cat/feat/27
Browse files Browse the repository at this point in the history
feat: 미션에 매일 속성 추가
  • Loading branch information
Yoon-Jemin authored Feb 19, 2024
2 parents 9efe653 + fbec866 commit e7fa45c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ public static MissionResponseDTO.MissionInfoDTO toMissionInfoDTO(Mission mission
.missionId(mission.getId())
.name(mission.getName())
.steps(mission.getSteps())
.everyday(mission.isEveryday())
.stepsCompleted(currentStepsCompleted)
.missionStatus(currentMissionStatus)
.build();
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/aromanticcat/umcproject/entity/Mission.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ public class Mission extends BaseEntity {

private Integer coin; // 미션 성공 시 보상으로 받을 코인 수

private boolean everyday;

@OneToMany(mappedBy = "mission", fetch = FetchType.LAZY, cascade = CascadeType.ALL)
private List<MemberMission> memberMissions = new ArrayList<>();
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ public static class MissionInfoDTO{
Long missionId; // 미션 아이디
String name; // 미션 이름
Integer steps; // 미션의 총 단계 수
boolean everyday;
Integer stepsCompleted; // 한 미션에서 사용자가 완료한 미션의 수
MissionStatus missionStatus; // 미션 완료 여부

Expand Down

0 comments on commit e7fa45c

Please sign in to comment.