Skip to content

Commit d92adf6

Browse files
authored
Web: Fix ServerInfoResponse and EnableSharing3rdPartyResponse (#821)
1 parent ecb223c commit d92adf6

File tree

2 files changed

+16
-4
lines changed

2 files changed

+16
-4
lines changed

mwdb/web/src/commons/api/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import {
2323
DeleteQuickQueryResponse,
2424
DownloadFileResponse,
2525
DownloadRemoteFileResponse,
26-
EnableSharing3rdPartyReponse,
26+
EnableSharing3rdPartyResponse,
2727
GenerateSetPasswordResponse,
2828
GetAttributeDefinitionResponse,
2929
GetAttributeDefinitionsResponse,
@@ -764,7 +764,7 @@ function removeKartonAnalysisFromObject(
764764

765765
function enableSharing3rdParty(
766766
identifier: string
767-
): EnableSharing3rdPartyReponse {
767+
): EnableSharing3rdPartyResponse {
768768
return axios.put(`/object/${identifier}/share_3rd_party`);
769769
}
770770

mwdb/web/src/types/api.ts

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,19 @@ import {
2020

2121
export type Response<T> = Promise<AxiosResponse<T>>;
2222

23-
export type ServerInfoResponse = Response<{ status: string }>;
23+
export type ServerInfoResponse = Response<{
24+
server_version: string;
25+
is_authenticated: boolean;
26+
instance_name: string;
27+
is_maintenance_set: boolean;
28+
is_registration_enabled: boolean;
29+
is_karton_enabled: boolean;
30+
is_oidc_enabled: boolean;
31+
recaptcha_site_key: boolean;
32+
request_timeout: number;
33+
file_upload_timeout: number;
34+
statement_timeout: number;
35+
}>;
2436

2537
type ServerDocsInfo = {
2638
description: string;
@@ -288,4 +300,4 @@ export type ResubmitKartonAnalysisResponse = Response<{
288300

289301
export type RemoveKartonAnalysisFromObjectResponse = Response<null>;
290302

291-
export type EnableSharing3rdPartyReponse = Response<null>;
303+
export type EnableSharing3rdPartyResponse = Response<null>;

0 commit comments

Comments
 (0)