mirror of
https://github.com/spacebarchat/server.git
synced 2026-10-22 13:12:19 +00:00
fix: getting message pinss
This commit is contained in:
1 parent
06ae335d1b
commit
b8b461f0db
3 files changed
+31
-2
No files matched your search
@@ -188,6 +188,9 @@ export class Message extends BaseClass {
|
||||
@Column({ nullable: true })
|
||||
pinned?: boolean;
|
||||
|
||||
@Column({ nullable: true })
|
||||
pinned_at?: Date;
|
||||
|
||||
@Column({ type: "int" })
|
||||
type: MessageType;
|
||||
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||
|
||||
export class MessagePinnedAt1752383879533 implements MigrationInterface {
|
||||
name = "MessagePinnedAt1752383879533";
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(
|
||||
`ALTER TABLE "messages" ADD "pinned_at" TIMESTAMP`,
|
||||
);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(
|
||||
`ALTER TABLE "messages" DROP COLUMN "pinned_at"`,
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user