MCPcopy Create free account
hub / github.com/axe-api/axe-api / applySorting

Method applySorting

packages/axe-api/src/Services/QueryService.ts:65–78  ·  view source on GitHub ↗
(query: Knex.QueryBuilder, sort: ISortField[])

Source from the content-addressed store, hash-verified

63 }
64
65 applySorting(query: Knex.QueryBuilder, sort: ISortField[]) {
66 if (sort.length === 0) {
67 return;
68 }
69
70 sort.forEach((item) => {
71 valideteQueryFeature(
72 this.model,
73 QueryFeature.Sorting,
74 `${this.model.instance.table}.${item.name}`,
75 );
76 query.orderBy(item.name, item.type);
77 });
78 }
79
80 applyWheresInsideGroup(
81 sub: Knex.QueryBuilder,

Callers 3

FetchPhase.tsFile · 0.80
PreparePhase.tsFile · 0.80
FetchPhase.tsFile · 0.80

Calls 1

valideteQueryFeatureFunction · 0.90

Tested by

no test coverage detected