feat(web): show partners assets on the main timeline (#4933)

This commit is contained in:
Alex
2023-11-11 15:06:19 -06:00
committed by GitHub
parent 3b11854702
commit 35767591d2
59 changed files with 1929 additions and 172 deletions
@@ -519,7 +519,7 @@ export class AssetRepository implements IAssetRepository {
}
private getBuilder(options: TimeBucketOptions) {
const { isArchived, isFavorite, isTrashed, albumId, personId, userId, withStacked } = options;
const { isArchived, isFavorite, isTrashed, albumId, personId, userIds, withStacked } = options;
let builder = this.repository
.createQueryBuilder('asset')
@@ -532,11 +532,11 @@ export class AssetRepository implements IAssetRepository {
builder = builder.leftJoin('asset.albums', 'album').andWhere('album.id = :albumId', { albumId });
}
if (userId) {
builder = builder.andWhere('asset.ownerId = :userId', { userId });
if (userIds) {
builder = builder.andWhere('asset.ownerId IN (:...userIds )', { userIds });
}
if (isArchived != undefined) {
if (isArchived !== undefined) {
builder = builder.andWhere('asset.isArchived = :isArchived', { isArchived });
}