diff --git a/Resources/ChangeLog.html b/Resources/ChangeLog.html
index 2f3a1ac..020521a 100644
--- a/Resources/ChangeLog.html
+++ b/Resources/ChangeLog.html
@@ -1,6 +1,6 @@
WebDoorCreator - Egalware
- Version: 0.9.2307.2109
+ Version: 0.9.2307.2116
Release note:
-
diff --git a/Resources/VersNum.txt b/Resources/VersNum.txt
index 9c9e1a6..bcab6ec 100644
--- a/Resources/VersNum.txt
+++ b/Resources/VersNum.txt
@@ -1 +1 @@
-0.9.2307.2109
+0.9.2307.2116
diff --git a/Resources/manifest.xml b/Resources/manifest.xml
index b05a392..ae98d72 100644
--- a/Resources/manifest.xml
+++ b/Resources/manifest.xml
@@ -1,6 +1,6 @@
-
- 0.9.2307.2109
+ 0.9.2307.2116
http://nexus.steamware.net/repository/SWS/WDC/stable/WDC.UI.zip
http://nexus.steamware.net/repository/SWS/WDC/stable/ChangeLog.html
false
diff --git a/WebDoorCreator.Data/DbModels/IdentityTableSeedTest.cs b/WebDoorCreator.Data/DbModels/IdentityTableSeedTest.cs
new file mode 100644
index 0000000..13840ca
--- /dev/null
+++ b/WebDoorCreator.Data/DbModels/IdentityTableSeedTest.cs
@@ -0,0 +1,23 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel.DataAnnotations;
+using System.ComponentModel.DataAnnotations.Schema;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace WebDoorCreator.Data.DbModels
+{
+ [Table("TestTable")]
+ public class IdentityTableSeedTest
+ {
+ [Key, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
+ public int IdUni { get; set; } = 0;
+
+ [MaxLength(50)]
+ public string Campo1 { get; set; } = "";
+
+ [MaxLength(500)]
+ public string Campo2 { get; set; } = "";
+ }
+}
diff --git a/WebDoorCreator.Data/Migrations/WDCData/20230721130731_AddIdTestTable.Designer.cs b/WebDoorCreator.Data/Migrations/WDCData/20230721130731_AddIdTestTable.Designer.cs
new file mode 100644
index 0000000..e68a978
--- /dev/null
+++ b/WebDoorCreator.Data/Migrations/WDCData/20230721130731_AddIdTestTable.Designer.cs
@@ -0,0 +1,1114 @@
+//
+using System;
+using Microsoft.EntityFrameworkCore;
+using Microsoft.EntityFrameworkCore.Infrastructure;
+using Microsoft.EntityFrameworkCore.Metadata;
+using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
+using WebDoorCreator.Data;
+
+#nullable disable
+
+namespace WebDoorCreator.Data.Migrations.WDCData
+{
+ [DbContext(typeof(WDCDataContext))]
+ [Migration("20230721130731_AddIdTestTable")]
+ partial class AddIdTestTable
+ {
+ protected override void BuildTargetModel(ModelBuilder modelBuilder)
+ {
+#pragma warning disable 612, 618
+ modelBuilder
+ .UseCollation("Latin1_General_CI_AS")
+ .HasAnnotation("ProductVersion", "6.0.14")
+ .HasAnnotation("Relational:MaxIdentifierLength", 128);
+
+ SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1);
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.AspNetRoles", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("ConcurrencyStamp")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("NormalizedName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("Id");
+
+ b.ToTable("AspNetRoles", null, t => t.ExcludeFromMigrations());
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.AspNetUserRoles", b =>
+ {
+ b.Property("UserId")
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("RoleId")
+ .HasColumnType("nvarchar(450)");
+
+ b.HasKey("UserId", "RoleId");
+
+ b.HasIndex("RoleId");
+
+ b.ToTable("AspNetUserRoles", null, t => t.ExcludeFromMigrations());
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.AspNetUsers", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("AccessFailedCount")
+ .HasColumnType("int");
+
+ b.Property("ConcurrencyStamp")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Email")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("EmailConfirmed")
+ .HasColumnType("bit");
+
+ b.Property("LockoutEnabled")
+ .HasColumnType("bit");
+
+ b.Property("LockoutEnd")
+ .HasColumnType("datetimeoffset");
+
+ b.Property("NormalizedEmail")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("NormalizedUserName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("PasswordHash")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("PhoneNumber")
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("PhoneNumberConfirmed")
+ .HasColumnType("bit");
+
+ b.Property("SecurityStamp")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("TwoFactorEnabled")
+ .HasColumnType("bit");
+
+ b.Property("UserName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("Id");
+
+ b.ToTable("AspNetUsers", null, t => t.ExcludeFromMigrations());
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.CompanyModel", b =>
+ {
+ b.Property("CompanyId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("CompanyId"), 1L, 1);
+
+ b.Property("Address")
+ .IsRequired()
+ .HasMaxLength(250)
+ .HasColumnType("nvarchar(250)");
+
+ b.Property("City")
+ .IsRequired()
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("CompanyExtCode")
+ .IsRequired()
+ .HasMaxLength(250)
+ .HasColumnType("nvarchar(250)");
+
+ b.Property("CompanyName")
+ .IsRequired()
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.Property("CompanyToken")
+ .IsRequired()
+ .HasMaxLength(150)
+ .HasColumnType("nvarchar(150)");
+
+ b.Property("PrivateNote")
+ .IsRequired()
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.Property("State")
+ .IsRequired()
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("VAT")
+ .IsRequired()
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("ZipCode")
+ .HasColumnType("int");
+
+ b.HasKey("CompanyId");
+
+ b.ToTable("Company");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.ConfigModel", b =>
+ {
+ b.Property("chiave")
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("note")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("valore")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("valoreStd")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("chiave");
+
+ b.ToTable("Config");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.DoorModel", b =>
+ {
+ b.Property("DoorId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("DoorId"), 1L, 1);
+
+ b.Property("DateIns")
+ .HasColumnType("datetime2");
+
+ b.Property("DateLockExpiry")
+ .HasColumnType("datetime2");
+
+ b.Property("DateMod")
+ .HasColumnType("datetime2");
+
+ b.Property("DoorDescript")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("DoorExtCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("MeasureUnit")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("OrderId")
+ .HasColumnType("int");
+
+ b.Property("ParentId")
+ .HasColumnType("int");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.Property("UnitCost")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("UserIdIns")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserIdLock")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserIdMod")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("isLogicDel")
+ .HasColumnType("bit");
+
+ b.HasKey("DoorId");
+
+ b.HasIndex("OrderId");
+
+ b.ToTable("Door");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.DoorOpModel", b =>
+ {
+ b.Property("DoorOpId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("DoorOpId"), 1L, 1);
+
+ b.Property("DateIns")
+ .HasColumnType("datetime2");
+
+ b.Property("DateMod")
+ .HasColumnType("datetime2");
+
+ b.Property("Description")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("DoorId")
+ .HasColumnType("int");
+
+ b.Property("DtConfirm")
+ .HasColumnType("datetime2");
+
+ b.Property("JsoncActVal")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("JsoncConfigVal")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ObjectId")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserIdIns")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserIdMod")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("userConfirm")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("DoorOpId");
+
+ b.HasIndex("DoorId");
+
+ b.ToTable("DoorOp");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.DoorOpTypeModel", b =>
+ {
+ b.Property("DoorOpTypId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("DoorOpTypId"), 1L, 1);
+
+ b.Property("Description")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("DisplayUrl")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ExtDescript")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ExtOpCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("FPath")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("FileDim")
+ .HasColumnType("bigint");
+
+ b.Property("FileMD5")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("HasHw")
+ .HasColumnType("bit");
+
+ b.Property("HwCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("HwDescription")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("IsConcrete")
+ .HasColumnType("bit");
+
+ b.Property("IsDefault")
+ .HasColumnType("bit");
+
+ b.Property("LastMod")
+ .HasColumnType("datetime2");
+
+ b.Property("MaxAllowed")
+ .HasColumnType("int");
+
+ b.Property("OpCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ParentId")
+ .HasColumnType("int");
+
+ b.Property("Rev")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UnitCost")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("ValidFrom")
+ .HasColumnType("datetime2");
+
+ b.Property("ValidUntil")
+ .HasColumnType("datetime2");
+
+ b.HasKey("DoorOpTypId");
+
+ b.ToTable("DoorOpType");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.DoorOpTypeTempModel", b =>
+ {
+ b.Property("DoorOpTypId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("DoorOpTypId"), 1L, 1);
+
+ b.Property("Description")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("DisplayUrl")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ExtDescript")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ExtOpCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("FPath")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("FileDim")
+ .HasColumnType("bigint");
+
+ b.Property("FileMD5")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("HasHw")
+ .HasColumnType("bit");
+
+ b.Property("HwCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("HwDescription")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("IsConcrete")
+ .HasColumnType("bit");
+
+ b.Property("IsDefault")
+ .HasColumnType("bit");
+
+ b.Property("LastMod")
+ .HasColumnType("datetime2");
+
+ b.Property("MaxAllowed")
+ .HasColumnType("int");
+
+ b.Property("OpCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ParentDoorOpId")
+ .HasColumnType("int");
+
+ b.Property("Rev")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UnitCost")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("ValidFrom")
+ .HasColumnType("datetime2");
+
+ b.Property("ValidUntil")
+ .HasColumnType("datetime2");
+
+ b.HasKey("DoorOpTypId");
+
+ b.ToTable("DoorOpTypeTemp");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.GraphicParamsModel", b =>
+ {
+ b.Property("GraphicParamId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("GraphicParamId"), 1L, 1);
+
+ b.Property("compoId")
+ .HasColumnType("int");
+
+ b.Property("graphicParamAlias")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("graphicParamDefaultVal")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("graphicParamKey")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("graphicParamName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("graphicParamType")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("graphicParamsN")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("GraphicParamId");
+
+ b.ToTable("GraphicParams");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.HardwareModel", b =>
+ {
+ b.Property("HardwareId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("HardwareId"), 1L, 1);
+
+ b.Property("compoAlias")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("compoLayerName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("compoName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("compoTemplateIsActive")
+ .HasColumnType("bit");
+
+ b.HasKey("HardwareId");
+
+ b.ToTable("Hardware");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.IdentityTableSeedTest", b =>
+ {
+ b.Property("IdUni")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("Campo1")
+ .IsRequired()
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Campo2")
+ .IsRequired()
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.HasKey("IdUni");
+
+ b.ToTable("TestTable");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.LanguageModel", b =>
+ {
+ b.Property("CodLingua")
+ .HasMaxLength(5)
+ .HasColumnType("nvarchar(5)");
+
+ b.Property("DescrizioneLingua")
+ .IsRequired()
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.HasKey("CodLingua");
+
+ b.ToTable("Languages");
+
+ b.HasData(
+ new
+ {
+ CodLingua = "EN",
+ DescrizioneLingua = "English"
+ },
+ new
+ {
+ CodLingua = "IT",
+ DescrizioneLingua = "Italiano"
+ });
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.ListValuesModel", b =>
+ {
+ b.Property("TableName")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("FieldName")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Value")
+ .HasMaxLength(250)
+ .HasColumnType("nvarchar(250)");
+
+ b.Property("DefaultVal")
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("InputType")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Label")
+ .HasMaxLength(250)
+ .HasColumnType("nvarchar(250)");
+
+ b.Property("Ordinal")
+ .HasColumnType("int");
+
+ b.Property("isSerializable")
+ .HasMaxLength(5)
+ .HasColumnType("bit");
+
+ b.HasKey("TableName", "FieldName", "Value");
+
+ b.ToTable("ListValues");
+
+ b.HasData(
+ new
+ {
+ TableName = "Opening",
+ FieldName = "Swing",
+ Value = "LH",
+ Label = "Left Handed",
+ Ordinal = 1,
+ isSerializable = false
+ },
+ new
+ {
+ TableName = "Opening",
+ FieldName = "Swing",
+ Value = "RH",
+ Label = "Right Handed",
+ Ordinal = 2,
+ isSerializable = false
+ },
+ new
+ {
+ TableName = "Opening",
+ FieldName = "Swing",
+ Value = "LHR",
+ Label = "Left Handed Reverse",
+ Ordinal = 3,
+ isSerializable = false
+ },
+ new
+ {
+ TableName = "Opening",
+ FieldName = "Swing",
+ Value = "RHR",
+ Label = "Right Handed Reverse",
+ Ordinal = 4,
+ isSerializable = false
+ },
+ new
+ {
+ TableName = "Edges",
+ FieldName = "EdgeType",
+ Value = "BV",
+ Label = "Bevel",
+ Ordinal = 1,
+ isSerializable = false
+ },
+ new
+ {
+ TableName = "Edges",
+ FieldName = "EdgeType",
+ Value = "SQ",
+ Label = "Squared",
+ Ordinal = 2,
+ isSerializable = false
+ },
+ new
+ {
+ TableName = "Edges",
+ FieldName = "EdgeType",
+ Value = "1B",
+ Label = "Bull Nose 1",
+ Ordinal = 3,
+ isSerializable = false
+ });
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.ListValuesTempModel", b =>
+ {
+ b.Property("TableName")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("FieldName")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Value")
+ .HasMaxLength(250)
+ .HasColumnType("nvarchar(250)");
+
+ b.Property("DefaultVal")
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("InputType")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Label")
+ .HasMaxLength(250)
+ .HasColumnType("nvarchar(250)");
+
+ b.Property("Ordinal")
+ .HasColumnType("int");
+
+ b.Property("isSerializable")
+ .HasMaxLength(5)
+ .HasColumnType("bit");
+
+ b.HasKey("TableName", "FieldName", "Value");
+
+ b.ToTable("ListValuesTemp");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.OrderModel", b =>
+ {
+ b.Property("OrderId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("OrderId"), 1L, 1);
+
+ b.Property("CompanyId")
+ .HasColumnType("int");
+
+ b.Property("DateDelivery")
+ .HasColumnType("datetime2");
+
+ b.Property("DateIns")
+ .HasColumnType("datetime2");
+
+ b.Property("DateMod")
+ .HasColumnType("datetime2");
+
+ b.Property("DateOrd")
+ .HasColumnType("datetime2");
+
+ b.Property("DateProm")
+ .HasColumnType("datetime2");
+
+ b.Property("Discount")
+ .HasColumnType("float");
+
+ b.Property("OrderDescript")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("OrderExtCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Status")
+ .HasColumnType("int");
+
+ b.Property("UserIdIns")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserIdMod")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("OrderId");
+
+ b.HasIndex("CompanyId");
+
+ b.ToTable("Order");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.OrderStatusViewModel", b =>
+ {
+ b.Property("OrderId")
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("OrderId"), 1L, 1);
+
+ b.Property("CompanyId")
+ .HasColumnType("int");
+
+ b.Property("DateDelivery")
+ .HasColumnType("datetime2");
+
+ b.Property("DateIns")
+ .HasColumnType("datetime2");
+
+ b.Property("DateOrd")
+ .HasColumnType("datetime2");
+
+ b.Property("DateProm")
+ .HasColumnType("datetime2");
+
+ b.Property("Discount")
+ .HasColumnType("float");
+
+ b.Property("NumDoors")
+ .HasColumnType("int");
+
+ b.Property("NumType")
+ .HasColumnType("int");
+
+ b.Property("OrderDescript")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("OrderExtCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("OrderStatus")
+ .HasColumnType("int");
+
+ b.Property("TotCost")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("UserIdIns")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserIdMod")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("OrderId");
+
+ b.ToView("v_OrderStatus");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.PrtRepOrderModel", b =>
+ {
+ b.Property("OrderId")
+ .HasColumnType("int");
+
+ b.Property("DoorId")
+ .HasColumnType("int");
+
+ b.Property("ObjectKey")
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("Address")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("City")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("CompanyExtCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("CompanyId")
+ .HasColumnType("int");
+
+ b.Property("CompanyName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("DateIns")
+ .HasColumnType("datetime2");
+
+ b.Property("DateMod")
+ .HasColumnType("datetime2");
+
+ b.Property("DoorDescript")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("DoorExtCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("MeasureUnit")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ObjectQty")
+ .HasColumnType("int");
+
+ b.Property("ObjectType")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ObjectVal")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("OrderDescript")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("OrderExtCode")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ParentId")
+ .HasColumnType("int");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.Property("State")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Status")
+ .HasColumnType("int");
+
+ b.Property("UnitCost")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("UserIdIns")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserIdMod")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("VAT")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ZipCode")
+ .HasColumnType("int");
+
+ b.HasKey("OrderId", "DoorId", "ObjectKey");
+
+ b.ToView("v_PrtReport");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.SerializedDoorsModel", b =>
+ {
+ b.Property("DoorTmpId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("DoorTmpId"), 1L, 1);
+
+ b.Property("DoorSerVal")
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Lock")
+ .HasColumnType("bit");
+
+ b.HasKey("DoorTmpId");
+
+ b.ToTable("SerializedDoors");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.UsersViewModel", b =>
+ {
+ b.Property("UserId")
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("RoleId")
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("ClaimId")
+ .HasColumnType("int");
+
+ b.Property("ClaimType")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ClaimValue")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Email")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("RoleName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("UserId", "RoleId", "ClaimId");
+
+ b.ToView("v_UserRolesClaims");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.VocabularyModel", b =>
+ {
+ b.Property("Lingua")
+ .HasMaxLength(5)
+ .HasColumnType("nvarchar(5)");
+
+ b.Property("Lemma")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Traduzione")
+ .IsRequired()
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.HasKey("Lingua", "Lemma");
+
+ b.ToTable("Vocabulary");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.VocabularyTempModel", b =>
+ {
+ b.Property("Lingua")
+ .HasMaxLength(5)
+ .HasColumnType("nvarchar(5)");
+
+ b.Property("Lemma")
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("IsConfSave")
+ .HasColumnType("bit");
+
+ b.Property("Traduzione")
+ .IsRequired()
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.HasKey("Lingua", "Lemma");
+
+ b.ToTable("VocabularyTemp");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.AspNetUserRoles", b =>
+ {
+ b.HasOne("WebDoorCreator.Data.DbModels.AspNetRoles", "RolesNav")
+ .WithMany()
+ .HasForeignKey("RoleId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("WebDoorCreator.Data.DbModels.AspNetUsers", "UsersNav")
+ .WithMany()
+ .HasForeignKey("UserId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("RolesNav");
+
+ b.Navigation("UsersNav");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.DoorModel", b =>
+ {
+ b.HasOne("WebDoorCreator.Data.DbModels.OrderModel", "OrderNav")
+ .WithMany()
+ .HasForeignKey("OrderId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("OrderNav");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.DoorOpModel", b =>
+ {
+ b.HasOne("WebDoorCreator.Data.DbModels.DoorModel", "DoorNav")
+ .WithMany()
+ .HasForeignKey("DoorId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("DoorNav");
+ });
+
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.OrderModel", b =>
+ {
+ b.HasOne("WebDoorCreator.Data.DbModels.CompanyModel", "CompanyNav")
+ .WithMany()
+ .HasForeignKey("CompanyId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("CompanyNav");
+ });
+#pragma warning restore 612, 618
+ }
+ }
+}
diff --git a/WebDoorCreator.Data/Migrations/WDCData/20230721130731_AddIdTestTable.cs b/WebDoorCreator.Data/Migrations/WDCData/20230721130731_AddIdTestTable.cs
new file mode 100644
index 0000000..b9501f6
--- /dev/null
+++ b/WebDoorCreator.Data/Migrations/WDCData/20230721130731_AddIdTestTable.cs
@@ -0,0 +1,31 @@
+using Microsoft.EntityFrameworkCore.Migrations;
+
+#nullable disable
+
+namespace WebDoorCreator.Data.Migrations.WDCData
+{
+ public partial class AddIdTestTable : Migration
+ {
+ protected override void Up(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.CreateTable(
+ name: "TestTable",
+ columns: table => new
+ {
+ IdUni = table.Column(type: "nvarchar(450)", nullable: false),
+ Campo1 = table.Column(type: "nvarchar(50)", maxLength: 50, nullable: false),
+ Campo2 = table.Column(type: "nvarchar(500)", maxLength: 500, nullable: false)
+ },
+ constraints: table =>
+ {
+ table.PrimaryKey("PK_TestTable", x => x.IdUni);
+ });
+ }
+
+ protected override void Down(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.DropTable(
+ name: "TestTable");
+ }
+ }
+}
diff --git a/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs b/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs
index 118524f..8cf8b4e 100644
--- a/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs
+++ b/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs
@@ -551,6 +551,27 @@ namespace WebDoorCreator.Data.Migrations.WDCData
b.ToTable("Hardware");
});
+ modelBuilder.Entity("WebDoorCreator.Data.DbModels.IdentityTableSeedTest", b =>
+ {
+ b.Property("IdUni")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("Campo1")
+ .IsRequired()
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Campo2")
+ .IsRequired()
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.HasKey("IdUni");
+
+ b.ToTable("TestTable");
+ });
+
modelBuilder.Entity("WebDoorCreator.Data.DbModels.LanguageModel", b =>
{
b.Property("CodLingua")
diff --git a/WebDoorCreator.Data/TestConfiguration.cs b/WebDoorCreator.Data/TestConfiguration.cs
new file mode 100644
index 0000000..a9cb6e9
--- /dev/null
+++ b/WebDoorCreator.Data/TestConfiguration.cs
@@ -0,0 +1,47 @@
+using Microsoft.AspNetCore.Identity;
+using Microsoft.EntityFrameworkCore;
+using Microsoft.EntityFrameworkCore.Metadata.Builders;
+using WebDoorCreator.Data.DbModels;
+
+namespace WebDoorCreator.Data
+{
+ public class TestConfiguration : IEntityTypeConfiguration
+ {
+ #region Public Methods
+
+ public void Configure(EntityTypeBuilder builder)
+ {
+
+ // Default seeded users
+ builder.HasData(
+ // SuperAdmins
+ getNewTestRec("zaccaria.majid@egalware.com", "th1sIsTh3R1vrOfThNgt98"),
+ getNewTestRec("samuele.locatelli@egalware.com", "th1sIsTh3R1vrOfThNgt96"),
+ // Admin
+ getNewTestRec("zaccaria.majid01@egalware.com", "th1sIsTh3R1vrOfThNgt94"),
+ getNewTestRec("zaccaria.majid02@egalware.com", "th1sIsTh3R1vrOfThNgt92")
+ );
+ }
+
+ #endregion Public Methods
+
+ #region Protected Fields
+
+
+ #endregion Protected Fields
+
+ #region Protected Methods
+
+ protected IdentityTableSeedTest getNewTestRec(string campo1, string campo2)
+ {
+ var newRec = new IdentityTableSeedTest
+ {
+ Campo1 = campo1,
+ Campo2 = campo2.ToUpper()
+ };
+ return newRec;
+ }
+
+ #endregion Protected Methods
+ }
+}
\ No newline at end of file
diff --git a/WebDoorCreator.Data/WDCDataContext.cs b/WebDoorCreator.Data/WDCDataContext.cs
index 5a16abc..818721b 100644
--- a/WebDoorCreator.Data/WDCDataContext.cs
+++ b/WebDoorCreator.Data/WDCDataContext.cs
@@ -25,7 +25,7 @@ namespace WebDoorCreator.Data
try
{
// se non ci fosse... crea o migra!
- //Database.Migrate();
+ Database.Migrate();
}
catch (Exception exc)
{
@@ -78,6 +78,7 @@ namespace WebDoorCreator.Data
public virtual DbSet DbSetSerializedDoors { get; set; } = null!;
public virtual DbSet DbSetConfig { get; set; } = null!;
public virtual DbSet DbSetPrtRepOrder { get; set; } = null!;
+ public virtual DbSet DbSetIdentityTableSeedTest { get; set; } = null!;
#endregion Public Properties
@@ -119,7 +120,7 @@ namespace WebDoorCreator.Data
{
//// dev
//optionsBuilder.UseSqlServer("Server=SQL2016DEV;Database=WebDoorCreator;Trusted_Connection=True;", e => e.UseHierarchyId());
- optionsBuilder.UseSqlServer("Server=SQL2016PROD;Database=DCA_WebDoorCreator;Trusted_Connection=True;", e => e.UseHierarchyId());
+ optionsBuilder.UseSqlServer("Server=SQL2016DEV;Database=WebDoorCreator;Trusted_Connection=True;", e => e.UseHierarchyId());
}
}
}
@@ -168,12 +169,16 @@ namespace WebDoorCreator.Data
modelBuilder.ApplyConfiguration(new LanguageConfiguration());
}
+ //this.Database.ExecuteSqlRaw("SET IDENTITY_INSERT [dbo].[TestTable] ON");
+ modelBuilder.ApplyConfiguration(new TestConfiguration());
+ //this.Database.ExecuteSqlRaw("SET IDENTITY_INSERT [dbo].[TestTable] OFF");
+
+
// modello dati x report ordini
- modelBuilder.Entity().HasKey(c => new { c.OrderId, c.DoorId, c.ObjectKey});
+ modelBuilder.Entity().HasKey(c => new { c.OrderId, c.DoorId, c.ObjectKey });
-
- //modelBuilder.Seed();
+ modelBuilder.Seed();
OnModelCreatingPartial(modelBuilder);
}
diff --git a/WebDoorCreator.UI/WebDoorCreator.UI.csproj b/WebDoorCreator.UI/WebDoorCreator.UI.csproj
index 6b62f42..4872cf4 100644
--- a/WebDoorCreator.UI/WebDoorCreator.UI.csproj
+++ b/WebDoorCreator.UI/WebDoorCreator.UI.csproj
@@ -3,7 +3,7 @@
net6.0
enable
- 0.9.2307.2109
+ 0.9.2307.2116
enable
aspnet-WebDoorCreator.UI-dfe95fed-1398-4144-bd43-8b3a765d6608