diff --git a/IoTSharp.Data.Storage/IoTSharp.Data.MySQL/Migrations/20221109174343_addflowexfield.Designer.cs b/IoTSharp.Data.Storage/IoTSharp.Data.MySQL/Migrations/20221109174343_addflowexfield.Designer.cs
new file mode 100644
index 000000000..4c58d3884
--- /dev/null
+++ b/IoTSharp.Data.Storage/IoTSharp.Data.MySQL/Migrations/20221109174343_addflowexfield.Designer.cs
@@ -0,0 +1,2644 @@
+//
+using System;
+using IoTSharp.Data;
+using Microsoft.EntityFrameworkCore;
+using Microsoft.EntityFrameworkCore.Infrastructure;
+using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
+
+#nullable disable
+
+namespace IoTSharp.Data.MySql.Migrations
+{
+ [DbContext(typeof(ApplicationDbContext))]
+ [Migration("20221109174343_addflowexfield")]
+ partial class addflowexfield
+ {
+ protected override void BuildTargetModel(ModelBuilder modelBuilder)
+ {
+#pragma warning disable 612, 618
+ modelBuilder
+ .HasAnnotation("ProductVersion", "6.0.10")
+ .HasAnnotation("Relational:MaxIdentifierLength", 64);
+
+ modelBuilder.Entity("IoTSharp.Data.Alarm", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("AckDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("AlarmDetail")
+ .HasColumnType("longtext");
+
+ b.Property("AlarmStatus")
+ .HasColumnType("int");
+
+ b.Property("AlarmType")
+ .HasColumnType("longtext");
+
+ b.Property("ClearDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("EndDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("OriginatorId")
+ .HasColumnType("char(36)");
+
+ b.Property("OriginatorType")
+ .HasColumnType("int");
+
+ b.Property("Propagate")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Serverity")
+ .HasColumnType("int");
+
+ b.Property("StartDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("Alarms");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.Asset", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("AssetType")
+ .HasColumnType("longtext");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("Deleted")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Description")
+ .HasColumnType("longtext");
+
+ b.Property("Name")
+ .HasColumnType("longtext");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("Assets");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.AssetRelation", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("AssetId")
+ .HasColumnType("char(36)");
+
+ b.Property("DataCatalog")
+ .HasColumnType("int");
+
+ b.Property("Description")
+ .HasColumnType("longtext");
+
+ b.Property("DeviceId")
+ .HasColumnType("char(36)");
+
+ b.Property("KeyName")
+ .HasColumnType("longtext");
+
+ b.Property("Name")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("AssetId");
+
+ b.ToTable("AssetRelations");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.AuditLog", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("ActionData")
+ .HasColumnType("JSON");
+
+ b.Property("ActionName")
+ .HasColumnType("longtext");
+
+ b.Property("ActionResult")
+ .HasColumnType("JSON");
+
+ b.Property("ActiveDateTime")
+ .HasColumnType("timestamp");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("ObjectID")
+ .HasColumnType("char(36)");
+
+ b.Property("ObjectName")
+ .HasColumnType("longtext");
+
+ b.Property("ObjectType")
+ .HasColumnType("int");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.Property("UserId")
+ .HasColumnType("longtext");
+
+ b.Property("UserName")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("AuditLog");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.AuthorizedKey", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("AuthToken")
+ .HasColumnType("longtext");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("Deleted")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Name")
+ .HasColumnType("longtext");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("AuthorizedKeys");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.BaseDictionary", b =>
+ {
+ b.Property("DictionaryId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("bigint");
+
+ b.Property("Dictionary18NKeyName")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryColor")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryDesc")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryGroupId")
+ .HasColumnType("bigint");
+
+ b.Property("DictionaryIcon")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryName")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryPattern")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryStatus")
+ .HasColumnType("int");
+
+ b.Property("DictionaryTag")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryValue")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryValueType")
+ .HasColumnType("int");
+
+ b.Property("DictionaryValueTypeName")
+ .HasColumnType("longtext");
+
+ b.HasKey("DictionaryId");
+
+ b.ToTable("BaseDictionaries");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.BaseDictionaryGroup", b =>
+ {
+ b.Property("DictionaryGroupId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("bigint");
+
+ b.Property("DictionaryGroup18NKeyName")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryGroupDesc")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryGroupKey")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryGroupName")
+ .HasColumnType("longtext");
+
+ b.Property("DictionaryGroupStatus")
+ .HasColumnType("int");
+
+ b.Property("DictionaryGroupValueType")
+ .HasColumnType("int");
+
+ b.Property("DictionaryGroupValueTypeName")
+ .HasColumnType("longtext");
+
+ b.HasKey("DictionaryGroupId");
+
+ b.ToTable("BaseDictionaryGroups");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.BaseEvent", b =>
+ {
+ b.Property("EventId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("BizData")
+ .HasColumnType("longtext");
+
+ b.Property("Bizid")
+ .HasColumnType("longtext");
+
+ b.Property("CreaterDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("char(36)");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("EventDesc")
+ .HasColumnType("longtext");
+
+ b.Property("EventName")
+ .HasColumnType("longtext");
+
+ b.Property("EventStaus")
+ .HasColumnType("int");
+
+ b.Property("FlowRuleRuleId")
+ .HasColumnType("char(36)");
+
+ b.Property("MataData")
+ .HasColumnType("longtext");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.Property("Type")
+ .HasColumnType("int");
+
+ b.HasKey("EventId");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("FlowRuleRuleId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("BaseEvents");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.BaseI18N", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("bigint");
+
+ b.Property("AddDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("KeyName")
+ .HasColumnType("longtext");
+
+ b.Property("ResouceDesc")
+ .HasColumnType("longtext");
+
+ b.Property("ResouceGroupId")
+ .HasColumnType("int");
+
+ b.Property("ResourceId")
+ .HasColumnType("bigint");
+
+ b.Property("ResourceKey")
+ .HasColumnType("longtext");
+
+ b.Property("ResourceTag")
+ .HasColumnType("longtext");
+
+ b.Property("ResourceType")
+ .HasColumnType("int");
+
+ b.Property("Status")
+ .HasColumnType("int");
+
+ b.Property("UserId")
+ .HasColumnType("char(36)");
+
+ b.Property("ValueBG")
+ .HasColumnType("longtext");
+
+ b.Property("ValueCS")
+ .HasColumnType("longtext");
+
+ b.Property("ValueDA")
+ .HasColumnType("longtext");
+
+ b.Property("ValueDEDE")
+ .HasColumnType("longtext");
+
+ b.Property("ValueELGR")
+ .HasColumnType("longtext");
+
+ b.Property("ValueENGR")
+ .HasColumnType("longtext");
+
+ b.Property("ValueENUS")
+ .HasColumnType("longtext");
+
+ b.Property("ValueESES")
+ .HasColumnType("longtext");
+
+ b.Property("ValueFI")
+ .HasColumnType("longtext");
+
+ b.Property("ValueFRFR")
+ .HasColumnType("longtext");
+
+ b.Property("ValueHE")
+ .HasColumnType("longtext");
+
+ b.Property("ValueHRHR")
+ .HasColumnType("longtext");
+
+ b.Property("ValueHU")
+ .HasColumnType("longtext");
+
+ b.Property("ValueITIT")
+ .HasColumnType("longtext");
+
+ b.Property("ValueJAJP")
+ .HasColumnType("longtext");
+
+ b.Property("ValueKOKR")
+ .HasColumnType("longtext");
+
+ b.Property("ValueNL")
+ .HasColumnType("longtext");
+
+ b.Property("ValuePLPL")
+ .HasColumnType("longtext");
+
+ b.Property("ValuePT")
+ .HasColumnType("longtext");
+
+ b.Property("ValueSLSL")
+ .HasColumnType("longtext");
+
+ b.Property("ValueSR")
+ .HasColumnType("longtext");
+
+ b.Property("ValueSV")
+ .HasColumnType("longtext");
+
+ b.Property("ValueTRTR")
+ .HasColumnType("longtext");
+
+ b.Property("ValueUK")
+ .HasColumnType("longtext");
+
+ b.Property("ValueVI")
+ .HasColumnType("longtext");
+
+ b.Property("ValueZHCN")
+ .HasColumnType("longtext");
+
+ b.Property("ValueZHTW")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.ToTable("BaseI18Ns");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.Customer", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("Address")
+ .HasColumnType("longtext");
+
+ b.Property("City")
+ .HasColumnType("longtext");
+
+ b.Property("Country")
+ .HasColumnType("longtext");
+
+ b.Property("Deleted")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Email")
+ .HasColumnType("longtext");
+
+ b.Property("Name")
+ .HasColumnType("longtext");
+
+ b.Property("Phone")
+ .HasColumnType("longtext");
+
+ b.Property("Province")
+ .HasColumnType("longtext");
+
+ b.Property("Street")
+ .HasColumnType("longtext");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.Property("ZipCode")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("Customer");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DataStorage", b =>
+ {
+ b.Property("Catalog")
+ .HasColumnType("int")
+ .HasColumnOrder(0);
+
+ b.Property("DeviceId")
+ .HasColumnType("char(36)")
+ .HasColumnOrder(1);
+
+ b.Property("KeyName")
+ .HasColumnType("varchar(255)")
+ .HasColumnOrder(2);
+
+ b.Property("DataSide")
+ .HasColumnType("int")
+ .HasColumnOrder(4);
+
+ b.Property("DateTime")
+ .HasColumnType("timestamp")
+ .HasColumnOrder(3);
+
+ b.Property("Type")
+ .HasColumnType("int")
+ .HasColumnOrder(5);
+
+ b.Property("Value_Binary")
+ .HasColumnType("longblob");
+
+ b.Property("Value_Boolean")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Value_DateTime")
+ .HasColumnType("timestamp");
+
+ b.Property("Value_Double")
+ .HasColumnType("double");
+
+ b.Property("Value_Json")
+ .HasColumnType("JSON");
+
+ b.Property("Value_Long")
+ .HasColumnType("bigint");
+
+ b.Property("Value_String")
+ .HasColumnType("longtext");
+
+ b.Property("Value_XML")
+ .HasColumnType("longtext");
+
+ b.HasKey("Catalog", "DeviceId", "KeyName");
+
+ b.HasIndex("Catalog");
+
+ b.HasIndex("Catalog", "DeviceId");
+
+ b.ToTable("DataStorage");
+
+ b.HasDiscriminator("Catalog").HasValue(0);
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.Device", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("AuthorizedKeyId")
+ .HasColumnType("char(36)");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("Deleted")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("DeviceModelId")
+ .HasColumnType("char(36)");
+
+ b.Property("DeviceType")
+ .HasColumnType("int");
+
+ b.Property("Name")
+ .HasColumnType("longtext");
+
+ b.Property("OwnerId")
+ .HasColumnType("char(36)");
+
+ b.Property("ProduceId")
+ .HasColumnType("char(36)");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.Property("Timeout")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("AuthorizedKeyId");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("OwnerId");
+
+ b.HasIndex("ProduceId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("Device");
+
+ b.HasDiscriminator("DeviceType").HasValue(0);
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DeviceDiagram", b =>
+ {
+ b.Property("DiagramId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("CreateDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("char(36)");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("DiagramDesc")
+ .HasColumnType("longtext");
+
+ b.Property("DiagramImage")
+ .HasColumnType("longtext");
+
+ b.Property("DiagramName")
+ .HasColumnType("longtext");
+
+ b.Property("DiagramStatus")
+ .HasColumnType("int");
+
+ b.Property("IsDefault")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.HasKey("DiagramId");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("DeviceDiagrams");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DeviceGraph", b =>
+ {
+ b.Property("GraphId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("CreateDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("char(36)");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("DeviceDiagramDiagramId")
+ .HasColumnType("char(36)");
+
+ b.Property("DeviceId")
+ .HasColumnType("char(36)");
+
+ b.Property("GraphElementId")
+ .HasColumnType("longtext");
+
+ b.Property("GraphFill")
+ .HasColumnType("longtext");
+
+ b.Property("GraphHeight")
+ .HasColumnType("int");
+
+ b.Property("GraphPostionX")
+ .HasColumnType("int");
+
+ b.Property("GraphPostionY")
+ .HasColumnType("int");
+
+ b.Property("GraphShape")
+ .HasColumnType("longtext");
+
+ b.Property("GraphStroke")
+ .HasColumnType("longtext");
+
+ b.Property("GraphStrokeWidth")
+ .HasColumnType("int");
+
+ b.Property("GraphTextAnchor")
+ .HasColumnType("longtext");
+
+ b.Property("GraphTextFill")
+ .HasColumnType("longtext");
+
+ b.Property("GraphTextFontFamily")
+ .HasColumnType("longtext");
+
+ b.Property("GraphTextFontSize")
+ .HasColumnType("int");
+
+ b.Property("GraphTextRefX")
+ .HasColumnType("int");
+
+ b.Property("GraphTextRefY")
+ .HasColumnType("int");
+
+ b.Property("GraphTextVerticalAnchor")
+ .HasColumnType("longtext");
+
+ b.Property("GraphWidth")
+ .HasColumnType("int");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.HasKey("GraphId");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("DeviceDiagramDiagramId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("DeviceGraphs");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DeviceGraphToolBox", b =>
+ {
+ b.Property("ToolBoxId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("CommondParam")
+ .HasColumnType("longtext");
+
+ b.Property("CommondType")
+ .HasColumnType("longtext");
+
+ b.Property("CreateDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("char(36)");
+
+ b.Property("CustomerId")
+ .HasColumnType("char(36)");
+
+ b.Property("DeviceId")
+ .HasColumnType("bigint");
+
+ b.Property("TenantId")
+ .HasColumnType("char(36)");
+
+ b.Property("ToolBoxIcon")
+ .HasColumnType("longtext");
+
+ b.Property("ToolBoxName")
+ .HasColumnType("longtext");
+
+ b.Property("ToolBoxOffsetLeftPer")
+ .HasColumnType("int");
+
+ b.Property("ToolBoxOffsetTopPer")
+ .HasColumnType("int");
+
+ b.Property("ToolBoxOffsetX")
+ .HasColumnType("int");
+
+ b.Property("ToolBoxOffsetY")
+ .HasColumnType("int");
+
+ b.Property("ToolBoxRequestUri")
+ .HasColumnType("longtext");
+
+ b.Property("ToolBoxStatus")
+ .HasColumnType("int");
+
+ b.Property("ToolBoxType")
+ .HasColumnType("longtext");
+
+ b.HasKey("ToolBoxId");
+
+ b.HasIndex("CustomerId");
+
+ b.HasIndex("TenantId");
+
+ b.ToTable("DeviceGraphToolBoxes");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DeviceIdentity", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("DeviceId")
+ .HasColumnType("char(36)");
+
+ b.Property("IdentityId")
+ .IsRequired()
+ .HasColumnType("longtext");
+
+ b.Property("IdentityType")
+ .HasColumnType("int");
+
+ b.Property("IdentityValue")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("DeviceId")
+ .IsUnique();
+
+ b.ToTable("DeviceIdentities");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DeviceModel", b =>
+ {
+ b.Property("DeviceModelId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("CreateDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("char(36)");
+
+ b.Property("ModelDesc")
+ .HasColumnType("longtext");
+
+ b.Property("ModelName")
+ .HasColumnType("longtext");
+
+ b.Property("ModelStatus")
+ .HasColumnType("int");
+
+ b.HasKey("DeviceModelId");
+
+ b.ToTable("DeviceModels");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DeviceModelCommand", b =>
+ {
+ b.Property("CommandId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("CommandI18N")
+ .HasColumnType("longtext");
+
+ b.Property("CommandName")
+ .HasColumnType("longtext");
+
+ b.Property("CommandParams")
+ .HasColumnType("longtext");
+
+ b.Property("CommandStatus")
+ .HasColumnType("int");
+
+ b.Property("CommandTemplate")
+ .HasColumnType("longtext");
+
+ b.Property("CommandTitle")
+ .HasColumnType("longtext");
+
+ b.Property("CommandType")
+ .HasColumnType("int");
+
+ b.Property("CreateDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("char(36)");
+
+ b.Property("DeviceModelId")
+ .HasColumnType("char(36)");
+
+ b.HasKey("CommandId");
+
+ b.HasIndex("DeviceModelId");
+
+ b.ToTable("DeviceModelCommands");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DevicePort", b =>
+ {
+ b.Property("PortId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("CreateDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("bigint");
+
+ b.Property("DeviceId")
+ .HasColumnType("char(36)");
+
+ b.Property("PortDesc")
+ .HasColumnType("longtext");
+
+ b.Property("PortElementId")
+ .HasColumnType("longtext");
+
+ b.Property("PortName")
+ .HasColumnType("longtext");
+
+ b.Property("PortPhyType")
+ .HasColumnType("int");
+
+ b.Property("PortPic")
+ .HasColumnType("longtext");
+
+ b.Property("PortStatus")
+ .HasColumnType("int");
+
+ b.Property("PortType")
+ .HasColumnType("int");
+
+ b.HasKey("PortId");
+
+ b.ToTable("DevicePorts");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DevicePortMapping", b =>
+ {
+ b.Property("MappingId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("CreateDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Creator")
+ .HasColumnType("char(36)");
+
+ b.Property("MappingIndex")
+ .HasColumnType("int");
+
+ b.Property("MappingStatus")
+ .HasColumnType("int");
+
+ b.Property("SourceDeviceId")
+ .HasColumnType("char(36)");
+
+ b.Property("SourceElementId")
+ .HasColumnType("longtext");
+
+ b.Property("SourceId")
+ .HasColumnType("longtext");
+
+ b.Property("TargeId")
+ .HasColumnType("longtext");
+
+ b.Property("TargetDeviceId")
+ .HasColumnType("char(36)");
+
+ b.Property("TargetElementId")
+ .HasColumnType("longtext");
+
+ b.HasKey("MappingId");
+
+ b.ToTable("DevicePortMappings");
+ });
+
+ modelBuilder.Entity("IoTSharp.Data.DeviceRule", b =>
+ {
+ b.Property("DeviceRuleId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("char(36)");
+
+ b.Property("ConfigDateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("ConfigUser")
+ .HasColumnType("char(36)");
+
+ b.Property