diff --git a/Demka-2/Use/Conector.cs b/Demka-2/Use/Conector.cs index cf22e39..dd5cce5 100644 --- a/Demka-2/Use/Conector.cs +++ b/Demka-2/Use/Conector.cs @@ -8,6 +8,6 @@ public class AppDbContext : DbContext protected override void OnConfiguring(DbContextOptionsBuilder oB) { - oB.UseSqlServer("Host=45.67.56.214;Port=5421;Username=user16;Password=dZ28IVE5;Database=user16"); + oB.UseSqlServer("Server=45.67.56.214,5421;Database=user16;User Id=user16;Password=dZ28IVE5;"); } } \ No newline at end of file diff --git a/Demka-2/Use/Service.cs b/Demka-2/Use/Service.cs index d7d2402..9a690a6 100644 --- a/Demka-2/Use/Service.cs +++ b/Demka-2/Use/Service.cs @@ -1,8 +1,10 @@ using System; +using System.ComponentModel.DataAnnotations; namespace Demka_2.Use; public class Service { + [Key] public Guid guid { get; set; } public string Name { get; set; } public string ImagePath { get; set; } diff --git a/Demka-2/Views/MainWindow.axaml b/Demka-2/Views/MainWindow.axaml index 89dce4b..0b1cdac 100644 --- a/Demka-2/Views/MainWindow.axaml +++ b/Demka-2/Views/MainWindow.axaml @@ -15,11 +15,11 @@ - - -