Fix type tests
This commit is contained in:
parent
e3e82f2fb8
commit
7ed45f71d2
|
@ -24,6 +24,7 @@ import {
|
||||||
JsonFieldSubType,
|
JsonFieldSubType,
|
||||||
LogicalOperator,
|
LogicalOperator,
|
||||||
RelationshipType,
|
RelationshipType,
|
||||||
|
RequiredKeys,
|
||||||
Row,
|
Row,
|
||||||
RowSearchParams,
|
RowSearchParams,
|
||||||
SearchFilters,
|
SearchFilters,
|
||||||
|
@ -208,9 +209,25 @@ if (descriptions.length) {
|
||||||
|
|
||||||
private async performSearch(): Promise<SearchResponse<Row>> {
|
private async performSearch(): Promise<SearchResponse<Row>> {
|
||||||
if (isInMemory) {
|
if (isInMemory) {
|
||||||
return dataFilters.search(_.cloneDeep(rows), {
|
const inMemoryQuery: RequiredKeys<
|
||||||
...this.query,
|
Omit<RowSearchParams, "tableId">
|
||||||
})
|
> = {
|
||||||
|
sort: this.query.sort,
|
||||||
|
query: { ...this.query.query },
|
||||||
|
paginate: this.query.paginate,
|
||||||
|
bookmark: this.query.bookmark ?? undefined,
|
||||||
|
limit: this.query.limit,
|
||||||
|
sortOrder: this.query.sortOrder,
|
||||||
|
sortType: this.query.sortType ?? undefined,
|
||||||
|
version: this.query.version,
|
||||||
|
disableEscaping: this.query.disableEscaping,
|
||||||
|
countRows: this.query.countRows,
|
||||||
|
viewId: undefined,
|
||||||
|
fields: undefined,
|
||||||
|
indexer: undefined,
|
||||||
|
rows: undefined,
|
||||||
|
}
|
||||||
|
return dataFilters.search(_.cloneDeep(rows), inMemoryQuery)
|
||||||
} else {
|
} else {
|
||||||
return config.api.row.search(tableOrViewId, this.query)
|
return config.api.row.search(tableOrViewId, this.query)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue