mirror of
https://github.com/KevinMidboe/immich.git
synced 2025-10-29 17:40:28 +00:00
* feat(server): dynamic job concurrency * styling and add setting info to top of the job list * regenerate api * remove DETECT_OBJECT job --------- Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
24 lines
704 B
TypeScript
24 lines
704 B
TypeScript
import { ISystemConfigRepository } from '@app/domain';
|
|
import { InjectRepository } from '@nestjs/typeorm';
|
|
import { In, Repository } from 'typeorm';
|
|
import { SystemConfigEntity } from '../entities';
|
|
|
|
export class SystemConfigRepository implements ISystemConfigRepository {
|
|
constructor(
|
|
@InjectRepository(SystemConfigEntity)
|
|
private repository: Repository<SystemConfigEntity>,
|
|
) {}
|
|
|
|
load(): Promise<SystemConfigEntity[]> {
|
|
return this.repository.find();
|
|
}
|
|
|
|
saveAll(items: SystemConfigEntity[]): Promise<SystemConfigEntity[]> {
|
|
return this.repository.save(items);
|
|
}
|
|
|
|
async deleteKeys(keys: string[]): Promise<void> {
|
|
await this.repository.delete({ key: In(keys) });
|
|
}
|
|
}
|