Right-click on the Models folder in your project and add a class called ResearchModel.cs:
We actually need two classes—a Research class that is a representation of our entity object, and another, ResearchContext, which is a subclass of DbContext. To keep things simple, we can put both classes in our ResearchModel file.
Here's the code:
using Microsoft.EntityFrameworkCore; using System; namespace WebResearch.Models { public class Research { public int Id { get; set; } public string Url { get; set; } public DateTime DateSaved { get; set; } public string Note { get; set; } } public class ResearchContext : DbContext { public ...