Explicitly movie scenes by oldest.
This commit is contained in:
parent
2e3ce4e410
commit
eb2807d0e0
|
@ -21,6 +21,7 @@ export async function onBeforeRender(pageContext) {
|
|||
fetchMoviesById([Number(pageContext.routeParams.movieId)], pageContext.user),
|
||||
fetchScenes(await curateScenesQuery({
|
||||
...pageContext.urlQuery,
|
||||
scope: 'oldest',
|
||||
movieId: Number(pageContext.routeParams.movieId),
|
||||
}), {
|
||||
page: Number(pageContext.routeParams.page) || 1,
|
||||
|
|
|
@ -522,6 +522,8 @@ async function queryManticoreSql(filters, options, _reqUser) {
|
|||
{ column: 'stashed_at', order: 'desc' },
|
||||
{ column: 'scenes.effective_date', order: 'desc' },
|
||||
]);
|
||||
} else if (filters.scope === 'oldest') {
|
||||
builder.orderBy('scenes.effective_date', 'asc');
|
||||
} else {
|
||||
builder.orderBy('scenes.effective_date', 'desc');
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue