PIbd-21_Ihonkina_E.S._Preca.../PrecastConcretePlantDataBaseImplemet/PrecastConcretePlantDatabase.cs

32 lines
1.3 KiB
C#
Raw Normal View History

2023-03-18 19:33:11 +04:00
using Microsoft.EntityFrameworkCore;
using PrecastConcretePlantDatabaseImplement.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PrecastConcretePlantDatabaseImplement
{
public class PrecastConcretePlantDatabase : DbContext
{
protected override void OnConfiguring(DbContextOptionsBuilder
optionsBuilder)
{
if (optionsBuilder.IsConfigured == false)
{
2023-05-21 16:02:08 +04:00
optionsBuilder.UseSqlServer(@"Data Source=DESKTOP-0IOO2C0;Initial Catalog= PrecastConcretePlantDatabaseFull;Integrated Security=True;MultipleActiveResultSets=True;;TrustServerCertificate=True");
2023-03-18 19:33:11 +04:00
}
base.OnConfiguring(optionsBuilder);
}
public virtual DbSet<Component> Components { set; get; }
public virtual DbSet<Reinforced> Reinforceds { set; get; }
public virtual DbSet<ReinforcedComponent> ReinforcedComponents { set; get; }
public virtual DbSet<Order> Orders { set; get; }
2023-04-05 00:55:08 +04:00
public virtual DbSet<Client> Clients { set; get; }
2023-04-19 23:48:32 +04:00
public virtual DbSet<Implementer> Implementers { set; get; }
2023-05-21 16:02:08 +04:00
public virtual DbSet<Shop> Shops { set; get; }
public virtual DbSet<ShopReinforced> ShopReinforceds { set; get; }
2023-03-18 19:33:11 +04:00
}
}