DD.WellWorkover.Cloud/AsbCloudWebApi/Rest/ProcessMapPlanDrilling.http
ngfrolov 54ef71411a
ProcessMapPlanDrilling.http - fix encoding.
Handle foreignKeys exceptions as validation exceptions.
Add integr.tests for bad request cases.
2024-01-22 11:49:45 +05:00

132 lines
3.1 KiB
HTTP
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@baseUrl = http://127.0.0.1:5000
@contentType = application/json
@contentTypeForFiles = application/octet-stream
@auth = Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjEiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiZGV2IiwiaWRDb21wYW55IjoiMSIsImh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vd3MvMjAwOC8wNi9pZGVudGl0eS9jbGFpbXMvcm9sZSI6InJvb3QiLCJuYmYiOjE2OTc0MzcwMzEsImV4cCI6MTcyODk5NDYzMSwiaXNzIjoiYSIsImF1ZCI6ImEifQ.vB7Qb3K9gG77iP8y25zB3RcZIQk9cHkq3I1SkcooYJs
@uid = 20210101_000000000
@id = 1
@idWell = 1
### получение данных drill test с панели и сохранение их в ЕЦП
POST {{baseUrl}}/api/well/{{idWell}}/ProcessMapPlanDrilling
Content-Type: {{contentType}}
accept: */*
Authorization: {{auth}}
[
{
"id": 0,
"idAuthor": 0,
"idEditor": 0,
"creation": "2024-01-18T12:45:58.205Z",
"obsolete": "2024-01-18T12:45:58.205Z",
"idState": 0,
"idPrevious": 0,
"idWell": 1,
"idWellSectionType": 1,
"depthStart": 0,
"depthEnd": 10,
"idMode": 2,
"axialLoad": {
"plan": 0,
"limitMax": 0
},
"deltaPressure": {
"plan": 0,
"limitMax": 0
},
"topDriveTorque": {
"plan": 0,
"limitMax": 0
},
"topDriveSpeed": {
"plan": 0,
"limitMax": 0
},
"flow": {
"plan": 0,
"limitMax": 0
},
"ropPlan": 99999.9,
"usageSaub": 100,
"usageSpin": 100,
"comment": ""
}
]
### Получение всех
GET {{baseUrl}}/api/well/{{idWell}}/ProcessMapPlanDrilling
accept: */*
Authorization: {{auth}}
### замена старых записей новыми
POST {{baseUrl}}/api/well/{{idWell}}/ProcessMapPlanDrilling/replace
Content-Type: {{contentType}}
accept: */*
Authorization: {{auth}}
[
{
"id": 0,
"idAuthor": 0,
"idEditor": 0,
"creation": "2024-01-19T05:31:54.762Z",
"obsolete": "2024-01-19T05:31:54.762Z",
"idState": 0,
"idPrevious": 0,
"idWell": 1,
"idWellSectionType": 1500,
"depthStart": 0,
"depthEnd": 10,
"idMode": 2,
"axialLoad": {
"plan": 0,
"limitMax": 0
},
"deltaPressure": {
"plan": 0,
"limitMax": 0
},
"topDriveTorque": {
"plan": 0,
"limitMax": 0
},
"topDriveSpeed": {
"plan": 0,
"limitMax": 0
},
"flow": {
"plan": 0,
"limitMax": 0
},
"ropPlan": 99999.9,
"usageSaub": 100,
"usageSpin": 100,
"comment": "There is no spoon"
}
]
### Получение только актуальных
GET {{baseUrl}}/api/well/{{idWell}}/ProcessMapPlanDrilling?Moment=3000-01-01
accept: */*
Authorization: {{auth}}
### Получение
GET {{baseUrl}}/api/well/{{idWell}}/ProcessMapPlanDrilling/dates
accept: */*
Authorization: {{auth}}
### Получение изменений за дату
GET {{baseUrl}}/api/well/{{idWell}}/ProcessMapPlanDrilling/changeLog?date=2024-01-19
accept: */*
Authorization: {{auth}}
### удаление
DELETE {{baseUrl}}/api/well/{{idWell}}/ProcessMapPlanDrilling
Content-Type: {{contentType}}
accept: */*
Authorization: {{auth}}
[
1
]