6bc4c2e7f2
This commit introduces the TeamMeetingHistory entity, including its configuration and database migrations. A new ITeamMeetingHistoryService interface and its implementation, TeamMeetingHistoryService, are added to handle CRUD operations for meeting histories. Additionally, UI components such as History.razor, MeetingHistoryDetailDialog, and SaveMeetingHistoryDialog are created to facilitate viewing and saving meeting histories. The integration of INoteNamingService enhances note management for meeting records, improving overall functionality and user experience in the application.
105 lines
4.3 KiB
C#
105 lines
4.3 KiB
C#
using System;
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace Data.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class AddTeamMeetingHistory : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.CreateTable(
|
|
name: "TeamMeetingHistories",
|
|
columns: table => new
|
|
{
|
|
Id = table.Column<int>(type: "INTEGER", nullable: false)
|
|
.Annotation("Sqlite:Autoincrement", true),
|
|
MeetingDate = table.Column<DateTime>(type: "TEXT", nullable: false)
|
|
},
|
|
constraints: table =>
|
|
{
|
|
table.PrimaryKey("PK_TeamMeetingHistories", x => x.Id);
|
|
});
|
|
|
|
migrationBuilder.CreateTable(
|
|
name: "TeamMeetingHistoryStudents",
|
|
columns: table => new
|
|
{
|
|
StudentsId = table.Column<int>(type: "INTEGER", nullable: false),
|
|
TeamMeetingHistoryId = table.Column<int>(type: "INTEGER", nullable: false)
|
|
},
|
|
constraints: table =>
|
|
{
|
|
table.PrimaryKey("PK_TeamMeetingHistoryStudents", x => new { x.StudentsId, x.TeamMeetingHistoryId });
|
|
table.ForeignKey(
|
|
name: "FK_TeamMeetingHistoryStudents_Students_StudentsId",
|
|
column: x => x.StudentsId,
|
|
principalTable: "Students",
|
|
principalColumn: "Id",
|
|
onDelete: ReferentialAction.Cascade);
|
|
table.ForeignKey(
|
|
name: "FK_TeamMeetingHistoryStudents_TeamMeetingHistories_TeamMeetingHistoryId",
|
|
column: x => x.TeamMeetingHistoryId,
|
|
principalTable: "TeamMeetingHistories",
|
|
principalColumn: "Id",
|
|
onDelete: ReferentialAction.Cascade);
|
|
});
|
|
|
|
migrationBuilder.CreateTable(
|
|
name: "TeamMeetingHistoryTeams",
|
|
columns: table => new
|
|
{
|
|
TeamMeetingHistoryId = table.Column<int>(type: "INTEGER", nullable: false),
|
|
TeamsId = table.Column<int>(type: "INTEGER", nullable: false)
|
|
},
|
|
constraints: table =>
|
|
{
|
|
table.PrimaryKey("PK_TeamMeetingHistoryTeams", x => new { x.TeamMeetingHistoryId, x.TeamsId });
|
|
table.ForeignKey(
|
|
name: "FK_TeamMeetingHistoryTeams_TeamMeetingHistories_TeamMeetingHistoryId",
|
|
column: x => x.TeamMeetingHistoryId,
|
|
principalTable: "TeamMeetingHistories",
|
|
principalColumn: "Id",
|
|
onDelete: ReferentialAction.Cascade);
|
|
table.ForeignKey(
|
|
name: "FK_TeamMeetingHistoryTeams_Teams_TeamsId",
|
|
column: x => x.TeamsId,
|
|
principalTable: "Teams",
|
|
principalColumn: "Id",
|
|
onDelete: ReferentialAction.Cascade);
|
|
});
|
|
|
|
migrationBuilder.CreateIndex(
|
|
name: "IX_TeamMeetingHistories_MeetingDate",
|
|
table: "TeamMeetingHistories",
|
|
column: "MeetingDate");
|
|
|
|
migrationBuilder.CreateIndex(
|
|
name: "IX_TeamMeetingHistoryStudents_TeamMeetingHistoryId",
|
|
table: "TeamMeetingHistoryStudents",
|
|
column: "TeamMeetingHistoryId");
|
|
|
|
migrationBuilder.CreateIndex(
|
|
name: "IX_TeamMeetingHistoryTeams_TeamsId",
|
|
table: "TeamMeetingHistoryTeams",
|
|
column: "TeamsId");
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropTable(
|
|
name: "TeamMeetingHistoryStudents");
|
|
|
|
migrationBuilder.DropTable(
|
|
name: "TeamMeetingHistoryTeams");
|
|
|
|
migrationBuilder.DropTable(
|
|
name: "TeamMeetingHistories");
|
|
}
|
|
}
|
|
}
|