2023-04-07 14:17:13 +04:00
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using SoftwareInstallationDataBaseImplement.Models;
|
|
|
|
|
|
|
|
|
|
namespace SoftwareInstallationDataBaseImplement
|
|
|
|
|
{
|
|
|
|
|
public class SoftwareInstallationDataBase : DbContext
|
|
|
|
|
{
|
|
|
|
|
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
|
|
|
|
|
{
|
|
|
|
|
if (optionsBuilder.IsConfigured == false)
|
|
|
|
|
{
|
2023-05-04 21:09:17 +04:00
|
|
|
|
optionsBuilder.UseSqlServer(@"Data Source=COMP-AVZH\SQLEXPRESS;Initial Catalog=SoftwareInstallationDataBaseHardFulllab6;Integrated Security=True;MultipleActiveResultSets=True;;TrustServerCertificate=True");
|
2023-04-07 14:17:13 +04:00
|
|
|
|
}
|
|
|
|
|
base.OnConfiguring(optionsBuilder);
|
|
|
|
|
}
|
|
|
|
|
public virtual DbSet<Component> Components { set; get; }
|
|
|
|
|
public virtual DbSet<Package> Packages { set; get; }
|
|
|
|
|
public virtual DbSet<PackageComponent> PackageComponents { set; get; }
|
|
|
|
|
public virtual DbSet<Order> Orders { set; get; }
|
2023-03-26 22:01:47 +04:00
|
|
|
|
public virtual DbSet<Client> Clients { set; get; }
|
2023-04-07 16:05:51 +04:00
|
|
|
|
public virtual DbSet<Store> Stores { set; get; }
|
|
|
|
|
public virtual DbSet<StorePackage> StorePackages { set; get; }
|
2023-04-10 23:07:27 +04:00
|
|
|
|
public virtual DbSet<Implementer> Implementers { set; get; }
|
2023-04-07 14:17:13 +04:00
|
|
|
|
}
|
|
|
|
|
}
|