From bef1292e7c4c47452871cbddd2ff57fd7b6c11d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A4=D1=80=D0=BE=D0=BB=D0=BE=D0=B2?= Date: Thu, 12 Aug 2021 11:52:23 +0500 Subject: [PATCH] doc and terurn types --- AsbCloudWebApi/Controllers/WellSectionController.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/AsbCloudWebApi/Controllers/WellSectionController.cs b/AsbCloudWebApi/Controllers/WellSectionController.cs index 4817cb83..23836d2f 100644 --- a/AsbCloudWebApi/Controllers/WellSectionController.cs +++ b/AsbCloudWebApi/Controllers/WellSectionController.cs @@ -8,6 +8,9 @@ using System.Threading.Tasks; namespace AsbCloudWebApi.Controllers { + /// + /// Контроллер секций скважины + /// [Route("api/well/{idWell}/sections")] [ApiController] [Authorize] @@ -23,6 +26,7 @@ namespace AsbCloudWebApi.Controllers } [HttpGet] + [ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)] public async Task GetAllAsync(int idWell, int skip = 0, int take = 32, CancellationToken token = default) { @@ -35,6 +39,7 @@ namespace AsbCloudWebApi.Controllers [HttpGet] [Route("{idSection}")] + [ProducesResponseType(typeof(WellSectionDto), (int)System.Net.HttpStatusCode.OK)] public async Task GetAsync(int idWell, int idSection, CancellationToken token = default) { @@ -46,6 +51,7 @@ namespace AsbCloudWebApi.Controllers } [HttpPost] + [ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)] public async Task InsertAsync(int idWell, [FromBody] IEnumerable values, CancellationToken token = default) { @@ -57,6 +63,7 @@ namespace AsbCloudWebApi.Controllers } [HttpPut("{idSection}")] + [ProducesResponseType(typeof(WellSectionDto), (int)System.Net.HttpStatusCode.OK)] public async Task UpdateAsync(int idWell, int idSection, [FromBody] WellSectionDto value, CancellationToken token = default) { if (!await CanUserAccessToWellAsync(idWell, token)) @@ -67,6 +74,7 @@ namespace AsbCloudWebApi.Controllers } [HttpDelete("{idSection}")] + [ProducesResponseType(typeof(int), (int)System.Net.HttpStatusCode.OK)] public async Task DeleteAsync(int idWell, int idSection, CancellationToken token = default) { if (!await CanUserAccessToWellAsync(idWell, token))