Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class BaseModel
- {
- public BaseModel()
- {
- IsActive = true;
- }
- public int Id { get; set; }
- public bool IsActive { get; set; }
- public DateTime CreatedDate { get; set; }
- public string CreatedUser { get; set; }
- public DateTime UpdatedDate { get; set; }
- public string UpdatedUser { get; set; }
- }
- public class Category : BaseModel
- {
- public string Name { get; set; }
- }
- public class Book : BaseModel
- {
- public string Title { get; set; }
- public int CategoryId { get; set; }
- public virtual Category Category { get; set; }
- public virtual ICollection<Person> Authors { get; set; }
- }
- public class Person : BaseModel
- {
- public string FirstName { get; set; }
- public string LastName { get; set; }
- public virtual ICollection<Book> Books { get; set; }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement