成绩通知:仅在某门课程成绩正式发布后自动发送,按成绩单学生名单通知,不展示具体分数;发布状态与通知同一次提交。
手动发信:移除“成绩通知”选项,只能发送普通通知,原有角色与范围权限保持不变。 选课通知:管理员关闭一轮选课时,自动向每位参与学生发送一条汇总通知,包含最终选中课程及候补未成功课程;候补失效、轮次关闭和通知生成保持原子性。 关闭选课界面会明确提示发送通知,并显示实际通知人数。
This commit is contained in:
@@ -7,6 +7,42 @@ public sealed class Notification : EntityBase
|
||||
public Guid UserId { get; set; }
|
||||
public required string Title { get; set; }
|
||||
public required string Content { get; set; }
|
||||
public NotificationCategory Category { get; set; } = NotificationCategory.General;
|
||||
public bool IsRead { get; set; }
|
||||
public string? LinkUrl { get; set; }
|
||||
public Guid? MessageDispatchId { get; set; }
|
||||
public MessageDispatch? MessageDispatch { get; set; }
|
||||
}
|
||||
|
||||
public sealed class MessageDispatch : EntityBase
|
||||
{
|
||||
public Guid SenderUserId { get; set; }
|
||||
public required string SenderName { get; set; }
|
||||
public required string Title { get; set; }
|
||||
public required string Content { get; set; }
|
||||
public NotificationCategory Category { get; set; } = NotificationCategory.General;
|
||||
public MessageAudienceType AudienceType { get; set; }
|
||||
public Guid? AudienceId { get; set; }
|
||||
public required string AudienceName { get; set; }
|
||||
public int RecipientCount { get; set; }
|
||||
public string? LinkUrl { get; set; }
|
||||
public ICollection<Notification> Notifications { get; set; } = [];
|
||||
}
|
||||
|
||||
public enum NotificationCategory
|
||||
{
|
||||
General = 1,
|
||||
Approval = 2,
|
||||
Schedule = 3,
|
||||
Grade = 4,
|
||||
Attendance = 5,
|
||||
CourseSelection = 6,
|
||||
Warning = 7
|
||||
}
|
||||
|
||||
public enum MessageAudienceType
|
||||
{
|
||||
School = 1,
|
||||
College = 2,
|
||||
TeachingTask = 3
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user