IoTDB数据存储优化
This commit is contained in:
parent
384f05649e
commit
9f8e9f74c3
@ -5,10 +5,10 @@
|
||||
"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.37:6667" ],
|
||||
"TableModelClusterList": [ "192.168.111.37:6667" ],
|
||||
"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.37:6667" ],
|
||||
//"TableModelClusterList": [ "192.168.111.37:6667" ],
|
||||
"PoolSize": 32,
|
||||
"TableModelDataBaseName": "energy",
|
||||
"OpenDebugMode": true,
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
using JiShe.ServicePro.BasicManagement.UserRefreshTokens;
|
||||
using JiShe.ServicePro.CTWingManagement.CTWingAccount;
|
||||
using JiShe.ServicePro.CTWingManagement.CTWingProduct;
|
||||
using JiShe.ServicePro.CTWingManagement.EntityFrameworkCore;
|
||||
using JiShe.ServicePro.DeviceManagement.EntityFrameworkCore;
|
||||
using JiShe.ServicePro.DeviceManagement.Focuses;
|
||||
@ -8,6 +10,8 @@ using JiShe.ServicePro.DynamicMenuManagement.Menus;
|
||||
using JiShe.ServicePro.FileManagement.EntityFrameworkCore;
|
||||
using JiShe.ServicePro.FileManagement.Files;
|
||||
using JiShe.ServicePro.OneNETManagement.EntityFrameworkCore;
|
||||
using JiShe.ServicePro.OneNETManagement.OneNETAccounts;
|
||||
using JiShe.ServicePro.OneNETManagement.OneNETProducts;
|
||||
using JiShe.ServicePro.TemplateManagement.EntityFrameworkCore;
|
||||
using JiShe.ServicePro.TemplateManagement.TextTemplates;
|
||||
|
||||
@ -66,8 +70,12 @@ namespace JiShe.IoT.EntityFrameworkCore
|
||||
public DbSet<MeterInfo> MeterInfo { get; set; }
|
||||
|
||||
// CTWing管理
|
||||
public DbSet<CTWingAccountInfo> CTWingAccountInfo { get; set; }
|
||||
public DbSet<CTWingPrivateProductInfo> CTWingPrivateProductInfo { get; set; }
|
||||
|
||||
// OneNET管理
|
||||
public DbSet<OneNETAccountInfos> OneNETAccountInfo { get; set; }
|
||||
public DbSet<OneNETProductInfos> OneNETProductInfo { get; set; }
|
||||
|
||||
|
||||
|
||||
|
||||
@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore;
|
||||
namespace JiShe.IoT.Migrations
|
||||
{
|
||||
[DbContext(typeof(IoTDbContext))]
|
||||
[Migration("20250714034934_InitialCreate")]
|
||||
[Migration("20250722081519_InitialCreate")]
|
||||
partial class InitialCreate
|
||||
{
|
||||
/// <inheritdoc />
|
||||
@ -109,6 +109,280 @@ namespace JiShe.IoT.Migrations
|
||||
b.ToTable("ServiceProUserRefreshTokens", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.CTWingManagement.CTWingAccount.CTWingAccountInfo", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<string>("AccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账号ID");
|
||||
|
||||
b.Property<string>("AccountName")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("账号名称");
|
||||
|
||||
b.Property<string>("CommunicationAddress")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("通讯服务地址");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("PhoneNumber")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("手机号码");
|
||||
|
||||
b.Property<string>("PlatformTenantId")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("平台租户ID");
|
||||
|
||||
b.Property<int>("ProductCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "AccountId", "AccountName", "CreationTime" }, "IX_ServiceProCTWingAccountInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProCTWingAccountInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.CTWingManagement.CTWingProduct.CTWingPrivateProductInfo", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<int>("AccessType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("AuthType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("CTWingAccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账号ID");
|
||||
|
||||
b.Property<string>("CommunicationAddress")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("通讯服务地址");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<int>("DataEncryption")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<int>("DeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("DeviceThingModelUrl")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("设备物模型文件管理地址");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<int>("IoTPlatformProductId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<bool>("IsEnabled")
|
||||
.HasColumnType("tinyint(1)");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<string>("MasterKey")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("主密钥");
|
||||
|
||||
b.Property<int>("NetworkType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("NodeType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("ProductDesc")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("必填,产品描述");
|
||||
|
||||
b.Property<string>("ProductName")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("产品名称");
|
||||
|
||||
b.Property<int>("ProductProtocol")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("ProductType")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("一级分类名");
|
||||
|
||||
b.Property<string>("Protocol")
|
||||
.HasMaxLength(20)
|
||||
.HasColumnType("varchar(20)")
|
||||
.HasComment("通讯协议");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<string>("SecondaryType")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("二级分类名");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.Property<string>("ThirdType")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("三级分类名");
|
||||
|
||||
b.Property<string>("TupDeviceModel")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("设备型号");
|
||||
|
||||
b.Property<int>("TupIsThrough")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "IoTPlatformProductId", "ProductName", "CreationTime" }, "IX_ServiceProCTWingPrivateProductInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProCTWingPrivateProductInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.DataDictionaryManagement.DataDictionaries.Aggregates.DataDictionary", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
@ -288,10 +562,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器型号");
|
||||
|
||||
b.Property<long>("FocusId")
|
||||
.HasColumnType("bigint")
|
||||
.HasComment("集中器ID");
|
||||
|
||||
b.Property<string>("HardwareReleaseDate")
|
||||
.HasMaxLength(80)
|
||||
.HasColumnType("varchar(80)")
|
||||
@ -310,13 +580,15 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("int")
|
||||
.HasComment("物联网平台类型,默认没有指定");
|
||||
|
||||
b.Property<string>("IoTPlatformDeviceOpenId")
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
b.Property<string>("IoTPlatformDeviceOpenInfo")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中的设备ID");
|
||||
|
||||
b.Property<string>("IoTPlatformProductId")
|
||||
.HasColumnType("longtext");
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中对应的产品Id");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
@ -365,14 +637,10 @@ namespace JiShe.IoT.Migrations
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("PlatformPassword")
|
||||
.HasMaxLength(80)
|
||||
.HasColumnType("varchar(80)")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("物联网平台设备密码");
|
||||
|
||||
b.Property<int>("ProjectID")
|
||||
.HasColumnType("int")
|
||||
.HasComment("项目ID");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
@ -418,7 +686,7 @@ namespace JiShe.IoT.Migrations
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "FocusAddress", "ProjectID", "FocusId", "CreationTime" }, "IX_ServiceProFocusInfo_IsNotUniqueKey")
|
||||
b.HasIndex(new[] { "Id", "FocusAddress", "CreationTime" }, "IX_ServiceProFocusInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProFocusInfo", (string)null);
|
||||
@ -475,15 +743,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<string>("DataTypes")
|
||||
.HasMaxLength(5000)
|
||||
.HasColumnType("varchar(5000)")
|
||||
.HasComment("采集项编号ID");
|
||||
|
||||
b.Property<int>("DatabaseBusiID")
|
||||
.HasColumnType("int")
|
||||
.HasComment("业务库ID");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
@ -511,10 +770,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(20)")
|
||||
.HasComment("集中器地址");
|
||||
|
||||
b.Property<int>("FocusId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("集中器ID");
|
||||
|
||||
b.Property<int>("FunctionCount")
|
||||
.HasColumnType("int")
|
||||
.HasComment("功能数量(包含采集项和阀控等)");
|
||||
@ -527,17 +782,24 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("是否带阀控");
|
||||
|
||||
b.Property<string>("IoTPlatformDeviceOpenInfo")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中对应的设备Id或者名称");
|
||||
|
||||
b.Property<string>("IoTPlatformProductId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中对应的产品Id");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<string>("ItemCodes")
|
||||
.HasMaxLength(5000)
|
||||
.HasColumnType("varchar(5000)")
|
||||
.HasComment("采集项编码");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
@ -557,10 +819,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasComment("表计地址");
|
||||
|
||||
b.Property<int>("MeterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("表计ID");
|
||||
|
||||
b.Property<string>("MeterName")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
@ -602,9 +860,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("密码");
|
||||
|
||||
b.Property<int>("ProjectID")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("Protocol")
|
||||
.HasColumnType("int")
|
||||
.HasComment("协议类型");
|
||||
@ -617,10 +872,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("是否自研");
|
||||
|
||||
b.Property<bool>("SingleRate")
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("是否单倍率");
|
||||
|
||||
b.Property<int>("Special")
|
||||
.HasColumnType("int")
|
||||
.HasComment("是否特殊表");
|
||||
@ -655,7 +906,7 @@ namespace JiShe.IoT.Migrations
|
||||
|
||||
b.HasIndex("MeterAddress");
|
||||
|
||||
b.HasIndex(new[] { "Id", "MeterAddress", "FocusAddress", "ProjectID", "FocusId", "CreationTime" }, "IX_ServiceProMeterInfo_IsNotUniqueKey")
|
||||
b.HasIndex(new[] { "Id", "MeterAddress", "FocusAddress", "CreationTime" }, "IX_ServiceProMeterInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProMeterInfo", (string)null);
|
||||
@ -1196,6 +1447,275 @@ namespace JiShe.IoT.Migrations
|
||||
b.ToTable("AbpNotificationSubscriptions", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.OneNETManagement.OneNETAccounts.OneNETAccountInfos", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<string>("Accesskey")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账户通信密钥,平台可以重置密钥");
|
||||
|
||||
b.Property<string>("AccountName")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("账号名称");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("OneNETAccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账户Id");
|
||||
|
||||
b.Property<string>("PhoneNumber")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("手机号码");
|
||||
|
||||
b.Property<int>("ProductCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "OneNETAccountId", "AccountName", "PhoneNumber", "CreationTime" }, "IX_ServiceProOneNETAccountInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProOneNETAccountInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.OneNETManagement.OneNETProducts.OneNETProductInfos", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<int>("AccessProtocol")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("Brand")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<string>("CommunicationAddress")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("通讯服务地址");
|
||||
|
||||
b.Property<string>("CommunicationAddressTLS")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("TLS通讯服务地址");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<int>("DataProtocol")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<string>("DeviceThingModelUrl")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("设备物模型文件管理地址");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<string>("IoTPlatformProductId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("物联网平台对应的产品Id");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<bool>("IsEnabled")
|
||||
.HasColumnType("tinyint(1)");
|
||||
|
||||
b.Property<bool>("IsEncrypted")
|
||||
.HasColumnType("tinyint(1)");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<string>("Manufacturer")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<string>("Model")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<string>("Network")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<int>("NodeType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("NotActiveDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<int>("OfflineDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("OneNETAccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账户Id");
|
||||
|
||||
b.Property<int>("OnlineDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("OwnDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("ProductAccesskey")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("产品访问密钥");
|
||||
|
||||
b.Property<DateTime>("ProductCreateTime")
|
||||
.HasColumnType("datetime(6)");
|
||||
|
||||
b.Property<string>("ProductName")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("产品名称");
|
||||
|
||||
b.Property<DateTime>("ProductUpdateTime")
|
||||
.HasColumnType("datetime(6)");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<int>("Status")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "IoTPlatformProductId", "ProductName", "CreationTime" }, "IX_ServiceProOneNETProductInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProOneNETProductInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.TemplateManagement.TextTemplates.TextTemplate", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
@ -734,6 +734,107 @@ namespace JiShe.IoT.Migrations
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ServiceProCTWingAccountInfo",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"),
|
||||
AccountName = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "账号名称")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
AccountId = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账号ID")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
PlatformTenantId = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "平台租户ID")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CommunicationAddress = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "通讯服务地址")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
PhoneNumber = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "手机号码")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ProductCount = table.Column<int>(type: "int", nullable: false),
|
||||
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CreationTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||
CreatorId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
LastModificationTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
LastModifierId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
IsDeleted = table.Column<bool>(type: "tinyint(1)", nullable: false, defaultValue: false),
|
||||
DeleterId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
DeletionTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
TenantId = table.Column<Guid>(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"),
|
||||
Remark = table.Column<string>(type: "longtext", nullable: true, comment: "备注")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
OSACreatorId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权创建者Id"),
|
||||
OSALastModifierId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"),
|
||||
OSADeleterId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"),
|
||||
ExtraProperties = table.Column<string>(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式")
|
||||
.Annotation("MySql:CharSet", "utf8mb4")
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ServiceProCTWingAccountInfo", x => x.Id);
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ServiceProCTWingPrivateProductInfo",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"),
|
||||
CTWingAccountId = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账号ID")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CommunicationAddress = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "通讯服务地址")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
MasterKey = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "主密钥")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IoTPlatformProductId = table.Column<int>(type: "int", nullable: false),
|
||||
ProductName = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品名称")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Protocol = table.Column<string>(type: "varchar(20)", maxLength: 20, nullable: true, comment: "通讯协议")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ProductDesc = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "必填,产品描述")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ProductType = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "一级分类名")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
SecondaryType = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "二级分类名")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ThirdType = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "三级分类名")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
NodeType = table.Column<int>(type: "int", nullable: false),
|
||||
AccessType = table.Column<int>(type: "int", nullable: false),
|
||||
NetworkType = table.Column<int>(type: "int", nullable: false),
|
||||
ProductProtocol = table.Column<int>(type: "int", nullable: false),
|
||||
AuthType = table.Column<int>(type: "int", nullable: false),
|
||||
DataEncryption = table.Column<int>(type: "int", nullable: false),
|
||||
TupIsThrough = table.Column<int>(type: "int", nullable: false),
|
||||
TupDeviceModel = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "设备型号")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
DeviceCount = table.Column<int>(type: "int", nullable: false),
|
||||
DeviceThingModelUrl = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备物模型文件管理地址")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IsEnabled = table.Column<bool>(type: "tinyint(1)", nullable: false),
|
||||
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CreationTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||
CreatorId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
LastModificationTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
LastModifierId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
IsDeleted = table.Column<bool>(type: "tinyint(1)", nullable: false, defaultValue: false),
|
||||
DeleterId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
DeletionTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
TenantId = table.Column<Guid>(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"),
|
||||
Remark = table.Column<string>(type: "longtext", nullable: true, comment: "备注")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
OSACreatorId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权创建者Id"),
|
||||
OSALastModifierId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"),
|
||||
OSADeleterId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"),
|
||||
ExtraProperties = table.Column<string>(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式")
|
||||
.Annotation("MySql:CharSet", "utf8mb4")
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ServiceProCTWingPrivateProductInfo", x => x.Id);
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ServiceProFocusInfo",
|
||||
columns: table => new
|
||||
@ -756,8 +857,6 @@ namespace JiShe.IoT.Migrations
|
||||
HeartbeatInterval = table.Column<int>(type: "int", nullable: false, comment: "心跳间隔"),
|
||||
LastRefreshTime = table.Column<DateTime>(type: "datetime(6)", nullable: true, comment: "最后刷新时间"),
|
||||
TimeDensity = table.Column<int>(type: "int", nullable: false, comment: "采集密度"),
|
||||
FocusId = table.Column<long>(type: "bigint", nullable: false, comment: "集中器ID"),
|
||||
ProjectID = table.Column<int>(type: "int", nullable: false, comment: "项目ID"),
|
||||
Enabled = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否启用"),
|
||||
SimCard = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "通讯SIM卡卡号")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
@ -773,12 +872,12 @@ namespace JiShe.IoT.Migrations
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
HardwareReleaseDate = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "硬件软件发布日期:日月年")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IoTPlatformDeviceOpenId = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: true, comment: "集中器在物联网平台中的设备ID")
|
||||
IoTPlatformDeviceOpenInfo = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "集中器在物联网平台中的设备ID")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IoTPlatform = table.Column<int>(type: "int", nullable: false, comment: "物联网平台类型,默认没有指定"),
|
||||
PlatformPassword = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "物联网平台设备密码")
|
||||
PlatformPassword = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "物联网平台设备密码")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IoTPlatformProductId = table.Column<string>(type: "longtext", nullable: true)
|
||||
IoTPlatformProductId = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "集中器在物联网平台中对应的产品Id")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
@ -871,7 +970,6 @@ namespace JiShe.IoT.Migrations
|
||||
Password = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "密码")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
DynamicPassword = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否动态密码"),
|
||||
SingleRate = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否单倍率"),
|
||||
TypeName = table.Column<int>(type: "int", maxLength: 128, nullable: false, comment: "表计类型名称"),
|
||||
SelfDevelop = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否自研"),
|
||||
BrandType = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "品牌类型")
|
||||
@ -881,17 +979,9 @@ namespace JiShe.IoT.Migrations
|
||||
TimesA = table.Column<decimal>(type: "decimal(18,4)", nullable: false, comment: "倍率A"),
|
||||
Timev = table.Column<decimal>(type: "decimal(18,4)", nullable: false, comment: "倍率V"),
|
||||
HaveValve = table.Column<bool>(type: "tinyint(1)", nullable: true, comment: "是否带阀控"),
|
||||
FocusId = table.Column<int>(type: "int", nullable: false, comment: "集中器ID"),
|
||||
MeterId = table.Column<int>(type: "int", nullable: false, comment: "表计ID"),
|
||||
ProjectID = table.Column<int>(type: "int", nullable: false),
|
||||
DatabaseBusiID = table.Column<int>(type: "int", nullable: false, comment: "业务库ID"),
|
||||
Enabled = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否启用"),
|
||||
GatherCount = table.Column<int>(type: "int", nullable: false, comment: "采集项数量"),
|
||||
FunctionCount = table.Column<int>(type: "int", nullable: false, comment: "功能数量(包含采集项和阀控等)"),
|
||||
ItemCodes = table.Column<string>(type: "varchar(5000)", maxLength: 5000, nullable: true, comment: "采集项编码")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
DataTypes = table.Column<string>(type: "varchar(5000)", maxLength: 5000, nullable: true, comment: "采集项编号ID")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Address = table.Column<string>(type: "varchar(20)", maxLength: 20, nullable: true, comment: "表计地址")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
AreaCode = table.Column<string>(type: "varchar(20)", maxLength: 20, nullable: true, comment: "表计区域编码")
|
||||
@ -902,6 +992,10 @@ namespace JiShe.IoT.Migrations
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Special = table.Column<int>(type: "int", nullable: false, comment: "是否特殊表"),
|
||||
AutomaticReport = table.Column<int>(type: "int", nullable: false, comment: "是否自动采集"),
|
||||
IoTPlatformProductId = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "集中器在物联网平台中对应的产品Id")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IoTPlatformDeviceOpenInfo = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "集中器在物联网平台中对应的设备Id或者名称")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CreationTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||
@ -926,6 +1020,107 @@ namespace JiShe.IoT.Migrations
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ServiceProOneNETAccountInfo",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"),
|
||||
AccountName = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "账号名称")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
OneNETAccountId = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户Id")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
PhoneNumber = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "手机号码")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Accesskey = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户通信密钥,平台可以重置密钥")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ProductCount = table.Column<int>(type: "int", nullable: false),
|
||||
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CreationTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||
CreatorId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
LastModificationTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
LastModifierId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
IsDeleted = table.Column<bool>(type: "tinyint(1)", nullable: false, defaultValue: false),
|
||||
DeleterId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
DeletionTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
TenantId = table.Column<Guid>(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"),
|
||||
Remark = table.Column<string>(type: "longtext", nullable: true, comment: "备注")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
OSACreatorId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权创建者Id"),
|
||||
OSALastModifierId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"),
|
||||
OSADeleterId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"),
|
||||
ExtraProperties = table.Column<string>(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式")
|
||||
.Annotation("MySql:CharSet", "utf8mb4")
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ServiceProOneNETAccountInfo", x => x.Id);
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ServiceProOneNETProductInfo",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"),
|
||||
OneNETAccountId = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "账户Id")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IoTPlatformProductId = table.Column<string>(type: "varchar(50)", maxLength: 50, nullable: false, comment: "物联网平台对应的产品Id")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ProductName = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "产品名称")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ProductAccesskey = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "产品访问密钥")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
DeviceThingModelUrl = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "设备物模型文件管理地址")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IsEncrypted = table.Column<bool>(type: "tinyint(1)", nullable: false),
|
||||
IsEnabled = table.Column<bool>(type: "tinyint(1)", nullable: false),
|
||||
AccessProtocol = table.Column<int>(type: "int", nullable: false),
|
||||
DataProtocol = table.Column<int>(type: "int", nullable: false),
|
||||
NodeType = table.Column<int>(type: "int", nullable: false),
|
||||
ProductCreateTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||
ProductUpdateTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||
Network = table.Column<string>(type: "longtext", nullable: true)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Manufacturer = table.Column<string>(type: "longtext", nullable: true)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Model = table.Column<string>(type: "longtext", nullable: true)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Brand = table.Column<string>(type: "longtext", nullable: true)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Status = table.Column<int>(type: "int", nullable: false),
|
||||
OwnDeviceCount = table.Column<int>(type: "int", nullable: false),
|
||||
OnlineDeviceCount = table.Column<int>(type: "int", nullable: false),
|
||||
OfflineDeviceCount = table.Column<int>(type: "int", nullable: false),
|
||||
NotActiveDeviceCount = table.Column<int>(type: "int", nullable: false),
|
||||
CommunicationAddress = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "通讯服务地址")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CommunicationAddressTLS = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "TLS通讯服务地址")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CreationTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||
CreatorId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
LastModificationTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
LastModifierId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
IsDeleted = table.Column<bool>(type: "tinyint(1)", nullable: false, defaultValue: false),
|
||||
DeleterId = table.Column<Guid>(type: "char(36)", nullable: true, collation: "ascii_general_ci"),
|
||||
DeletionTime = table.Column<DateTime>(type: "datetime(6)", nullable: true),
|
||||
TenantId = table.Column<Guid>(type: "char(36)", nullable: true, comment: "租户ID", collation: "ascii_general_ci"),
|
||||
Remark = table.Column<string>(type: "longtext", nullable: true, comment: "备注")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
OSACreatorId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权创建者Id"),
|
||||
OSALastModifierId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后修改者Id"),
|
||||
OSADeleterId = table.Column<int>(type: "int", nullable: true, comment: "旧系统授权最后删除者Id"),
|
||||
ExtraProperties = table.Column<string>(type: "longtext", nullable: true, comment: "扩展属性,用于存储自定义字段,JSON格式")
|
||||
.Annotation("MySql:CharSet", "utf8mb4")
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ServiceProOneNETProductInfo", x => x.Id);
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ServiceProTextTemplates",
|
||||
columns: table => new
|
||||
@ -1553,6 +1748,28 @@ namespace JiShe.IoT.Migrations
|
||||
table: "AbpUsers",
|
||||
column: "UserName");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProCTWingAccountInfo_CreationTime",
|
||||
table: "ServiceProCTWingAccountInfo",
|
||||
column: "CreationTime");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProCTWingAccountInfo_IsNotUniqueKey",
|
||||
table: "ServiceProCTWingAccountInfo",
|
||||
columns: new[] { "Id", "AccountId", "AccountName", "CreationTime" },
|
||||
descending: new bool[0]);
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProCTWingPrivateProductInfo_CreationTime",
|
||||
table: "ServiceProCTWingPrivateProductInfo",
|
||||
column: "CreationTime");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProCTWingPrivateProductInfo_IsNotUniqueKey",
|
||||
table: "ServiceProCTWingPrivateProductInfo",
|
||||
columns: new[] { "Id", "IoTPlatformProductId", "ProductName", "CreationTime" },
|
||||
descending: new bool[0]);
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProFocusInfo_CreationTime",
|
||||
table: "ServiceProFocusInfo",
|
||||
@ -1561,7 +1778,7 @@ namespace JiShe.IoT.Migrations
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProFocusInfo_IsNotUniqueKey",
|
||||
table: "ServiceProFocusInfo",
|
||||
columns: new[] { "Id", "FocusAddress", "ProjectID", "FocusId", "CreationTime" },
|
||||
columns: new[] { "Id", "FocusAddress", "CreationTime" },
|
||||
descending: new bool[0]);
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
@ -1577,7 +1794,7 @@ namespace JiShe.IoT.Migrations
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProMeterInfo_IsNotUniqueKey",
|
||||
table: "ServiceProMeterInfo",
|
||||
columns: new[] { "Id", "MeterAddress", "FocusAddress", "ProjectID", "FocusId", "CreationTime" },
|
||||
columns: new[] { "Id", "MeterAddress", "FocusAddress", "CreationTime" },
|
||||
descending: new bool[0]);
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
@ -1585,6 +1802,28 @@ namespace JiShe.IoT.Migrations
|
||||
table: "ServiceProMeterInfo",
|
||||
column: "MeterAddress");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProOneNETAccountInfo_CreationTime",
|
||||
table: "ServiceProOneNETAccountInfo",
|
||||
column: "CreationTime");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProOneNETAccountInfo_IsNotUniqueKey",
|
||||
table: "ServiceProOneNETAccountInfo",
|
||||
columns: new[] { "Id", "OneNETAccountId", "AccountName", "PhoneNumber", "CreationTime" },
|
||||
descending: new bool[0]);
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProOneNETProductInfo_CreationTime",
|
||||
table: "ServiceProOneNETProductInfo",
|
||||
column: "CreationTime");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProOneNETProductInfo_IsNotUniqueKey",
|
||||
table: "ServiceProOneNETProductInfo",
|
||||
columns: new[] { "Id", "IoTPlatformProductId", "ProductName", "CreationTime" },
|
||||
descending: new bool[0]);
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceProTextTemplates_Code",
|
||||
table: "ServiceProTextTemplates",
|
||||
@ -1689,6 +1928,12 @@ namespace JiShe.IoT.Migrations
|
||||
migrationBuilder.DropTable(
|
||||
name: "AbpUserTokens");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceProCTWingAccountInfo");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceProCTWingPrivateProductInfo");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceProFocusInfo");
|
||||
|
||||
@ -1698,6 +1943,12 @@ namespace JiShe.IoT.Migrations
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceProMeterInfo");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceProOneNETAccountInfo");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceProOneNETProductInfo");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceProTextTemplates");
|
||||
|
||||
@ -106,6 +106,280 @@ namespace JiShe.IoT.Migrations
|
||||
b.ToTable("ServiceProUserRefreshTokens", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.CTWingManagement.CTWingAccount.CTWingAccountInfo", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<string>("AccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账号ID");
|
||||
|
||||
b.Property<string>("AccountName")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("账号名称");
|
||||
|
||||
b.Property<string>("CommunicationAddress")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("通讯服务地址");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("PhoneNumber")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("手机号码");
|
||||
|
||||
b.Property<string>("PlatformTenantId")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("平台租户ID");
|
||||
|
||||
b.Property<int>("ProductCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "AccountId", "AccountName", "CreationTime" }, "IX_ServiceProCTWingAccountInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProCTWingAccountInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.CTWingManagement.CTWingProduct.CTWingPrivateProductInfo", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<int>("AccessType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("AuthType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("CTWingAccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账号ID");
|
||||
|
||||
b.Property<string>("CommunicationAddress")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("通讯服务地址");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<int>("DataEncryption")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<int>("DeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("DeviceThingModelUrl")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("设备物模型文件管理地址");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<int>("IoTPlatformProductId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<bool>("IsEnabled")
|
||||
.HasColumnType("tinyint(1)");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<string>("MasterKey")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("主密钥");
|
||||
|
||||
b.Property<int>("NetworkType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("NodeType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("ProductDesc")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("必填,产品描述");
|
||||
|
||||
b.Property<string>("ProductName")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("产品名称");
|
||||
|
||||
b.Property<int>("ProductProtocol")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("ProductType")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("一级分类名");
|
||||
|
||||
b.Property<string>("Protocol")
|
||||
.HasMaxLength(20)
|
||||
.HasColumnType("varchar(20)")
|
||||
.HasComment("通讯协议");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<string>("SecondaryType")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("二级分类名");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.Property<string>("ThirdType")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("三级分类名");
|
||||
|
||||
b.Property<string>("TupDeviceModel")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("设备型号");
|
||||
|
||||
b.Property<int>("TupIsThrough")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "IoTPlatformProductId", "ProductName", "CreationTime" }, "IX_ServiceProCTWingPrivateProductInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProCTWingPrivateProductInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.DataDictionaryManagement.DataDictionaries.Aggregates.DataDictionary", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
@ -285,10 +559,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器型号");
|
||||
|
||||
b.Property<long>("FocusId")
|
||||
.HasColumnType("bigint")
|
||||
.HasComment("集中器ID");
|
||||
|
||||
b.Property<string>("HardwareReleaseDate")
|
||||
.HasMaxLength(80)
|
||||
.HasColumnType("varchar(80)")
|
||||
@ -307,13 +577,15 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("int")
|
||||
.HasComment("物联网平台类型,默认没有指定");
|
||||
|
||||
b.Property<string>("IoTPlatformDeviceOpenId")
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
b.Property<string>("IoTPlatformDeviceOpenInfo")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中的设备ID");
|
||||
|
||||
b.Property<string>("IoTPlatformProductId")
|
||||
.HasColumnType("longtext");
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中对应的产品Id");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
@ -362,14 +634,10 @@ namespace JiShe.IoT.Migrations
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("PlatformPassword")
|
||||
.HasMaxLength(80)
|
||||
.HasColumnType("varchar(80)")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("物联网平台设备密码");
|
||||
|
||||
b.Property<int>("ProjectID")
|
||||
.HasColumnType("int")
|
||||
.HasComment("项目ID");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
@ -415,7 +683,7 @@ namespace JiShe.IoT.Migrations
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "FocusAddress", "ProjectID", "FocusId", "CreationTime" }, "IX_ServiceProFocusInfo_IsNotUniqueKey")
|
||||
b.HasIndex(new[] { "Id", "FocusAddress", "CreationTime" }, "IX_ServiceProFocusInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProFocusInfo", (string)null);
|
||||
@ -472,15 +740,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<string>("DataTypes")
|
||||
.HasMaxLength(5000)
|
||||
.HasColumnType("varchar(5000)")
|
||||
.HasComment("采集项编号ID");
|
||||
|
||||
b.Property<int>("DatabaseBusiID")
|
||||
.HasColumnType("int")
|
||||
.HasComment("业务库ID");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
@ -508,10 +767,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(20)")
|
||||
.HasComment("集中器地址");
|
||||
|
||||
b.Property<int>("FocusId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("集中器ID");
|
||||
|
||||
b.Property<int>("FunctionCount")
|
||||
.HasColumnType("int")
|
||||
.HasComment("功能数量(包含采集项和阀控等)");
|
||||
@ -524,17 +779,24 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("是否带阀控");
|
||||
|
||||
b.Property<string>("IoTPlatformDeviceOpenInfo")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中对应的设备Id或者名称");
|
||||
|
||||
b.Property<string>("IoTPlatformProductId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("集中器在物联网平台中对应的产品Id");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<string>("ItemCodes")
|
||||
.HasMaxLength(5000)
|
||||
.HasColumnType("varchar(5000)")
|
||||
.HasComment("采集项编码");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
@ -554,10 +816,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasComment("表计地址");
|
||||
|
||||
b.Property<int>("MeterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("表计ID");
|
||||
|
||||
b.Property<string>("MeterName")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
@ -599,9 +857,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("密码");
|
||||
|
||||
b.Property<int>("ProjectID")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("Protocol")
|
||||
.HasColumnType("int")
|
||||
.HasComment("协议类型");
|
||||
@ -614,10 +869,6 @@ namespace JiShe.IoT.Migrations
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("是否自研");
|
||||
|
||||
b.Property<bool>("SingleRate")
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("是否单倍率");
|
||||
|
||||
b.Property<int>("Special")
|
||||
.HasColumnType("int")
|
||||
.HasComment("是否特殊表");
|
||||
@ -652,7 +903,7 @@ namespace JiShe.IoT.Migrations
|
||||
|
||||
b.HasIndex("MeterAddress");
|
||||
|
||||
b.HasIndex(new[] { "Id", "MeterAddress", "FocusAddress", "ProjectID", "FocusId", "CreationTime" }, "IX_ServiceProMeterInfo_IsNotUniqueKey")
|
||||
b.HasIndex(new[] { "Id", "MeterAddress", "FocusAddress", "CreationTime" }, "IX_ServiceProMeterInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProMeterInfo", (string)null);
|
||||
@ -1193,6 +1444,275 @@ namespace JiShe.IoT.Migrations
|
||||
b.ToTable("AbpNotificationSubscriptions", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.OneNETManagement.OneNETAccounts.OneNETAccountInfos", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<string>("Accesskey")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账户通信密钥,平台可以重置密钥");
|
||||
|
||||
b.Property<string>("AccountName")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("账号名称");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<string>("OneNETAccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账户Id");
|
||||
|
||||
b.Property<string>("PhoneNumber")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("手机号码");
|
||||
|
||||
b.Property<int>("ProductCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "OneNETAccountId", "AccountName", "PhoneNumber", "CreationTime" }, "IX_ServiceProOneNETAccountInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProOneNETAccountInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.OneNETManagement.OneNETProducts.OneNETProductInfos", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<int>("AccessProtocol")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("Brand")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<string>("CommunicationAddress")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("通讯服务地址");
|
||||
|
||||
b.Property<string>("CommunicationAddressTLS")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("TLS通讯服务地址");
|
||||
|
||||
b.Property<string>("ConcurrencyStamp")
|
||||
.IsConcurrencyToken()
|
||||
.IsRequired()
|
||||
.HasMaxLength(40)
|
||||
.HasColumnType("varchar(40)")
|
||||
.HasColumnName("ConcurrencyStamp");
|
||||
|
||||
b.Property<DateTime>("CreationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("CreationTime");
|
||||
|
||||
b.Property<Guid?>("CreatorId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("CreatorId");
|
||||
|
||||
b.Property<int>("DataProtocol")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<Guid?>("DeleterId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("DeleterId");
|
||||
|
||||
b.Property<DateTime?>("DeletionTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("DeletionTime");
|
||||
|
||||
b.Property<string>("DeviceThingModelUrl")
|
||||
.HasMaxLength(256)
|
||||
.HasColumnType("varchar(256)")
|
||||
.HasComment("设备物模型文件管理地址");
|
||||
|
||||
b.Property<string>("ExtraProperties")
|
||||
.HasColumnType("longtext")
|
||||
.HasColumnName("ExtraProperties")
|
||||
.HasComment("扩展属性,用于存储自定义字段,JSON格式");
|
||||
|
||||
b.Property<string>("IoTPlatformProductId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("物联网平台对应的产品Id");
|
||||
|
||||
b.Property<bool>("IsDeleted")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasDefaultValue(false)
|
||||
.HasColumnName("IsDeleted");
|
||||
|
||||
b.Property<bool>("IsEnabled")
|
||||
.HasColumnType("tinyint(1)");
|
||||
|
||||
b.Property<bool>("IsEncrypted")
|
||||
.HasColumnType("tinyint(1)");
|
||||
|
||||
b.Property<DateTime?>("LastModificationTime")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasColumnName("LastModificationTime");
|
||||
|
||||
b.Property<Guid?>("LastModifierId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("LastModifierId");
|
||||
|
||||
b.Property<string>("Manufacturer")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<string>("Model")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<string>("Network")
|
||||
.HasColumnType("longtext");
|
||||
|
||||
b.Property<int>("NodeType")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("NotActiveDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int?>("OSACreatorId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权创建者Id");
|
||||
|
||||
b.Property<int?>("OSADeleterId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后删除者Id");
|
||||
|
||||
b.Property<int?>("OSALastModifierId")
|
||||
.HasColumnType("int")
|
||||
.HasComment("旧系统授权最后修改者Id");
|
||||
|
||||
b.Property<int>("OfflineDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("OneNETAccountId")
|
||||
.IsRequired()
|
||||
.HasMaxLength(50)
|
||||
.HasColumnType("varchar(50)")
|
||||
.HasComment("账户Id");
|
||||
|
||||
b.Property<int>("OnlineDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("OwnDeviceCount")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("ProductAccesskey")
|
||||
.IsRequired()
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("产品访问密钥");
|
||||
|
||||
b.Property<DateTime>("ProductCreateTime")
|
||||
.HasColumnType("datetime(6)");
|
||||
|
||||
b.Property<string>("ProductName")
|
||||
.HasMaxLength(128)
|
||||
.HasColumnType("varchar(128)")
|
||||
.HasComment("产品名称");
|
||||
|
||||
b.Property<DateTime>("ProductUpdateTime")
|
||||
.HasColumnType("datetime(6)");
|
||||
|
||||
b.Property<string>("Remark")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("备注");
|
||||
|
||||
b.Property<int>("Status")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<Guid?>("TenantId")
|
||||
.HasColumnType("char(36)")
|
||||
.HasColumnName("TenantId")
|
||||
.HasComment("租户ID");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CreationTime");
|
||||
|
||||
b.HasIndex(new[] { "Id", "IoTPlatformProductId", "ProductName", "CreationTime" }, "IX_ServiceProOneNETProductInfo_IsNotUniqueKey")
|
||||
.IsDescending();
|
||||
|
||||
b.ToTable("ServiceProOneNETProductInfo", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("JiShe.ServicePro.TemplateManagement.TextTemplates.TextTemplate", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user