-
Notifications
You must be signed in to change notification settings - Fork 1
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/#144 #147
base: master
Are you sure you want to change the base?
Feat/#144 #147
Conversation
|
||
public ResponseData<List<NoticeRes>> getCreated(){ | ||
Member member = memberAuthenticationHolder.current(); | ||
List<DivisionMember> divisionMembers = divisionMemberService.getByMember(member); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
divisionMemberService.getByMember가 호출될 때 마다 getDivision으로 조직을 가져오는데 그냥 DivisionService에서 쿼리로 해결하는게 좋을 듯합니다
Notice notice = noticeService.save(generateNoticeReq.toEntity(member)); | ||
|
||
List<Division> divisions = generateNoticeReq.divisions().stream() | ||
.map(divisionService::getById) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
division 개수만큼 SQL 조회하는 거 아닌가요?
SQL 한번만 쓸 수 있지 않나여?
No description provided.