Procházet zdrojové kódy

修改立项备案提醒

tags/24080901
WendyYang před 7 měsíci
rodič
revize
aafcba1db7
2 změnil soubory, kde provedl 22 přidání a 17 odebrání
  1. +1
    -0
      hz-pm-api/src/main/java/com/hz/pm/api/common/helper/impl/UserInfoHelperImpl.java
  2. +21
    -17
      hz-pm-api/src/main/java/com/hz/pm/api/scheduler/task/DeclaredRecordReminderTask.java

+ 1
- 0
hz-pm-api/src/main/java/com/hz/pm/api/common/helper/impl/UserInfoHelperImpl.java Zobrazit soubor

@@ -117,6 +117,7 @@ public class UserInfoHelperImpl implements UserInfoHelper {
userFullInfo.setUsername(userInfo.getRealName());
userFullInfo.setMobile(userInfo.getMobile());
userFullInfo.setAccountId(userInfo.getAccountId());
userFullInfo.setMhUserId(userInfo.getMhUserId());
String available = userInfo.getAvailable();
if (StrUtils.isNotBlank(available)) {
userFullInfo.setAvailable(UserAvailableEnum.valueOf(available));


+ 21
- 17
hz-pm-api/src/main/java/com/hz/pm/api/scheduler/task/DeclaredRecordReminderTask.java Zobrazit soubor

@@ -78,7 +78,7 @@ public class DeclaredRecordReminderTask extends ReminderTask {
private void declaredRecordReminder() {
Wrapper<Project> query = Wrappers.lambdaQuery(Project.class)
.eq(Project::getNewest, Boolean.TRUE)
.eq(Project::getStatus, ProjectStatusEnum.DECLARED_APPROVED_TO_BE_RECORD);
.eq(Project::getStatus, ProjectStatusEnum.DECLARED_APPROVED_TO_BE_RECORD.getCode());
List<Project> projects = projectService.list(query);
if (projects.isEmpty()) {
return;
@@ -115,22 +115,26 @@ public class DeclaredRecordReminderTask extends ReminderTask {
}
String content = String.format(MSG_FMT, project.getProjectName());
for (UserFullInfoDTO user : currUnitUsers) {
if (todoRecordMap.containsKey(project.getProjectCode())) {
MhZwddWorkNoticeDTO notice = MhZwddWorkNoticeDTO.builder()
.title(DECLARED_RECORD_APPLY.getVal())
.content(content)
.targetUser(user.getMhUserId())
.build();
mhApiClient.sendZwddWorkNotice(notice);
} else {
MhTodoExtraParamDTO paramObj = MhTodoExtraParamDTO.builder()
.projectId(project.getId())
.projectCode(projectCode)
.path("/declareManage/projectFiling")
.userId(user.getUserId())
.userName(user.getRealName())
.build();
mhTodoClient.addTodo(paramObj, user, DECLARED_RECORD_APPLY, projectCode, content);
try {
if (todoRecordMap.containsKey(project.getProjectCode())) {
MhZwddWorkNoticeDTO notice = MhZwddWorkNoticeDTO.builder()
.title(DECLARED_RECORD_APPLY.getVal())
.content(content)
.targetUser(user.getMhUserId())
.build();
mhApiClient.sendZwddWorkNotice(notice);
} else {
MhTodoExtraParamDTO paramObj = MhTodoExtraParamDTO.builder()
.projectId(project.getId())
.projectCode(projectCode)
.path("/declareManage/projectFiling")
.userId(user.getUserId())
.userName(user.getRealName())
.build();
mhTodoClient.addTodo(paramObj, user, DECLARED_RECORD_APPLY, projectCode, content);
}
} catch (Exception e) {
log.error("立项备案提醒发送失败:{}", project.getProjectCode(), e);
}
}
} catch (Exception e) {


Načítá se…
Zrušit
Uložit