enhance(backend): add user.score for moderation purpose
This commit is contained in:
parent
ca022b9349
commit
9e9198086d
|
@ -0,0 +1,16 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: syuilo and misskey-project
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
export class UserScore1727491883993 {
|
||||
name = 'UserScore1727491883993'
|
||||
|
||||
async up(queryRunner) {
|
||||
await queryRunner.query(`ALTER TABLE "user" ADD "score" integer NOT NULL DEFAULT '0'`);
|
||||
}
|
||||
|
||||
async down(queryRunner) {
|
||||
await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "score"`);
|
||||
}
|
||||
}
|
|
@ -155,6 +155,11 @@ export class MiUser {
|
|||
})
|
||||
public tags: string[];
|
||||
|
||||
@Column('integer', {
|
||||
default: 0,
|
||||
})
|
||||
public score: number;
|
||||
|
||||
@Column('boolean', {
|
||||
default: false,
|
||||
comment: 'Whether the User is suspended.',
|
||||
|
|
Loading…
Reference in New Issue