初步完成评论

This commit is contained in:
2025-06-07 03:21:27 +08:00
parent c872b55083
commit 3821ef6657
12 changed files with 208 additions and 4 deletions

View File

@@ -1,4 +1,5 @@
import { Column, CreateDateColumn, DeleteDateColumn, Entity, OneToMany, PrimaryGeneratedColumn, UpdateDateColumn } from "typeorm";
import { BlogComment } from "./BlogComment";
@Entity()
export class Blog {
@@ -27,4 +28,8 @@ export class Blog {
deletedAt: Date;
// 权限关系 TODO
// 关系
@OneToMany(() => BlogComment, blog => blog.id)
comments: BlogComment[];
}