From 3c3510a8f938f45becbdf3d3b2262d8bfbdee571 Mon Sep 17 00:00:00 2001 From: "HOME-LAPTOP\\kshkulev" Date: Sat, 1 Nov 2025 19:59:20 +0900 Subject: [PATCH] Redo initial migration --- ...s => 20251101105658_CreateHcsSchema.Designer.cs} | 13 +++++-------- ...sSchema.cs => 20251101105658_CreateHcsSchema.cs} | 5 ++--- .../Hcs/Migrations/HcsDbContextModelSnapshot.cs | 11 ++++------- 3 files changed, 11 insertions(+), 18 deletions(-) rename Hcs.WebApp/Data/Hcs/Migrations/{20251028065710_CreateHcsSchema.Designer.cs => 20251101105658_CreateHcsSchema.Designer.cs} (96%) rename Hcs.WebApp/Data/Hcs/Migrations/{20251028065710_CreateHcsSchema.cs => 20251101105658_CreateHcsSchema.cs} (96%) diff --git a/Hcs.WebApp/Data/Hcs/Migrations/20251028065710_CreateHcsSchema.Designer.cs b/Hcs.WebApp/Data/Hcs/Migrations/20251101105658_CreateHcsSchema.Designer.cs similarity index 96% rename from Hcs.WebApp/Data/Hcs/Migrations/20251028065710_CreateHcsSchema.Designer.cs rename to Hcs.WebApp/Data/Hcs/Migrations/20251101105658_CreateHcsSchema.Designer.cs index 91ca463..29b0898 100644 --- a/Hcs.WebApp/Data/Hcs/Migrations/20251028065710_CreateHcsSchema.Designer.cs +++ b/Hcs.WebApp/Data/Hcs/Migrations/20251101105658_CreateHcsSchema.Designer.cs @@ -7,7 +7,7 @@ using Microsoft.EntityFrameworkCore.Migrations; namespace Hcs.WebApp.Data.Hcs.Migrations { [DbContext(typeof(HcsDbContext))] - [Migration("20251028065710_CreateHcsSchema")] + [Migration("20251101105658_CreateHcsSchema")] public partial class CreateHcsSchema { /// @@ -102,9 +102,6 @@ namespace Hcs.WebApp.Data.Hcs.Migrations b.Property("IsCommon") .HasColumnType("bit"); - b.Property("LastSyncError") - .HasColumnType("nvarchar(max)"); - b.Property("LastSyncOperationId") .HasColumnType("int"); @@ -139,13 +136,13 @@ namespace Hcs.WebApp.Data.Hcs.Migrations .IsRequired() .HasColumnType("nvarchar(max)"); - b.Property("RegistryId") - .HasColumnType("uniqueidentifier"); - - b.Property("Xml") + b.Property("Json") .IsRequired() .HasColumnType("nvarchar(max)"); + b.Property("RegistryId") + .HasColumnType("uniqueidentifier"); + b.HasKey("Id"); b.HasIndex("RegistryId"); diff --git a/Hcs.WebApp/Data/Hcs/Migrations/20251028065710_CreateHcsSchema.cs b/Hcs.WebApp/Data/Hcs/Migrations/20251101105658_CreateHcsSchema.cs similarity index 96% rename from Hcs.WebApp/Data/Hcs/Migrations/20251028065710_CreateHcsSchema.cs rename to Hcs.WebApp/Data/Hcs/Migrations/20251101105658_CreateHcsSchema.cs index 745f2bd..744edc5 100644 --- a/Hcs.WebApp/Data/Hcs/Migrations/20251028065710_CreateHcsSchema.cs +++ b/Hcs.WebApp/Data/Hcs/Migrations/20251101105658_CreateHcsSchema.cs @@ -62,8 +62,7 @@ namespace Hcs.WebApp.Data.Hcs.Migrations Name = table.Column(type: "nvarchar(max)", nullable: false), IsCommon = table.Column(type: "bit", nullable: false), SyncedAt = table.Column(type: "datetime2", nullable: true), - LastSyncOperationId = table.Column(type: "int", nullable: true), - LastSyncError = table.Column(type: "nvarchar(max)", nullable: true) + LastSyncOperationId = table.Column(type: "int", nullable: true) }, constraints: table => { @@ -83,7 +82,7 @@ namespace Hcs.WebApp.Data.Hcs.Migrations RegistryId = table.Column(type: "uniqueidentifier", nullable: false), Code = table.Column(type: "nvarchar(max)", nullable: false), GUID = table.Column(type: "nvarchar(max)", nullable: false), - Xml = table.Column(type: "nvarchar(max)", nullable: false) + Json = table.Column(type: "nvarchar(max)", nullable: false) }, constraints: table => { diff --git a/Hcs.WebApp/Data/Hcs/Migrations/HcsDbContextModelSnapshot.cs b/Hcs.WebApp/Data/Hcs/Migrations/HcsDbContextModelSnapshot.cs index b7525ca..2d2b31c 100644 --- a/Hcs.WebApp/Data/Hcs/Migrations/HcsDbContextModelSnapshot.cs +++ b/Hcs.WebApp/Data/Hcs/Migrations/HcsDbContextModelSnapshot.cs @@ -99,9 +99,6 @@ namespace Hcs.WebApp.Data.Hcs.Migrations b.Property("IsCommon") .HasColumnType("bit"); - b.Property("LastSyncError") - .HasColumnType("nvarchar(max)"); - b.Property("LastSyncOperationId") .HasColumnType("int"); @@ -136,13 +133,13 @@ namespace Hcs.WebApp.Data.Hcs.Migrations .IsRequired() .HasColumnType("nvarchar(max)"); - b.Property("RegistryId") - .HasColumnType("uniqueidentifier"); - - b.Property("Xml") + b.Property("Json") .IsRequired() .HasColumnType("nvarchar(max)"); + b.Property("RegistryId") + .HasColumnType("uniqueidentifier"); + b.HasKey("Id"); b.HasIndex("RegistryId");