[FIX] userに目標が紐づけられない問題を修正しました。
This commit is contained in:
@@ -45,13 +45,11 @@ public class UserServiceImpl implements UserService {
|
|||||||
GoalEntity goalEntity = new GoalEntity();
|
GoalEntity goalEntity = new GoalEntity();
|
||||||
goalEntity.setTargetAmount(Integer.parseInt(String.valueOf(userForm.getGoalId())));
|
goalEntity.setTargetAmount(Integer.parseInt(String.valueOf(userForm.getGoalId())));
|
||||||
|
|
||||||
goalRepository.save(
|
|
||||||
goalEntity);
|
|
||||||
|
|
||||||
CourseEntity courseEntity = courseRepository.findById(courseId).orElse(null);
|
CourseEntity courseEntity = courseRepository.findById(courseId).orElse(null);
|
||||||
|
|
||||||
userEntity.setQuestionEntity(questionEntity);
|
userEntity.setQuestionEntity(questionEntity);
|
||||||
userEntity.setGoalEntity(goalEntity);
|
userEntity.setGoalEntity(goalRepository.save(
|
||||||
|
goalEntity));
|
||||||
userEntity.setCourseEntity(courseEntity);
|
userEntity.setCourseEntity(courseEntity);
|
||||||
|
|
||||||
userEntity.setDeleteFlag(0);
|
userEntity.setDeleteFlag(0);
|
||||||
|
|||||||
Reference in New Issue
Block a user