using Hotline.Share.Dtos;
using Hotline.Share.Enums.Article;
using Hotline.Users;
using SqlSugar;
using System.ComponentModel;
using XF.Domain.Repository;
namespace Hotline.Snapshot;
///
/// 随手拍公告
///
[Description("随手拍公告")]
public class SnapshotBulletin : CreationEntity
{
public string Title { get; set; }
[SugarColumn(ColumnDataType = "text")]
public string Content { get; set; }
public string SnapshotBulletinTypeId { get; set; }
public string SnapshotBulletinTypeName { get; set; }
///
/// 阅读量
///
public int ReadedNum { get; set; }
///
/// 公告状态
///
public EBulletinState BulletinState { get; set; }
///
/// 提交时间
///
public DateTime? CommitTime { get; set; }
///
/// 审核意见
///
public string? ExaminOpinion { get; set; }
///
/// 审核人
///
public string? ExaminManId { get; set; }
///
/// 审核人
///
[Navigate(NavigateType.OneToOne, nameof(ExaminManId))]
public User? ExaminMan { get; set; }
///
/// 审核时间
///
public DateTime? ExaminTime { get; set; }
///
/// 是否上架
///
public bool? IsArrive { get; set; }
///
/// 阅读量+1
///
public void Read()
{
ReadedNum++;
}
}