forked from ddrilling/asb_cloud_front
CF2-55: Added data to cluster info tables
This commit is contained in:
parent
36bd376b7a
commit
ac987546b3
@ -1,13 +1,29 @@
|
|||||||
import { Layout, Menu } from "antd";
|
import { Layout, Menu } from "antd";
|
||||||
import { Link, Switch, Route, useParams } from "react-router-dom";
|
import { Link, Switch, Route, useParams } from "react-router-dom";
|
||||||
|
import { useState, useEffect } from "react"
|
||||||
import ClusterWells from './ClusterWells'
|
import ClusterWells from './ClusterWells'
|
||||||
import ClusterSections from './ClusterSections'
|
import ClusterSections from './ClusterSections'
|
||||||
|
import LoaderPortal from '../components/LoaderPortal'
|
||||||
|
import {invokeWebApiWrapperAsync} from '../components/factory'
|
||||||
|
import {WellOperationStatService} from "../services/api";
|
||||||
|
|
||||||
const { Content } = Layout;
|
const { Content } = Layout;
|
||||||
|
|
||||||
export default function ClusterInfo() {
|
export default function ClusterInfo() {
|
||||||
let { id } = useParams();
|
let { id } = useParams();
|
||||||
let {tab} = useParams()
|
let { tab } = useParams()
|
||||||
|
const [data, setData] = useState([]);
|
||||||
|
const [showLoader, setShowLoader] = useState(false)
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
invokeWebApiWrapperAsync(
|
||||||
|
async () => {
|
||||||
|
const clusterData = await WellOperationStatService.getStatCluster(id)
|
||||||
|
setData(clusterData)
|
||||||
|
},
|
||||||
|
setShowLoader,
|
||||||
|
`Не удалось загрузить данные по кусту "${id}"`)
|
||||||
|
} ,[id])
|
||||||
|
|
||||||
return(<>
|
return(<>
|
||||||
<Layout>
|
<Layout>
|
||||||
@ -25,16 +41,18 @@ export default function ClusterInfo() {
|
|||||||
</Layout>
|
</Layout>
|
||||||
|
|
||||||
<Layout>
|
<Layout>
|
||||||
<Content className="site-layout-background">
|
<LoaderPortal show={showLoader}>
|
||||||
<Switch>
|
<Content className="site-layout-background">
|
||||||
<Route path="/cluster/:id/all">
|
<Switch>
|
||||||
<ClusterWells />
|
<Route path="/cluster/:id/all">
|
||||||
</Route>
|
<ClusterWells clusterData = {data}/>
|
||||||
<Route path="/cluster/:id/sections">
|
</Route>
|
||||||
<ClusterSections />
|
<Route path="/cluster/:id/sections">
|
||||||
</Route>
|
<ClusterSections clusterData = {data}/>
|
||||||
</Switch>
|
</Route>
|
||||||
</Content>
|
</Switch>
|
||||||
|
</Content>
|
||||||
|
</LoaderPortal>
|
||||||
</Layout>
|
</Layout>
|
||||||
</>)
|
</>)
|
||||||
}
|
}
|
@ -1,7 +1,8 @@
|
|||||||
import { Table, Tag, Button, Badge, Divider, Modal} from "antd"
|
import { Table, Tag, Button, Badge, Divider, Modal} from "antd"
|
||||||
|
import { useParams } from "react-router-dom";
|
||||||
import { LineChartOutlined, ProfileOutlined } from '@ant-design/icons'
|
import { LineChartOutlined, ProfileOutlined } from '@ant-design/icons'
|
||||||
import { useState } from "react"
|
import { useState, useEffect } from "react"
|
||||||
import { makeTextColumn, makeGroupColumn, makeNumericColumn, makeNumericColumnPlanFact, calcAndUpdateStatsBySections } from '../components/Table/index'
|
import { makeTextColumn, makeNumericColumnPlanFact, calcAndUpdateStatsBySections } from '../components/Table/index'
|
||||||
|
|
||||||
|
|
||||||
const filtersMinMax = [
|
const filtersMinMax = [
|
||||||
@ -63,17 +64,15 @@ const ModalWindowButton = ({buttonIcon, buttonText, modalTitle, modalContent}) =
|
|||||||
|
|
||||||
const columns = [
|
const columns = [
|
||||||
makeTextColumn('скв №', 'caption'),
|
makeTextColumn('скв №', 'caption'),
|
||||||
makeGroupColumn( 'По секциям', [
|
makeTextColumn('Секция', 'sectionType', filtersSectionsType),
|
||||||
makeTextColumn('Конструкция скважины', 'sectionType', filtersSectionsType),
|
makeNumericColumnPlanFact('Глубина', 'sectionWellDepth', filtersMinMax),
|
||||||
makeNumericColumnPlanFact('Глубина', 'sectionWellDepth', filtersMinMax),
|
makeNumericColumnPlanFact('Продолжительность', 'sectionBuildDays', filtersMinMax), //Цикл строительства
|
||||||
makeNumericColumnPlanFact('Продолжительность', 'sectionBuildDays', filtersMinMax), //Цикл строительства
|
makeNumericColumnPlanFact('МСП', 'sectionRateOfPenetration', filtersMinMax),
|
||||||
makeNumericColumnPlanFact('МСП', 'sectionRateOfPenetration', filtersMinMax),
|
makeNumericColumnPlanFact('Рейсовая скорость', 'sectionRouteSpeed', filtersMinMax),
|
||||||
makeNumericColumnPlanFact('Рейсовая скорость', 'sectionRouteSpeed', filtersMinMax),
|
makeNumericColumnPlanFact('Спуск КНБК', 'sectionBhaDownSpeed', filtersMinMax),//Скорость спуска КНБК
|
||||||
makeNumericColumnPlanFact('Спуск КНБК', 'sectionBhaDownSpeed', filtersMinMax),//Скорость спуска КНБК
|
makeNumericColumnPlanFact('Подъем КНБК', 'sectionBhaUpSpeed', filtersMinMax),//Скорость подъема КНБК
|
||||||
makeNumericColumnPlanFact('Подъем КНБК', 'sectionBhaUpSpeed', filtersMinMax),//Скорость подъема КНБК
|
makeNumericColumnPlanFact('Скорость спуска ОК', 'sectionCasingDownSpeed', filtersMinMax),
|
||||||
makeNumericColumnPlanFact('Скорость спуска ОК', 'sectionCasingDownSpeed', filtersMinMax),
|
makeNumericColumnPlanFact('НПВ, сут', 'notProductiveTime', filtersMinMax),
|
||||||
]),
|
|
||||||
makeNumericColumn('НПВ, сут', 'notProductiveTime', filtersMinMax, '80px'),
|
|
||||||
{
|
{
|
||||||
title: "TVD",
|
title: "TVD",
|
||||||
render: (_, record) => <ModalWindowButton
|
render: (_, record) => <ModalWindowButton
|
||||||
@ -92,51 +91,76 @@ const columns = [
|
|||||||
title: "Подрядчики",
|
title: "Подрядчики",
|
||||||
dataIndex: "companies",
|
dataIndex: "companies",
|
||||||
render: (item) =>
|
render: (item) =>
|
||||||
item.map((company) => <Tag color="blue">{company.caption}</Tag>),
|
item?.map((company) => <Tag color="blue">{company.caption}</Tag>),
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
const contractors = [
|
|
||||||
{ type: "Буровой подрядчик", caption: 'ООО "НГ-Бурение"' },
|
|
||||||
// { type: "ННБ", caption: 'ООО НПП "Буринтех"' },
|
|
||||||
// { type: "Растворный сревис", caption: 'ООО НПП "Буринтех"' },
|
|
||||||
// { type: "Цементирование", caption: "Норд-Сервис" },
|
|
||||||
]
|
|
||||||
|
|
||||||
const wellsStat = [
|
export default function ClusterSections({clusterData}) {
|
||||||
{ key:1, caption :'42669', sectionType :'Направление', sectionWellDepthPlan :80.0, sectionWellDepthFact :79.0, sectionBuildDaysPlan :19.0, sectionBuildDaysFact :10.3, sectionRateOfPenetrationPlan :60.0, sectionRateOfPenetrationFact :158.0, rateOfPenetrationPlan :60.0, rateOfPenetrationFact :63.7, sectionRouteSpeedPlan :4.2, sectionRouteSpeedFact :7.7, routeSpeedPlan :9.7, routeSpeedFact :9.2, sectionBhaDownSpeedPlan :1.0, sectionBhaDownSpeedFact :0.3, sectionBhaUpSpeedPlan :1.0, sectionBhaUpSpeedFact :0.3, sectionCasingDownSpeedPlan :2.0, sectionCasingDownSpeedFact :1.0, notProductiveTime: 10, companies :contractors },
|
let { id } = useParams()
|
||||||
{ key:2, caption :'42669', sectionType :'Кондуктор', sectionWellDepthPlan :1280.0, sectionWellDepthFact :1284.0, sectionBuildDaysPlan :90.0, sectionBuildDaysFact :138.3, sectionRateOfPenetrationPlan :60.0, sectionRateOfPenetrationFact :85.5, rateOfPenetrationPlan :60.0, rateOfPenetrationFact :63.7, sectionRouteSpeedPlan :14.2, sectionRouteSpeedFact :9.3, routeSpeedPlan :9.7, routeSpeedFact :9.2, sectionBhaDownSpeedPlan :12.5, sectionBhaDownSpeedFact :5.8, sectionBhaUpSpeedPlan :11.0, sectionBhaUpSpeedFact :10.5, sectionCasingDownSpeedPlan :10.0, sectionCasingDownSpeedFact :14.0, notProductiveTime: 11, companies :contractors },
|
const [wellsStat, setWellsStat] = useState([])
|
||||||
{ key:3, caption :'42669', sectionType :'Транспорт. Ствол', sectionWellDepthPlan :3615.9, sectionWellDepthFact :3616.0, sectionBuildDaysPlan :406.1, sectionBuildDaysFact :391.0, sectionRateOfPenetrationPlan :60.0, sectionRateOfPenetrationFact :57.7, rateOfPenetrationPlan :60.0, rateOfPenetrationFact :63.7, sectionRouteSpeedPlan :8.9, sectionRouteSpeedFact :9.2, routeSpeedPlan :9.7, routeSpeedFact :9.2, sectionBhaDownSpeedPlan :50.0, sectionBhaDownSpeedFact :40.5, sectionBhaUpSpeedPlan :52.0, sectionBhaUpSpeedFact :57.2, sectionCasingDownSpeedPlan :14.0, sectionCasingDownSpeedFact :16.3, notProductiveTime: 12, companies :contractors },
|
|
||||||
{ key:4, caption :'16311', sectionType :'Направление', sectionWellDepthPlan :80.0, sectionWellDepthFact :81.0, sectionBuildDaysPlan :10.8, sectionBuildDaysFact :11.0, sectionRateOfPenetrationPlan :60.0, sectionRateOfPenetrationFact :81.0, rateOfPenetrationPlan :60.0, rateOfPenetrationFact :63.7, sectionRouteSpeedPlan :7.4, sectionRouteSpeedFact :7.4, routeSpeedPlan :9.7, routeSpeedFact :9.2, sectionBhaDownSpeedPlan :1.0, sectionBhaDownSpeedFact :0.5, sectionBhaUpSpeedPlan :1.0, sectionBhaUpSpeedFact :0.5, sectionCasingDownSpeedPlan :1.0, sectionCasingDownSpeedFact :2.3, notProductiveTime: 13, companies :contractors },
|
|
||||||
{ key:5, caption :'16311', sectionType :'Кондуктор', sectionWellDepthPlan :1411.0, sectionWellDepthFact :1412.0, sectionBuildDaysPlan :107.8, sectionBuildDaysFact :99.0, sectionRateOfPenetrationPlan :60.0, sectionRateOfPenetrationFact :96.4, rateOfPenetrationPlan :60.0, rateOfPenetrationFact :63.7, sectionRouteSpeedPlan :13.1, sectionRouteSpeedFact :14.3, routeSpeedPlan :9.7, routeSpeedFact :9.2, sectionBhaDownSpeedPlan :12.5, sectionBhaDownSpeedFact :0.3, sectionBhaUpSpeedPlan :11.0, sectionBhaUpSpeedFact :8.8, sectionCasingDownSpeedPlan :9.0, sectionCasingDownSpeedFact :12.8, notProductiveTime: 14, companies :contractors },
|
|
||||||
{ key:6, caption :'16311', sectionType :'Транспорт. Ствол', sectionWellDepthPlan :3181.0, sectionWellDepthFact :3181.0, sectionBuildDaysPlan :171.6, sectionBuildDaysFact :171.0, sectionRateOfPenetrationPlan :35.0, sectionRateOfPenetrationFact :80.9, rateOfPenetrationPlan :60.0, rateOfPenetrationFact :63.7, sectionRouteSpeedPlan :18.5, sectionRouteSpeedFact :18.6, routeSpeedPlan :9.7, routeSpeedFact :9.2, sectionBhaDownSpeedPlan :14.0, sectionBhaDownSpeedFact :4.8, sectionBhaUpSpeedPlan :23.0, sectionBhaUpSpeedFact :14.8, sectionCasingDownSpeedPlan :15.0, sectionCasingDownSpeedFact :16.5, notProductiveTime: 15, companies :contractors },
|
|
||||||
{ key:7, caption :'16311', sectionType :'Хвостовик', sectionWellDepthPlan :4181.0, sectionWellDepthFact :4187.0, sectionBuildDaysPlan :271.9, sectionBuildDaysFact :220.0, sectionRateOfPenetrationPlan :20.0, sectionRateOfPenetrationFact :32.9, rateOfPenetrationPlan :60.0, rateOfPenetrationFact :63.7, sectionRouteSpeedPlan :15.4, sectionRouteSpeedFact :19.0, routeSpeedPlan :9.7, routeSpeedFact :9.2, sectionBhaDownSpeedPlan :61.5, sectionBhaDownSpeedFact :34.0, sectionBhaUpSpeedPlan :40.0, sectionBhaUpSpeedFact :36.5, sectionCasingDownSpeedPlan :24.5, sectionCasingDownSpeedFact :9.0, notProductiveTime: 16, companies :contractors },
|
|
||||||
{ key:8, caption :'16315', sectionType :'Направление', sectionWellDepthPlan :80.0, sectionWellDepthFact :80.0, sectionBuildDaysPlan :21.1, sectionBuildDaysFact :23.0, sectionRateOfPenetrationPlan :60.0, sectionRateOfPenetrationFact :53.3, rateOfPenetrationPlan :27.2, rateOfPenetrationFact :30.1, sectionRouteSpeedPlan :3.8, sectionRouteSpeedFact :3.5, routeSpeedPlan :14.4, routeSpeedFact :7.5, sectionBhaDownSpeedPlan :1.0, sectionBhaDownSpeedFact :0.5, sectionBhaUpSpeedPlan :1.0, sectionBhaUpSpeedFact :1.0, sectionCasingDownSpeedPlan :2.0, sectionCasingDownSpeedFact :2.0, notProductiveTime: 17, companies :contractors },
|
|
||||||
{ key:9, caption :'16315', sectionType :'Кондуктор', sectionWellDepthPlan :1500.0, sectionWellDepthFact :1505.0, sectionBuildDaysPlan :130.3, sectionBuildDaysFact :150.5, sectionRateOfPenetrationPlan :60.0, sectionRateOfPenetrationFact :58.2, rateOfPenetrationPlan :27.2, rateOfPenetrationFact :30.1, sectionRouteSpeedPlan :11.5, sectionRouteSpeedFact :10.0, routeSpeedPlan :14.4, routeSpeedFact :7.5, sectionBhaDownSpeedPlan :8.3, sectionBhaDownSpeedFact :0.5, sectionBhaUpSpeedPlan :11.0, sectionBhaUpSpeedFact :6.5, sectionCasingDownSpeedPlan :10.0, sectionCasingDownSpeedFact :11.0, notProductiveTime: 18, companies :contractors }
|
|
||||||
]
|
|
||||||
|
|
||||||
calcAndUpdateStatsBySections(wellsStat, [
|
|
||||||
"sectionWellDepthPlan",
|
|
||||||
"sectionWellDepthFact",
|
|
||||||
"sectionBuildDaysPlan",
|
|
||||||
"sectionBuildDaysFact",
|
|
||||||
"sectionRateOfPenetrationPlan",
|
|
||||||
"sectionRateOfPenetrationFact",
|
|
||||||
"sectionRouteSpeedPlan",
|
|
||||||
"sectionRouteSpeedFact",
|
|
||||||
"sectionBhaDownSpeedPlan",
|
|
||||||
"sectionBhaDownSpeedFact",
|
|
||||||
"sectionBhaUpSpeedPlan",
|
|
||||||
"sectionBhaUpSpeedFact",
|
|
||||||
"sectionCasingDownSpeedPlan",
|
|
||||||
"sectionCasingDownSpeedFact",
|
|
||||||
"notProductiveTime"
|
|
||||||
])
|
|
||||||
|
|
||||||
export default function ClusterStat() {
|
|
||||||
const [selectedWells, setSelectedWells] = useState([])
|
const [selectedWells, setSelectedWells] = useState([])
|
||||||
const [selectedWellsKeys, setSelectedWellsKeys] = useState([])
|
const [selectedWellsKeys, setSelectedWellsKeys] = useState([])
|
||||||
|
|
||||||
|
calcAndUpdateStatsBySections(wellsStat ?? [], [
|
||||||
|
"sectionWellDepthPlan",
|
||||||
|
"sectionWellDepthFact",
|
||||||
|
"sectionBuildDaysPlan",
|
||||||
|
"sectionBuildDaysFact",
|
||||||
|
"sectionRateOfPenetrationPlan",
|
||||||
|
"sectionRateOfPenetrationFact",
|
||||||
|
"sectionRouteSpeedPlan",
|
||||||
|
"sectionRouteSpeedFact",
|
||||||
|
"sectionBhaDownSpeedPlan",
|
||||||
|
"sectionBhaDownSpeedFact",
|
||||||
|
"sectionBhaUpSpeedPlan",
|
||||||
|
"sectionBhaUpSpeedFact",
|
||||||
|
"sectionCasingDownSpeedPlan",
|
||||||
|
"sectionCasingDownSpeedFact",
|
||||||
|
"notProductiveTimePlan",
|
||||||
|
"notProductiveTimeFact"
|
||||||
|
])
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
let resArr = []
|
||||||
|
|
||||||
|
clusterData.statsWells?.forEach(el => {
|
||||||
|
|
||||||
|
el.sections.forEach(section => {
|
||||||
|
let row = {
|
||||||
|
key: el.id,
|
||||||
|
id: el.id,
|
||||||
|
caption: el.caption,
|
||||||
|
sectionType: section.caption,
|
||||||
|
sectionWellDepthPlan: section.plan.wellDepthEnd,
|
||||||
|
sectionWellDepthFact: section.fact.wellDepthEnd,
|
||||||
|
sectionBuildDaysPlan: (Math.abs(new Date(section.plan.start) -
|
||||||
|
new Date(section.plan.end)) / (1000 * 60 * 60 * 24)).toFixed(2),
|
||||||
|
sectionBuildDaysFact: (Math.abs(new Date(section.fact.start) -
|
||||||
|
new Date(section.fact.end)) / (1000 * 60 * 60 * 24)).toFixed(2),
|
||||||
|
sectionRateOfPenetrationPlan: section.plan.rop.toFixed(2),
|
||||||
|
sectionRateOfPenetrationFact: section.fact.rop.toFixed(2),
|
||||||
|
sectionRouteSpeedPlan: section.plan.routeSpeed.toFixed(2),
|
||||||
|
sectionRouteSpeedFact: section.fact.routeSpeed.toFixed(2),
|
||||||
|
sectionBhaDownSpeedPlan: section.plan.bhaDownSpeed.toFixed(2),
|
||||||
|
sectionBhaDownSpeedFact: section.fact.bhaDownSpeed.toFixed(2),
|
||||||
|
sectionBhaUpSpeedPlan: section.plan.bhaUpSpeed.toFixed(2),
|
||||||
|
sectionBhaUpSpeedFact: section.fact.bhaUpSpeed.toFixed(2),
|
||||||
|
sectionCasingDownSpeedPlan: section.plan.casingDownSpeed.toFixed(2),
|
||||||
|
sectionCasingDownSpeedFact: section.fact.casingDownSpeed.toFixed(2),
|
||||||
|
notProductiveTimePlan: section.plan.nonProductiveHours.toFixed(2),
|
||||||
|
notProductiveTimeFact: section.fact.nonProductiveHours.toFixed(2),
|
||||||
|
companies: el.companies
|
||||||
|
}
|
||||||
|
|
||||||
|
resArr.push(row)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
setWellsStat(resArr)
|
||||||
|
|
||||||
|
}, [id, clusterData])
|
||||||
|
|
||||||
const rowSelection = {
|
const rowSelection = {
|
||||||
selectedRowKeys: selectedWellsKeys,
|
selectedRowKeys: selectedWellsKeys,
|
||||||
onChange: (keys, items) => {
|
onChange: (keys, items) => {
|
||||||
@ -144,7 +168,7 @@ export default function ClusterStat() {
|
|||||||
setSelectedWellsKeys(keys)
|
setSelectedWellsKeys(keys)
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<Table
|
<Table
|
||||||
|
@ -1,11 +1,9 @@
|
|||||||
import { useParams } from "react-router-dom";
|
import { useParams } from "react-router-dom";
|
||||||
import { Link } from "react-router-dom";
|
import { Link } from "react-router-dom";
|
||||||
import LoaderPortal from '../components/LoaderPortal'
|
|
||||||
import { useState, useEffect } from "react";
|
import { useState, useEffect } from "react";
|
||||||
import { ClusterService } from '../services/api'
|
|
||||||
import { notify } from "../components/factory"
|
|
||||||
import { Table, Tag, Button } from 'antd';
|
import { Table, Tag, Button } from 'antd';
|
||||||
import { makeTextColumn, makeGroupColumn, makeNumericColumn, makeNumericColumnPlanFact, calcAndUpdateStatsBySections } from '../components/Table/index'
|
import { makeTextColumn, makeGroupColumn, makeNumericColumn,
|
||||||
|
makeNumericColumnPlanFact, calcAndUpdateStatsBySections } from '../components/Table/index'
|
||||||
|
|
||||||
|
|
||||||
const filtersMinMax = [
|
const filtersMinMax = [
|
||||||
@ -30,63 +28,49 @@ const filtersWellsType = [
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
const contractors = [
|
|
||||||
{ type: "Буровой подрядчик", caption: 'ООО "НГ-Бурение"' },
|
|
||||||
// { type: "ННБ", caption: 'ООО НПП "Буринтех"' },
|
|
||||||
// { type: "Растворный сревис", caption: 'ООО НПП "Буринтех"' },
|
|
||||||
// { type: "Цементирование", caption: "Норд-Сервис" },
|
|
||||||
]
|
|
||||||
|
|
||||||
const wellsStatDefault = [
|
export default function ClusterWells({clusterData}) {
|
||||||
{ key:1, caption :'42669', wellType :'Наклонно-направленная', factStart: 5, factEnd: 12, periodPlan :80.0, periodFact :79.0, rateOfPenetrationPlan :19.0, rateOfPenetrationFact :10.3, routeSpeedPlan :60.0, routeSpeedFact :158.0, notProductiveTime: 10, companies :contractors },
|
|
||||||
{ key:2, caption :'42669', wellType :'Горизонтальная', factStart: 7, factEnd: 11, periodPlan :1280.0, periodFact :1284.0, rateOfPenetrationPlan :90.0, rateOfPenetrationFact :138.3, routeSpeedPlan :60.0, routeSpeedFact :85.5, notProductiveTime: 11, companies :contractors },
|
|
||||||
{ key:3, caption :'42669', wellType :'Наклонно-направленная', factStart: 8, factEnd: 13, periodPlan :3615.9, periodFact :3616.0, rateOfPenetrationPlan :406.1, rateOfPenetrationFact :391.0, routeSpeedPlan :60.0, routeSpeedFact :57.7, notProductiveTime: 12, companies :contractors },
|
|
||||||
{ key:4, caption :'16311', wellType :'Наклонно-направленная', factStart: 9, factEnd: 17, periodPlan :80.0, periodFact :81.0, rateOfPenetrationPlan :10.8, rateOfPenetrationFact :11.0, routeSpeedPlan :60.0, routeSpeedFact :81.0, notProductiveTime: 13, companies :contractors },
|
|
||||||
{ key:5, caption :'16314', wellType :'Горизонтальная', factStart: 15, factEnd: 15, periodPlan :1411.0, periodFact :1412.0, rateOfPenetrationPlan :107.8, rateOfPenetrationFact :99.0, routeSpeedPlan :60.0, routeSpeedFact :96.4, notProductiveTime: 14, companies :contractors },
|
|
||||||
{ key:6, caption :'16311', wellType :'Наклонно-направленная', factStart: 14, factEnd: 20, periodPlan :3181.0, periodFact :3181.0, rateOfPenetrationPlan :171.6, rateOfPenetrationFact :171.0, routeSpeedPlan :35.0, routeSpeedFact :80.9, notProductiveTime: 15, companies :contractors },
|
|
||||||
{ key:7, caption :'16311', wellType :'Горизонтальная', factStart: 12, factEnd: 21, periodPlan :4181.0, periodFact :4187.0, rateOfPenetrationPlan :271.9, rateOfPenetrationFact :220.0, routeSpeedPlan :20.0, routeSpeedFact :32.9, notProductiveTime: 16, companies :contractors },
|
|
||||||
{ key:8, caption :'16315', wellType :'Наклонно-направленная', factStart: 13, factEnd: 22, periodPlan :80.0, periodFact :80.0, rateOfPenetrationPlan :21.1, rateOfPenetrationFact :23.0, routeSpeedPlan :60.0, routeSpeedFact :53.3, notProductiveTime: 17, companies :contractors },
|
|
||||||
{ key:9, caption :'16315', wellType :'Горизонтальная', factStart: 11, factEnd: 23, periodPlan :1500.0, periodFact :1505.0, rateOfPenetrationPlan :130.3, rateOfPenetrationFact :150.5, routeSpeedPlan :60.0, routeSpeedFact :58.2, notProductiveTime: 18, companies :contractors }
|
|
||||||
]
|
|
||||||
|
|
||||||
calcAndUpdateStatsBySections(wellsStatDefault, [
|
|
||||||
"factStart",
|
|
||||||
"factEnd",
|
|
||||||
"periodPlan",
|
|
||||||
"periodFact",
|
|
||||||
"rateOfPenetrationPlan",
|
|
||||||
"rateOfPenetrationFact",
|
|
||||||
"routeSpeedPlan",
|
|
||||||
"routeSpeedFact",
|
|
||||||
"notProductiveTime"
|
|
||||||
])
|
|
||||||
|
|
||||||
export default function Cluster() {
|
|
||||||
let { id } = useParams()
|
let { id } = useParams()
|
||||||
const [wellsStat, setWellsStat] = useState(wellsStatDefault)
|
const [wellsStat, setWellsStat] = useState([])
|
||||||
const [showLoader, setShowLoader] = useState(false)
|
|
||||||
|
calcAndUpdateStatsBySections(wellsStat ?? [], [
|
||||||
|
"factStart",
|
||||||
|
"factEnd",
|
||||||
|
"periodPlan",
|
||||||
|
"periodFact",
|
||||||
|
"rateOfPenetrationPlan",
|
||||||
|
"rateOfPenetrationFact",
|
||||||
|
"routeSpeedPlan",
|
||||||
|
"routeSpeedFact",
|
||||||
|
"notProductiveTime"
|
||||||
|
])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const updateWellsStat = async () => {
|
let tableData = clusterData.statsWells?.map(el => {
|
||||||
setShowLoader(true)
|
return {
|
||||||
try {
|
key: el.id,
|
||||||
const msInDay = 1000 * 60 * 60 * 24
|
id: el.id,
|
||||||
const data = await ClusterService.getStat(id)
|
caption: el.caption,
|
||||||
const wellsStat = data.wellsStat.map(w => ({
|
wellType: el.wellType,
|
||||||
...w,
|
factStart: new Date(el.total.fact.start).toLocaleString(),
|
||||||
periodPlan: (new Date(w.planEnd) - new Date(w.planStart)) / msInDay,
|
factEnd: new Date(el.total.fact.end).toLocaleString(),
|
||||||
periodFact: (new Date(w.factEnd) - new Date(w.factStart)) / msInDay,
|
periodPlan: (Math.abs(new Date(el.total.plan.start) -
|
||||||
}))
|
new Date(el.total.plan.end)) / (1000 * 60 * 60 * 24)).toFixed(2),
|
||||||
setWellsStat(wellsStat)
|
periodFact: (Math.abs(new Date(el.total.fact.start) -
|
||||||
|
new Date(el.total.fact.end)) / (1000 * 60 * 60 * 24)).toFixed(2),
|
||||||
|
rateOfPenetrationPlan: el.total.plan.rop.toFixed(2),
|
||||||
|
rateOfPenetrationFact: el.total.fact.rop.toFixed(2),
|
||||||
|
routeSpeedPlan: el.total.plan.routeSpeed.toFixed(2),
|
||||||
|
routeSpeedFact: el.total.fact.routeSpeed.toFixed(2),
|
||||||
|
notProductiveTimePlan: el.total.plan.nonProductiveHours.toFixed(2),
|
||||||
|
notProductiveTimeFact: el.total.fact.nonProductiveHours.toFixed(2),
|
||||||
|
companies: el.companies
|
||||||
}
|
}
|
||||||
catch (ex) {
|
})
|
||||||
notify(`Не удалось загрузить статистику по скважинам куста "${id}"`, 'error')
|
|
||||||
console.log(ex)
|
setWellsStat(tableData)
|
||||||
}
|
|
||||||
setShowLoader(false)
|
}, [id, clusterData])
|
||||||
}
|
|
||||||
updateWellsStat()
|
|
||||||
}, [id])
|
|
||||||
|
|
||||||
const columns = [
|
const columns = [
|
||||||
makeTextColumn('скв №', 'caption', null, null,
|
makeTextColumn('скв №', 'caption', null, null,
|
||||||
@ -99,7 +83,7 @@ export default function Cluster() {
|
|||||||
makeNumericColumnPlanFact('Продолжительность', 'period', filtersMinMax),
|
makeNumericColumnPlanFact('Продолжительность', 'period', filtersMinMax),
|
||||||
makeNumericColumnPlanFact('МСП', 'rateOfPenetration', filtersMinMax),
|
makeNumericColumnPlanFact('МСП', 'rateOfPenetration', filtersMinMax),
|
||||||
makeNumericColumnPlanFact('Рейсовая скорость', 'routeSpeed', filtersMinMax),
|
makeNumericColumnPlanFact('Рейсовая скорость', 'routeSpeed', filtersMinMax),
|
||||||
makeNumericColumn('НПВ, сут', 'notProductiveTime', filtersMinMax),
|
makeNumericColumnPlanFact('НПВ, сут', 'notProductiveTime', filtersMinMax),
|
||||||
{
|
{
|
||||||
title: 'График глубина-день',
|
title: 'График глубина-день',
|
||||||
render: (_, item) => (<Button>Открыть</Button>)
|
render: (_, item) => (<Button>Открыть</Button>)
|
||||||
@ -117,15 +101,14 @@ export default function Cluster() {
|
|||||||
];
|
];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<LoaderPortal show={showLoader}>
|
<Table
|
||||||
<Table
|
columns={columns}
|
||||||
columns={columns}
|
dataSource={wellsStat}
|
||||||
dataSource={wellsStat}
|
size={'small'}
|
||||||
size={'small'}
|
bordered
|
||||||
bordered
|
pagination={false}
|
||||||
pagination={false}
|
rowKey={(record) => record.id}
|
||||||
rowKey={(record) => record.id}
|
className={'mt-20px'}
|
||||||
className={'mt-20px'}
|
/>
|
||||||
/>
|
)
|
||||||
</LoaderPortal>)
|
|
||||||
}
|
}
|
@ -2,7 +2,7 @@ import { useState, useEffect } from 'react'
|
|||||||
import LoaderPortal from '../../components/LoaderPortal'
|
import LoaderPortal from '../../components/LoaderPortal'
|
||||||
import { invokeWebApiWrapperAsync } from '../../components/factory'
|
import { invokeWebApiWrapperAsync } from '../../components/factory'
|
||||||
import { Table, makeColumn, makeColumnsPlanFact } from '../../components/Table'
|
import { Table, makeColumn, makeColumnsPlanFact } from '../../components/Table'
|
||||||
import { WellSectionService } from '../../services/api'
|
import { WellOperationStatService } from '../../services/api'
|
||||||
|
|
||||||
const makeNumberRender = (format) => ((value) => (+value).toFixed(format))
|
const makeNumberRender = (format) => ((value) => (+value).toFixed(format))
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ export const WellSectionsStat = ({idWell}) => {
|
|||||||
|
|
||||||
useEffect(() => invokeWebApiWrapperAsync(
|
useEffect(() => invokeWebApiWrapperAsync(
|
||||||
async () => {
|
async () => {
|
||||||
const sectionsResponse = await WellSectionService.getSectionsByWellId(idWell)
|
const sectionsResponse = await WellOperationStatService.getSectionsByWellId(idWell)
|
||||||
|
|
||||||
if(sectionsResponse){
|
if(sectionsResponse){
|
||||||
const sections = sectionsResponse.sort((a,b)=>a.wellDepthPlan - b.wellDepthPlan)
|
const sections = sectionsResponse.sort((a,b)=>a.wellDepthPlan - b.wellDepthPlan)
|
||||||
|
@ -6,7 +6,6 @@ export { OpenAPI } from './core/OpenAPI';
|
|||||||
|
|
||||||
export type { AuthDto } from './models/AuthDto';
|
export type { AuthDto } from './models/AuthDto';
|
||||||
export type { ClusterDto } from './models/ClusterDto';
|
export type { ClusterDto } from './models/ClusterDto';
|
||||||
export type { ClusterStatDto } from './models/ClusterStatDto';
|
|
||||||
export type { CompanyDto } from './models/CompanyDto';
|
export type { CompanyDto } from './models/CompanyDto';
|
||||||
export type { DataSaubBaseDto } from './models/DataSaubBaseDto';
|
export type { DataSaubBaseDto } from './models/DataSaubBaseDto';
|
||||||
export type { DatesRangeDto } from './models/DatesRangeDto';
|
export type { DatesRangeDto } from './models/DatesRangeDto';
|
||||||
@ -19,6 +18,11 @@ export type { MessageDto } from './models/MessageDto';
|
|||||||
export type { MessageDtoPaginationContainer } from './models/MessageDtoPaginationContainer';
|
export type { MessageDtoPaginationContainer } from './models/MessageDtoPaginationContainer';
|
||||||
export type { MudDiagramDataDto } from './models/MudDiagramDataDto';
|
export type { MudDiagramDataDto } from './models/MudDiagramDataDto';
|
||||||
export type { NnbDataDto } from './models/NnbDataDto';
|
export type { NnbDataDto } from './models/NnbDataDto';
|
||||||
|
export type { StatClusterDto } from './models/StatClusterDto';
|
||||||
|
export type { StatOperationsDto } from './models/StatOperationsDto';
|
||||||
|
export type { StatOperationsDtoPlanFactBase } from './models/StatOperationsDtoPlanFactBase';
|
||||||
|
export type { StatSectionDto } from './models/StatSectionDto';
|
||||||
|
export type { StatWellDto } from './models/StatWellDto';
|
||||||
export type { TelemetryInfoDto } from './models/TelemetryInfoDto';
|
export type { TelemetryInfoDto } from './models/TelemetryInfoDto';
|
||||||
export type { TelemetryMessageDto } from './models/TelemetryMessageDto';
|
export type { TelemetryMessageDto } from './models/TelemetryMessageDto';
|
||||||
export type { TelemetryOperationDto } from './models/TelemetryOperationDto';
|
export type { TelemetryOperationDto } from './models/TelemetryOperationDto';
|
||||||
@ -32,8 +36,6 @@ export type { WellDto } from './models/WellDto';
|
|||||||
export type { WellOperationCategoryDto } from './models/WellOperationCategoryDto';
|
export type { WellOperationCategoryDto } from './models/WellOperationCategoryDto';
|
||||||
export type { WellOperationDto } from './models/WellOperationDto';
|
export type { WellOperationDto } from './models/WellOperationDto';
|
||||||
export type { WellOperationDtoPaginationContainer } from './models/WellOperationDtoPaginationContainer';
|
export type { WellOperationDtoPaginationContainer } from './models/WellOperationDtoPaginationContainer';
|
||||||
export type { WellSectionDto } from './models/WellSectionDto';
|
|
||||||
export type { WellStatDto } from './models/WellStatDto';
|
|
||||||
|
|
||||||
export { AuthService } from './services/AuthService';
|
export { AuthService } from './services/AuthService';
|
||||||
export { ClusterService } from './services/ClusterService';
|
export { ClusterService } from './services/ClusterService';
|
||||||
@ -48,5 +50,5 @@ export { ReportService } from './services/ReportService';
|
|||||||
export { TelemetryAnalyticsService } from './services/TelemetryAnalyticsService';
|
export { TelemetryAnalyticsService } from './services/TelemetryAnalyticsService';
|
||||||
export { TelemetryService } from './services/TelemetryService';
|
export { TelemetryService } from './services/TelemetryService';
|
||||||
export { WellOperationService } from './services/WellOperationService';
|
export { WellOperationService } from './services/WellOperationService';
|
||||||
export { WellSectionService } from './services/WellSectionService';
|
export { WellOperationStatService } from './services/WellOperationStatService';
|
||||||
export { WellService } from './services/WellService';
|
export { WellService } from './services/WellService';
|
||||||
|
@ -1,16 +0,0 @@
|
|||||||
/* istanbul ignore file */
|
|
||||||
/* tslint:disable */
|
|
||||||
/* eslint-disable */
|
|
||||||
|
|
||||||
import type { WellDto } from './WellDto';
|
|
||||||
import type { WellStatDto } from './WellStatDto';
|
|
||||||
|
|
||||||
export type ClusterStatDto = {
|
|
||||||
id?: number;
|
|
||||||
caption?: string | null;
|
|
||||||
description?: string | null;
|
|
||||||
latitude?: number | null;
|
|
||||||
longitude?: number | null;
|
|
||||||
wells?: Array<WellDto> | null;
|
|
||||||
wellsStat?: Array<WellStatDto> | null;
|
|
||||||
}
|
|
11
src/services/api/models/StatClusterDto.ts
Normal file
11
src/services/api/models/StatClusterDto.ts
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
/* istanbul ignore file */
|
||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
|
||||||
|
import type { StatWellDto } from './StatWellDto';
|
||||||
|
|
||||||
|
export type StatClusterDto = {
|
||||||
|
id?: number;
|
||||||
|
caption?: string | null;
|
||||||
|
statsWells?: Array<StatWellDto> | null;
|
||||||
|
}
|
16
src/services/api/models/StatOperationsDto.ts
Normal file
16
src/services/api/models/StatOperationsDto.ts
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
/* istanbul ignore file */
|
||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
|
||||||
|
export type StatOperationsDto = {
|
||||||
|
start?: string;
|
||||||
|
end?: string;
|
||||||
|
wellDepthStart?: number;
|
||||||
|
wellDepthEnd?: number;
|
||||||
|
routeSpeed?: number;
|
||||||
|
rop?: number;
|
||||||
|
bhaUpSpeed?: number;
|
||||||
|
bhaDownSpeed?: number;
|
||||||
|
casingDownSpeed?: number;
|
||||||
|
nonProductiveHours?: number;
|
||||||
|
}
|
10
src/services/api/models/StatOperationsDtoPlanFactBase.ts
Normal file
10
src/services/api/models/StatOperationsDtoPlanFactBase.ts
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
/* istanbul ignore file */
|
||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
|
||||||
|
import type { StatOperationsDto } from './StatOperationsDto';
|
||||||
|
|
||||||
|
export type StatOperationsDtoPlanFactBase = {
|
||||||
|
plan?: StatOperationsDto;
|
||||||
|
fact?: StatOperationsDto;
|
||||||
|
}
|
12
src/services/api/models/StatSectionDto.ts
Normal file
12
src/services/api/models/StatSectionDto.ts
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
/* istanbul ignore file */
|
||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
|
||||||
|
import type { StatOperationsDto } from './StatOperationsDto';
|
||||||
|
|
||||||
|
export type StatSectionDto = {
|
||||||
|
plan?: StatOperationsDto;
|
||||||
|
fact?: StatOperationsDto;
|
||||||
|
id?: number;
|
||||||
|
caption?: string | null;
|
||||||
|
}
|
16
src/services/api/models/StatWellDto.ts
Normal file
16
src/services/api/models/StatWellDto.ts
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
/* istanbul ignore file */
|
||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
|
||||||
|
import type { CompanyDto } from './CompanyDto';
|
||||||
|
import type { StatOperationsDtoPlanFactBase } from './StatOperationsDtoPlanFactBase';
|
||||||
|
import type { StatSectionDto } from './StatSectionDto';
|
||||||
|
|
||||||
|
export type StatWellDto = {
|
||||||
|
id?: number;
|
||||||
|
caption?: string | null;
|
||||||
|
wellType?: string | null;
|
||||||
|
sections?: Array<StatSectionDto> | null;
|
||||||
|
total?: StatOperationsDtoPlanFactBase;
|
||||||
|
companies?: Array<CompanyDto> | null;
|
||||||
|
}
|
@ -1,22 +0,0 @@
|
|||||||
/* istanbul ignore file */
|
|
||||||
/* tslint:disable */
|
|
||||||
/* eslint-disable */
|
|
||||||
|
|
||||||
export type WellSectionDto = {
|
|
||||||
id?: number;
|
|
||||||
sectionType?: string | null;
|
|
||||||
wellDepthPlan?: number;
|
|
||||||
wellDepthFact?: number;
|
|
||||||
durationPlan?: number;
|
|
||||||
durationFact?: number;
|
|
||||||
mechSpeedPlan?: number;
|
|
||||||
mechSpeedFact?: number;
|
|
||||||
routeSpeedPlan?: number;
|
|
||||||
routeSpeedFact?: number;
|
|
||||||
bhaUpSpeedPlan?: number;
|
|
||||||
bhaUpSpeedFact?: number;
|
|
||||||
bhaDownSpeedPlan?: number;
|
|
||||||
bhaDownSpeedFact?: number;
|
|
||||||
casingDownSpeedPlan?: number;
|
|
||||||
casingDownSpeedFact?: number;
|
|
||||||
}
|
|
@ -1,27 +0,0 @@
|
|||||||
/* 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;
|
|
||||||
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;
|
|
||||||
}
|
|
@ -2,7 +2,6 @@
|
|||||||
/* tslint:disable */
|
/* tslint:disable */
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
import type { ClusterDto } from '../models/ClusterDto';
|
import type { ClusterDto } from '../models/ClusterDto';
|
||||||
import type { ClusterStatDto } from '../models/ClusterStatDto';
|
|
||||||
import type { WellDto } from '../models/WellDto';
|
import type { WellDto } from '../models/WellDto';
|
||||||
import { request as __request } from '../core/request';
|
import { request as __request } from '../core/request';
|
||||||
|
|
||||||
@ -37,20 +36,4 @@ idCluster: number,
|
|||||||
return result.body;
|
return result.body;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Получение обопщенной статистики по кусту (лучшая/худшая скважина)
|
|
||||||
* @param idCluster
|
|
||||||
* @returns ClusterStatDto Success
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static async getStat(
|
|
||||||
idCluster: number,
|
|
||||||
): Promise<ClusterStatDto> {
|
|
||||||
const result = await __request({
|
|
||||||
method: 'GET',
|
|
||||||
path: `/api/cluster/${idCluster}/Stat`,
|
|
||||||
});
|
|
||||||
return result.body;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
@ -32,6 +32,8 @@ idWell: string,
|
|||||||
* @param operationCategoryIds фильтр по списку id категорий операции
|
* @param operationCategoryIds фильтр по списку id категорий операции
|
||||||
* @param begin фильтр по началу операции
|
* @param begin фильтр по началу операции
|
||||||
* @param end фильтр по окончанию операции
|
* @param end фильтр по окончанию операции
|
||||||
|
* @param minDepth фильтр по минимальной глубине скважины
|
||||||
|
* @param maxDepth фильтр по максимальной глубине скважины
|
||||||
* @param skip
|
* @param skip
|
||||||
* @param take
|
* @param take
|
||||||
* @returns WellOperationDtoPaginationContainer Success
|
* @returns WellOperationDtoPaginationContainer Success
|
||||||
@ -44,6 +46,8 @@ sectionTypeIds?: Array<number>,
|
|||||||
operationCategoryIds?: Array<number>,
|
operationCategoryIds?: Array<number>,
|
||||||
begin?: string,
|
begin?: string,
|
||||||
end?: string,
|
end?: string,
|
||||||
|
minDepth: number = -1.7976931348623157e+308,
|
||||||
|
maxDepth: number = 1.7976931348623157e+308,
|
||||||
skip?: number,
|
skip?: number,
|
||||||
take: number = 32,
|
take: number = 32,
|
||||||
): Promise<WellOperationDtoPaginationContainer> {
|
): Promise<WellOperationDtoPaginationContainer> {
|
||||||
@ -56,6 +60,8 @@ take: number = 32,
|
|||||||
'operationCategoryIds': operationCategoryIds,
|
'operationCategoryIds': operationCategoryIds,
|
||||||
'begin': begin,
|
'begin': begin,
|
||||||
'end': end,
|
'end': end,
|
||||||
|
'minDepth': minDepth,
|
||||||
|
'maxDepth': maxDepth,
|
||||||
'skip': skip,
|
'skip': skip,
|
||||||
'take': take,
|
'take': take,
|
||||||
},
|
},
|
||||||
|
40
src/services/api/services/WellOperationStatService.ts
Normal file
40
src/services/api/services/WellOperationStatService.ts
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
/* istanbul ignore file */
|
||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
import type { StatClusterDto } from '../models/StatClusterDto';
|
||||||
|
import type { StatWellDto } from '../models/StatWellDto';
|
||||||
|
import { request as __request } from '../core/request';
|
||||||
|
|
||||||
|
export class WellOperationStatService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param idCluster
|
||||||
|
* @returns StatClusterDto Success
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static async getStatCluster(
|
||||||
|
idCluster: number,
|
||||||
|
): Promise<StatClusterDto> {
|
||||||
|
const result = await __request({
|
||||||
|
method: 'GET',
|
||||||
|
path: `/api/cluster/${idCluster}/stat`,
|
||||||
|
});
|
||||||
|
return result.body;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param idWell
|
||||||
|
* @returns StatWellDto Success
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static async getStatWell(
|
||||||
|
idWell: number,
|
||||||
|
): Promise<StatWellDto> {
|
||||||
|
const result = await __request({
|
||||||
|
method: 'GET',
|
||||||
|
path: `/api/well/${idWell}/stat`,
|
||||||
|
});
|
||||||
|
return result.body;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -1,41 +0,0 @@
|
|||||||
/* istanbul ignore file */
|
|
||||||
/* tslint:disable */
|
|
||||||
/* eslint-disable */
|
|
||||||
import type { WellSectionDto } from '../models/WellSectionDto';
|
|
||||||
import { request as __request } from '../core/request';
|
|
||||||
|
|
||||||
export class WellSectionService {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param idWell
|
|
||||||
* @returns WellSectionDto Success
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static async getSectionsByWellId(
|
|
||||||
idWell: number,
|
|
||||||
): Promise<Array<WellSectionDto>> {
|
|
||||||
const result = await __request({
|
|
||||||
method: 'GET',
|
|
||||||
path: `/api/well/${idWell}/sections`,
|
|
||||||
});
|
|
||||||
return result.body;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param idWell
|
|
||||||
* @param idSection
|
|
||||||
* @returns WellSectionDto Success
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static async get(
|
|
||||||
idWell: number,
|
|
||||||
idSection: number,
|
|
||||||
): Promise<WellSectionDto> {
|
|
||||||
const result = await __request({
|
|
||||||
method: 'GET',
|
|
||||||
path: `/api/well/${idWell}/sections/${idSection}`,
|
|
||||||
});
|
|
||||||
return result.body;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user