From e1bc27415a7d05f89e0b1cb06ac2425841f668f0 Mon Sep 17 00:00:00 2001 From: FLARJ <122087628+FLARJ@users.noreply.github.com> Date: Sat, 8 Apr 2023 22:03:52 +0400 Subject: [PATCH] fix --- .../FurnitureFactoryBusinessLogic.csproj | 4 ++++ .../FurnitureFactoryDataBaseImplement/FurnitureDataBase.cs | 7 +------ .../FurnitureFactoryDataBaseImplement/Models/Headset.cs | 2 +- .../FurnitureFactoryDataBaseImplement/Models/Manager.cs | 2 +- .../Models/SalesSalons.cs | 2 +- 5 files changed, 8 insertions(+), 9 deletions(-) diff --git a/FurnitureFactory/FurnitureFactoryBusinessLogic/FurnitureFactoryBusinessLogic.csproj b/FurnitureFactory/FurnitureFactoryBusinessLogic/FurnitureFactoryBusinessLogic.csproj index 2fcc5e8..c1d6233 100644 --- a/FurnitureFactory/FurnitureFactoryBusinessLogic/FurnitureFactoryBusinessLogic.csproj +++ b/FurnitureFactory/FurnitureFactoryBusinessLogic/FurnitureFactoryBusinessLogic.csproj @@ -8,6 +8,10 @@ + + all + runtime; build; native; contentfiles; analyzers; buildtransitive + diff --git a/FurnitureFactory/FurnitureFactoryDataBaseImplement/FurnitureDataBase.cs b/FurnitureFactory/FurnitureFactoryDataBaseImplement/FurnitureDataBase.cs index 09594c2..2d760e6 100644 --- a/FurnitureFactory/FurnitureFactoryDataBaseImplement/FurnitureDataBase.cs +++ b/FurnitureFactory/FurnitureFactoryDataBaseImplement/FurnitureDataBase.cs @@ -10,7 +10,6 @@ using System.ComponentModel; using System.Linq; using System.Reflection.Metadata; using System.Runtime.ConstrainedExecution; -using System.Text; using System.Threading.Tasks; using HeadsetModule = FurnitureFactoryDataBaseImplement.Models.HeadsetModule; using System.Threading.Tasks; @@ -23,15 +22,13 @@ namespace FurnitureFactoryDataBaseImplement { if (optionsBuilder.IsConfigured == false) { - optionsBuilder.UseNpgsql("Server=PostgreSQL;Host=localhost;Port=5432;Database=FurnitureFactoryDataBase;Username=postgres;Password=postgres"); + optionsBuilder.UseNpgsql("Host=localhost;Port=5432;Database=FurnitureFactory;Username=postgres;Password=Jus999666Y"); } base.OnConfiguring(optionsBuilder); } public virtual DbSet Managers { set; get; } - public virtual DbSet SalesSalons { set; get; } - public virtual DbSet Headsets { set; get; } public virtual DbSet HeadsetSalesSalons { set; get; } public virtual DbSet Orders { set; get; } @@ -40,9 +37,7 @@ namespace FurnitureFactoryDataBaseImplement public virtual DbSet FurnitureMaterials { set; get; } public virtual DbSet Furnitures { set; get; } public virtual DbSet Masters { set; get; } - public virtual DbSet HeadsetModuleMaterials { set; get; } - public virtual DbSet Materials { set; get; } } diff --git a/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Headset.cs b/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Headset.cs index c8a4d5d..4e314c1 100644 --- a/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Headset.cs +++ b/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Headset.cs @@ -12,7 +12,7 @@ using FurnitureContracts.SearchModels; namespace FurnitureFactoryDataBaseImplement.Models { - public class Headset + public class Headset : IHeadsetModel { [Required] public string Title { get; set; } = string.Empty; diff --git a/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Manager.cs b/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Manager.cs index 8a7a85a..7319ef4 100644 --- a/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Manager.cs +++ b/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/Manager.cs @@ -12,7 +12,7 @@ using FurnitureContracts.SearchModels; namespace FurnitureFactoryDataBaseImplement.Models { - public class Manager + public class Manager : IManagerModel { [Required] public string UserName { get; set; } = string.Empty; diff --git a/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/SalesSalons.cs b/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/SalesSalons.cs index 7a25c0c..1b8ee77 100644 --- a/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/SalesSalons.cs +++ b/FurnitureFactory/FurnitureFactoryDataBaseImplement/Models/SalesSalons.cs @@ -12,7 +12,7 @@ using FurnitureContracts.ViewModel; namespace FurnitureFactoryDataBaseImplement.Models { - public class SalesSalons + public class SalesSalons : ISalesSalonsModel { [Required]