mirror of
https://github.com/Art051/immich.git
synced 2025-08-11 19:29:00 +00:00
* refactor: store latest immich version available on the server * don't store admins acknowledgement * merge main * fix: api * feat: custom interval * pr feedback * remove unused code * update environment-variables * pr feedback * ci: fix server tests * fix: dart number * pr feedback * remove proxy * pr feedback * feat: make stringToVersion more flexible * feat(web): disable check * feat: working version * remove env * fix: check if interval exists when updating the interval * feat: show last check * fix: tests * fix: remove availableVersion when updated * fix merge * fix: web * fix e2e tests * merge main * merge main * pr feedback * pr feedback * fix: tests * pr feedback * pr feedback * pr feedback * pr feedback * pr feedback * fix: migration * regenerate api * fix: typo * fix: compare versions * pr feedback * fix * pr feedback * fix: checkIntervalTime on startup * refactor: websockets and interval logic * chore: open api * chore: remove unused code * fix: use interval instead of cron * mobile: handle WS event data as json object --------- Co-authored-by: Jason Rasmussen <jrasm91@gmail.com> Co-authored-by: shalong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
22 lines
739 B
TypeScript
22 lines
739 B
TypeScript
export const ICommunicationRepository = 'ICommunicationRepository';
|
|
|
|
export enum CommunicationEvent {
|
|
UPLOAD_SUCCESS = 'on_upload_success',
|
|
ASSET_DELETE = 'on_asset_delete',
|
|
ASSET_TRASH = 'on_asset_trash',
|
|
ASSET_UPDATE = 'on_asset_update',
|
|
ASSET_RESTORE = 'on_asset_restore',
|
|
PERSON_THUMBNAIL = 'on_person_thumbnail',
|
|
SERVER_VERSION = 'on_server_version',
|
|
CONFIG_UPDATE = 'on_config_update',
|
|
NEW_RELEASE = 'on_new_release',
|
|
}
|
|
|
|
export type Callback = (userId: string) => Promise<void>;
|
|
|
|
export interface ICommunicationRepository {
|
|
send(event: CommunicationEvent, userId: string, data: any): void;
|
|
broadcast(event: CommunicationEvent, data: any): void;
|
|
addEventListener(event: 'connect', callback: Callback): void;
|
|
}
|