CommentMeta.cs 3.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. using Microsoft.EntityFrameworkCore;
  2. using System.ComponentModel.DataAnnotations;
  3. using System.ComponentModel;
  4. using System.ComponentModel.DataAnnotations.Schema;
  5. namespace bitforum.Models.BBS
  6. {
  7. [Table("CommentMeta")]
  8. public class CommentMeta()
  9. {
  10. [ForeignKey("BoardID")]
  11. public Board Board { get; set; } = null!;
  12. [Key]
  13. [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
  14. [DisplayName("PK")]
  15. [Comment("PK")]
  16. public int ID { get; set; }
  17. [Required]
  18. [DisplayName("게시판 ID")]
  19. [Comment("게시판 ID")]
  20. public int BoardID { get; set; }
  21. [DisplayName("댓글 사용")]
  22. [Comment("댓글 사용")]
  23. public bool EnableComment { get; set; } = false;
  24. [DisplayName("목록 표시")]
  25. [Comment("목록 표시")]
  26. public ushort PerPage { get; set; } = 0;
  27. [DisplayName("댓글 공감 사용")]
  28. [Comment("댓글 공감 사용")]
  29. public bool AllowLike { get; set; } = false;
  30. [DisplayName("댓글 비공감 사용")]
  31. [Comment("댓글 비공감 사용")]
  32. public bool AllowDisLike { get; set; } = false;
  33. [DisplayName("회원 사진 공개")]
  34. [Comment("회원 사진 공개")]
  35. public bool ShowMemberPhoto { get; set; } = false;
  36. [DisplayName("회원 아이콘 공개")]
  37. [Comment("회원 아이콘 공개")]
  38. public bool ShowMemberIcon { get; set; } = false;
  39. [DisplayName("안내 문구")]
  40. [Comment("안내 문구")]
  41. [StringLength(1000)]
  42. public string? ContentPlaceholder { get; set; } = null;
  43. [DisplayName("최소 입력 글자")]
  44. [Comment("최소 입력 글자")]
  45. public ushort MinContentLength { get; set; } = 0;
  46. [DisplayName("최대 입력 글자")]
  47. [Comment("최대 입력 글자")]
  48. public ushort MaxContentLength { get; set; } = 0;
  49. [DisplayName("웹 에디터 사용")]
  50. [Comment("웹 에디터 사용")]
  51. public bool EnableEditor { get; set; } = false;
  52. [DisplayName("비밀글 사용")]
  53. [Comment("비밀글 사용")]
  54. public bool AllowSecret { get; set; } = false;
  55. [DisplayName("댓글 신고 시 숨김")]
  56. [Comment("댓글 신고 시 숨김")]
  57. public ushort BlameHideCount { get; set; } = 0;
  58. [DisplayName("댓글 삭제 금지 기간")]
  59. [Comment("댓글 삭제 금지 기간")]
  60. public ushort DeleteProtectionDays { get; set; } = 0;
  61. [DisplayName("댓글 수정 금지 기간")]
  62. [Comment("댓글 수정 금지 기간")]
  63. public ushort UpdateProtectionDays { get; set; } = 0;
  64. [DisplayName("댓글 보호 기능 (삭제 시)")]
  65. [Comment("댓글 보호 기능 (삭제 시)")]
  66. public bool AllowDeleteProtection { get; set; } = false;
  67. [DisplayName("댓글 보호 기능 (수정 시)")]
  68. [Comment("댓글 보호 기능 (수정 시)")]
  69. public bool AllowUpdateProtection { get; set; } = false;
  70. [DisplayName("댓글 변경 기록")]
  71. [Comment("댓글 변경 기록")]
  72. public bool EnableCommentUpdateLog { get; set; } = false;
  73. }
  74. }