返回IP
continuous-integration/drone/push Build is running
Details
continuous-integration/drone/push Build is running
Details
parent
34faaaf231
commit
19f9af8af8
|
@ -580,6 +580,8 @@ namespace IRaCIS.Core.Application.Contracts
|
|||
public string UserFullName { get; set; }
|
||||
public DateTime CreateTime { get; set; }
|
||||
|
||||
public string IP { get; set; }
|
||||
|
||||
}
|
||||
|
||||
public class TrialIamgeDownQuery:PageInput
|
||||
|
|
|
@ -20,4 +20,4 @@ https://www.cnblogs.com/cqpanda/p/16815263.html
|
|||
5、撤销某次更新到数据库的迁移(自动执行down 方法)
|
||||
dotnet ef database update 某次迁移的前一次迁移名称 -p IRaCIS.Core.Test -c IRCContext
|
||||
|
||||
|
||||
dotnet ef migrations add RemoveForeignKey -p IRaCIS.Core.Test -c IRCContext -o CodeFirstTest/MSSQL/Migrations
|
||||
|
|
|
@ -42,10 +42,11 @@ public partial class IRCContext : DbContext
|
|||
|
||||
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
|
||||
{
|
||||
optionsBuilder.UseSqlServer("Server=106.14.89.110,1433;Database=IRC_Code;User ID=sa;Password=mssql_KnTs2a;TrustServerCertificate=true");
|
||||
|
||||
//移除外键约束
|
||||
optionsBuilder.ReplaceService<IMigrationsSqlGenerator, MigrationRemoveForeignKeysSqlGenerator>();
|
||||
optionsBuilder.UseSqlServer("Server=106.14.89.110,1433;Database=IRC_Code;User ID=sa;Password=mssql_KnTs2a;TrustServerCertificate=true");
|
||||
|
||||
|
||||
}
|
||||
|
||||
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
||||
|
|
|
@ -12,8 +12,8 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|||
namespace IRaCIS.Core.Test.CodeFirstTest.MSSQL.Migrations
|
||||
{
|
||||
[DbContext(typeof(IRCContext))]
|
||||
[Migration("20240911151956_RemoveForeignKeys")]
|
||||
partial class RemoveForeignKeys
|
||||
[Migration("20240912012757_RemoveForeignKey")]
|
||||
partial class RemoveForeignKey
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
@ -6,7 +6,7 @@ using Microsoft.EntityFrameworkCore.Migrations;
|
|||
namespace IRaCIS.Core.Test.CodeFirstTest.MSSQL.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RemoveForeignKeys : Migration
|
||||
public partial class RemoveForeignKey : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
Loading…
Reference in New Issue