@paroicms/server
Version:
The ParoiCMS server
16 lines (15 loc) • 606 B
TypeScript
import type { ScDocumentType, ScSorting, ScSortRule } from "@paroicms/public-anywhere-lib";
import type { Knex } from "knex";
import type { SiteContext } from "../site-context/site-context.types.js";
export declare function applyRegularChildrenSortingOnQuery(siteContext: Pick<SiteContext, "cn" | "siteSchema">, options: {
query: Knex.QueryBuilder;
parentDocumentType: ScDocumentType;
regularChildrenSorting?: ScSorting;
leftJoinDocument?: boolean;
orderByAsString?: boolean;
sorting?: ScSortRule[];
useAggregates?: boolean;
}): {
ordered: boolean;
orderBy?: string;
};