feat: add student engagement endpoints

This commit is contained in:
xiong
2026-07-26 18:39:55 +08:00
parent 387b85342a
commit 89e1f2a4df
5 changed files with 547 additions and 0 deletions

View File

@@ -11,6 +11,17 @@ public sealed class ProfileQueryDto
[Range(1, 20)]
public int? Limit { get; set; }
[StringLength(32)]
public string? Status { get; set; }
[StringLength(50)]
public string? Type { get; set; }
[StringLength(50)]
public string? Category { get; set; }
public bool IncludeLocked { get; set; }
}
public sealed class UpdateProfileDto
@@ -43,3 +54,60 @@ public sealed class UpdateProfileDto
RecentActivities);
}
}
public sealed class NotificationStatusDto
{
[Required]
[MinLength(1)]
[MaxLength(100)]
public IReadOnlyCollection<Guid> NotificationIds { get; set; } = [];
[StringLength(32)]
public string? Status { get; set; }
public UpdateNotificationStatusCommand ToCommand()
{
return new UpdateNotificationStatusCommand(NotificationIds, Status);
}
}
public sealed class SubmitFeedbackDto
{
public Guid? QuestionId { get; set; }
[StringLength(50)]
public string? Type { get; set; }
[StringLength(100)]
public string? Category { get; set; }
[StringLength(200)]
public string? Title { get; set; }
[Required]
[StringLength(5000)]
public string Description { get; set; } = string.Empty;
[StringLength(32)]
public string? Priority { get; set; }
[StringLength(200)]
public string? Contact { get; set; }
public JsonElement Attachments { get; set; } = JsonSerializer.SerializeToElement(Array.Empty<object>());
public JsonElement Metadata { get; set; } = JsonSerializer.SerializeToElement(new { });
public SubmitFeedbackCommand ToCommand()
{
return new SubmitFeedbackCommand(
QuestionId,
Type,
Category,
Title,
Description,
Priority,
Contact,
Attachments,
Metadata);
}
}