yavsc/Yavsc/Models/Blog/Blog.cs

49 lines
1.1 KiB
C#

using System;
9 years ago
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Newtonsoft.Json;
9 years ago
using Yavsc.Models.Access;
namespace Yavsc.Models
{
public partial class Blog : IBlog
{
[Key(), DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public long Id { get; set; }
9 years ago
public string Content { get; set; }
public string Photo { get; set; }
public int Rate { get; set; }
public string Title { get; set; }
public string AuthorId { get; set; }
[ForeignKey("AuthorId"),JsonIgnore]
public ApplicationUser Author { set; get; }
9 years ago
public bool Visible { get; set; }
9 years ago
public DateTime DateCreated
{
get; set;
}
public string UserCreated
{
get; set;
}
public DateTime DateModified
{
get; set;
}
public string UserModified
{
get; set;
}
9 years ago
[InverseProperty("Post")]
public virtual List<CircleAuthorizationToBlogPost> ACL { get; set; }
}
}