import { IncrementIdEntity } from 'src/common/entities/increment-id.entity';
import { Column, Entity } from 'typeorm';

/**
 * 学员讨论
 */
@Entity()
export class CourseStudyDiscussion extends IncrementIdEntity {
  @Column({ name: 'record_id', comment: '所属记录id' })
  recordId: number;

  @Column({
    name: 'reply_id',
    comment: '所回复的评论id',
    nullable: true,
    default: null,
  })
  replyId: number;

  @Column({
    type: 'longtext',
    name: 'reply_user_id',
    comment: '所回复评论的用户ID',
    nullable: true,
    default: null,
  })
  replyUserId: string;

  @Column({
    name: 'root_dis',
    comment: '所回复评论的根节点id',
    nullable: true,
    default: null,
  })
  rootDis: number;

  @Column({ type: 'longtext', comment: '的评论内容' })
  content: string;

  // @Column({ comment: '点赞量', default: 0 })
  // kudos: number;

  // @Column({ comment: '踩量', default: 0 })
  // unkudos: number;

  // @Column({ comment: '评论人ID', name: 'discussion_user' })
  // discussionUser: number;
}
