enhance(backend): refine moderation log (#10939)
* wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * Update DriveService.ts
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import { ModerationLogPayloads } from './consts.js';
|
||||
|
||||
export type ID = string;
|
||||
export type DateString = string;
|
||||
|
||||
@@ -566,3 +568,43 @@ export type UserSorting =
|
||||
| '+updatedAt'
|
||||
| '-updatedAt';
|
||||
export type OriginType = 'combined' | 'local' | 'remote';
|
||||
|
||||
export type ModerationLog = {
|
||||
id: ID;
|
||||
createdAt: DateString;
|
||||
userId: User['id'];
|
||||
user: UserDetailed | null;
|
||||
} & ({
|
||||
type: 'updateServerSettings';
|
||||
info: ModerationLogPayloads['updateServerSettings'];
|
||||
} | {
|
||||
type: 'suspend';
|
||||
info: ModerationLogPayloads['suspend'];
|
||||
} | {
|
||||
type: 'unsuspend';
|
||||
info: ModerationLogPayloads['unsuspend'];
|
||||
} | {
|
||||
type: 'updateUserNote';
|
||||
info: ModerationLogPayloads['updateUserNote'];
|
||||
} | {
|
||||
type: 'addCustomEmoji';
|
||||
info: ModerationLogPayloads['addCustomEmoji'];
|
||||
} | {
|
||||
type: 'assignRole';
|
||||
info: ModerationLogPayloads['assignRole'];
|
||||
} | {
|
||||
type: 'unassignRole';
|
||||
info: ModerationLogPayloads['unassignRole'];
|
||||
} | {
|
||||
type: 'updateRole';
|
||||
info: ModerationLogPayloads['updateRole'];
|
||||
} | {
|
||||
type: 'deleteRole';
|
||||
info: ModerationLogPayloads['deleteRole'];
|
||||
} | {
|
||||
type: 'clearQueue';
|
||||
info: ModerationLogPayloads['clearQueue'];
|
||||
} | {
|
||||
type: 'promoteQueue';
|
||||
info: ModerationLogPayloads['promoteQueue'];
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user