いちおう動くようにはなった

Signed-off-by: mattyatea <mattyacocacora0@gmail.com>
This commit is contained in:
mattyatea 2023-11-06 18:15:29 +09:00
parent f72228f428
commit e133a6b6a4
No known key found for this signature in database
GPG key ID: 068E54E2C33BEF9A
21 changed files with 597 additions and 8 deletions

View file

@ -0,0 +1,29 @@
/*
* SPDX-FileCopyrightText: syuilo and other misskey contributors
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { Entity, Index, JoinColumn, Column, PrimaryColumn, ManyToOne } from 'typeorm';
import { noteVisibilities } from '@/types.js';
import { MiNote } from '@/models/Note.js';
import { id } from './util/id.js';
import { MiUser } from './User.js';
import { MiChannel } from './Channel.js';
import type { MiDriveFile } from './DriveFile.js';
@Entity('note_schedule')
export class MiNoteSchedule {
@PrimaryColumn(id())
public noteId: MiNote['id'];
@Column('string')
public note:{ apEmojis: any[] | undefined; visibility: any; apMentions: any[] | undefined; visibleUsers: MiUser[]; channel: null | MiChannel; poll: { multiple: any; choices: any; expiresAt: Date | null } | undefined; renote: null | MiNote; localOnly: any; cw: any; apHashtags: any[] | undefined; reactionAcceptance: any; files: MiDriveFile[]; text: any; reply: null | MiNote };
@Column('string')
public user: MiUser & {host: null;uri: null;};
@Column('timestamp with time zone', {
nullable: true,
})
public expiresAt: Date;
}

View file

@ -68,6 +68,7 @@ import { MiRoleAssignment } from '@/models/RoleAssignment.js';
import { MiFlash } from '@/models/Flash.js';
import { MiFlashLike } from '@/models/FlashLike.js';
import { MiUserListFavorite } from '@/models/UserListFavorite.js';
import { MiNoteSchedule } from './NoteSchedule.js';
import type { Repository } from 'typeorm';
export {
@ -104,6 +105,7 @@ export {
MiNoteReaction,
MiNoteThreadMuting,
MiNoteUnread,
MiNoteSchedule,
MiPage,
MiPageLike,
MiPasswordResetRequest,
@ -171,6 +173,7 @@ export type NoteFavoritesRepository = Repository<MiNoteFavorite>;
export type NoteReactionsRepository = Repository<MiNoteReaction>;
export type NoteThreadMutingsRepository = Repository<MiNoteThreadMuting>;
export type NoteUnreadsRepository = Repository<MiNoteUnread>;
export type NoteScheduleRepository = Repository<MiNoteSchedule>;
export type PagesRepository = Repository<MiPage>;
export type PageLikesRepository = Repository<MiPageLike>;
export type PasswordResetRequestsRepository = Repository<MiPasswordResetRequest>;