Revize b61ca51b
Přidáno uživatelem Michal Schwob před téměř 3 roky(ů)
frontend/src/features/Catalog/CatalogItemDetail.tsx | ||
---|---|---|
83 | 83 |
items: [item?.name], |
84 | 84 |
}, |
85 | 85 |
{ |
86 |
rowName: 'Alternative Names',
|
|
87 |
items: item?.alternativeNames,
|
|
86 |
rowName: 'All Names',
|
|
87 |
items: item?.allNames,
|
|
88 | 88 |
}, |
89 | 89 |
{ |
90 | 90 |
rowName: 'Written Forms', |
frontend/src/swagger/ExternalCatalogItems.ts | ||
---|---|---|
1 |
/* eslint-disable */ |
|
2 |
/* tslint:disable */ |
|
3 |
/* |
|
4 |
* --------------------------------------------------------------- |
|
5 |
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## |
|
6 |
* ## ## |
|
7 |
* ## AUTHOR: acacode ## |
|
8 |
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ## |
|
9 |
* --------------------------------------------------------------- |
|
10 |
*/ |
|
11 |
|
|
12 |
import { ExternalCatalogItemDto } from "./data-contracts"; |
|
13 |
import { ContentType, HttpClient, RequestParams } from "./http-client"; |
|
14 |
|
|
15 |
export class ExternalCatalogItems<SecurityDataType = unknown> extends HttpClient<SecurityDataType> { |
|
16 |
/** |
|
17 |
* No description |
|
18 |
* |
|
19 |
* @tags external-catalog-controller |
|
20 |
* @name GetCatalog |
|
21 |
* @summary returns external catalog items based on filter |
|
22 |
* @request GET:/external-catalog-items |
|
23 |
*/ |
|
24 |
getCatalog = ( |
|
25 |
query: { name: string; source: "PLEIADES" | "GEONAMES" | "CIGS" | "ANE" }, |
|
26 |
params: RequestParams = {}, |
|
27 |
) => |
|
28 |
this.request<ExternalCatalogItemDto[], any>({ |
|
29 |
path: `/external-catalog-items`, |
|
30 |
method: "GET", |
|
31 |
query: query, |
|
32 |
...params, |
|
33 |
}); |
|
34 |
/** |
|
35 |
* No description |
|
36 |
* |
|
37 |
* @tags external-catalog-controller |
|
38 |
* @name UpdateCatalog |
|
39 |
* @summary updates external catalog |
|
40 |
* @request POST:/external-catalog-items |
|
41 |
*/ |
|
42 |
updateCatalog = (data: { file: File }, params: RequestParams = {}) => |
|
43 |
this.request<void, any>({ |
|
44 |
path: `/external-catalog-items`, |
|
45 |
method: "POST", |
|
46 |
body: data, |
|
47 |
type: ContentType.FormData, |
|
48 |
...params, |
|
49 |
}); |
|
50 |
} |
frontend/src/swagger/Sources.ts | ||
---|---|---|
1 |
/* eslint-disable */ |
|
2 |
/* tslint:disable */ |
|
3 |
/* |
|
4 |
* --------------------------------------------------------------- |
|
5 |
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## |
|
6 |
* ## ## |
|
7 |
* ## AUTHOR: acacode ## |
|
8 |
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ## |
|
9 |
* --------------------------------------------------------------- |
|
10 |
*/ |
|
11 |
|
|
12 |
import { SourcesDto } from "./data-contracts"; |
|
13 |
import { ContentType, HttpClient, RequestParams } from "./http-client"; |
|
14 |
|
|
15 |
export class Sources<SecurityDataType = unknown> extends HttpClient<SecurityDataType> { |
|
16 |
/** |
|
17 |
* No description |
|
18 |
* |
|
19 |
* @tags sources-controller |
|
20 |
* @name GetTitlePage1 |
|
21 |
* @summary returns sources |
|
22 |
* @request GET:/sources |
|
23 |
*/ |
|
24 |
getTitlePage1 = (params: RequestParams = {}) => |
|
25 |
this.request<SourcesDto, any>({ |
|
26 |
path: `/sources`, |
|
27 |
method: "GET", |
|
28 |
...params, |
|
29 |
}); |
|
30 |
/** |
|
31 |
* No description |
|
32 |
* |
|
33 |
* @tags sources-controller |
|
34 |
* @name UpdateTitlePage1 |
|
35 |
* @summary updates/creates sources |
|
36 |
* @request POST:/sources |
|
37 |
*/ |
|
38 |
updateTitlePage1 = (data: SourcesDto, params: RequestParams = {}) => |
|
39 |
this.request<void, any>({ |
|
40 |
path: `/sources`, |
|
41 |
method: "POST", |
|
42 |
body: data, |
|
43 |
type: ContentType.Json, |
|
44 |
...params, |
|
45 |
}); |
|
46 |
} |
frontend/src/swagger/data-contracts.ts | ||
---|---|---|
13 | 13 |
/** @format uuid */ |
14 | 14 |
id?: string; |
15 | 15 |
name?: string; |
16 |
alternativeNames?: string[];
|
|
16 |
allNames?: string[];
|
|
17 | 17 |
writtenForms?: string[]; |
18 | 18 |
types?: string[]; |
19 | 19 |
countries?: string[]; |
... | ... | |
49 | 49 |
} |
50 | 50 |
|
51 | 51 |
export interface TitlePageDto { |
52 |
title?: string; |
|
53 | 52 |
content?: string; |
54 | 53 |
} |
55 | 54 |
|
55 |
export interface SourcesDto { |
|
56 |
sources?: string; |
|
57 |
} |
|
58 |
|
|
56 | 59 |
export interface PathDto { |
57 | 60 |
text?: string; |
58 | 61 |
foundCatalogItems?: CatalogItemDto[][]; |
... | ... | |
61 | 64 |
export interface ExternalCatalogItemDto { |
62 | 65 |
/** @format uuid */ |
63 | 66 |
id?: string; |
64 |
externalSource?: "PLEIADES" | "GEONAMES" | "CIGS"; |
|
67 |
externalSource?: "PLEIADES" | "GEONAMES" | "CIGS" | "ANE";
|
|
65 | 68 |
|
66 | 69 |
/** @format double */ |
67 | 70 |
latitude?: number; |
Také k dispozici: Unified diff
Updated files generated from swagger and code refactor
re #9802