mirror of
https://github.com/immich-app/immich.git
synced 2025-05-24 01:12:58 -04:00
fix(server): memory lane assets order (#15882)
* fix(server): memory lane assets order * fix: sql * pr feedback * sql
This commit is contained in:
parent
47f6181d42
commit
06f077bac2
@ -47,6 +47,8 @@ with
|
|||||||
and "asset_files"."type" = $6
|
and "asset_files"."type" = $6
|
||||||
)
|
)
|
||||||
and "assets"."deletedAt" is null
|
and "assets"."deletedAt" is null
|
||||||
|
order by
|
||||||
|
(assets."localDateTime" at time zone 'UTC')::date desc
|
||||||
limit
|
limit
|
||||||
$7
|
$7
|
||||||
) as "a" on true
|
) as "a" on true
|
||||||
|
@ -121,6 +121,7 @@ export class AssetRepository implements IAssetRepository {
|
|||||||
),
|
),
|
||||||
)
|
)
|
||||||
.where('assets.deletedAt', 'is', null)
|
.where('assets.deletedAt', 'is', null)
|
||||||
|
.orderBy(sql`(assets."localDateTime" at time zone 'UTC')::date`, 'desc')
|
||||||
.limit(20)
|
.limit(20)
|
||||||
.as('a'),
|
.as('a'),
|
||||||
(join) => join.onTrue(),
|
(join) => join.onTrue(),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user