diff --git a/GWMS.Data/DatabaseModels/TableCount.cs b/GWMS.Data/DatabaseModels/TableCount.cs index d3d6cfa..618f54b 100644 --- a/GWMS.Data/DatabaseModels/TableCount.cs +++ b/GWMS.Data/DatabaseModels/TableCount.cs @@ -1,6 +1,7 @@ using Microsoft.EntityFrameworkCore; using System; using System.Collections.Generic; +using System.ComponentModel.DataAnnotations.Schema; using System.Linq; using System.Text; using System.Threading.Tasks; @@ -10,7 +11,7 @@ namespace GWMS.Data.DatabaseModels /// /// Classe fake x il conteggio tabelle e check preliminari /// - [Keyless] + [NotMapped] public class TableCount { #region Public Properties diff --git a/GWMS.Data/Migrations/20240411155438_RemoveTableCount.Designer.cs b/GWMS.Data/Migrations/20240411155438_RemoveTableCount.Designer.cs new file mode 100644 index 0000000..e5f3a18 --- /dev/null +++ b/GWMS.Data/Migrations/20240411155438_RemoveTableCount.Designer.cs @@ -0,0 +1,313 @@ +// +using System; +using GWMS.Data; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace GWMS.User.Migrations +{ + [DbContext(typeof(UserIdentityDbContext))] + [Migration("20240411155438_RemoveTableCount")] + partial class RemoveTableCount + { + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "6.0.2") + .HasAnnotation("Relational:MaxIdentifierLength", 64); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRole", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasColumnType("longtext"); + + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("varchar(256)"); + + b.Property("NormalizedName") + .HasMaxLength(256) + .HasColumnType("varchar(256)"); + + b.HasKey("Id"); + + b.HasIndex("NormalizedName") + .IsUnique() + .HasDatabaseName("RoleNameIndex"); + + b.ToTable("AspNetRoles", (string)null); + + b.HasData( + new + { + Id = "315208c3-0fb0-421d-b373-8f4730106dd5", + ConcurrencyStamp = "9bd570a3-2012-42a8-bb38-0030e0d45de2", + Name = "Undef", + NormalizedName = "UNDEF" + }, + new + { + Id = "757673aa-ea00-4b6a-8c98-f75b3dcd65b7", + ConcurrencyStamp = "55cbb043-dbd6-4018-a834-050c2a15c30f", + Name = "ExtUser", + NormalizedName = "EXTUSER" + }, + new + { + Id = "b5083225-0c73-40cb-a7be-db0747b20dca", + ConcurrencyStamp = "496441df-9b5b-4df2-bdc2-54a073a4a912", + Name = "ExtTransp", + NormalizedName = "EXTTRANSP" + }, + new + { + Id = "b5136e2c-f9e9-43ae-8cfd-d4b2883b963a", + ConcurrencyStamp = "2009b165-9681-4891-934e-020a35e6fc80", + Name = "User", + NormalizedName = "USER" + }, + new + { + Id = "0bbf8f56-fcc8-4afd-9865-805881ca4067", + ConcurrencyStamp = "759f05b6-3995-4763-b76a-aef212eb17f1", + Name = "Admin", + NormalizedName = "ADMIN" + }, + new + { + Id = "55fd587f-bfea-40b2-8e44-3ad95a9a9ee1", + ConcurrencyStamp = "8b2b2fbf-ba91-420a-b490-13e02916d8a1", + Name = "SuperAdmin", + NormalizedName = "SUPERADMIN" + }); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("ClaimType") + .HasColumnType("longtext"); + + b.Property("ClaimValue") + .HasColumnType("longtext"); + + b.Property("RoleId") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.HasKey("Id"); + + b.HasIndex("RoleId"); + + b.ToTable("AspNetRoleClaims", (string)null); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUser", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AccessFailedCount") + .HasColumnType("int"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasColumnType("longtext"); + + b.Property("Email") + .HasMaxLength(256) + .HasColumnType("varchar(256)"); + + b.Property("EmailConfirmed") + .HasColumnType("tinyint(1)"); + + b.Property("LockoutEnabled") + .HasColumnType("tinyint(1)"); + + b.Property("LockoutEnd") + .HasColumnType("datetime(6)"); + + b.Property("NormalizedEmail") + .HasMaxLength(256) + .HasColumnType("varchar(256)"); + + b.Property("NormalizedUserName") + .HasMaxLength(256) + .HasColumnType("varchar(256)"); + + b.Property("PasswordHash") + .HasColumnType("longtext"); + + b.Property("PhoneNumber") + .HasColumnType("longtext"); + + b.Property("PhoneNumberConfirmed") + .HasColumnType("tinyint(1)"); + + b.Property("SecurityStamp") + .HasColumnType("longtext"); + + b.Property("TwoFactorEnabled") + .HasColumnType("tinyint(1)"); + + b.Property("UserName") + .HasMaxLength(256) + .HasColumnType("varchar(256)"); + + b.HasKey("Id"); + + b.HasIndex("NormalizedEmail") + .HasDatabaseName("EmailIndex"); + + b.HasIndex("NormalizedUserName") + .IsUnique() + .HasDatabaseName("UserNameIndex"); + + b.ToTable("AspNetUsers", (string)null); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("ClaimType") + .HasColumnType("longtext"); + + b.Property("ClaimValue") + .HasColumnType("longtext"); + + b.Property("UserId") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.HasKey("Id"); + + b.HasIndex("UserId"); + + b.ToTable("AspNetUserClaims", (string)null); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin", b => + { + b.Property("LoginProvider") + .HasColumnType("varchar(255)"); + + b.Property("ProviderKey") + .HasColumnType("varchar(255)"); + + b.Property("ProviderDisplayName") + .HasColumnType("longtext"); + + b.Property("UserId") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.HasKey("LoginProvider", "ProviderKey"); + + b.HasIndex("UserId"); + + b.ToTable("AspNetUserLogins", (string)null); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole", b => + { + b.Property("UserId") + .HasColumnType("varchar(255)"); + + b.Property("RoleId") + .HasColumnType("varchar(255)"); + + b.HasKey("UserId", "RoleId"); + + b.HasIndex("RoleId"); + + b.ToTable("AspNetUserRoles", (string)null); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken", b => + { + b.Property("UserId") + .HasColumnType("varchar(255)"); + + b.Property("LoginProvider") + .HasColumnType("varchar(255)"); + + b.Property("Name") + .HasColumnType("varchar(255)"); + + b.Property("Value") + .HasColumnType("longtext"); + + b.HasKey("UserId", "LoginProvider", "Name"); + + b.ToTable("AspNetUserTokens", (string)null); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim", b => + { + b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null) + .WithMany() + .HasForeignKey("RoleId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim", b => + { + b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null) + .WithMany() + .HasForeignKey("UserId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin", b => + { + b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null) + .WithMany() + .HasForeignKey("UserId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole", b => + { + b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null) + .WithMany() + .HasForeignKey("RoleId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null) + .WithMany() + .HasForeignKey("UserId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken", b => + { + b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null) + .WithMany() + .HasForeignKey("UserId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/GWMS.Data/Migrations/20240411155438_RemoveTableCount.cs b/GWMS.Data/Migrations/20240411155438_RemoveTableCount.cs new file mode 100644 index 0000000..f3bea0c --- /dev/null +++ b/GWMS.Data/Migrations/20240411155438_RemoveTableCount.cs @@ -0,0 +1,122 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace GWMS.User.Migrations +{ + public partial class RemoveTableCount : Migration + { + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "DbSetCounts"); + + migrationBuilder.AlterColumn( + name: "Name", + table: "AspNetUserTokens", + type: "varchar(255)", + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(128)", + oldMaxLength: 128) + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AlterColumn( + name: "LoginProvider", + table: "AspNetUserTokens", + type: "varchar(255)", + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(128)", + oldMaxLength: 128) + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AlterColumn( + name: "ProviderKey", + table: "AspNetUserLogins", + type: "varchar(255)", + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(128)", + oldMaxLength: 128) + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AlterColumn( + name: "LoginProvider", + table: "AspNetUserLogins", + type: "varchar(255)", + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(128)", + oldMaxLength: 128) + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + } + + protected override void Down(MigrationBuilder migrationBuilder) + { + + migrationBuilder.AlterColumn( + name: "Name", + table: "AspNetUserTokens", + type: "varchar(128)", + maxLength: 128, + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(255)") + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AlterColumn( + name: "LoginProvider", + table: "AspNetUserTokens", + type: "varchar(128)", + maxLength: 128, + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(255)") + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AlterColumn( + name: "ProviderKey", + table: "AspNetUserLogins", + type: "varchar(128)", + maxLength: 128, + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(255)") + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AlterColumn( + name: "LoginProvider", + table: "AspNetUserLogins", + type: "varchar(128)", + maxLength: 128, + nullable: false, + oldClrType: typeof(string), + oldType: "varchar(255)") + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "DbSetCounts", + columns: table => new + { + Count = table.Column(type: "int", nullable: false), + TableName = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4") + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + } + } +} diff --git a/GWMS.Data/Migrations/UserIdentityDbContextModelSnapshot.cs b/GWMS.Data/Migrations/UserIdentityDbContextModelSnapshot.cs index 32d3b3b..6ab71fb 100644 --- a/GWMS.Data/Migrations/UserIdentityDbContextModelSnapshot.cs +++ b/GWMS.Data/Migrations/UserIdentityDbContextModelSnapshot.cs @@ -5,6 +5,8 @@ using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +#nullable disable + namespace GWMS.User.Migrations { [DbContext(typeof(UserIdentityDbContext))] @@ -14,19 +16,8 @@ namespace GWMS.User.Migrations { #pragma warning disable 612, 618 modelBuilder - .HasAnnotation("Relational:MaxIdentifierLength", 64) - .HasAnnotation("ProductVersion", "5.0.7"); - - modelBuilder.Entity("GWMS.Data.DatabaseModels.TableCount", b => - { - b.Property("Count") - .HasColumnType("int"); - - b.Property("TableName") - .HasColumnType("longtext"); - - b.ToTable("DbSetCounts"); - }); + .HasAnnotation("ProductVersion", "6.0.2") + .HasAnnotation("Relational:MaxIdentifierLength", 64); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRole", b => { @@ -51,48 +42,48 @@ namespace GWMS.User.Migrations .IsUnique() .HasDatabaseName("RoleNameIndex"); - b.ToTable("AspNetRoles"); + b.ToTable("AspNetRoles", (string)null); b.HasData( new { - Id = "339a7ac3-4fcd-4baa-bd19-a6a09d1b7c5d", - ConcurrencyStamp = "3caf0732-df97-4b81-ba2c-9fb51e34532a", + Id = "315208c3-0fb0-421d-b373-8f4730106dd5", + ConcurrencyStamp = "9bd570a3-2012-42a8-bb38-0030e0d45de2", Name = "Undef", NormalizedName = "UNDEF" }, new { - Id = "47c8d4fb-6925-4ef0-a830-5df33e705d7a", - ConcurrencyStamp = "9671ece6-f70a-4ca6-88db-64562e007c72", + Id = "757673aa-ea00-4b6a-8c98-f75b3dcd65b7", + ConcurrencyStamp = "55cbb043-dbd6-4018-a834-050c2a15c30f", Name = "ExtUser", NormalizedName = "EXTUSER" }, new { - Id = "2d87821f-5c6d-4d9e-98d7-7ae801030100", - ConcurrencyStamp = "9ee56f2f-558f-4579-9ad7-4a6150e3d822", + Id = "b5083225-0c73-40cb-a7be-db0747b20dca", + ConcurrencyStamp = "496441df-9b5b-4df2-bdc2-54a073a4a912", Name = "ExtTransp", NormalizedName = "EXTTRANSP" }, new { - Id = "db1d1ac5-905d-46a5-bcf4-ef8a5f3f715c", - ConcurrencyStamp = "3244e9d3-ab0e-45ae-97b6-c8c74f57cf64", + Id = "b5136e2c-f9e9-43ae-8cfd-d4b2883b963a", + ConcurrencyStamp = "2009b165-9681-4891-934e-020a35e6fc80", Name = "User", NormalizedName = "USER" }, new { - Id = "7e3dc53b-c152-440f-a49d-6c3a2f6bf6eb", - ConcurrencyStamp = "a0a109e5-ab8e-4e20-9aa8-eba3c429fd12", + Id = "0bbf8f56-fcc8-4afd-9865-805881ca4067", + ConcurrencyStamp = "759f05b6-3995-4763-b76a-aef212eb17f1", Name = "Admin", NormalizedName = "ADMIN" }, new { - Id = "2fcd8455-143a-4ebc-b41c-e9bdf6a0315b", - ConcurrencyStamp = "549b8a8d-ba83-4b79-be88-fde0bd4cc60f", + Id = "55fd587f-bfea-40b2-8e44-3ad95a9a9ee1", + ConcurrencyStamp = "8b2b2fbf-ba91-420a-b490-13e02916d8a1", Name = "SuperAdmin", NormalizedName = "SUPERADMIN" }); @@ -118,7 +109,7 @@ namespace GWMS.User.Migrations b.HasIndex("RoleId"); - b.ToTable("AspNetRoleClaims"); + b.ToTable("AspNetRoleClaims", (string)null); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUser", b => @@ -182,7 +173,7 @@ namespace GWMS.User.Migrations .IsUnique() .HasDatabaseName("UserNameIndex"); - b.ToTable("AspNetUsers"); + b.ToTable("AspNetUsers", (string)null); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim", b => @@ -205,18 +196,16 @@ namespace GWMS.User.Migrations b.HasIndex("UserId"); - b.ToTable("AspNetUserClaims"); + b.ToTable("AspNetUserClaims", (string)null); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin", b => { b.Property("LoginProvider") - .HasMaxLength(128) - .HasColumnType("varchar(128)"); + .HasColumnType("varchar(255)"); b.Property("ProviderKey") - .HasMaxLength(128) - .HasColumnType("varchar(128)"); + .HasColumnType("varchar(255)"); b.Property("ProviderDisplayName") .HasColumnType("longtext"); @@ -229,7 +218,7 @@ namespace GWMS.User.Migrations b.HasIndex("UserId"); - b.ToTable("AspNetUserLogins"); + b.ToTable("AspNetUserLogins", (string)null); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole", b => @@ -244,7 +233,7 @@ namespace GWMS.User.Migrations b.HasIndex("RoleId"); - b.ToTable("AspNetUserRoles"); + b.ToTable("AspNetUserRoles", (string)null); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken", b => @@ -253,19 +242,17 @@ namespace GWMS.User.Migrations .HasColumnType("varchar(255)"); b.Property("LoginProvider") - .HasMaxLength(128) - .HasColumnType("varchar(128)"); + .HasColumnType("varchar(255)"); b.Property("Name") - .HasMaxLength(128) - .HasColumnType("varchar(128)"); + .HasColumnType("varchar(255)"); b.Property("Value") .HasColumnType("longtext"); b.HasKey("UserId", "LoginProvider", "Name"); - b.ToTable("AspNetUserTokens"); + b.ToTable("AspNetUserTokens", (string)null); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim", b => diff --git a/GWMS.Data/UserIdentityDbContext.cs b/GWMS.Data/UserIdentityDbContext.cs index f69a8a4..82ff7af 100644 --- a/GWMS.Data/UserIdentityDbContext.cs +++ b/GWMS.Data/UserIdentityDbContext.cs @@ -51,6 +51,7 @@ namespace GWMS.Data string connString = DbConfig.CONNECTION_STRING; if (!optionsBuilder.IsConfigured) { + //connString = "Server=localhost;port=3306;database=GWMS;user=GWMS;pwd=GWMS_secret_pwd;sslmode=None;"; var serverVersion = ServerVersion.AutoDetect(connString); optionsBuilder.UseMySql(connString, serverVersion); } diff --git a/GWMS.UI/GWMS.UI.csproj b/GWMS.UI/GWMS.UI.csproj index 53b2d56..8eeffc2 100644 --- a/GWMS.UI/GWMS.UI.csproj +++ b/GWMS.UI/GWMS.UI.csproj @@ -2,16 +2,22 @@ net6.0 - 1.0.2402.1919 + 1.0.2404.1117 95c9f021-52d1-4390-a670-5810b7b777b0 true true true + + + + + + + - @@ -52,10 +58,6 @@ - - - - diff --git a/Resources/ChangeLog.html b/Resources/ChangeLog.html index 249b478..7fc31c4 100644 --- a/Resources/ChangeLog.html +++ b/Resources/ChangeLog.html @@ -1,6 +1,6 @@ GWMS - Gas Warehouse Management System -

Versione: 1.0.2402.1919

+

Versione: 1.0.2404.1117


Note di rilascio:
  • diff --git a/Resources/VersNum.txt b/Resources/VersNum.txt index a899f6f..3551ccd 100644 --- a/Resources/VersNum.txt +++ b/Resources/VersNum.txt @@ -1 +1 @@ -1.0.2402.1919 +1.0.2404.1117 diff --git a/Resources/manifest.xml b/Resources/manifest.xml index 8d28926..9faab04 100644 --- a/Resources/manifest.xml +++ b/Resources/manifest.xml @@ -1,6 +1,6 @@ - 1.0.2402.1919 + 1.0.2404.1117 http://nexus.steamware.net/repository/SWS/GWMS/stable/0/GWMS.UI.zip http://nexus.steamware.net/repository/SWS/GWMS/stable/0/ChangeLog.html false