diff --git a/AsbCloudWebApi/Controllers/AdminTelemetryController.cs b/AsbCloudWebApi/Controllers/AdminTelemetryController.cs
index b9f30009..c0471f8e 100644
--- a/AsbCloudWebApi/Controllers/AdminTelemetryController.cs
+++ b/AsbCloudWebApi/Controllers/AdminTelemetryController.cs
@@ -29,7 +29,7 @@ namespace AsbCloudWebApi.Controllers
///
///
[HttpPost]
- [Route("/merge/{idFrom}/{idTo}")]
+ [Route("/merger/{idFrom}/{idTo}")]
[Permission]
public async Task MergeTelemetriesAsync(int idFrom, int idTo, CancellationToken token)
{
diff --git a/AsbCloudWebApi/Controllers/AuthController.cs b/AsbCloudWebApi/Controllers/AuthController.cs
index ca3143ba..102acc8f 100644
--- a/AsbCloudWebApi/Controllers/AuthController.cs
+++ b/AsbCloudWebApi/Controllers/AuthController.cs
@@ -2,7 +2,6 @@
using AsbCloudApp.Data.User;
using AsbCloudApp.Repositories;
using AsbCloudApp.Services;
-using AsbCloudInfrastructure.Repository;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Swashbuckle.AspNetCore.Annotations;
@@ -35,7 +34,7 @@ namespace AsbCloudWebApi.Controllers
/// новый токен
/// логин и пароль не подходят
[AllowAnonymous]
- [HttpPost("login")]
+ [HttpPost]
[SwaggerOperation(OperationId = "login")]
[ProducesResponseType(typeof(UserTokenDto), (int)System.Net.HttpStatusCode.OK)]
public async Task LoginAsync([FromBody] AuthDto auth, CancellationToken token)
@@ -53,7 +52,7 @@ namespace AsbCloudWebApi.Controllers
///
/// новый токен
[Authorize]
- [HttpGet("refresh")]
+ [HttpGet]
[ProducesResponseType(typeof(UserTokenDto), (int)System.Net.HttpStatusCode.OK)]
public async Task RefreshAsync(CancellationToken token)
{
@@ -71,6 +70,7 @@ namespace AsbCloudWebApi.Controllers
/// Информация о новом пользователе
/// Ок
[HttpPost]
+ [Route("registration")]
public IActionResult Register(UserRegistrationDto user)
{
var code = authService.Register(user);
@@ -92,7 +92,7 @@ namespace AsbCloudWebApi.Controllers
///
/// Ок
[Authorize]
- [HttpPut("{idUser}/ChangePassword")]
+ [HttpPut("{idUser}")]
public IActionResult ChangePassword([FromRoute] int idUser, [FromBody] string newPassword)
{
var editorUserId = User.GetUserId();
diff --git a/AsbCloudWebApi/Controllers/AutoGeneratedDailyReportController.cs b/AsbCloudWebApi/Controllers/AutoGeneratedDailyReportController.cs
index 0ef6c6da..d19d8950 100644
--- a/AsbCloudWebApi/Controllers/AutoGeneratedDailyReportController.cs
+++ b/AsbCloudWebApi/Controllers/AutoGeneratedDailyReportController.cs
@@ -40,7 +40,7 @@ public class AutoGeneratedDailyReportController : ControllerBase
///
///
[HttpGet]
- [Route("generate")]
+ [Route("file")]
[ProducesResponseType(typeof(PhysicalFileResult), (int)HttpStatusCode.OK)]
[ProducesResponseType(StatusCodes.Status204NoContent)]
public async Task GenerateAsync([FromRoute] int idWell,
diff --git a/AsbCloudWebApi/Controllers/DailyReportController.cs b/AsbCloudWebApi/Controllers/DailyReportController.cs
index 5abc6659..60076819 100644
--- a/AsbCloudWebApi/Controllers/DailyReportController.cs
+++ b/AsbCloudWebApi/Controllers/DailyReportController.cs
@@ -164,7 +164,7 @@ namespace AsbCloudWebApi.Controllers
///
///
///
- [HttpGet("{date}/excel")]
+ [HttpGet("{date}/file")]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task DownloadAsync(int idWell, DateOnly date, CancellationToken token)
{
diff --git a/AsbCloudWebApi/Controllers/DrillingProgramController.cs b/AsbCloudWebApi/Controllers/DrillingProgramController.cs
index 69944c9d..fc4ad8ea 100644
--- a/AsbCloudWebApi/Controllers/DrillingProgramController.cs
+++ b/AsbCloudWebApi/Controllers/DrillingProgramController.cs
@@ -83,7 +83,7 @@ namespace AsbCloudWebApi.Controllers
///
///
///
- [HttpPost("ClearError")]
+ [HttpDelete("errors")]
[Permission("DrillingProgram.get")]
public IActionResult ClearError(int idWell)
{
diff --git a/AsbCloudWebApi/Controllers/FactTrajectoryController.cs b/AsbCloudWebApi/Controllers/FactTrajectoryController.cs
index c17ce3fd..fbdb6703 100644
--- a/AsbCloudWebApi/Controllers/FactTrajectoryController.cs
+++ b/AsbCloudWebApi/Controllers/FactTrajectoryController.cs
@@ -30,7 +30,6 @@ public class FactTrajectoryController : ControllerBase
/// Токен отмены операции
///
[HttpGet]
- [Route("getRows")]
[ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)]
public async Task GetRowsAsync([FromRoute] int idWell,
CancellationToken cancellationToken)
diff --git a/AsbCloudWebApi/Controllers/FaqController.cs b/AsbCloudWebApi/Controllers/FaqController.cs
index 763d0f6d..d0ac20c1 100644
--- a/AsbCloudWebApi/Controllers/FaqController.cs
+++ b/AsbCloudWebApi/Controllers/FaqController.cs
@@ -82,7 +82,7 @@ namespace AsbCloudWebApi.Controllers
///
///
///
- [HttpPost("merge")]
+ [HttpPost("merger")]
[Permission]
[ProducesResponseType(typeof(int), (int)System.Net.HttpStatusCode.OK)]
public async Task MergeAsync(
diff --git a/AsbCloudWebApi/Controllers/PlannedTrajectoryController.cs b/AsbCloudWebApi/Controllers/PlannedTrajectoryController.cs
index 5da1a2c2..bde9e732 100644
--- a/AsbCloudWebApi/Controllers/PlannedTrajectoryController.cs
+++ b/AsbCloudWebApi/Controllers/PlannedTrajectoryController.cs
@@ -42,7 +42,7 @@ namespace AsbCloudWebApi.Controllers
///
/// Запрашиваемый файл
[HttpGet]
- [Route("template")]
+ [Route("template/file")]
[AllowAnonymous]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public IActionResult GetTemplate()
@@ -59,7 +59,7 @@ namespace AsbCloudWebApi.Controllers
/// Токен отмены задачи
/// Запрашиваемый файл
[HttpGet]
- [Route("export")]
+ [Route("file")]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task ExportAsync([FromRoute] int idWell, CancellationToken token)
{
@@ -80,7 +80,7 @@ namespace AsbCloudWebApi.Controllers
/// Токен отмены задачи
/// количество успешно записанных строк в БД
[HttpPost]
- [Route("import/{deleteBeforeImport}")]
+ [Route("file/{deleteBeforeImport}")]
[ProducesResponseType(typeof(int), (int)System.Net.HttpStatusCode.OK)]
public async Task ImportAsync(int idWell,
[FromForm] IFormFileCollection files,
@@ -118,7 +118,6 @@ namespace AsbCloudWebApi.Controllers
/// Токен отмены задачи
/// Список добавленных координат плановой траектории
[HttpGet]
- [Route("getRows")]
[ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)]
public async Task GetAsync([FromRoute] int idWell, CancellationToken token)
{
@@ -137,7 +136,6 @@ namespace AsbCloudWebApi.Controllers
///
/// количество успешно записанных строк в БД
[HttpPost]
- [Route("addRow")]
[ProducesResponseType(typeof(int), (int)System.Net.HttpStatusCode.OK)]
public async Task AddAsync(int idWell, [FromBody] TrajectoryGeoPlanDto row,
CancellationToken token)
@@ -161,7 +159,7 @@ namespace AsbCloudWebApi.Controllers
///
/// количество успешно записанных строк в БД
[HttpPost]
- [Route("addRangeRows")]
+ [Route("range")]
[ProducesResponseType(typeof(int), (int)System.Net.HttpStatusCode.OK)]
public async Task AddRangeAsync(int idWell, [FromBody] IEnumerable rows,
CancellationToken token)
@@ -232,6 +230,7 @@ namespace AsbCloudWebApi.Controllers
///
///
[HttpGet]
+ [Route("trajectoryCartesianPlanFact")]
[ProducesResponseType(typeof(PlanFactBase, IEnumerable>), (int)System.Net.HttpStatusCode.OK)]
public async Task GetTrajectoryCartesianPlanFactAsync(int idWell, CancellationToken token)
{
diff --git a/AsbCloudWebApi/Controllers/ProcessMapController.cs b/AsbCloudWebApi/Controllers/ProcessMapController.cs
index ffa88938..1e9b5e1f 100644
--- a/AsbCloudWebApi/Controllers/ProcessMapController.cs
+++ b/AsbCloudWebApi/Controllers/ProcessMapController.cs
@@ -100,7 +100,7 @@ namespace AsbCloudWebApi.Controllers
/// ///
///
[HttpGet]
- [Route("getReportFile/{wellId}")]
+ [Route("processMapReport/{wellId}/file")]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task GetReportFileAsync(int wellId, CancellationToken token)
{
@@ -127,7 +127,7 @@ namespace AsbCloudWebApi.Controllers
///
///
[HttpGet]
- [Route("getDrillProcessMap/{wellId}")]
+ [Route("drillProcessMap/{wellId}")]
[ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)]
public async Task GetDrillProcessMap(int wellId, CancellationToken token)
{
@@ -170,7 +170,7 @@ namespace AsbCloudWebApi.Controllers
///
/// Запрашиваемый файл
[HttpGet]
- [Route("template")]
+ [Route("template/file")]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task GetTemplateAsync(CancellationToken cancellationToken)
{
@@ -188,7 +188,7 @@ namespace AsbCloudWebApi.Controllers
///
///
[HttpPost]
- [Route("import/{idWell}/{options}")]
+ [Route("file/{idWell}/{options}")]
public async Task ImportAsync(int idWell,
int options,
[Required] IFormFile file,
@@ -227,7 +227,7 @@ namespace AsbCloudWebApi.Controllers
///
///
[HttpGet]
- [Route("export/{idWell}")]
+ [Route("file/{idWell}")]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task ExportAsync(int idWell, CancellationToken cancellationToken)
{
diff --git a/AsbCloudWebApi/Controllers/SAUB/DetectedOperationController.cs b/AsbCloudWebApi/Controllers/SAUB/DetectedOperationController.cs
index 02737317..3e1c4da2 100644
--- a/AsbCloudWebApi/Controllers/SAUB/DetectedOperationController.cs
+++ b/AsbCloudWebApi/Controllers/SAUB/DetectedOperationController.cs
@@ -121,7 +121,7 @@ namespace AsbCloudWebApi.Controllers.SAUB
/// Токен отмены задачи
/// Запрашиваемый файл
[HttpGet]
- [Route("export")]
+ [Route("file")]
[Permission]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task ExportAsync(int? idWell, int? idCluster, CancellationToken token)
diff --git a/AsbCloudWebApi/Controllers/SAUB/TelemetryDataSaubController.cs b/AsbCloudWebApi/Controllers/SAUB/TelemetryDataSaubController.cs
index 8158308e..7baf98a6 100644
--- a/AsbCloudWebApi/Controllers/SAUB/TelemetryDataSaubController.cs
+++ b/AsbCloudWebApi/Controllers/SAUB/TelemetryDataSaubController.cs
@@ -3,10 +3,8 @@ using AsbCloudApp.Services;
using AsbCloudWebApi.SignalR;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.SignalR;
-using System.IO;
using System.Threading.Tasks;
using System.Threading;
-using AsbCloudInfrastructure.Services;
using System;
namespace AsbCloudWebApi.Controllers.SAUB
@@ -43,7 +41,7 @@ namespace AsbCloudWebApi.Controllers.SAUB
/// конец интервала в формате: yyyy-MM-DD HH:mm
///
///
- [HttpGet("{idWell}/export/csv")]
+ [HttpGet("{idWell}/file")]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task GetZippedCsv(int idWell, DateTime beginDate, DateTime endDate, CancellationToken token)
{
diff --git a/AsbCloudWebApi/Controllers/WellCompositeController.cs b/AsbCloudWebApi/Controllers/WellCompositeController.cs
index e64118fd..d977128d 100644
--- a/AsbCloudWebApi/Controllers/WellCompositeController.cs
+++ b/AsbCloudWebApi/Controllers/WellCompositeController.cs
@@ -71,7 +71,7 @@ namespace AsbCloudWebApi.Controllers
///
///
///
- [HttpGet("getCompositeProcessMap")]
+ [HttpGet("compositeProcessMap")]
[Permission]
[ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)]
public async Task GetCompositeProcessMap(int idWell, CancellationToken token)
diff --git a/AsbCloudWebApi/Controllers/WellOperationController.cs b/AsbCloudWebApi/Controllers/WellOperationController.cs
index 7bac5579..b2bd75a2 100644
--- a/AsbCloudWebApi/Controllers/WellOperationController.cs
+++ b/AsbCloudWebApi/Controllers/WellOperationController.cs
@@ -284,7 +284,7 @@ namespace AsbCloudWebApi.Controllers
///
[HttpPost]
[Permission]
- [Route("import/{options}")]
+ [Route("file/{options}")]
public async Task ImportAsync(int idWell,
[FromForm] IFormFileCollection files,
int options,
@@ -327,7 +327,7 @@ namespace AsbCloudWebApi.Controllers
/// Токен отмены задачи
/// Запрашиваемый файл
[HttpGet]
- [Route("export")]
+ [Route("file")]
[Permission]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public async Task ExportAsync([FromRoute] int idWell, CancellationToken token)
@@ -378,7 +378,7 @@ namespace AsbCloudWebApi.Controllers
///
/// Запрашиваемый файл
[HttpGet]
- [Route("template")]
+ [Route("template/file")]
[AllowAnonymous]
[ProducesResponseType(typeof(PhysicalFileResult), (int)System.Net.HttpStatusCode.OK)]
public IActionResult GetTemplate()