fix chore
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
using Atomx.Common.Constant;
|
||||
using Atomx.Common.Constants;
|
||||
using Atomx.Common.Entities;
|
||||
|
||||
namespace Atomx.Data.CacheServices
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Atomx.Common.Constant;
|
||||
using Atomx.Common.Constants;
|
||||
using Atomx.Common.Entities;
|
||||
using Atomx.Common.Enums;
|
||||
using Atomx.Common.Models;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Atomx.Common.Constant;
|
||||
using Atomx.Common.Constants;
|
||||
using Atomx.Common.Entities;
|
||||
|
||||
namespace Atomx.Data.CacheServices
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Atomx.Common.Constant;
|
||||
using Atomx.Common.Constants;
|
||||
using Atomx.Common.Entities;
|
||||
|
||||
namespace Atomx.Data.CacheServices
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Atomx.Common.Constant;
|
||||
using Atomx.Common.Constants;
|
||||
using Atomx.Common.Entities;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Atomx.Common.Constant;
|
||||
using Atomx.Common.Constants;
|
||||
using Atomx.Common.Entities;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Atomx.Common.Constant;
|
||||
using Atomx.Common.Constants;
|
||||
using Atomx.Common.Entities;
|
||||
|
||||
namespace Atomx.Data.CacheServices
|
||||
|
||||
@@ -12,7 +12,7 @@ using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
||||
namespace Atomx.Data.Migrations
|
||||
{
|
||||
[DbContext(typeof(DataContext))]
|
||||
[Migration("20251130091101_0.1")]
|
||||
[Migration("20251203175828_0.1")]
|
||||
partial class _01
|
||||
{
|
||||
/// <inheritdoc />
|
||||
@@ -138,6 +138,9 @@ namespace Atomx.Data.Migrations
|
||||
b.Property<DateTime?>("LastLogin")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<DateTime?>("LockoutEndTime")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<int>("LoginCount")
|
||||
.HasColumnType("integer");
|
||||
|
||||
@@ -1114,6 +1117,43 @@ namespace Atomx.Data.Migrations
|
||||
b.ToTable("ProductInventoryLogs");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Atomx.Common.Entities.RefreshToken", b =>
|
||||
{
|
||||
b.Property<string>("Id")
|
||||
.HasColumnType("text");
|
||||
|
||||
b.Property<DateTime>("ExpiresTime")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<string>("Ip")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(50)");
|
||||
|
||||
b.Property<bool>("IsRevoked")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<DateTime>("IssuedTime")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<DateTime>("RevokedTime")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<string>("Token")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(500)");
|
||||
|
||||
b.Property<string>("UserAgent")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(500)");
|
||||
|
||||
b.Property<long>("UserId")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("RefreshTokens");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Atomx.Common.Entities.Role", b =>
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
@@ -1347,11 +1387,23 @@ namespace Atomx.Data.Migrations
|
||||
|
||||
b.Property<string>("Email")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(64)");
|
||||
.HasColumnType("varchar(128)");
|
||||
|
||||
b.Property<bool>("EmailConfirmed")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<int>("FailedLoginAttempts")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<bool>("IsActive")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<DateTime?>("LockoutEndTime")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<string>("Mobile")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(64)");
|
||||
.HasColumnType("varchar(32)");
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
@@ -62,6 +62,7 @@ namespace Atomx.Data.Migrations
|
||||
LoginCount = table.Column<int>(type: "integer", nullable: false),
|
||||
LastLogin = table.Column<DateTime>(type: "timestamptz", nullable: true),
|
||||
LastIp = table.Column<string>(type: "varchar(50)", nullable: false),
|
||||
LockoutEndTime = table.Column<DateTime>(type: "timestamptz", nullable: true),
|
||||
CreateTime = table.Column<DateTime>(type: "timestamptz", nullable: false),
|
||||
UpdateTime = table.Column<DateTime>(type: "timestamptz", nullable: false)
|
||||
},
|
||||
@@ -516,6 +517,25 @@ namespace Atomx.Data.Migrations
|
||||
table.PrimaryKey("PK_Products", x => x.Id);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "RefreshTokens",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<string>(type: "text", nullable: false),
|
||||
UserId = table.Column<long>(type: "bigint", nullable: false),
|
||||
Token = table.Column<string>(type: "varchar(500)", nullable: false),
|
||||
IssuedTime = table.Column<DateTime>(type: "timestamp with time zone", nullable: false),
|
||||
ExpiresTime = table.Column<DateTime>(type: "timestamp with time zone", nullable: false),
|
||||
IsRevoked = table.Column<bool>(type: "boolean", nullable: false),
|
||||
RevokedTime = table.Column<DateTime>(type: "timestamptz", nullable: false),
|
||||
Ip = table.Column<string>(type: "varchar(50)", nullable: false),
|
||||
UserAgent = table.Column<string>(type: "varchar(500)", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_RefreshTokens", x => x.Id);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "Roles",
|
||||
columns: table => new
|
||||
@@ -636,10 +656,14 @@ namespace Atomx.Data.Migrations
|
||||
{
|
||||
Id = table.Column<long>(type: "bigint", nullable: false),
|
||||
Name = table.Column<string>(type: "varchar(64)", nullable: false),
|
||||
Email = table.Column<string>(type: "varchar(64)", nullable: false),
|
||||
Mobile = table.Column<string>(type: "varchar(64)", nullable: false),
|
||||
Email = table.Column<string>(type: "varchar(128)", nullable: false),
|
||||
Mobile = table.Column<string>(type: "varchar(32)", nullable: false),
|
||||
Avatar = table.Column<string>(type: "varchar(64)", nullable: false),
|
||||
Password = table.Column<string>(type: "varchar(32)", nullable: false),
|
||||
IsActive = table.Column<bool>(type: "boolean", nullable: false),
|
||||
EmailConfirmed = table.Column<bool>(type: "boolean", nullable: false),
|
||||
LockoutEndTime = table.Column<DateTime>(type: "timestamptz", nullable: true),
|
||||
FailedLoginAttempts = table.Column<int>(type: "integer", nullable: false),
|
||||
CreateTime = table.Column<DateTime>(type: "timestamptz", nullable: false),
|
||||
UpdateTime = table.Column<DateTime>(type: "timestamptz", nullable: true)
|
||||
},
|
||||
@@ -718,6 +742,9 @@ namespace Atomx.Data.Migrations
|
||||
migrationBuilder.DropTable(
|
||||
name: "Products");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "RefreshTokens");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "Roles");
|
||||
|
||||
@@ -135,6 +135,9 @@ namespace Atomx.Data.Migrations
|
||||
b.Property<DateTime?>("LastLogin")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<DateTime?>("LockoutEndTime")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<int>("LoginCount")
|
||||
.HasColumnType("integer");
|
||||
|
||||
@@ -1111,6 +1114,43 @@ namespace Atomx.Data.Migrations
|
||||
b.ToTable("ProductInventoryLogs");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Atomx.Common.Entities.RefreshToken", b =>
|
||||
{
|
||||
b.Property<string>("Id")
|
||||
.HasColumnType("text");
|
||||
|
||||
b.Property<DateTime>("ExpiresTime")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<string>("Ip")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(50)");
|
||||
|
||||
b.Property<bool>("IsRevoked")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<DateTime>("IssuedTime")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<DateTime>("RevokedTime")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<string>("Token")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(500)");
|
||||
|
||||
b.Property<string>("UserAgent")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(500)");
|
||||
|
||||
b.Property<long>("UserId")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("RefreshTokens");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Atomx.Common.Entities.Role", b =>
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
@@ -1344,11 +1384,23 @@ namespace Atomx.Data.Migrations
|
||||
|
||||
b.Property<string>("Email")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(64)");
|
||||
.HasColumnType("varchar(128)");
|
||||
|
||||
b.Property<bool>("EmailConfirmed")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<int>("FailedLoginAttempts")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<bool>("IsActive")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<DateTime?>("LockoutEndTime")
|
||||
.HasColumnType("timestamptz");
|
||||
|
||||
b.Property<string>("Mobile")
|
||||
.IsRequired()
|
||||
.HasColumnType("varchar(64)");
|
||||
.HasColumnType("varchar(32)");
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
|
||||
Reference in New Issue
Block a user