mirror of
https://github.com/muerwre/vk-tg-bot.git
synced 2025-04-25 06:56:40 +07:00
#4 added entities and synchronization to project
This commit is contained in:
parent
c5c3c013ba
commit
50db549cbe
5 changed files with 33 additions and 4 deletions
|
@ -1,5 +1,6 @@
|
|||
import { VkEvent } from "../vk/types";
|
||||
import { StoredEvent, StoredLike } from "./types";
|
||||
import { Like } from "./postgres/entities/Like";
|
||||
|
||||
export interface Storage {
|
||||
getEvent(
|
||||
|
@ -9,7 +10,9 @@ export interface Storage {
|
|||
channel: string
|
||||
): Promise<StoredEvent>;
|
||||
|
||||
createEvent(event: StoredEvent): Promise<StoredEvent>;
|
||||
createEvent(event: Partial<StoredEvent>): Promise<StoredEvent>;
|
||||
|
||||
createOrUpdateLike(like: Partial<StoredLike>): Promise<Like>;
|
||||
|
||||
getLikesFor(channel: string, messageId: number): Promise<StoredLike[]>;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue