Update db migrations with new objects and fields

This commit is contained in:
Tech Garage 2024-01-25 20:34:54 +03:30
parent 115f657738
commit 24c99bf691
17 changed files with 1450 additions and 0 deletions

View file

@ -17,18 +17,76 @@ namespace MTWireGuard.Application.Migrations
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "7.0.5");
modelBuilder.Entity("MTWireGuard.Application.Models.DataUsage", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime>("CreationTime")
.HasColumnType("TEXT");
b.Property<int>("RX")
.HasColumnType("INTEGER");
b.Property<string>("ResetNotes")
.HasColumnType("TEXT");
b.Property<int>("TX")
.HasColumnType("INTEGER");
b.Property<int>("UserID")
.HasColumnType("INTEGER");
b.Property<bool>("UserReset")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.ToTable("DataUsages");
});
modelBuilder.Entity("MTWireGuard.Application.Models.LastKnownTraffic", b =>
{
b.Property<int>("UserID")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime>("CreationTime")
.HasColumnType("TEXT");
b.Property<int>("RX")
.HasColumnType("INTEGER");
b.Property<int>("TX")
.HasColumnType("INTEGER");
b.HasKey("UserID");
b.ToTable("LastKnownTraffic");
});
modelBuilder.Entity("MTWireGuard.Application.Models.Mikrotik.WGPeerDBModel", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("DNSAddress")
.HasColumnType("TEXT");
b.Property<DateTime?>("Expire")
.HasColumnType("TEXT");
b.Property<int?>("ExpireID")
.HasColumnType("INTEGER");
b.Property<bool>("InheritDNS")
.HasColumnType("INTEGER");
b.Property<bool>("InheritIP")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.HasColumnType("TEXT");
@ -40,6 +98,15 @@ namespace MTWireGuard.Application.Migrations
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("RX")
.HasColumnType("INTEGER");
b.Property<int>("TX")
.HasColumnType("INTEGER");
b.Property<int>("TrafficLimit")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("PrivateKey")
@ -50,6 +117,29 @@ namespace MTWireGuard.Application.Migrations
b.ToTable("Users");
});
modelBuilder.Entity("MTWireGuard.Application.Models.Mikrotik.WGServerDBModel", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("DNSAddress")
.HasColumnType("TEXT");
b.Property<int?>("IPPoolId")
.HasColumnType("INTEGER");
b.Property<bool>("InheritDNS")
.HasColumnType("INTEGER");
b.Property<bool>("UseIPPool")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.ToTable("Servers");
});
#pragma warning restore 612, 618
}
}