Add DAL
This commit is contained in:
22
DAL/Domain/Foorum.cs
Normal file
22
DAL/Domain/Foorum.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DAL.Domain
|
||||
{
|
||||
public class Foorum
|
||||
{
|
||||
[Key]
|
||||
public int FoorumId { get; set; }
|
||||
public string Title { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string Body { get; set; }
|
||||
public DateTime CreationTime { get; set; }
|
||||
public string Author { get; set; }
|
||||
|
||||
public bool Visible { get; set; } = true;
|
||||
|
||||
public virtual List<Post> Posts {get; set;} = new List<Post>();
|
||||
|
||||
}
|
||||
}
|
||||
16
DAL/Domain/Post.cs
Normal file
16
DAL/Domain/Post.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
using System;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DAL.Domain
|
||||
{
|
||||
public class Post
|
||||
{
|
||||
[Key]
|
||||
public int PostId { get; set; }
|
||||
public string Title { get; set; }
|
||||
public string Body { get; set; }
|
||||
public DateTime CreationTime { get; set; }
|
||||
public string Author { get; set; }
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user