mirror of
https://github.com/hcengineering/platform.git
synced 2025-05-11 01:40:32 +00:00
Support fulltext search api in REST api-client (#8712)
Some checks failed
CI / build (push) Has been cancelled
CI / uitest (push) Has been cancelled
CI / uitest-pg (push) Has been cancelled
CI / uitest-qms (push) Has been cancelled
CI / uitest-workspaces (push) Has been cancelled
CI / svelte-check (push) Has been cancelled
CI / formatting (push) Has been cancelled
CI / test (push) Has been cancelled
CI / docker-build (push) Has been cancelled
CI / dist-build (push) Has been cancelled
Some checks failed
CI / build (push) Has been cancelled
CI / uitest (push) Has been cancelled
CI / uitest-pg (push) Has been cancelled
CI / uitest-qms (push) Has been cancelled
CI / uitest-workspaces (push) Has been cancelled
CI / svelte-check (push) Has been cancelled
CI / formatting (push) Has been cancelled
CI / test (push) Has been cancelled
CI / docker-build (push) Has been cancelled
CI / dist-build (push) Has been cancelled
* Support fulltext search api in REST api-client Signed-off-by: Nikolay Marchuk <nikolay.marchuk@hardcoreeng.com> * Fix template string formatting Signed-off-by: Nikolay Marchuk <nikolay.marchuk@hardcoreeng.com> --------- Signed-off-by: Nikolay Marchuk <nikolay.marchuk@hardcoreeng.com>
This commit is contained in:
parent
e61eea7076
commit
e4fbe05455
@ -229,7 +229,7 @@ export class RestClientImpl implements RestClient {
|
|||||||
if (options.limit != null) {
|
if (options.limit != null) {
|
||||||
params.append('limit', `${options.limit}`)
|
params.append('limit', `${options.limit}`)
|
||||||
}
|
}
|
||||||
const requestUrl = concatLink(this.endpoint, `/api/v1/search-fulltext/${this.workspace}`)
|
const requestUrl = concatLink(this.endpoint, `/api/v1/search-fulltext/${this.workspace}?${params.toString()}`)
|
||||||
const response = await fetch(requestUrl, {
|
const response = await fetch(requestUrl, {
|
||||||
method: 'GET',
|
method: 'GET',
|
||||||
headers: this.jsonHeaders(),
|
headers: this.jsonHeaders(),
|
||||||
|
@ -22,6 +22,7 @@ import {
|
|||||||
type Doc,
|
type Doc,
|
||||||
type DocumentQuery,
|
type DocumentQuery,
|
||||||
type FindOptions,
|
type FindOptions,
|
||||||
|
type FulltextStorage,
|
||||||
type Hierarchy,
|
type Hierarchy,
|
||||||
type ModelDb,
|
type ModelDb,
|
||||||
type Ref,
|
type Ref,
|
||||||
@ -29,7 +30,7 @@ import {
|
|||||||
type WithLookup
|
type WithLookup
|
||||||
} from '@hcengineering/core'
|
} from '@hcengineering/core'
|
||||||
|
|
||||||
export interface RestClient extends Storage {
|
export interface RestClient extends Storage, FulltextStorage {
|
||||||
getAccount: () => Promise<Account>
|
getAccount: () => Promise<Account>
|
||||||
|
|
||||||
findOne: <T extends Doc>(
|
findOne: <T extends Doc>(
|
||||||
|
Loading…
Reference in New Issue
Block a user