系统每日--修改--添加对空值的判断

This commit is contained in:
haotian 2025-02-21 14:51:00 +08:00
parent ce3e326841
commit 4a420381b1

View File

@ -569,20 +569,24 @@ public class dailySysServer {
//发送消息通知
Long workId = sysSource.getWorkId();
// 查询用户id
Long receiveUserId = userWorkService.selectUserWorkByWorkId(workId).getUserId();
if (receiveUserId != null){
SysUserNotification sysUserNotification = new SysUserNotification();
sysUserNotification.setUserId(receiveUserId);
sysUserNotification.setSenderId(0L);
// 24小时临期消息
sysUserNotification.setType("7");
sysUserNotification.setStatus("0");
UserWork userWork = userWorkService.selectUserWorkByWorkId(workId);
if(userWork != null){
Long receiveUserId = userWork.getUserId();
if (receiveUserId != null){
SysUserNotification sysUserNotification = new SysUserNotification();
sysUserNotification.setUserId(receiveUserId);
sysUserNotification.setSenderId(0L);
// 24小时临期消息
sysUserNotification.setType("7");
sysUserNotification.setStatus("0");
userNotificationService.insertSysUserNotification(sysUserNotification);
userNotificationService.insertSysUserNotification(sysUserNotification);
}
}
}
}