增加文章下架功能

This commit is contained in:
ronger 2023-07-26 11:52:53 +08:00
parent 5d505eec6a
commit 94dcceaf22

View File

@ -126,6 +126,16 @@ public class NotificationUtils {
notificationDTO.setAuthor(genAuthor(user)); notificationDTO.setAuthor(genAuthor(user));
} }
break; break;
case "5":
// 文章状态变更
article = articleService.findArticleDTOById(notification.getDataId(), 0);
if (Objects.nonNull(article)) {
notificationDTO.setDataTitle("系统通知");
notificationDTO.setDataUrl(article.getArticlePermalink());
user = userService.findById(article.getArticleAuthorId().toString());
notificationDTO.setAuthor(genAuthor(user));
}
break;
default: default:
break; break;
} }