@en-solutions/tgm-client-sdk 1.9.6 → 1.9.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/models/api/component.models.mjs +1 -1
- package/esm2022/lib/models/api/grid.models.mjs +1 -1
- package/esm2022/lib/models/api/intervention.models.mjs +1 -1
- package/esm2022/lib/models/enums/type.enums.mjs +3 -1
- package/esm2022/lib/services/api/grid.service.mjs +16 -1
- package/fesm2022/en-solutions-tgm-client-sdk.mjs +18 -1
- package/fesm2022/en-solutions-tgm-client-sdk.mjs.map +1 -1
- package/lib/models/api/component.models.d.ts +7 -1
- package/lib/models/api/grid.models.d.ts +2 -0
- package/lib/models/api/intervention.models.d.ts +2 -0
- package/lib/models/enums/type.enums.d.ts +7 -0
- package/lib/services/api/grid.service.d.ts +20 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ComponentType, ComponentCategory, ComponentInfoType, ComponentInfoCategory, ComponentInfoStatus, MeteringParameterType, MeteringParameterSubType, AssetPhase } from '../enums';
|
|
1
|
+
import { ComponentType, ComponentCategory, ComponentInfoType, ComponentInfoCategory, ComponentInfoStatus, MeteringParameterType, MeteringParameterSubType, AssetPhase, ChainSegment } from '../enums';
|
|
2
2
|
import { Failure } from './failure.models';
|
|
3
3
|
import { StrapiFile } from './media.models';
|
|
4
4
|
import { TurbineType } from './misc.models';
|
|
@@ -9,6 +9,8 @@ export interface Component {
|
|
|
9
9
|
description?: string;
|
|
10
10
|
type?: ComponentType;
|
|
11
11
|
category?: ComponentCategory;
|
|
12
|
+
/** Position in the electricity value chain (GENERATION / TRANSMISSION / DISTRIBUTION). */
|
|
13
|
+
chainSegment?: ChainSegment;
|
|
12
14
|
status?: ComponentInfoStatus;
|
|
13
15
|
isActive?: boolean;
|
|
14
16
|
isSubComponent?: boolean;
|
|
@@ -107,6 +109,8 @@ export type ComponentUpdateRequest = ComponentCreateRequest;
|
|
|
107
109
|
export interface ComponentGroup {
|
|
108
110
|
id: number;
|
|
109
111
|
name: string;
|
|
112
|
+
/** Position in the electricity value chain (GENERATION / TRANSMISSION / DISTRIBUTION). */
|
|
113
|
+
chainSegment?: ChainSegment;
|
|
110
114
|
description?: string;
|
|
111
115
|
isActive?: boolean;
|
|
112
116
|
code?: string;
|
|
@@ -156,6 +160,8 @@ export type ComponentGroupUpdateRequest = ComponentGroupCreateRequest;
|
|
|
156
160
|
export interface SubAssembly {
|
|
157
161
|
id: number;
|
|
158
162
|
name: string;
|
|
163
|
+
/** Position in the electricity value chain (GENERATION / TRANSMISSION / DISTRIBUTION). */
|
|
164
|
+
chainSegment?: ChainSegment;
|
|
159
165
|
code?: string;
|
|
160
166
|
description?: string;
|
|
161
167
|
isActive?: boolean;
|
|
@@ -54,4 +54,6 @@ export interface GridNodeStatus {
|
|
|
54
54
|
/** Id of the worst active SensorAlert on this node — pass to acknowledge/resolve/escalate. */
|
|
55
55
|
activeAlertId?: number | null;
|
|
56
56
|
reachable: boolean;
|
|
57
|
+
/** Number of OPEN interventions covering this node (badge "travaux en cours" on the map). */
|
|
58
|
+
openInterventions?: number;
|
|
57
59
|
}
|
|
@@ -211,6 +211,8 @@ export interface InterventionRequest {
|
|
|
211
211
|
components?: any[];
|
|
212
212
|
location?: any;
|
|
213
213
|
company?: any;
|
|
214
|
+
/** Grid Management: grid node(s) this intervention covers (lazy — read with ?populate=gridNodeIds). */
|
|
215
|
+
gridNodeIds?: number[];
|
|
214
216
|
locationId?: number;
|
|
215
217
|
unitId?: number;
|
|
216
218
|
componentId?: number;
|
|
@@ -81,6 +81,13 @@ export declare const ComponentType: {
|
|
|
81
81
|
readonly HYBRID_PLANT: "HYBRIDPLANT";
|
|
82
82
|
};
|
|
83
83
|
export type ComponentType = (typeof ComponentType)[keyof typeof ComponentType];
|
|
84
|
+
/** Position of an asset element in the electricity value chain. */
|
|
85
|
+
export declare const ChainSegment: {
|
|
86
|
+
readonly GENERATION: "GENERATION";
|
|
87
|
+
readonly TRANSMISSION: "TRANSMISSION";
|
|
88
|
+
readonly DISTRIBUTION: "DISTRIBUTION";
|
|
89
|
+
};
|
|
90
|
+
export type ChainSegment = (typeof ChainSegment)[keyof typeof ChainSegment];
|
|
84
91
|
export declare const ConversationType: {
|
|
85
92
|
readonly DIRECT: "DIRECT";
|
|
86
93
|
readonly GROUP: "GROUP";
|
|
@@ -4,6 +4,7 @@ import { WebSocketService } from '../../core/websocket.service';
|
|
|
4
4
|
import { BaseCrudService } from './base-crud.service';
|
|
5
5
|
import { ApiResponse } from '../../models/base.models';
|
|
6
6
|
import { GridLink, GridNode, GridNodeStatus } from '../../models/api/grid.models';
|
|
7
|
+
import { InterventionRequest } from '../../models/api/intervention.models';
|
|
7
8
|
import * as i0 from "@angular/core";
|
|
8
9
|
/** CRUD for grid nodes (`/api/grid/nodes`). Requires the grid-management plugin. */
|
|
9
10
|
export declare class GridNodeService extends BaseCrudService<GridNode> {
|
|
@@ -49,6 +50,25 @@ export declare class GridService {
|
|
|
49
50
|
autoResponse(): Observable<ApiResponse<{
|
|
50
51
|
changed: number;
|
|
51
52
|
}>>;
|
|
53
|
+
/**
|
|
54
|
+
* Raise a maintenance intervention on a single grid node — routes the work into the core
|
|
55
|
+
* Intervention/Maintenance module, pre-filled from the node (component/location/grid link).
|
|
56
|
+
* `POST /api/grid/nodes/{id}/intervention`.
|
|
57
|
+
*/
|
|
58
|
+
createIntervention(nodeId: number, body?: {
|
|
59
|
+
title?: string;
|
|
60
|
+
description?: string;
|
|
61
|
+
priority?: string;
|
|
62
|
+
}): Observable<ApiResponse<InterventionRequest>>;
|
|
63
|
+
/**
|
|
64
|
+
* Raise ONE intervention covering several grid nodes (e.g. a feeder reconfiguration).
|
|
65
|
+
* `POST /api/grid/interventions`.
|
|
66
|
+
*/
|
|
67
|
+
createInterventionForNodes(gridNodeIds: number[], body?: {
|
|
68
|
+
title?: string;
|
|
69
|
+
description?: string;
|
|
70
|
+
priority?: string;
|
|
71
|
+
}): Observable<ApiResponse<InterventionRequest>>;
|
|
52
72
|
/**
|
|
53
73
|
* Live stream of full status snapshots pushed on `/topic/grid/status`.
|
|
54
74
|
* Ensure {@link WebSocketService.connect} has been called once after login.
|
package/package.json
CHANGED