forked from ddrilling/asb_cloud_front
api client update
This commit is contained in:
parent
732e793527
commit
13f56cda57
@ -5,14 +5,17 @@ export { ApiError } from './core/ApiError';
|
||||
export { OpenAPI } from './core/OpenAPI';
|
||||
|
||||
export type { AuthDto } from './models/AuthDto';
|
||||
export type { ClusterAnalysisDto } from './models/ClusterAnalysisDto';
|
||||
export type { ClusterDto } from './models/ClusterDto';
|
||||
export type { ClusterStatDto } from './models/ClusterStatDto';
|
||||
export type { CompanyDto } from './models/CompanyDto';
|
||||
export type { DataSaubBaseDto } from './models/DataSaubBaseDto';
|
||||
export type { DatesRangeDto } from './models/DatesRangeDto';
|
||||
export type { DepositDto } from './models/DepositDto';
|
||||
export type { EventDto } from './models/EventDto';
|
||||
export type { MessageDto } from './models/MessageDto';
|
||||
export type { MessageDtoPaginationContainer } from './models/MessageDtoPaginationContainer';
|
||||
export type { OperationDto } from './models/OperationDto';
|
||||
export type { OperationDtoPaginationContainer } from './models/OperationDtoPaginationContainer';
|
||||
export type { OperationDurationDto } from './models/OperationDurationDto';
|
||||
export type { TelemetryInfoDto } from './models/TelemetryInfoDto';
|
||||
export type { TelemetryMessageDto } from './models/TelemetryMessageDto';
|
||||
@ -21,6 +24,8 @@ export type { UserTokenDto } from './models/UserTokenDto';
|
||||
export type { WellDepthToDayDto } from './models/WellDepthToDayDto';
|
||||
export type { WellDepthToIntervalDto } from './models/WellDepthToIntervalDto';
|
||||
export type { WellDto } from './models/WellDto';
|
||||
export type { WellSectionDto } from './models/WellSectionDto';
|
||||
export type { WellStatDto } from './models/WellStatDto';
|
||||
|
||||
export { AnalyticsService } from './services/AnalyticsService';
|
||||
export { AuthService } from './services/AuthService';
|
||||
|
@ -1,7 +0,0 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type ClusterAnalysisDto = {
|
||||
id?: number;
|
||||
}
|
@ -4,8 +4,8 @@
|
||||
|
||||
export type ClusterDto = {
|
||||
id?: number;
|
||||
name?: string | null;
|
||||
caption?: string | null;
|
||||
description?: string | null;
|
||||
latitude?: number;
|
||||
longitude?: number;
|
||||
latitude?: number | null;
|
||||
longitude?: number | null;
|
||||
}
|
14
src/services/api/models/ClusterStatDto.ts
Normal file
14
src/services/api/models/ClusterStatDto.ts
Normal file
@ -0,0 +1,14 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { WellStatDto } from './WellStatDto';
|
||||
|
||||
export type ClusterStatDto = {
|
||||
id?: number;
|
||||
caption?: string | null;
|
||||
description?: string | null;
|
||||
latitude?: number | null;
|
||||
longitude?: number | null;
|
||||
wellsStat?: Array<WellStatDto> | null;
|
||||
}
|
9
src/services/api/models/CompanyDto.ts
Normal file
9
src/services/api/models/CompanyDto.ts
Normal file
@ -0,0 +1,9 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type CompanyDto = {
|
||||
id?: number;
|
||||
caption?: string | null;
|
||||
companyType?: string | null;
|
||||
}
|
@ -38,4 +38,6 @@ export type DataSaubBaseDto = {
|
||||
flow?: number | null;
|
||||
flowIdle?: number | null;
|
||||
flowDeltaLimitMax?: number | null;
|
||||
idFeedRegulator?: number | null;
|
||||
mseState?: number | null;
|
||||
}
|
@ -6,6 +6,6 @@ export type DepositDto = {
|
||||
id?: number;
|
||||
name?: string | null;
|
||||
description?: string | null;
|
||||
latitude?: number;
|
||||
longitude?: number;
|
||||
latitude?: number | null;
|
||||
longitude?: number | null;
|
||||
}
|
12
src/services/api/models/OperationDto.ts
Normal file
12
src/services/api/models/OperationDto.ts
Normal file
@ -0,0 +1,12 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type OperationDto = {
|
||||
id?: number;
|
||||
name?: string | null;
|
||||
beginDate?: string;
|
||||
endDate?: string;
|
||||
startWellDepth?: number;
|
||||
endWellDepth?: number;
|
||||
}
|
12
src/services/api/models/OperationDtoPaginationContainer.ts
Normal file
12
src/services/api/models/OperationDtoPaginationContainer.ts
Normal file
@ -0,0 +1,12 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { OperationDto } from './OperationDto';
|
||||
|
||||
export type OperationDtoPaginationContainer = {
|
||||
skip?: number;
|
||||
take?: number;
|
||||
count?: number;
|
||||
items?: Array<OperationDto> | null;
|
||||
}
|
@ -3,6 +3,6 @@
|
||||
/* eslint-disable */
|
||||
|
||||
export type OperationDurationDto = {
|
||||
processName?: string | null;
|
||||
operationName?: string | null;
|
||||
duration?: number;
|
||||
}
|
@ -9,7 +9,7 @@ export type UserTokenDto = {
|
||||
surname?: string | null;
|
||||
patronymic?: string | null;
|
||||
id?: number;
|
||||
customerName?: string | null;
|
||||
companyName?: string | null;
|
||||
roleName?: string | null;
|
||||
token?: string | null;
|
||||
}
|
@ -8,6 +8,7 @@ export type WellDto = {
|
||||
deposit?: string | null;
|
||||
id?: number;
|
||||
lastData?: any;
|
||||
latitude?: number;
|
||||
longitude?: number;
|
||||
latitude?: number | null;
|
||||
longitude?: number | null;
|
||||
wellType?: string | null;
|
||||
}
|
21
src/services/api/models/WellSectionDto.ts
Normal file
21
src/services/api/models/WellSectionDto.ts
Normal file
@ -0,0 +1,21 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type WellSectionDto = {
|
||||
sectionType?: string | null;
|
||||
wellDepthPlan?: number;
|
||||
wellDepthFact?: number;
|
||||
buildDaysPlan?: number;
|
||||
buildDaysFact?: number;
|
||||
rateOfPenetrationPlan?: number;
|
||||
rateOfPenetrationFact?: number;
|
||||
routeSpeedPlan?: number;
|
||||
routeSpeedFact?: number;
|
||||
bhaUpSpeedPlan?: number;
|
||||
bhaUpSpeedFact?: number;
|
||||
bhaDownSpeedPlan?: number;
|
||||
bhaDownSpeedFact?: number;
|
||||
casingDownSpeedPlan?: number;
|
||||
casingDownSpeedFact?: number;
|
||||
}
|
28
src/services/api/models/WellStatDto.ts
Normal file
28
src/services/api/models/WellStatDto.ts
Normal file
@ -0,0 +1,28 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { CompanyDto } from './CompanyDto';
|
||||
import type { WellSectionDto } from './WellSectionDto';
|
||||
|
||||
export type WellStatDto = {
|
||||
caption?: string | null;
|
||||
cluster?: string | null;
|
||||
deposit?: string | null;
|
||||
id?: number;
|
||||
lastData?: any;
|
||||
latitude?: number | null;
|
||||
longitude?: number | null;
|
||||
wellType?: string | null;
|
||||
planStart?: string | null;
|
||||
planEnd?: string | null;
|
||||
factStart?: string | null;
|
||||
factEnd?: string | null;
|
||||
unProductiveDays?: number | null;
|
||||
rateOfPenetrationPlan?: number | null;
|
||||
rateOfPenetrationFact?: number | null;
|
||||
routeSpeedPlan?: number | null;
|
||||
routeSpeedFact?: number | null;
|
||||
sections?: Array<WellSectionDto> | null;
|
||||
companies?: Array<CompanyDto> | null;
|
||||
}
|
@ -1,6 +1,7 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
import type { OperationDtoPaginationContainer } from '../models/OperationDtoPaginationContainer';
|
||||
import type { OperationDurationDto } from '../models/OperationDurationDto';
|
||||
import type { WellDepthToDayDto } from '../models/WellDepthToDayDto';
|
||||
import type { WellDepthToIntervalDto } from '../models/WellDepthToIntervalDto';
|
||||
@ -8,6 +9,39 @@ import { request as __request } from '../core/request';
|
||||
|
||||
export class AnalyticsService {
|
||||
|
||||
/**
|
||||
* Возвращает список операций на скважине за все время
|
||||
* @param wellId id скважины
|
||||
* @param skip для пагинации кол-во записей пропустить
|
||||
* @param take для пагинации кол-во записей
|
||||
* @param categoryIds список категорий
|
||||
* @param begin дата начала
|
||||
* @param end окончание
|
||||
* @returns OperationDtoPaginationContainer Success
|
||||
* @throws ApiError
|
||||
*/
|
||||
public static async getOperationsByWell(
|
||||
wellId: number,
|
||||
skip: number,
|
||||
take: number = 32,
|
||||
categoryIds?: Array<number>,
|
||||
begin?: string,
|
||||
end?: string,
|
||||
): Promise<OperationDtoPaginationContainer> {
|
||||
const result = await __request({
|
||||
method: 'GET',
|
||||
path: `/api/analytics/${wellId}/operationsByWell`,
|
||||
query: {
|
||||
'skip': skip,
|
||||
'take': take,
|
||||
'categoryIds': categoryIds,
|
||||
'begin': begin,
|
||||
'end': end,
|
||||
},
|
||||
});
|
||||
return result.body;
|
||||
}
|
||||
|
||||
/**
|
||||
* Возвращает данные по скважине "глубина-день"
|
||||
* @param wellId id скважины
|
||||
@ -27,22 +61,22 @@ wellId: number,
|
||||
/**
|
||||
* Возвращает данные по глубине скважины за период
|
||||
* @param wellId id скважины
|
||||
* @param intervalHoursTimestamp количество секунд в необходимом интервале времени
|
||||
* @param workBeginTimestamp количество секунд в времени начала смены
|
||||
* @param intervalSeconds количество секунд в необходимом интервале времени
|
||||
* @param workBeginSeconds количество секунд в времени начала смены
|
||||
* @returns WellDepthToIntervalDto Success
|
||||
* @throws ApiError
|
||||
*/
|
||||
public static async getWellDepthToInterval(
|
||||
wellId: number,
|
||||
intervalHoursTimestamp?: number,
|
||||
workBeginTimestamp?: number,
|
||||
intervalSeconds?: number,
|
||||
workBeginSeconds?: number,
|
||||
): Promise<Array<WellDepthToIntervalDto>> {
|
||||
const result = await __request({
|
||||
method: 'GET',
|
||||
path: `/api/analytics/${wellId}/wellDepthToInterval`,
|
||||
query: {
|
||||
'intervalHoursTimestamp': intervalHoursTimestamp,
|
||||
'workBeginTimestamp': workBeginTimestamp,
|
||||
'intervalSeconds': intervalSeconds,
|
||||
'workBeginSeconds': workBeginSeconds,
|
||||
},
|
||||
});
|
||||
return result.body;
|
||||
@ -75,22 +109,22 @@ end?: string,
|
||||
/**
|
||||
* Возвращает детальные данные по операциям на скважине за период
|
||||
* @param wellId id скважины
|
||||
* @param intervalHoursTimestamp количество секунд в необходимом интервале времени
|
||||
* @param workBeginTimestamp количество секунд в времени начала смены
|
||||
* @param intervalSeconds количество секунд в необходимом интервале времени
|
||||
* @param workBeginSeconds количество секунд в времени начала смены
|
||||
* @returns OperationDurationDto Success
|
||||
* @throws ApiError
|
||||
*/
|
||||
public static async getOperationsToInterval(
|
||||
wellId: number,
|
||||
intervalHoursTimestamp?: number,
|
||||
workBeginTimestamp?: number,
|
||||
intervalSeconds?: number,
|
||||
workBeginSeconds?: number,
|
||||
): Promise<Array<OperationDurationDto>> {
|
||||
const result = await __request({
|
||||
method: 'GET',
|
||||
path: `/api/analytics/${wellId}/operationsToInterval`,
|
||||
query: {
|
||||
'intervalHoursTimestamp': intervalHoursTimestamp,
|
||||
'workBeginTimestamp': workBeginTimestamp,
|
||||
'intervalSeconds': intervalSeconds,
|
||||
'workBeginSeconds': workBeginSeconds,
|
||||
},
|
||||
});
|
||||
return result.body;
|
||||
|
@ -1,8 +1,8 @@
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
import type { ClusterAnalysisDto } from '../models/ClusterAnalysisDto';
|
||||
import type { ClusterDto } from '../models/ClusterDto';
|
||||
import type { ClusterStatDto } from '../models/ClusterStatDto';
|
||||
import type { WellDto } from '../models/WellDto';
|
||||
import { request as __request } from '../core/request';
|
||||
|
||||
@ -23,32 +23,32 @@ export class ClusterService {
|
||||
|
||||
/**
|
||||
* Получение доступных пользователю скважин
|
||||
* @param clusterId
|
||||
* @param idCluster
|
||||
* @returns WellDto Success
|
||||
* @throws ApiError
|
||||
*/
|
||||
public static async getWells(
|
||||
clusterId: number,
|
||||
idCluster: number,
|
||||
): Promise<Array<WellDto>> {
|
||||
const result = await __request({
|
||||
method: 'GET',
|
||||
path: `/api/cluster/${clusterId}`,
|
||||
path: `/api/cluster/${idCluster}`,
|
||||
});
|
||||
return result.body;
|
||||
}
|
||||
|
||||
/**
|
||||
* Получение обопщенной аналитики по кусту (лучшая/худшая скважина)
|
||||
* @param clusterId
|
||||
* @returns ClusterAnalysisDto Success
|
||||
* Получение обопщенной статистики по кусту (лучшая/худшая скважина)
|
||||
* @param idCluster
|
||||
* @returns ClusterStatDto Success
|
||||
* @throws ApiError
|
||||
*/
|
||||
public static async getAnalysis(
|
||||
clusterId: number,
|
||||
): Promise<Array<ClusterAnalysisDto>> {
|
||||
public static async getStat(
|
||||
idCluster: number,
|
||||
): Promise<ClusterStatDto> {
|
||||
const result = await __request({
|
||||
method: 'GET',
|
||||
path: `/api/cluster/${clusterId}/Analysis`,
|
||||
path: `/api/cluster/${idCluster}/Stat`,
|
||||
});
|
||||
return result.body;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user