Fixes in info pane and others

This commit is contained in:
phil 2024-03-08 12:09:02 +05:30
parent adba349c38
commit 5f97c58b52
21 changed files with 232 additions and 145 deletions

View file

@ -21,17 +21,23 @@ export type { DashboardGroup } from './models/DashboardGroup';
export type { DashboardHome } from './models/DashboardHome';
export type { DashboardPage_ } from './models/DashboardPage_';
export type { DataProvider } from './models/DataProvider';
export type { Downloader } from './models/Downloader';
export type { Equipment } from './models/Equipment';
export type { FeatureInfo } from './models/FeatureInfo';
export type { FileImport } from './models/FileImport';
export type { FormField } from './models/FormField';
export type { Geo } from './models/Geo';
export type { HTTPValidationError } from './models/HTTPValidationError';
export type { InfoCategory } from './models/InfoCategory';
export type { InfoItem } from './models/InfoItem';
export type { LegendItem } from './models/LegendItem';
export type { Map } from './models/Map';
export type { MapInitData } from './models/MapInitData';
export type { MaplibreStyle } from './models/MaplibreStyle';
export type { Measures } from './models/Measures';
export type { ModelAction } from './models/ModelAction';
export type { ModelInfo } from './models/ModelInfo';
export type { ModelValue } from './models/ModelValue';
export type { PlotBaseLine } from './models/PlotBaseLine';
export type { PlotBgShape } from './models/PlotBgShape';
export type { PlotParams } from './models/PlotParams';
@ -44,6 +50,9 @@ export type { Store } from './models/Store';
export type { StoreNameOnly } from './models/StoreNameOnly';
export type { SurveyMeta } from './models/SurveyMeta';
export type { Surveyor } from './models/Surveyor';
export type { Tag } from './models/Tag';
export type { TagAction } from './models/TagAction';
export type { TagActions } from './models/TagActions';
export type { TileServer } from './models/TileServer';
export type { Token } from './models/Token';
export type { UserRead } from './models/UserRead';

View file

@ -0,0 +1,10 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type Downloader = {
roles?: Array<string>;
name: string;
icon?: (string | null);
};

View file

@ -6,14 +6,15 @@ import type { Attachment } from './Attachment';
import type { InfoCategory } from './InfoCategory';
import type { InfoItem } from './InfoItem';
import type { PlotParams } from './PlotParams';
import type { Tag } from './Tag';
export type FeatureInfo = {
id: string;
itemName: string;
geoInfoItems?: Array<InfoItem>;
surveyInfoItems?: Array<InfoItem>;
infoItems?: Array<InfoItem>;
categorizedInfoItems?: Array<InfoCategory>;
tags?: Array<InfoItem>;
categorizedInfoItems?: (Array<InfoCategory> | null);
tags?: Array<Tag>;
graph?: (string | null);
plotParams?: (PlotParams | null);
files?: Array<Attachment>;

View file

@ -0,0 +1,11 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type FormField = {
name: string;
type: string;
dflt?: (string | null);
value?: (string | null);
};

View file

@ -0,0 +1,9 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type LegendItem = {
key: string;
value: string;
};

View file

@ -0,0 +1,11 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { FormField } from './FormField';
export type ModelAction = {
name: string;
icon: string;
formFields: Array<FormField>;
};

View file

@ -0,0 +1,24 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { Downloader } from './Downloader';
import type { FormField } from './FormField';
import type { LegendItem } from './LegendItem';
import type { ModelAction } from './ModelAction';
import type { ModelValue } from './ModelValue';
import type { TagActions } from './TagActions';
export type ModelInfo = {
store: string;
modelName: string;
symbol?: (string | null);
values?: Array<ModelValue>;
actions?: Array<ModelAction>;
formName?: (string | null);
formFields?: Array<FormField>;
tagPlugins?: Array<string>;
tagActions?: Array<TagActions>;
downloaders?: Array<Downloader>;
legend?: Array<LegendItem>;
};

View file

@ -0,0 +1,12 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type ModelValue = {
name: string;
title: string;
unit: string;
chartType?: string;
chartColor?: string;
};

View file

@ -0,0 +1,9 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type Tag = {
key: string;
value: string;
};

View file

@ -0,0 +1,12 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type TagAction = {
name: string;
action: string;
roles?: (Array<string> | null);
link?: (string | null);
save?: boolean;
};

View file

@ -0,0 +1,11 @@
/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { TagAction } from './TagAction';
export type TagActions = {
domain: string;
key: string;
actions: Array<TagAction>;
};

View file

@ -10,6 +10,7 @@ import type { BootstrapData } from '../models/BootstrapData';
import type { CategoryRead } from '../models/CategoryRead';
import type { DataProvider } from '../models/DataProvider';
import type { FeatureInfo } from '../models/FeatureInfo';
import type { ModelInfo } from '../models/ModelInfo';
import type { Project } from '../models/Project';
import type { RoleRead } from '../models/RoleRead';
import type { Store } from '../models/Store';
@ -190,7 +191,7 @@ export class ApiService {
}
/**
* Get Feature Info
* @returns FeatureInfo Successful Response
* @returns any Successful Response
* @throws ApiError
*/
public getFeatureInfoApiFeatureInfoStoreIdGet({
@ -199,7 +200,7 @@ export class ApiService {
}: {
store: string,
id: string,
}): Observable<FeatureInfo> {
}): Observable<(FeatureInfo | null)> {
return __request(OpenAPI, this.http, {
method: 'GET',
url: '/api/feature-info/{store}/{id}',
@ -213,4 +214,26 @@ export class ApiService {
},
});
}
/**
* Get Model Info
* @returns ModelInfo Successful Response
* @throws ApiError
*/
public getModelInfoApiModelInfoStoreGet({
store,
}: {
store: string,
}): Observable<ModelInfo> {
return __request(OpenAPI, this.http, {
method: 'GET',
url: '/api/model-info/{store}',
path: {
'store': store,
},
errors: {
404: `Not found`,
422: `Validation Error`,
},
});
}
}