Skip to content

Commit

Permalink
now with name and real count
Browse files Browse the repository at this point in the history
  • Loading branch information
Marc Gorzala committed Apr 8, 2024
1 parent f119a6d commit c2d56fe
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ public class UserInfoAdapter implements UserInfoPort {
public UserInfoDto loadByDancerId(String dancerId) {
UserInfoDto userInfoDto = new UserInfoDto();
userInfoDto.setDancerId(dancerId);
userInfoDto.setDancerName("recoby");
userInfoDto.setEmailAddress("dancer@dancier.net");
return userInfoDto;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ public void sendMail(String dancerId, State state) {

private String createBody(State state, UserInfoDto userInfoDto) {
Map<String, Object> map = new HashMap<>();
map.put("unread_messages", 10);
map.put("unread_messages", state.unreadMessagesCount());
map.put("dancer_name", userInfoDto.getDancerName());
Context context = new Context(Locale.GERMANY, map);
return templateEngine.process(USER_INFO_MAIL, context);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ public class UserInfoDto {

private String dancerId;

private String dancerName;

private String emailAddress;

}

0 comments on commit c2d56fe

Please sign in to comment.