using Microsoft.EntityFrameworkCore.Migrations; #nullable disable namespace VOL.Core.Migrations { public partial class _20250403v1 : Migration { protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.DropForeignKey( name: "FK_XW_TrainStudents_XW_SportsTestData_XW_SportsTestDataId", table: "XW_TrainStudents"); migrationBuilder.DropColumn( name: "StadiumCode", table: "Y_StadiumVisiting"); migrationBuilder.AddColumn( name: "StadiumId", table: "Y_StadiumVisiting", type: "int", nullable: false, defaultValue: 0, comment: "场馆Id"); migrationBuilder.AlterColumn( name: "Longitude", table: "Y_Stadium", type: "float", nullable: true, comment: "经度", oldClrType: typeof(double), oldType: "float", oldComment: "经度"); migrationBuilder.AlterColumn( name: "Latitude", table: "Y_Stadium", type: "float", nullable: true, comment: "纬度", oldClrType: typeof(double), oldType: "float", oldComment: "纬度"); migrationBuilder.AlterColumn( name: "XW_SportsTestDataId", table: "XW_TrainStudents", type: "int", nullable: false, defaultValue: 0, oldClrType: typeof(int), oldType: "int", oldNullable: true); migrationBuilder.AddForeignKey( name: "FK_XW_TrainStudents_XW_SportsTestData_XW_SportsTestDataId", table: "XW_TrainStudents", column: "XW_SportsTestDataId", principalTable: "XW_SportsTestData", principalColumn: "Id", onDelete: ReferentialAction.Cascade); } protected override void Down(MigrationBuilder migrationBuilder) { } } }