123456789101112131415161718 |
- using System.Configuration;
- using Microsoft.EntityFrameworkCore;
- namespace BookStore_2._0
- {
- class BookStoreContext : DbContext
- {
- public DbSet<Book> Books { get; set; }
- public BookStoreContext()
- {
- }
- protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
- {
- optionsBuilder.UseSqlServer(ConfigurationManager.ConnectionStrings["gr601_kayual"].ConnectionString);
- }
- }
- }
|