diff --git a/Directory.Build.Microsoft.targets b/Directory.Build.Microsoft.targets index d6e6d98..33e48c0 100644 --- a/Directory.Build.Microsoft.targets +++ b/Directory.Build.Microsoft.targets @@ -17,9 +17,10 @@ - - - + + + + diff --git a/Directory.Build.Volo.targets b/Directory.Build.Volo.targets index c40b1cc..4b4cf58 100644 --- a/Directory.Build.Volo.targets +++ b/Directory.Build.Volo.targets @@ -94,5 +94,6 @@ + \ No newline at end of file diff --git a/Directory.Build.props b/Directory.Build.props index e3dea23..2a080ed 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -4,10 +4,10 @@ 1.0.5.40 - 9.2.1 + 9.3.4 - 9.0.4 + 9.0.6 net9.0 diff --git a/Directory.Build.targets b/Directory.Build.targets index b368fca..3d137be 100644 --- a/Directory.Build.targets +++ b/Directory.Build.targets @@ -103,6 +103,9 @@ + + + diff --git a/host/JiShe.IoT.HttpApi.Host/configs/appsettings.Development.json b/host/JiShe.IoT.HttpApi.Host/configs/appsettings.Development.json index 6ff0927..2e492ec 100644 --- a/host/JiShe.IoT.HttpApi.Host/configs/appsettings.Development.json +++ b/host/JiShe.IoT.HttpApi.Host/configs/appsettings.Development.json @@ -4,19 +4,19 @@ "CorsOrigins": "https://*.IoT.com,http://localhost:4200,http://localhost:3100,http://localhost:80,http://10.10.90.3:4200" }, "ConnectionStrings": { - "Default": "Data Source=192.168.111.174;Port=13306;Database=JiSheIoTProDB;uid=root;pwd=JiShe!aqG#5kGgh&0;charset=utf8mb4;Allow User Variables=true;AllowLoadLocalInfile=true;TreatTinyAsBoolean=false;SslMode=None;Pooling=true;" + "Default": "Data Source=localhost;Port=33306;Database=JiSheIoTProDB4;uid=root;pwd=123456789;charset=utf8mb4;Allow User Variables=true;AllowLoadLocalInfile=true;TreatTinyAsBoolean=false;SslMode=None;Pooling=true;" }, "Hangfire": { "Redis": { - "Host": "192.168.111.174:30712,password=1q3J@BGf!yhTaD46nS#", + "Host": "47.110.53.196:30712,password=1q3J@BGf!yhTaD46nS#", "DB": "2" } }, "Redis": { - "Configuration": "192.168.111.174:30712,password=1q3J@BGf!yhTaD46nS#,defaultdatabase=5" + "Configuration": "47.110.53.196:30712,password=1q3J@BGf!yhTaD46nS#,defaultdatabase=5" }, "Kafka": { - "BootstrapServers": "47.110.62.104:9094,192.168.111.174:9094,47.110.60.222:9094", + "BootstrapServers": "47.110.62.104:9094,47.110.53.196:9094,47.110.60.222:9094", "EnableFilter": true, "EnableAuthorization": false, "SaslUserName": "lixiao", @@ -26,8 +26,8 @@ "TaskThreadCount": -1 }, "Pulsar": { - "ServiceUrl": "pulsar+ssl://iot-north-mq.heclouds.com:6651", //pulsar+ssl://iot-north-mq.heclouds.com:6651 ,pulsar://192.168.111.174:26974 - "WebUrl": "http://192.168.111.174:9094", + "ServiceUrl": "pulsar+ssl://iot-north-mq.heclouds.com:6651", //pulsar+ssl://iot-north-mq.heclouds.com:6651 ,pulsar://47.110.53.196:26974 + "WebUrl": "http://47.110.53.196:9094", "UserName": "admin", "TenantName": "1YMVZZkAkRArjxSD8457", "Namespace": "OneNET", @@ -57,10 +57,10 @@ "IoTDBOptions": { "UserName": "root", "Password": "Lixiao@1980", - //"TreeModelClusterList": [ "192.168.111.174:6667", "47.110.60.222:6667", "47.110.62.104:6667" ], - //"TableModelClusterList": [ "192.168.111.174:6667", "47.110.60.222:6667", "47.110.62.104:6667" ], - "TreeModelClusterList": [ "192.168.111.174:30710" ], - "TableModelClusterList": [ "192.168.111.174:30710" ], + //"TreeModelClusterList": [ "47.110.53.196:6667", "47.110.60.222:6667", "47.110.62.104:6667" ], + //"TableModelClusterList": [ "47.110.53.196:6667", "47.110.60.222:6667", "47.110.62.104:6667" ], + "TreeModelClusterList": [ "47.110.53.196:30710" ], + "TableModelClusterList": [ "47.110.53.196:30710" ], "PoolSize": 32, "DataBaseName": "jisheiotdata", "OpenDebugMode": true, @@ -97,7 +97,7 @@ } }, "FreeRedisOptions": { - "ConnectionString": "192.168.111.174:30712,password=1q3J@BGf!yhTaD46nS#,abortConnect=false,connectTimeout=30000,allowAdmin=true,maxPoolSize=500,defaultdatabase=14", + "ConnectionString": "47.110.53.196:30712,password=1q3J@BGf!yhTaD46nS#,abortConnect=false,connectTimeout=30000,allowAdmin=true,maxPoolSize=500,defaultdatabase=14", "UseDistributedCache": true }, "FreeSqlProviderOptions": { diff --git a/src/JiShe.IoT.DbMigrator/appsettings.json b/src/JiShe.IoT.DbMigrator/appsettings.json index 5cb5a3c..64b4512 100644 --- a/src/JiShe.IoT.DbMigrator/appsettings.json +++ b/src/JiShe.IoT.DbMigrator/appsettings.json @@ -1,14 +1,14 @@ { "ConnectionStrings": { - "Default": "Data Source=192.168.111.174;Port=13306;Database=JiSheIoTProDB;uid=root;pwd=JiShe!aqG#5kGgh&0;charset=utf8mb4;Allow User Variables=true;AllowLoadLocalInfile=true;TreatTinyAsBoolean=false;SslMode=None;Pooling=true;" + "Default": "Data Source=localhost;Port=33306;Database=JiSheIoTProDB4;uid=root;pwd=123456789;charset=utf8mb4;Allow User Variables=true;AllowLoadLocalInfile=true;TreatTinyAsBoolean=false;SslMode=None;Pooling=true;" }, "IoTDBOptions": { "UserName": "root", "Password": "Lixiao@1980", //"TreeModelClusterList": [ "47.110.53.196:6667", "47.110.60.222:6667", "47.110.62.104:6667" ], //"TableModelClusterList": [ "47.110.53.196:6667", "47.110.60.222:6667", "47.110.62.104:6667" ], - "TreeModelClusterList": [ "192.168.111.174:30710" ], - "TableModelClusterList": [ "192.168.111.174:30710" ], + "TreeModelClusterList": [ "47.110.53.196:30710" ], + "TableModelClusterList": [ "47.110.53.196:30710" ], "PoolSize": 32, "DataBaseName": "jisheiotdata", "OpenDebugMode": false, diff --git a/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTDbContext.cs b/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTDbContext.cs index 5f9c0bf..0e400af 100644 --- a/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTDbContext.cs +++ b/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTDbContext.cs @@ -50,6 +50,8 @@ namespace JiShe.IoT.EntityFrameworkCore public DbSet TenantConnectionStrings { get; set; } public DbSet BackgroundJobs { get; set; } public DbSet AuditLogs { get; set; } + public DbSet AuditLogExcelFiles { get; set; } + public DbSet Notifications { get; set; } public DbSet NotificationSubscriptions { get; set; } public DbSet DataDictionaries { get; set; } diff --git a/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTMigrationsDbContextFactory.cs b/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTMigrationsDbContextFactory.cs index 4b8a107..b6f8181 100644 --- a/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTMigrationsDbContextFactory.cs +++ b/src/JiShe.IoT.EntityFrameworkCore/EntityFrameworkCore/IoTMigrationsDbContextFactory.cs @@ -11,7 +11,7 @@ namespace JiShe.IoT.EntityFrameworkCore var configuration = BuildConfiguration(); var builder = new DbContextOptionsBuilder() - .UseMySql(configuration.GetConnectionString("Default"), MySqlServerVersion.LatestSupportedServerVersion); + .UseMySQL(configuration.GetConnectionString("Default") ?? string.Empty); return new IoTDbContext(builder.Options); } diff --git a/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251205064351_InitialCreate.Designer.cs b/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251207050159_InitialCreate.Designer.cs similarity index 99% rename from src/JiShe.IoT.EntityFrameworkCore/Migrations/20251205064351_InitialCreate.Designer.cs rename to src/JiShe.IoT.EntityFrameworkCore/Migrations/20251207050159_InitialCreate.Designer.cs index 34875da..fff8c85 100644 --- a/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251205064351_InitialCreate.Designer.cs +++ b/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251207050159_InitialCreate.Designer.cs @@ -3,17 +3,15 @@ using System; using JiShe.IoT.EntityFrameworkCore; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; using Microsoft.EntityFrameworkCore.Migrations; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; #nullable disable namespace JiShe.IoT.Migrations { [DbContext(typeof(IoTDbContext))] - [Migration("20251205064351_InitialCreate")] + [Migration("20251207050159_InitialCreate")] partial class InitialCreate { /// @@ -21,12 +19,9 @@ namespace JiShe.IoT.Migrations { #pragma warning disable 612, 618 modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.MySql) - .HasAnnotation("ProductVersion", "9.0.4") + .HasAnnotation("ProductVersion", "9.0.6") .HasAnnotation("Relational:MaxIdentifierLength", 64); - MySqlModelBuilderExtensions.AutoIncrementColumns(modelBuilder); - modelBuilder.Entity("JiShe.ServicePro.BasicManagement.UserRefreshTokens.UserRefreshToken", b => { b.Property("Id") @@ -813,7 +808,7 @@ namespace JiShe.IoT.Migrations .HasColumnType("int") .HasComment("旧系统授权最后修改者Id"); - b.PrimitiveCollection("PropertyArray") + b.Property("PropertyArray") .IsRequired() .HasMaxLength(1024) .HasColumnType("varchar(1024)") @@ -2355,6 +2350,33 @@ namespace JiShe.IoT.Migrations b.ToTable("AbpAuditLogActions", (string)null); }); + modelBuilder.Entity("Volo.Abp.AuditLogging.AuditLogExcelFile", b => + { + b.Property("Id") + .HasColumnType("char(36)"); + + b.Property("CreationTime") + .HasColumnType("datetime(6)") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("char(36)") + .HasColumnName("CreatorId"); + + b.Property("FileName") + .HasMaxLength(256) + .HasColumnType("varchar(256)") + .HasColumnName("FileName"); + + b.Property("TenantId") + .HasColumnType("char(36)") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpAuditLogExcelFiles", (string)null); + }); + modelBuilder.Entity("Volo.Abp.AuditLogging.EntityChange", b => { b.Property("Id") @@ -2997,7 +3019,7 @@ namespace JiShe.IoT.Migrations .HasColumnName("LastModifierId"); b.Property("LastPasswordChangeTime") - .HasColumnType("datetime(6)"); + .HasColumnType("datetime"); b.Property("LockoutEnabled") .ValueGeneratedOnAdd() @@ -3006,7 +3028,7 @@ namespace JiShe.IoT.Migrations .HasColumnName("LockoutEnabled"); b.Property("LockoutEnd") - .HasColumnType("datetime(6)"); + .HasColumnType("datetime"); b.Property("Name") .HasMaxLength(64) diff --git a/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251205064351_InitialCreate.cs b/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251207050159_InitialCreate.cs similarity index 72% rename from src/JiShe.IoT.EntityFrameworkCore/Migrations/20251205064351_InitialCreate.cs rename to src/JiShe.IoT.EntityFrameworkCore/Migrations/20251207050159_InitialCreate.cs index 7e093ef..cdc6fa4 100644 --- a/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251205064351_InitialCreate.cs +++ b/src/JiShe.IoT.EntityFrameworkCore/Migrations/20251207050159_InitialCreate.cs @@ -12,137 +12,121 @@ namespace JiShe.IoT.Migrations protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.AlterDatabase() - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "AbpAuditLogExcelFiles", + columns: table => new + { + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + FileName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + CreationTime = table.Column(type: "datetime(6)", nullable: false), + CreatorId = table.Column(type: "char(36)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpAuditLogExcelFiles", x => x.Id); + }) + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpAuditLogs", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - ApplicationName = table.Column(type: "varchar(96)", maxLength: 96, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - UserId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - UserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - TenantName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - ImpersonatorUserId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ImpersonatorUserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - ImpersonatorTenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ImpersonatorTenantName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + ApplicationName = table.Column(type: "varchar(96)", maxLength: 96, nullable: true), + UserId = table.Column(type: "char(36)", nullable: true), + UserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + TenantId = table.Column(type: "char(36)", nullable: true), + TenantName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + ImpersonatorUserId = table.Column(type: "char(36)", nullable: true), + ImpersonatorUserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + ImpersonatorTenantId = table.Column(type: "char(36)", nullable: true), + ImpersonatorTenantName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), ExecutionTime = table.Column(type: "datetime(6)", nullable: false), ExecutionDuration = table.Column(type: "int", nullable: false), - ClientIpAddress = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - ClientName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - ClientId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - CorrelationId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - BrowserInfo = table.Column(type: "varchar(512)", maxLength: 512, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - HttpMethod = table.Column(type: "varchar(16)", maxLength: 16, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Url = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Exceptions = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Comments = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + ClientIpAddress = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + ClientName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), + ClientId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + CorrelationId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + BrowserInfo = table.Column(type: "varchar(512)", maxLength: 512, nullable: true), + HttpMethod = table.Column(type: "varchar(16)", maxLength: 16, nullable: true), + Url = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + Exceptions = table.Column(type: "longtext", nullable: true), + Comments = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), HttpStatusCode = table.Column(type: "int", nullable: true), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpAuditLogs", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpBackgroundJobs", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - ApplicationName = table.Column(type: "varchar(96)", maxLength: 96, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - JobName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - JobArgs = table.Column(type: "longtext", maxLength: 1048576, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + ApplicationName = table.Column(type: "varchar(96)", maxLength: 96, nullable: true), + JobName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + JobArgs = table.Column(type: "longtext", maxLength: 1048576, nullable: false), TryCount = table.Column(type: "smallint", nullable: false, defaultValue: (short)0), CreationTime = table.Column(type: "datetime(6)", nullable: false), NextTryTime = table.Column(type: "datetime(6)", nullable: false), LastTryTime = table.Column(type: "datetime(6)", nullable: true), IsAbandoned = table.Column(type: "bit(1)", nullable: false, defaultValue: false), Priority = table.Column(type: "tinyint unsigned", nullable: false, defaultValue: (byte)15), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpBackgroundJobs", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpClaimTypes", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), Required = table.Column(type: "bit(1)", nullable: false), IsStatic = table.Column(type: "bit(1)", nullable: false), - Regex = table.Column(type: "varchar(512)", maxLength: 512, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - RegexDescription = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Description = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Regex = table.Column(type: "varchar(512)", maxLength: 512, nullable: true), + RegexDescription = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), + Description = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), ValueType = table.Column(type: "int", nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpClaimTypes", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpDataDictionaries", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - Code = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayText = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Description = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + Code = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), + DisplayText = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), + Description = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -150,99 +134,79 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_AbpDataDictionaries", x => x.Id); }, comment: "数据字典") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpFeatureGroups", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpFeatureGroups", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpFeatures", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - GroupName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ParentName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Description = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - DefaultValue = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + GroupName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + ParentName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), + DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), + Description = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + DefaultValue = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), IsVisibleToClients = table.Column(type: "bit(1)", nullable: false), IsAvailableToHost = table.Column(type: "bit(1)", nullable: false), - AllowedProviders = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - ValueType = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + AllowedProviders = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + ValueType = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: true), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpFeatures", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpFeatureValues", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Value = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ProviderName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + Value = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + ProviderName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), ProviderKey = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpFeatureValues", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpFileObjects", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - FileName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "文件名称") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + FileName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "文件名称"), FileSize = table.Column(type: "bigint", nullable: false, comment: "文件大小"), - ContentType = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "文件名称") - .Annotation("MySql:CharSet", "utf8mb4"), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ContentType = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "文件名称"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -250,34 +214,28 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_AbpFileObjects", x => x.Id); }, comment: "文件管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpLanguages", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - CultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "语言名称") - .Annotation("MySql:CharSet", "utf8mb4"), - UiCultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "Ui语言名称") - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "显示名称") - .Annotation("MySql:CharSet", "utf8mb4"), - FlagIcon = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "图标") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + CultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "语言名称"), + UiCultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "Ui语言名称"), + DisplayName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "显示名称"), + FlagIcon = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "图标"), IsEnabled = table.Column(type: "bit(1)", nullable: false), IsDefault = table.Column(type: "bit(1)", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -285,32 +243,26 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_AbpLanguages", x => x.Id); }, comment: "语言管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpLanguageTexts", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - CultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "语言名称") - .Annotation("MySql:CharSet", "utf8mb4"), - ResourceName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "资源名称") - .Annotation("MySql:CharSet", "utf8mb4"), - Name = table.Column(type: "varchar(256)", maxLength: 256, nullable: false, comment: "名称") - .Annotation("MySql:CharSet", "utf8mb4"), - Value = table.Column(type: "varchar(256)", maxLength: 256, nullable: false, comment: "值") - .Annotation("MySql:CharSet", "utf8mb4"), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + CultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "语言名称"), + ResourceName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "资源名称"), + Name = table.Column(type: "varchar(256)", maxLength: 256, nullable: false, comment: "名称"), + Value = table.Column(type: "varchar(256)", maxLength: 256, nullable: false, comment: "值"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -318,54 +270,48 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_AbpLanguageTexts", x => x.Id); }, comment: "语言文本管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpLinkUsers", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - SourceUserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - SourceTenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - TargetUserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TargetTenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci") + Id = table.Column(type: "char(36)", nullable: false), + SourceUserId = table.Column(type: "char(36)", nullable: false), + SourceTenantId = table.Column(type: "char(36)", nullable: true), + TargetUserId = table.Column(type: "char(36)", nullable: false), + TargetTenantId = table.Column(type: "char(36)", nullable: true) }, constraints: table => { table.PrimaryKey("PK_AbpLinkUsers", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpNotifications", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - Title = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Content = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + Title = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + Content = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false), MessageType = table.Column(type: "int", nullable: false), MessageLevel = table.Column(type: "int", nullable: false), - SenderUserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - SenderUserName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ReceiveUserId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ReceiveUserName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + SenderUserId = table.Column(type: "char(36)", nullable: false), + SenderUserName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + ReceiveUserId = table.Column(type: "char(36)", nullable: true), + ReceiveUserName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), Read = table.Column(type: "bit(1)", nullable: false), ReadTime = table.Column(type: "datetime(6)", nullable: true), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -373,30 +319,27 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_AbpNotifications", x => x.Id); }, comment: "消息通知管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpNotificationSubscriptions", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - NotificationId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - ReceiveUserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - ReceiveUserName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + NotificationId = table.Column(type: "char(36)", nullable: false), + ReceiveUserId = table.Column(type: "char(36)", nullable: false), + ReceiveUserName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), Read = table.Column(type: "bit(1)", nullable: false), ReadTime = table.Column(type: "datetime(6)", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -404,30 +347,26 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_AbpNotificationSubscriptions", x => x.Id); }, comment: "消息订阅者") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpOrganizationUnits", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ParentId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - Code = table.Column(type: "varchar(95)", maxLength: 95, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + ParentId = table.Column(type: "char(36)", nullable: true), + Code = table.Column(type: "varchar(95)", maxLength: 95, nullable: false), + DisplayName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), EntityVersion = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -439,247 +378,199 @@ namespace JiShe.IoT.Migrations principalTable: "AbpOrganizationUnits", principalColumn: "Id"); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpPermissionGrants", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ProviderName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + ProviderName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), ProviderKey = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpPermissionGrants", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpPermissionGroups", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpPermissionGroups", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpPermissions", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - GroupName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ParentName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + GroupName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + ParentName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), + DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), IsEnabled = table.Column(type: "bit(1)", nullable: false), MultiTenancySide = table.Column(type: "tinyint unsigned", nullable: false), - Providers = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - StateCheckers = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Providers = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), + StateCheckers = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpPermissions", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpRoles", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - NormalizedName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + Name = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), + NormalizedName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), IsDefault = table.Column(type: "bit(1)", nullable: false), IsStatic = table.Column(type: "bit(1)", nullable: false), IsPublic = table.Column(type: "bit(1)", nullable: false), EntityVersion = table.Column(type: "int", nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpRoles", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpSecurityLogs", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ApplicationName = table.Column(type: "varchar(96)", maxLength: 96, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Identity = table.Column(type: "varchar(96)", maxLength: 96, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Action = table.Column(type: "varchar(96)", maxLength: 96, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - UserId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - UserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - TenantName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - ClientId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - CorrelationId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - ClientIpAddress = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - BrowserInfo = table.Column(type: "varchar(512)", maxLength: 512, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + ApplicationName = table.Column(type: "varchar(96)", maxLength: 96, nullable: true), + Identity = table.Column(type: "varchar(96)", maxLength: 96, nullable: true), + Action = table.Column(type: "varchar(96)", maxLength: 96, nullable: true), + UserId = table.Column(type: "char(36)", nullable: true), + UserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + TenantName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + ClientId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + CorrelationId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + ClientIpAddress = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + BrowserInfo = table.Column(type: "varchar(512)", maxLength: 512, nullable: true), CreationTime = table.Column(type: "datetime(6)", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpSecurityLogs", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpSessions", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - SessionId = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Device = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - DeviceInfo = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - UserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - ClientId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - IpAddresses = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + SessionId = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + Device = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), + DeviceInfo = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + TenantId = table.Column(type: "char(36)", nullable: true), + UserId = table.Column(type: "char(36)", nullable: false), + ClientId = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + IpAddresses = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: true), SignedIn = table.Column(type: "datetime(6)", nullable: false), LastAccessed = table.Column(type: "datetime(6)", nullable: true), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpSessions", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpSettingDefinitions", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Description = table.Column(type: "varchar(512)", maxLength: 512, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - DefaultValue = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + DisplayName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), + Description = table.Column(type: "varchar(512)", maxLength: 512, nullable: true), + DefaultValue = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: true), IsVisibleToClients = table.Column(type: "bit(1)", nullable: false), - Providers = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Providers = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: true), IsInherited = table.Column(type: "bit(1)", nullable: false), IsEncrypted = table.Column(type: "bit(1)", nullable: false), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpSettingDefinitions", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpSettings", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Value = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ProviderName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + Value = table.Column(type: "varchar(2048)", maxLength: 2048, nullable: false), + ProviderName = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), ProviderKey = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_AbpSettings", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpTenants", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - NormalizedName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), + NormalizedName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), EntityVersion = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => { table.PrimaryKey("PK_AbpTenants", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpUserDelegations", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - SourceUserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TargetUserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + SourceUserId = table.Column(type: "char(36)", nullable: false), + TargetUserId = table.Column(type: "char(36)", nullable: false), StartTime = table.Column(type: "datetime(6)", nullable: false), EndTime = table.Column(type: "datetime(6)", nullable: false) }, @@ -687,137 +578,103 @@ namespace JiShe.IoT.Migrations { table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - UserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - NormalizedUserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Name = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Surname = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Email = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - NormalizedEmail = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + UserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), + NormalizedUserName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), + Name = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + Surname = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + Email = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), + NormalizedEmail = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), EmailConfirmed = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - PasswordHash = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - SecurityStamp = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + PasswordHash = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + SecurityStamp = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), IsExternal = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - PhoneNumber = table.Column(type: "varchar(16)", maxLength: 16, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + PhoneNumber = table.Column(type: "varchar(16)", maxLength: 16, nullable: true), PhoneNumberConfirmed = table.Column(type: "bit(1)", nullable: false, defaultValue: false), IsActive = table.Column(type: "bit(1)", nullable: false), TwoFactorEnabled = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - LockoutEnd = table.Column(type: "datetime(6)", nullable: true), + LockoutEnd = table.Column(type: "datetime", nullable: true), LockoutEnabled = table.Column(type: "bit(1)", nullable: false, defaultValue: false), AccessFailedCount = table.Column(type: "int", nullable: false, defaultValue: 0), ShouldChangePasswordOnNextLogin = table.Column(type: "bit(1)", nullable: false), EntityVersion = table.Column(type: "int", nullable: false), - LastPasswordChangeTime = table.Column(type: "datetime(6)", nullable: true), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + LastPasswordChangeTime = table.Column(type: "datetime", nullable: true), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => { table.PrimaryKey("PK_AbpUsers", x => x.Id); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProCTWingAccountInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - AccountName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "账号名称") - .Annotation("MySql:CharSet", "utf8mb4"), - AccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账号ID") - .Annotation("MySql:CharSet", "utf8mb4"), - AppId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "应用 ID") - .Annotation("MySql:CharSet", "utf8mb4"), - AppKey = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "应用 AppKey") - .Annotation("MySql:CharSet", "utf8mb4"), - AppSecret = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "应用 AppSecret") - .Annotation("MySql:CharSet", "utf8mb4"), - PlatformTenantId = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "平台租户ID") - .Annotation("MySql:CharSet", "utf8mb4"), - CommunicationAddress = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "通讯服务地址") - .Annotation("MySql:CharSet", "utf8mb4"), - PhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "手机号码") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + AccountName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "账号名称"), + AccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账号ID"), + AppId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "应用 ID"), + AppKey = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "应用 AppKey"), + AppSecret = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "应用 AppSecret"), + PlatformTenantId = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "平台租户ID"), + CommunicationAddress = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "通讯服务地址"), + PhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "手机号码"), ProductCount = table.Column(type: "int", nullable: false), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProCTWingAccountInfo", x => x.Id); }, comment: "CTWing账号信息") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProCTWingPrivateProductInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - CTWingAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账号ID") - .Annotation("MySql:CharSet", "utf8mb4"), - AccountPhoneNumber = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - CommunicationAddress = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "通讯服务地址") - .Annotation("MySql:CharSet", "utf8mb4"), - MasterKey = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "OpenAPI 通信主密钥") - .Annotation("MySql:CharSet", "utf8mb4"), - FeatureAccesskey = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备访问密钥") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformProductId = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品ID") - .Annotation("MySql:CharSet", "utf8mb4"), - ProductName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品名称") - .Annotation("MySql:CharSet", "utf8mb4"), - Protocol = table.Column(type: "varchar(20)", maxLength: 20, nullable: true, comment: "通讯协议") - .Annotation("MySql:CharSet", "utf8mb4"), - ProductDesc = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "必填,产品描述") - .Annotation("MySql:CharSet", "utf8mb4"), - ProductType = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "一级分类名") - .Annotation("MySql:CharSet", "utf8mb4"), - SecondaryType = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "二级分类名") - .Annotation("MySql:CharSet", "utf8mb4"), - ThirdType = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "三级分类名") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + CTWingAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账号ID"), + AccountPhoneNumber = table.Column(type: "longtext", nullable: true), + CommunicationAddress = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "通讯服务地址"), + MasterKey = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "OpenAPI 通信主密钥"), + FeatureAccesskey = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备访问密钥"), + IoTPlatformProductId = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品ID"), + ProductName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品名称"), + Protocol = table.Column(type: "varchar(20)", maxLength: 20, nullable: true, comment: "通讯协议"), + ProductDesc = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "必填,产品描述"), + ProductType = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "一级分类名"), + SecondaryType = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "二级分类名"), + ThirdType = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "三级分类名"), NodeType = table.Column(type: "int", nullable: false), AccessType = table.Column(type: "int", nullable: false), NetworkType = table.Column(type: "int", nullable: false), @@ -825,309 +682,248 @@ namespace JiShe.IoT.Migrations AuthType = table.Column(type: "int", nullable: false), DataEncryption = table.Column(type: "int", nullable: false), TupIsThrough = table.Column(type: "int", nullable: false), - TupDeviceModel = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "设备型号") - .Annotation("MySql:CharSet", "utf8mb4"), + TupDeviceModel = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "设备型号"), DeviceCount = table.Column(type: "int", nullable: false), - DeviceThingModelFileId = table.Column(type: "varchar(50)", maxLength: 50, nullable: true, comment: "设备物模型文件Id") - .Annotation("MySql:CharSet", "utf8mb4"), - DeviceThingModelFileName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备物模型文件名称") - .Annotation("MySql:CharSet", "utf8mb4"), + DeviceThingModelFileId = table.Column(type: "varchar(50)", maxLength: 50, nullable: true, comment: "设备物模型文件Id"), + DeviceThingModelFileName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备物模型文件名称"), IsEnabled = table.Column(type: "bit(1)", nullable: false, comment: "是否启用"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProCTWingPrivateProductInfo", x => x.Id); }, comment: "CTWing产品信息") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProDeviceInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - DeviceName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "设备名称") - .Annotation("MySql:CharSet", "utf8mb4"), - DeviceAddress = table.Column(type: "varchar(40)", maxLength: 40, nullable: false, comment: "设备地址") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + DeviceName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "设备名称"), + DeviceAddress = table.Column(type: "varchar(40)", maxLength: 40, nullable: false, comment: "设备地址"), IoTPlatform = table.Column(type: "int", nullable: false, comment: "物联网平台类型,默认没有指定"), DeviceType = table.Column(type: "int", nullable: false, comment: "设备类型,与业务系统无关,主要区分是网关设备、直连设备"), - IoTPlatformDeviceOpenInfo = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "物联网平台中对应的设备Id或者名称") - .Annotation("MySql:CharSet", "utf8mb4"), - PlatformPassword = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "物联网平台设备密码") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformProductName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "物联网平台中对应的产品Name") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的账号Id") - .Annotation("MySql:CharSet", "utf8mb4"), - AccountPhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户手机号") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformResponse = table.Column(type: "text", nullable: true, comment: "物联网平台返回的响应信息") - .Annotation("MySql:CharSet", "utf8mb4"), + IoTPlatformDeviceOpenInfo = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "物联网平台中对应的设备Id或者名称"), + PlatformPassword = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "物联网平台设备密码"), + IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id"), + IoTPlatformProductName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "物联网平台中对应的产品Name"), + IoTPlatformAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的账号Id"), + AccountPhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户手机号"), + IoTPlatformResponse = table.Column(type: "text", nullable: true, comment: "物联网平台返回的响应信息"), IsPlatformPushSuccess = table.Column(type: "tinyint(1)", nullable: false, comment: "物联网平台推送是否成功"), DeviceOnlineStatus = table.Column(type: "int", nullable: true, comment: "设备在线状态"), LastOnlineTime = table.Column(type: "datetime(6)", nullable: true, comment: "最后在线时间"), LastOfflineTime = table.Column(type: "datetime(6)", nullable: true, comment: "最后离线时间"), DeviceSource = table.Column(type: "int", nullable: false, comment: "设备来源类型"), IsNeedConfigDevicMdoel = table.Column(type: "bit(1)", nullable: false, comment: "是否需要配置设备模型"), - DeviceThingModelDataId = table.Column(type: "char(36)", nullable: true, comment: "设备物模型数据Id", collation: "ascii_general_ci"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + DeviceThingModelDataId = table.Column(type: "char(36)", nullable: true, comment: "设备物模型数据Id"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProDeviceInfo", x => x.Id); }, comment: "设备信息") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProDeviceThingModelCommandInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - DeviceThingModelId = table.Column(type: "char(36)", nullable: false, comment: "设备端物模型Id", collation: "ascii_general_ci"), + Id = table.Column(type: "char(36)", nullable: false), + DeviceThingModelId = table.Column(type: "char(36)", nullable: false, comment: "设备端物模型Id"), IoTPlatform = table.Column(type: "int", nullable: false, comment: "物联网平台类型"), - IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id") - .Annotation("MySql:CharSet", "utf8mb4"), - CommandName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false, comment: "指令名称") - .Annotation("MySql:CharSet", "utf8mb4"), - IssueCommand = table.Column(type: "varchar(512)", maxLength: 512, nullable: false, comment: "完整的单个下发指令") - .Annotation("MySql:CharSet", "utf8mb4"), - PropertyArray = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "指令设备端物模型的属性名称集合,JSON格式字符串数组") - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id"), + CommandName = table.Column(type: "varchar(256)", maxLength: 256, nullable: false, comment: "指令名称"), + IssueCommand = table.Column(type: "varchar(512)", maxLength: 512, nullable: false, comment: "完整的单个下发指令"), + PropertyArray = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "指令设备端物模型的属性名称集合,JSON格式字符串数组"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProDeviceThingModelCommandInfo", x => x.Id); }, comment: "设备端透传指令详情") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProDeviceThingModelManagement", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - DeviceModelName = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "设备端物模型名称") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + DeviceModelName = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "设备端物模型名称"), IoTPlatform = table.Column(type: "int", nullable: false, comment: "物联网平台类型,默认没有指定"), - IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id") - .Annotation("MySql:CharSet", "utf8mb4"), - ScriptName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "脚本函数名称") - .Annotation("MySql:CharSet", "utf8mb4"), - FunctionScript = table.Column(type: "text", nullable: false, comment: "脚本函数体") - .Annotation("MySql:CharSet", "utf8mb4"), + IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id"), + ScriptName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "脚本函数名称"), + FunctionScript = table.Column(type: "text", nullable: false, comment: "脚本函数体"), ParsingSequence = table.Column(type: "int", nullable: false, comment: "解析顺序,1234或者3412(高低位反转)"), FunctionAnalysisFlag = table.Column(type: "tinyint(1)", nullable: false, comment: "函数解析标记,默认为false, 不能解析"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProDeviceThingModelManagement", x => x.Id); }, comment: "设备端物模型管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProDeviceThingModelPropertylInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - DeviceThingModelId = table.Column(type: "char(36)", nullable: false, comment: "设备端物模型Id", collation: "ascii_general_ci"), + Id = table.Column(type: "char(36)", nullable: false), + DeviceThingModelId = table.Column(type: "char(36)", nullable: false, comment: "设备端物模型Id"), IoTPlatform = table.Column(type: "int", nullable: false, comment: "物联网平台类型"), - IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id") - .Annotation("MySql:CharSet", "utf8mb4"), - FiledType = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应产品物模型属性或者事件类型") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformRawFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "物联网平台中对应的产品物模型属性或者事件名称") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformRawFieldDataType = table.Column(type: "varchar(20)", maxLength: 20, nullable: false, comment: "物联网平台中对应的产品物模型属性或者事件数据类型") - .Annotation("MySql:CharSet", "utf8mb4"), - StandardFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称") - .Annotation("MySql:CharSet", "utf8mb4"), - StandardFieldValueType = table.Column(type: "varchar(20)", maxLength: 20, nullable: false, comment: "标准物模型字段值类型") - .Annotation("MySql:CharSet", "utf8mb4"), - StandardFieldDisplayName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称") - .Annotation("MySql:CharSet", "utf8mb4"), + IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id"), + FiledType = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应产品物模型属性或者事件类型"), + IoTPlatformRawFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "物联网平台中对应的产品物模型属性或者事件名称"), + IoTPlatformRawFieldDataType = table.Column(type: "varchar(20)", maxLength: 20, nullable: false, comment: "物联网平台中对应的产品物模型属性或者事件数据类型"), + StandardFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称"), + StandardFieldValueType = table.Column(type: "varchar(20)", maxLength: 20, nullable: false, comment: "标准物模型字段值类型"), + StandardFieldDisplayName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称"), IsValueNeedConvert = table.Column(type: "tinyint(1)", nullable: false, comment: "是否需要值类型转换"), SkipNumber = table.Column(type: "int", nullable: false, comment: "跳过数量"), TakeNumber = table.Column(type: "int", nullable: false, comment: "获取数量"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProDeviceThingModelPropertylInfo", x => x.Id); }, comment: "设备端物模型属性信息,是指设备端支持的属性或者事件") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProIoTPlatformThingModelInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), + Id = table.Column(type: "char(36)", nullable: false), IoTPlatform = table.Column(type: "int", nullable: false, comment: "物联网平台类型,默认没有指定"), - IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id") - .Annotation("MySql:CharSet", "utf8mb4"), - FiledType = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应产品物模型属性或者事件类型") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformRawFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "物联网平台中对应的产品物模型属性或者事件名称") - .Annotation("MySql:CharSet", "utf8mb4"), - StandardFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称") - .Annotation("MySql:CharSet", "utf8mb4"), - StandardFieldValueType = table.Column(type: "varchar(20)", maxLength: 20, nullable: false, comment: "标准物模型字段值类型") - .Annotation("MySql:CharSet", "utf8mb4"), - StandardFieldDisplayName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称") - .Annotation("MySql:CharSet", "utf8mb4"), + IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应的产品Id"), + FiledType = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台中对应产品物模型属性或者事件类型"), + IoTPlatformRawFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "物联网平台中对应的产品物模型属性或者事件名称"), + StandardFieldName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称"), + StandardFieldValueType = table.Column(type: "varchar(20)", maxLength: 20, nullable: false, comment: "标准物模型字段值类型"), + StandardFieldDisplayName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false, comment: "管理后台产品标准的物模型属性或者事件名称"), IsValueNeedConvert = table.Column(type: "tinyint(1)", nullable: false, comment: "是否需要值类型转换"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProIoTPlatformThingModelInfo", x => x.Id); }, comment: "平台端物模型信息") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProMenus", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ParentId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "唯一编码") - .Annotation("MySql:CharSet", "utf8mb4"), - Title = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "标题") - .Annotation("MySql:CharSet", "utf8mb4"), - DisplayTitle = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "标准多语言") - .Annotation("MySql:CharSet", "utf8mb4"), - Icon = table.Column(type: "longtext", nullable: true, comment: "图标") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + ParentId = table.Column(type: "char(36)", nullable: true), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "唯一编码"), + Title = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "标题"), + DisplayTitle = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "标准多语言"), + Icon = table.Column(type: "longtext", nullable: true, comment: "图标"), KeepAlive = table.Column(type: "bit(1)", nullable: false, comment: "是否缓存"), HideInMenu = table.Column(type: "bit(1)", nullable: false, comment: "是否显示"), Order = table.Column(type: "int", nullable: false, comment: "排序"), - Path = table.Column(type: "varchar(512)", maxLength: 512, nullable: false, comment: "路由/接口地址") - .Annotation("MySql:CharSet", "utf8mb4"), + Path = table.Column(type: "varchar(512)", maxLength: 512, nullable: false, comment: "路由/接口地址"), MenuType = table.Column(type: "int", nullable: false, comment: "菜单类型"), OpenType = table.Column(type: "int", nullable: false, comment: "打开类型"), - Url = table.Column(type: "longtext", nullable: true, comment: "内外链地址") - .Annotation("MySql:CharSet", "utf8mb4"), - Component = table.Column(type: "varchar(512)", maxLength: 512, nullable: true, comment: "组件地址") - .Annotation("MySql:CharSet", "utf8mb4"), - Policy = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "授权策略名称") - .Annotation("MySql:CharSet", "utf8mb4"), + Url = table.Column(type: "longtext", nullable: true, comment: "内外链地址"), + Component = table.Column(type: "varchar(512)", maxLength: 512, nullable: true, comment: "组件地址"), + Policy = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "授权策略名称"), Enabled = table.Column(type: "bit(1)", nullable: false), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -1135,140 +931,110 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_ServiceProMenus", x => x.Id); }, comment: "动态菜单管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProOneNETAccountInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - AccountName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "账号名称") - .Annotation("MySql:CharSet", "utf8mb4"), - OneNETAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户Id") - .Annotation("MySql:CharSet", "utf8mb4"), - PhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "手机号码") - .Annotation("MySql:CharSet", "utf8mb4"), - AccountAccesskey = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "账户通信密钥,平台可以重置密钥") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + AccountName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "账号名称"), + OneNETAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户Id"), + PhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "手机号码"), + AccountAccesskey = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "账户通信密钥,平台可以重置密钥"), ProductCount = table.Column(type: "int", nullable: false, comment: "产品数量"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProOneNETAccountInfo", x => x.Id); }, comment: "OneNET账号管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProOneNETProductInfo", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - OneNETAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户Id") - .Annotation("MySql:CharSet", "utf8mb4"), - AccountPhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: true, comment: "账户手机号") - .Annotation("MySql:CharSet", "utf8mb4"), - IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台对应的产品Id") - .Annotation("MySql:CharSet", "utf8mb4"), - ProductName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品名称") - .Annotation("MySql:CharSet", "utf8mb4"), - ProductAccesskey = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "产品访问密钥") - .Annotation("MySql:CharSet", "utf8mb4"), - DeviceThingModelFileId = table.Column(type: "varchar(50)", maxLength: 50, nullable: true, comment: "设备物模型文件Id") - .Annotation("MySql:CharSet", "utf8mb4"), - DeviceThingModelFileName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备物模型文件名称") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + OneNETAccountId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户Id"), + AccountPhoneNumber = table.Column(type: "varchar(50)", maxLength: 50, nullable: true, comment: "账户手机号"), + IoTPlatformProductId = table.Column(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台对应的产品Id"), + ProductName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品名称"), + ProductAccesskey = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "产品访问密钥"), + DeviceThingModelFileId = table.Column(type: "varchar(50)", maxLength: 50, nullable: true, comment: "设备物模型文件Id"), + DeviceThingModelFileName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备物模型文件名称"), IsEnabled = table.Column(type: "bit(1)", nullable: false), AccessProtocol = table.Column(type: "int", nullable: false, comment: "接入协议"), DataProtocol = table.Column(type: "int", nullable: false, comment: "数据协议"), NodeType = table.Column(type: "int", nullable: false, comment: "节点类型"), ProductCreateTime = table.Column(type: "datetime(6)", nullable: false, comment: "产品创建时间"), ProductUpdateTime = table.Column(type: "datetime(6)", nullable: false, comment: "最近修改时间"), - Network = table.Column(type: "longtext", nullable: true, comment: "联网方式") - .Annotation("MySql:CharSet", "utf8mb4"), - Manufacturer = table.Column(type: "longtext", nullable: true, comment: "产品厂商") - .Annotation("MySql:CharSet", "utf8mb4"), - Model = table.Column(type: "longtext", nullable: true, comment: "产品型号") - .Annotation("MySql:CharSet", "utf8mb4"), - Brand = table.Column(type: "longtext", nullable: true, comment: "产品品牌") - .Annotation("MySql:CharSet", "utf8mb4"), + Network = table.Column(type: "longtext", nullable: true, comment: "联网方式"), + Manufacturer = table.Column(type: "longtext", nullable: true, comment: "产品厂商"), + Model = table.Column(type: "longtext", nullable: true, comment: "产品型号"), + Brand = table.Column(type: "longtext", nullable: true, comment: "产品品牌"), Status = table.Column(type: "int", nullable: false, comment: "开发状态"), OwnDeviceCount = table.Column(type: "int", nullable: false, comment: "自有设备总数"), OnlineDeviceCount = table.Column(type: "int", nullable: false, comment: "在线设备总数"), OfflineDeviceCount = table.Column(type: "int", nullable: false, comment: "离线设备数"), NotActiveDeviceCount = table.Column(type: "int", nullable: false, comment: "未激活设备数"), - CommunicationAddress = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "通讯服务地址") - .Annotation("MySql:CharSet", "utf8mb4"), - CommunicationAddressTLS = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "TLS通讯服务地址") - .Annotation("MySql:CharSet", "utf8mb4"), - ThingModelInfos = table.Column(type: "longtext", nullable: true, comment: "平台物模型信息") - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + CommunicationAddress = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "通讯服务地址"), + CommunicationAddressTLS = table.Column(type: "varchar(256)", maxLength: 256, nullable: true, comment: "TLS通讯服务地址"), + ThingModelInfos = table.Column(type: "longtext", nullable: true, comment: "平台物模型信息"), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true), - TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"), - Remark = table.Column(type: "longtext", nullable: true, comment: "备注") - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: true, comment: "租户ID"), + Remark = table.Column(type: "longtext", nullable: true, comment: "备注"), OSACreatorId = table.Column(type: "int", nullable: true, comment: "旧系统授权创建者Id"), OSALastModifierId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"), OSADeleterId = table.Column(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"), ExtraProperties = table.Column(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式") - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { table.PrimaryKey("PK_ServiceProOneNETProductInfo", x => x.Id); }, comment: "OneNET产品管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProTextTemplates", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "名称") - .Annotation("MySql:CharSet", "utf8mb4"), - Code = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "编码") - .Annotation("MySql:CharSet", "utf8mb4"), - Content = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "内容") - .Annotation("MySql:CharSet", "utf8mb4"), - CultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "语言") - .Annotation("MySql:CharSet", "utf8mb4"), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "名称"), + Code = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "编码"), + Content = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "内容"), + CultureName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "语言"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -1276,31 +1042,27 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_ServiceProTextTemplates", x => x.Id); }, comment: "模板管理") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "ServiceProUserRefreshTokens", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - UserId = table.Column(type: "char(36)", nullable: false, comment: "用户id", collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - RefreshToken = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "刷新token") - .Annotation("MySql:CharSet", "utf8mb4"), - Token = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "Token") - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + UserId = table.Column(type: "char(36)", nullable: false, comment: "用户id"), + TenantId = table.Column(type: "char(36)", nullable: true), + RefreshToken = table.Column(type: "varchar(128)", maxLength: 128, nullable: false, comment: "刷新token"), + Token = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false, comment: "Token"), IsUsed = table.Column(type: "bit(1)", nullable: false, comment: "是否使用"), ExpirationTime = table.Column(type: "datetime(6)", nullable: false, comment: "过期时间"), - ExtraProperties = table.Column(type: "longtext", nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtraProperties = table.Column(type: "longtext", nullable: false), + ConcurrencyStamp = table.Column(type: "varchar(40)", maxLength: 40, nullable: false), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + LastModifierId = table.Column(type: "char(36)", nullable: true), IsDeleted = table.Column(type: "bit(1)", nullable: false, defaultValue: false), - DeleterId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + DeleterId = table.Column(type: "char(36)", nullable: true), DeletionTime = table.Column(type: "datetime(6)", nullable: true) }, constraints: table => @@ -1308,25 +1070,21 @@ namespace JiShe.IoT.Migrations table.PrimaryKey("PK_ServiceProUserRefreshTokens", x => x.Id); }, comment: "刷新Token") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpAuditLogActions", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - AuditLogId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - ServiceName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - MethodName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Parameters = table.Column(type: "varchar(2000)", maxLength: 2000, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + AuditLogId = table.Column(type: "char(36)", nullable: false), + ServiceName = table.Column(type: "varchar(256)", maxLength: 256, nullable: true), + MethodName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), + Parameters = table.Column(type: "varchar(2000)", maxLength: 2000, nullable: true), ExecutionTime = table.Column(type: "datetime(6)", nullable: false), ExecutionDuration = table.Column(type: "int", nullable: false), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1338,24 +1096,21 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpEntityChanges", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - AuditLogId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + Id = table.Column(type: "char(36)", nullable: false), + AuditLogId = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), ChangeTime = table.Column(type: "datetime(6)", nullable: false), ChangeType = table.Column(type: "tinyint unsigned", nullable: false), - EntityTenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - EntityId = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - EntityTypeFullName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + EntityTenantId = table.Column(type: "char(36)", nullable: true), + EntityId = table.Column(type: "varchar(128)", maxLength: 128, nullable: true), + EntityTypeFullName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), ExtraProperties = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1367,28 +1122,24 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpDataDictionaryDetails", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - DataDictionaryId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Code = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + DataDictionaryId = table.Column(type: "char(36)", nullable: false), + Code = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), Order = table.Column(type: "int", nullable: false), - DisplayText = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - Description = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + DisplayText = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), + Description = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: true), IsEnabled = table.Column(type: "bit(1)", nullable: false), - ExtendedAttribute = table.Column(type: "varchar(64)", maxLength: 64, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), + ExtendedAttribute = table.Column(type: "varchar(64)", maxLength: 64, nullable: true), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + CreatorId = table.Column(type: "char(36)", nullable: true), LastModificationTime = table.Column(type: "datetime(6)", nullable: true), - LastModifierId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci") + LastModifierId = table.Column(type: "char(36)", nullable: true) }, constraints: table => { @@ -1401,17 +1152,17 @@ namespace JiShe.IoT.Migrations onDelete: ReferentialAction.Cascade); }, comment: "数据字典详情") - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpOrganizationUnitRoles", columns: table => new { - RoleId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - OrganizationUnitId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + RoleId = table.Column(type: "char(36)", nullable: false), + OrganizationUnitId = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci") + CreatorId = table.Column(type: "char(36)", nullable: true) }, constraints: table => { @@ -1429,19 +1180,17 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpRoleClaims", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - RoleId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ClaimType = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + RoleId = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + ClaimType = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), ClaimValue = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1453,17 +1202,15 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpTenantConnectionStrings", columns: table => new { - TenantId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - Name = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + TenantId = table.Column(type: "char(36)", nullable: false), + Name = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), Value = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1475,19 +1222,17 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpUserClaims", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - UserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ClaimType = table.Column(type: "varchar(256)", maxLength: 256, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + UserId = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + ClaimType = table.Column(type: "varchar(256)", maxLength: 256, nullable: false), ClaimValue = table.Column(type: "varchar(1024)", maxLength: 1024, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1499,20 +1244,17 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpUserLogins", columns: table => new { - UserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - LoginProvider = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - ProviderKey = table.Column(type: "varchar(196)", maxLength: 196, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + UserId = table.Column(type: "char(36)", nullable: false), + LoginProvider = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + ProviderKey = table.Column(type: "varchar(196)", maxLength: 196, nullable: false), ProviderDisplayName = table.Column(type: "varchar(128)", maxLength: 128, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1524,17 +1266,17 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpUserOrganizationUnits", columns: table => new { - UserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - OrganizationUnitId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + UserId = table.Column(type: "char(36)", nullable: false), + OrganizationUnitId = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), CreationTime = table.Column(type: "datetime(6)", nullable: false), - CreatorId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci") + CreatorId = table.Column(type: "char(36)", nullable: true) }, constraints: table => { @@ -1552,15 +1294,15 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpUserRoles", columns: table => new { - UserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - RoleId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci") + UserId = table.Column(type: "char(36)", nullable: false), + RoleId = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true) }, constraints: table => { @@ -1578,20 +1320,17 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpUserTokens", columns: table => new { - UserId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - LoginProvider = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), + UserId = table.Column(type: "char(36)", nullable: false), + LoginProvider = table.Column(type: "varchar(64)", maxLength: 64, nullable: false), + Name = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), Value = table.Column(type: "longtext", nullable: true) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1603,23 +1342,19 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateTable( name: "AbpEntityPropertyChanges", columns: table => new { - Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - TenantId = table.Column(type: "char(36)", nullable: true, collation: "ascii_general_ci"), - EntityChangeId = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), - NewValue = table.Column(type: "varchar(512)", maxLength: 512, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - OriginalValue = table.Column(type: "varchar(512)", maxLength: 512, nullable: true) - .Annotation("MySql:CharSet", "utf8mb4"), - PropertyName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "char(36)", nullable: false), + TenantId = table.Column(type: "char(36)", nullable: true), + EntityChangeId = table.Column(type: "char(36)", nullable: false), + NewValue = table.Column(type: "varchar(512)", maxLength: 512, nullable: true), + OriginalValue = table.Column(type: "varchar(512)", maxLength: 512, nullable: true), + PropertyName = table.Column(type: "varchar(128)", maxLength: 128, nullable: false), PropertyTypeFullName = table.Column(type: "varchar(64)", maxLength: 64, nullable: false) - .Annotation("MySql:CharSet", "utf8mb4") }, constraints: table => { @@ -1631,7 +1366,7 @@ namespace JiShe.IoT.Migrations principalColumn: "Id", onDelete: ReferentialAction.Cascade); }) - .Annotation("MySql:CharSet", "utf8mb4"); + .Annotation("MySQL:Charset", "utf8mb4"); migrationBuilder.CreateIndex( name: "IX_AbpAuditLogActions_AuditLogId", @@ -2040,6 +1775,9 @@ namespace JiShe.IoT.Migrations migrationBuilder.DropTable( name: "AbpAuditLogActions"); + migrationBuilder.DropTable( + name: "AbpAuditLogExcelFiles"); + migrationBuilder.DropTable( name: "AbpBackgroundJobs"); diff --git a/src/JiShe.IoT.EntityFrameworkCore/Migrations/IoTDbContextModelSnapshot.cs b/src/JiShe.IoT.EntityFrameworkCore/Migrations/IoTDbContextModelSnapshot.cs index 1ffb4af..a596df8 100644 --- a/src/JiShe.IoT.EntityFrameworkCore/Migrations/IoTDbContextModelSnapshot.cs +++ b/src/JiShe.IoT.EntityFrameworkCore/Migrations/IoTDbContextModelSnapshot.cs @@ -3,9 +3,7 @@ using System; using JiShe.IoT.EntityFrameworkCore; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; #nullable disable @@ -18,12 +16,9 @@ namespace JiShe.IoT.Migrations { #pragma warning disable 612, 618 modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.MySql) - .HasAnnotation("ProductVersion", "9.0.4") + .HasAnnotation("ProductVersion", "9.0.6") .HasAnnotation("Relational:MaxIdentifierLength", 64); - MySqlModelBuilderExtensions.AutoIncrementColumns(modelBuilder); - modelBuilder.Entity("JiShe.ServicePro.BasicManagement.UserRefreshTokens.UserRefreshToken", b => { b.Property("Id") @@ -810,7 +805,7 @@ namespace JiShe.IoT.Migrations .HasColumnType("int") .HasComment("旧系统授权最后修改者Id"); - b.PrimitiveCollection("PropertyArray") + b.Property("PropertyArray") .IsRequired() .HasMaxLength(1024) .HasColumnType("varchar(1024)") @@ -2352,6 +2347,33 @@ namespace JiShe.IoT.Migrations b.ToTable("AbpAuditLogActions", (string)null); }); + modelBuilder.Entity("Volo.Abp.AuditLogging.AuditLogExcelFile", b => + { + b.Property("Id") + .HasColumnType("char(36)"); + + b.Property("CreationTime") + .HasColumnType("datetime(6)") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("char(36)") + .HasColumnName("CreatorId"); + + b.Property("FileName") + .HasMaxLength(256) + .HasColumnType("varchar(256)") + .HasColumnName("FileName"); + + b.Property("TenantId") + .HasColumnType("char(36)") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpAuditLogExcelFiles", (string)null); + }); + modelBuilder.Entity("Volo.Abp.AuditLogging.EntityChange", b => { b.Property("Id") @@ -2994,7 +3016,7 @@ namespace JiShe.IoT.Migrations .HasColumnName("LastModifierId"); b.Property("LastPasswordChangeTime") - .HasColumnType("datetime(6)"); + .HasColumnType("datetime"); b.Property("LockoutEnabled") .ValueGeneratedOnAdd() @@ -3003,7 +3025,7 @@ namespace JiShe.IoT.Migrations .HasColumnName("LockoutEnabled"); b.Property("LockoutEnd") - .HasColumnType("datetime(6)"); + .HasColumnType("datetime"); b.Property("Name") .HasMaxLength(64)