committed by
GitHub
30 changed files with 3532 additions and 43 deletions
@ -0,0 +1,20 @@ |
|||||
|
Set-Location ".\migrations\LY.MicroService.BackendAdmin.EntityFrameworkCore" |
||||
|
dotnet ef database update |
||||
|
|
||||
|
Set-Location "..\LY.MicroService.Platform.EntityFrameworkCore" |
||||
|
dotnet ef database update |
||||
|
|
||||
|
Set-Location "..\LY.MicroService.LocalizationManagement.EntityFrameworkCore" |
||||
|
dotnet ef database update |
||||
|
|
||||
|
Set-Location "..\LY.MicroService.RealtimeMessage.EntityFrameworkCore" |
||||
|
dotnet ef database update |
||||
|
|
||||
|
Set-Location "..\LY.MicroService.IdentityServer.EntityFrameworkCore" |
||||
|
dotnet ef database update |
||||
|
|
||||
|
Set-Location "..\LY.MicroService.TaskManagement.EntityFrameworkCore" |
||||
|
dotnet ef database update |
||||
|
|
||||
|
Set-Location "..\LY.MicroService.AuthServer.EntityFrameworkCore" |
||||
|
dotnet ef database update |
||||
File diff suppressed because it is too large
@ -0,0 +1,60 @@ |
|||||
|
using System; |
||||
|
using Microsoft.EntityFrameworkCore.Migrations; |
||||
|
|
||||
|
#nullable disable |
||||
|
|
||||
|
namespace LY.MicroService.AuthServer.EntityFrameworkCore.Migrations |
||||
|
{ |
||||
|
/// <inheritdoc />
|
||||
|
public partial class FixUser : Migration |
||||
|
{ |
||||
|
/// <inheritdoc />
|
||||
|
protected override void Up(MigrationBuilder migrationBuilder) |
||||
|
{ |
||||
|
migrationBuilder.AddColumn<DateTimeOffset>( |
||||
|
name: "LastPasswordChangeTime", |
||||
|
table: "AbpUsers", |
||||
|
type: "datetime(6)", |
||||
|
nullable: true); |
||||
|
|
||||
|
migrationBuilder.AddColumn<bool>( |
||||
|
name: "ShouldChangePasswordOnNextLogin", |
||||
|
table: "AbpUsers", |
||||
|
type: "tinyint(1)", |
||||
|
nullable: false, |
||||
|
defaultValue: false); |
||||
|
|
||||
|
migrationBuilder.CreateTable( |
||||
|
name: "AbpUserDelegations", |
||||
|
columns: table => new |
||||
|
{ |
||||
|
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"), |
||||
|
TenantId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"), |
||||
|
SourceUserId = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"), |
||||
|
TargetUserId = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"), |
||||
|
StartTime = table.Column<DateTime>(type: "datetime(6)", nullable: false), |
||||
|
EndTime = table.Column<DateTime>(type: "datetime(6)", nullable: false) |
||||
|
}, |
||||
|
constraints: table => |
||||
|
{ |
||||
|
table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); |
||||
|
}) |
||||
|
.Annotation("MySql:CharSet", "utf8mb4"); |
||||
|
} |
||||
|
|
||||
|
/// <inheritdoc />
|
||||
|
protected override void Down(MigrationBuilder migrationBuilder) |
||||
|
{ |
||||
|
migrationBuilder.DropTable( |
||||
|
name: "AbpUserDelegations"); |
||||
|
|
||||
|
migrationBuilder.DropColumn( |
||||
|
name: "LastPasswordChangeTime", |
||||
|
table: "AbpUsers"); |
||||
|
|
||||
|
migrationBuilder.DropColumn( |
||||
|
name: "ShouldChangePasswordOnNextLogin", |
||||
|
table: "AbpUsers"); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
File diff suppressed because it is too large
@ -0,0 +1,60 @@ |
|||||
|
using System; |
||||
|
using Microsoft.EntityFrameworkCore.Migrations; |
||||
|
|
||||
|
#nullable disable |
||||
|
|
||||
|
namespace LY.MicroService.IdentityServer.EntityFrameworkCore.Migrations |
||||
|
{ |
||||
|
/// <inheritdoc />
|
||||
|
public partial class FixUser : Migration |
||||
|
{ |
||||
|
/// <inheritdoc />
|
||||
|
protected override void Up(MigrationBuilder migrationBuilder) |
||||
|
{ |
||||
|
migrationBuilder.AddColumn<DateTimeOffset>( |
||||
|
name: "LastPasswordChangeTime", |
||||
|
table: "AbpUsers", |
||||
|
type: "datetime(6)", |
||||
|
nullable: true); |
||||
|
|
||||
|
migrationBuilder.AddColumn<bool>( |
||||
|
name: "ShouldChangePasswordOnNextLogin", |
||||
|
table: "AbpUsers", |
||||
|
type: "tinyint(1)", |
||||
|
nullable: false, |
||||
|
defaultValue: false); |
||||
|
|
||||
|
migrationBuilder.CreateTable( |
||||
|
name: "AbpUserDelegations", |
||||
|
columns: table => new |
||||
|
{ |
||||
|
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"), |
||||
|
TenantId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"), |
||||
|
SourceUserId = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"), |
||||
|
TargetUserId = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"), |
||||
|
StartTime = table.Column<DateTime>(type: "datetime(6)", nullable: false), |
||||
|
EndTime = table.Column<DateTime>(type: "datetime(6)", nullable: false) |
||||
|
}, |
||||
|
constraints: table => |
||||
|
{ |
||||
|
table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); |
||||
|
}) |
||||
|
.Annotation("MySql:CharSet", "utf8mb4"); |
||||
|
} |
||||
|
|
||||
|
/// <inheritdoc />
|
||||
|
protected override void Down(MigrationBuilder migrationBuilder) |
||||
|
{ |
||||
|
migrationBuilder.DropTable( |
||||
|
name: "AbpUserDelegations"); |
||||
|
|
||||
|
migrationBuilder.DropColumn( |
||||
|
name: "LastPasswordChangeTime", |
||||
|
table: "AbpUsers"); |
||||
|
|
||||
|
migrationBuilder.DropColumn( |
||||
|
name: "ShouldChangePasswordOnNextLogin", |
||||
|
table: "AbpUsers"); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
Loading…
Reference in new issue