diff --git a/WebDoorCreator.Data/DbModels/OrderModel.cs b/WebDoorCreator.Data/DbModels/OrderModel.cs
index 568477f..5b97f88 100644
--- a/WebDoorCreator.Data/DbModels/OrderModel.cs
+++ b/WebDoorCreator.Data/DbModels/OrderModel.cs
@@ -56,6 +56,16 @@ namespace WebDoorCreator.Data.DbModels
///
public DateTime DateDelivery { get; set; } = DateTime.Now.AddDays(60);
+ ///
+ /// Expected order delivery from DCA
+ ///
+ public DateTime DateProm { get; set; } = DateTime.Now.AddDays(60);
+
+ ///
+ /// Date Order confirmed by customer from Order table
+ ///
+ public DateTime DateOrd { get; set; }
+
///
/// Eventuale sconto globale
///
@@ -71,7 +81,7 @@ namespace WebDoorCreator.Data.DbModels
///
public string OrderDescript { get; set; } = "";
-
+
[ForeignKey("CompanyId")]
public virtual CompanyModel? CompanyNav { get; set; }
diff --git a/WebDoorCreator.Data/Migrations/WDCData/20230627133840_AddOrderDatesInfo.Designer.cs b/WebDoorCreator.Data/Migrations/WDCData/20230627133840_AddOrderDatesInfo.Designer.cs
new file mode 100644
index 0000000..b2cefbc
--- /dev/null
+++ b/WebDoorCreator.Data/Migrations/WDCData/20230627133840_AddOrderDatesInfo.Designer.cs
@@ -0,0 +1,1093 @@
+//
+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("20230627133840_AddOrderDatesInfo")]
+ partial class AddOrderDatesInfo
+ {
+ 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.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/20230627133840_AddOrderDatesInfo.cs b/WebDoorCreator.Data/Migrations/WDCData/20230627133840_AddOrderDatesInfo.cs
new file mode 100644
index 0000000..17fa05a
--- /dev/null
+++ b/WebDoorCreator.Data/Migrations/WDCData/20230627133840_AddOrderDatesInfo.cs
@@ -0,0 +1,38 @@
+using System;
+using Microsoft.EntityFrameworkCore.Migrations;
+
+#nullable disable
+
+namespace WebDoorCreator.Data.Migrations.WDCData
+{
+ public partial class AddOrderDatesInfo : Migration
+ {
+ protected override void Up(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.AddColumn(
+ name: "DateOrd",
+ table: "Order",
+ type: "datetime2",
+ nullable: false,
+ defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified));
+
+ migrationBuilder.AddColumn(
+ name: "DateProm",
+ table: "Order",
+ type: "datetime2",
+ nullable: false,
+ defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified));
+ }
+
+ protected override void Down(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.DropColumn(
+ name: "DateOrd",
+ table: "Order");
+
+ migrationBuilder.DropColumn(
+ name: "DateProm",
+ table: "Order");
+ }
+ }
+}
diff --git a/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs b/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs
index 89e0646..118524f 100644
--- a/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs
+++ b/WebDoorCreator.Data/Migrations/WDCData/WDCDataContextModelSnapshot.cs
@@ -740,6 +740,12 @@ namespace WebDoorCreator.Data.Migrations.WDCData
b.Property("DateMod")
.HasColumnType("datetime2");
+ b.Property("DateOrd")
+ .HasColumnType("datetime2");
+
+ b.Property("DateProm")
+ .HasColumnType("datetime2");
+
b.Property("Discount")
.HasColumnType("float");
@@ -785,6 +791,12 @@ namespace WebDoorCreator.Data.Migrations.WDCData
b.Property("DateIns")
.HasColumnType("datetime2");
+ b.Property("DateOrd")
+ .HasColumnType("datetime2");
+
+ b.Property("DateProm")
+ .HasColumnType("datetime2");
+
b.Property("Discount")
.HasColumnType("float");
diff --git a/WebDoorCreator.Data/SqlScripts/View/OrderStatusView.sql b/WebDoorCreator.Data/SqlScripts/View/OrderStatusView.sql
index 0d0f706..483c1b0 100644
--- a/WebDoorCreator.Data/SqlScripts/View/OrderStatusView.sql
+++ b/WebDoorCreator.Data/SqlScripts/View/OrderStatusView.sql
@@ -21,7 +21,9 @@ SELECT ord.OrderId
,ord.OrderExtCode
,ord.DateIns
,ord.UserIdIns
- ,ord.DateMod
+ ,ord.DateMod
+ ,ord.DateProm
+ ,ord.DateOrd
,ord.UserIdMod
,ord.STATUS AS OrderStatus
,ord.OrderDescript