53 lines
1.7 KiB
C#
53 lines
1.7 KiB
C#
using System;
|
|
using Microsoft.EntityFrameworkCore;
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
using Microsoft.EntityFrameworkCore.Metadata;
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
using IdentityServer4.EntityFramework.DbContexts;
|
|
|
|
namespace Identity.API.Migrations
|
|
{
|
|
[DbContext(typeof(PersistedGrantDbContext))]
|
|
[Migration("20170604151240_Init-persisted-grant")]
|
|
partial class Initpersistedgrant
|
|
{
|
|
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
{
|
|
modelBuilder
|
|
.HasAnnotation("ProductVersion", "1.1.2")
|
|
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
|
|
|
modelBuilder.Entity("IdentityServer4.EntityFramework.Entities.PersistedGrant", b =>
|
|
{
|
|
b.Property<string>("Key")
|
|
.HasMaxLength(200);
|
|
|
|
b.Property<string>("ClientId")
|
|
.IsRequired()
|
|
.HasMaxLength(200);
|
|
|
|
b.Property<DateTime>("CreationTime");
|
|
|
|
b.Property<string>("Data")
|
|
.IsRequired()
|
|
.HasMaxLength(50000);
|
|
|
|
b.Property<DateTime?>("Expiration");
|
|
|
|
b.Property<string>("SubjectId")
|
|
.HasMaxLength(200);
|
|
|
|
b.Property<string>("Type")
|
|
.IsRequired()
|
|
.HasMaxLength(50);
|
|
|
|
b.HasKey("Key");
|
|
|
|
b.HasIndex("SubjectId", "ClientId", "Type");
|
|
|
|
b.ToTable("PersistedGrants");
|
|
});
|
|
}
|
|
}
|
|
}
|