Commit 7884ce4fd91e7237a91cb8adeec8d4946a7888e6
1 parent
05d1ad5f
fix(DEFECT-653): 短信记录没有用途
1、密码重置的消息记录, 没有用途问题
Showing
2 changed files
with
3 additions
and
0 deletions
@@ -209,6 +209,7 @@ public class YtNoticeServiceImpl implements YtNoticeService { | @@ -209,6 +209,7 @@ public class YtNoticeServiceImpl implements YtNoticeService { | ||
209 | params.put("organization", organization != null ? organization.getName() : ""); | 209 | params.put("organization", organization != null ? organization.getName() : ""); |
210 | params.put("createtime", YtDateTimeUtils.formate(alarmInfo.getCreateTs())); | 210 | params.put("createtime", YtDateTimeUtils.formate(alarmInfo.getCreateTs())); |
211 | info.setParams(params); | 211 | info.setParams(params); |
212 | + info.setTemplatePurpose(MsgTemplatePurposeEnum.FOR_ALARM_NOTICE.name()); | ||
212 | contacts.stream().parallel().forEach(item -> { | 213 | contacts.stream().parallel().forEach(item -> { |
213 | if (!item.getDingtalk().isEmpty()) { | 214 | if (!item.getDingtalk().isEmpty()) { |
214 | info.setPhoneNumbers(item.getDingtalk()); | 215 | info.setPhoneNumbers(item.getDingtalk()); |
@@ -238,6 +239,7 @@ public class YtNoticeServiceImpl implements YtNoticeService { | @@ -238,6 +239,7 @@ public class YtNoticeServiceImpl implements YtNoticeService { | ||
238 | params.put("organization", organization != null ? organization.getName() : ""); | 239 | params.put("organization", organization != null ? organization.getName() : ""); |
239 | params.put("createtime", YtDateTimeUtils.formate(alarmInfo.getCreateTs())); | 240 | params.put("createtime", YtDateTimeUtils.formate(alarmInfo.getCreateTs())); |
240 | info.setParams(params); | 241 | info.setParams(params); |
242 | + info.setTemplatePurpose(MsgTemplatePurposeEnum.FOR_ALARM_NOTICE.name()); | ||
241 | contacts.stream().parallel().forEach(item -> { | 243 | contacts.stream().parallel().forEach(item -> { |
242 | if (!item.getWechat().isEmpty()) { | 244 | if (!item.getWechat().isEmpty()) { |
243 | info.setPhoneNumbers(item.getWechat()); | 245 | info.setPhoneNumbers(item.getWechat()); |
@@ -536,6 +536,7 @@ public class YtUserServiceImpl extends AbstractBaseService<UserMapper, User> | @@ -536,6 +536,7 @@ public class YtUserServiceImpl extends AbstractBaseService<UserMapper, User> | ||
536 | LinkedHashMap<String, String> params = new LinkedHashMap<>(); | 536 | LinkedHashMap<String, String> params = new LinkedHashMap<>(); |
537 | params.put("code", accountProperties.getDefaultPassword()); | 537 | params.put("code", accountProperties.getDefaultPassword()); |
538 | smsReqDTO.setParams(params); | 538 | smsReqDTO.setParams(params); |
539 | + smsReqDTO.setTemplatePurpose(messageTemplateDTO.getTemplatePurpose()); | ||
539 | ytSmsService.sendSms(smsReqDTO); | 540 | ytSmsService.sendSms(smsReqDTO); |
540 | } | 541 | } |
541 | } | 542 | } |