|
|
|
@ -0,0 +1,231 @@
|
|
|
|
|
using System;
|
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Metadata;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
|
using Volo.Abp.Identity.EntityFrameworkCore;
|
|
|
|
|
|
|
|
|
|
namespace Volo.Abp.Identity.EntityFrameworkCore.Migrations
|
|
|
|
|
{
|
|
|
|
|
[DbContext(typeof(IdentityDbContext))]
|
|
|
|
|
[Migration("20170123063841_Remove_Unique_Index_Constraints")]
|
|
|
|
|
partial class Remove_Unique_Index_Constraints
|
|
|
|
|
{
|
|
|
|
|
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
|
|
|
{
|
|
|
|
|
modelBuilder
|
|
|
|
|
.HasAnnotation("ProductVersion", "1.1.0-rtm-22752")
|
|
|
|
|
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityRole", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd();
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ConcurrencyStamp")
|
|
|
|
|
.IsConcurrencyToken();
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasMaxLength(256);
|
|
|
|
|
|
|
|
|
|
b.Property<string>("NormalizedName")
|
|
|
|
|
.HasMaxLength(256);
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("NormalizedName")
|
|
|
|
|
.HasName("RoleNameIndex");
|
|
|
|
|
|
|
|
|
|
b.ToTable("IdentityRoles");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityRoleClaim", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd();
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ClaimType");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ClaimValue");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("RoleId");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("IdentityRoleClaims");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd();
|
|
|
|
|
|
|
|
|
|
b.Property<int>("AccessFailedCount");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ConcurrencyStamp")
|
|
|
|
|
.IsConcurrencyToken();
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Email")
|
|
|
|
|
.HasMaxLength(256);
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("EmailConfirmed");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("LockoutEnabled");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTimeOffset?>("LockoutEnd");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("NormalizedEmail")
|
|
|
|
|
.HasMaxLength(256);
|
|
|
|
|
|
|
|
|
|
b.Property<string>("NormalizedUserName")
|
|
|
|
|
.HasMaxLength(256);
|
|
|
|
|
|
|
|
|
|
b.Property<string>("PasswordHash");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("PhoneNumber");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("PhoneNumberConfirmed");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("SecurityStamp");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("TwoFactorEnabled");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("UserName")
|
|
|
|
|
.HasMaxLength(256);
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("NormalizedEmail")
|
|
|
|
|
.HasName("EmailIndex");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("NormalizedUserName")
|
|
|
|
|
.HasName("UserNameIndex");
|
|
|
|
|
|
|
|
|
|
b.ToTable("IdentityUsers");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserClaim", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd();
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ClaimType");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ClaimValue");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("UserId");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("IdentityUserClaims");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd();
|
|
|
|
|
|
|
|
|
|
b.Property<string>("LoginProvider");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ProviderDisplayName");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ProviderKey");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("UserId");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId", "LoginProvider", "ProviderKey");
|
|
|
|
|
|
|
|
|
|
b.ToTable("IdentityUserLogins");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserRole", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd();
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("RoleId");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("UserId");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId", "RoleId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("IdentityUserRoles");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserToken", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<Guid>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd();
|
|
|
|
|
|
|
|
|
|
b.Property<string>("LoginProvider");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name");
|
|
|
|
|
|
|
|
|
|
b.Property<Guid>("UserId");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Value");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("UserId", "LoginProvider", "Name");
|
|
|
|
|
|
|
|
|
|
b.ToTable("IdentityUserTokens");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityRoleClaim", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Volo.Abp.Identity.IdentityRole")
|
|
|
|
|
.WithMany("Claims")
|
|
|
|
|
.HasForeignKey("RoleId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserClaim", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Volo.Abp.Identity.IdentityUser")
|
|
|
|
|
.WithMany("Claims")
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Volo.Abp.Identity.IdentityUser")
|
|
|
|
|
.WithMany("Logins")
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserRole", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Volo.Abp.Identity.IdentityRole")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("RoleId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
|
|
|
|
|
b.HasOne("Volo.Abp.Identity.IdentityUser")
|
|
|
|
|
.WithMany("Roles")
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("Volo.Abp.Identity.IdentityUserToken", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("Volo.Abp.Identity.IdentityUser")
|
|
|
|
|
.WithMany("Tokens")
|
|
|
|
|
.HasForeignKey("UserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|