Files
chapter-organizer/WebApp/Services/ITeamMeetingHistoryService.cs
poprhythm 15d7edec8f Add Team Meeting History functionality with dialog and badge components
This commit introduces a new feature to display meeting history for teams. It adds a `TeamMeetingHistoryDialog` component that shows the meeting history in a dialog format, including a loading state and error handling. Additionally, a `TeamMeetingHistoryBadge` component is created to display the count of meetings for each team, enhancing the user interface with tooltips for better interaction. The `Details` and `Index` components are updated to integrate these new features, allowing users to view meeting history directly from the team details and index pages. These changes improve the overall functionality and user experience in managing team meetings.
2026-01-26 23:31:59 -05:00

66 lines
2.4 KiB
C#

using Core.Entities;
namespace WebApp.Services;
public interface ITeamMeetingHistoryService
{
/// <summary>
/// Gets all meeting histories within an optional date range.
/// </summary>
/// <param name="startDate">Optional start date filter</param>
/// <param name="endDate">Optional end date filter</param>
Task<IEnumerable<TeamMeetingHistory>> GetMeetingHistoriesAsync(DateTime? startDate = null, DateTime? endDate = null);
/// <summary>
/// Gets a specific meeting history by ID with teams and students included.
/// </summary>
Task<TeamMeetingHistory?> GetMeetingHistoryAsync(int id);
/// <summary>
/// Creates a new meeting history record.
/// </summary>
Task<TeamMeetingHistory> CreateMeetingHistoryAsync(TeamMeetingHistory meetingHistory);
/// <summary>
/// Updates an existing meeting history record.
/// </summary>
Task<TeamMeetingHistory> UpdateMeetingHistoryAsync(TeamMeetingHistory meetingHistory);
/// <summary>
/// Deletes a meeting history record.
/// </summary>
Task DeleteMeetingHistoryAsync(int id);
/// <summary>
/// Gets which teams met on a specific date.
/// </summary>
Task<IEnumerable<Team>> GetTeamsForDateAsync(DateTime date);
/// <summary>
/// Gets which students were present on a specific date.
/// </summary>
Task<IEnumerable<Student>> GetStudentsForDateAsync(DateTime date);
/// <summary>
/// Gets the meeting note for a specific meeting date by looking it up by title.
/// </summary>
/// <param name="meetingDate">The date of the meeting</param>
/// <returns>The note if found, null otherwise</returns>
Task<Note?> GetMeetingNoteAsync(DateTime meetingDate);
/// <summary>
/// Gets all meeting histories for a specific team, ordered by date descending.
/// </summary>
/// <param name="teamId">The ID of the team</param>
/// <returns>Meeting histories for the team, ordered by date descending</returns>
Task<IEnumerable<TeamMeetingHistory>> GetMeetingHistoriesForTeamAsync(int teamId);
/// <summary>
/// Gets the count of meeting histories for a specific team.
/// This is more efficient than loading all histories just to count them.
/// </summary>
/// <param name="teamId">The ID of the team</param>
/// <returns>The number of meeting histories for the team</returns>
Task<int> GetMeetingHistoryCountForTeamAsync(int teamId);
}