sharding/samples/Sample.SqlServer/Migrations/20221014021942_InitialCreat...

118 lines
3.9 KiB
C#
Raw Permalink Normal View History

// <auto-generated />
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using Sample.SqlServer.DbContexts;
#nullable disable
namespace Sample.SqlServer.Migrations
{
[DbContext(typeof(DefaultShardingDbContext))]
[Migration("20221014021942_InitialCreateAddName")]
partial class InitialCreateAddName
{
protected override void BuildTargetModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "6.0.10")
.HasAnnotation("Relational:MaxIdentifierLength", 128);
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1);
modelBuilder.Entity("Sample.SqlServer.Domain.Entities.SysTest", b =>
{
b.Property<string>("Id")
.ValueGeneratedOnAdd()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Name")
.HasColumnType("nvarchar(max)");
b.Property<string>("UserId")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.HasKey("Id");
b.ToTable("SysTest", (string)null);
});
modelBuilder.Entity("Sample.SqlServer.Domain.Entities.SysUserMod", b =>
{
b.Property<string>("Id")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<int>("Age")
.HasColumnType("int");
b.Property<int>("AgeGroup")
.HasColumnType("int");
b.Property<string>("Name")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.HasKey("Id");
b.ToTable("SysUserMod", (string)null);
});
modelBuilder.Entity("Sample.SqlServer.Domain.Entities.SysUserSalary", b =>
{
b.Property<string>("Id")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<int>("DateOfMonth")
.HasColumnType("int");
b.Property<int>("Salary")
.HasColumnType("int");
b.Property<decimal>("SalaryDecimal")
.HasColumnType("decimal(18,2)");
b.Property<double>("SalaryDouble")
.HasColumnType("float");
b.Property<float>("SalaryFloat")
.HasColumnType("real");
b.Property<long>("SalaryLong")
.HasColumnType("bigint");
b.Property<string>("UserId")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.HasKey("Id");
b.ToTable("SysUserSalary", (string)null);
});
modelBuilder.Entity("Sample.SqlServer.Domain.Entities.TestYearSharding", b =>
{
b.Property<string>("Id")
.HasColumnType("nvarchar(450)");
b.Property<DateTime>("CreateTIme")
.HasColumnType("datetime2");
b.HasKey("Id");
b.ToTable("TestYearSharding", (string)null);
});
#pragma warning restore 612, 618
}
}
}