diff --git a/AsbCloudApp/Data/CompanyDto.cs b/AsbCloudApp/Data/CompanyDto.cs index a572f8c6..9ca4bcc4 100644 --- a/AsbCloudApp/Data/CompanyDto.cs +++ b/AsbCloudApp/Data/CompanyDto.cs @@ -32,15 +32,4 @@ namespace AsbCloudApp.Data public string? CompanyTypeCaption { get; set; } = null!; } - - /// - /// DTO компании с пользователями - /// - public class CompanyWithContactsDto: CompanyDto - { - /// - /// Пользователи компании - /// - public IEnumerable Contacts { get; set; } = Enumerable.Empty(); - } } diff --git a/AsbCloudWebApi/Controllers/WellContactController.cs b/AsbCloudWebApi/Controllers/WellContactController.cs index a35434d6..132fdc15 100644 --- a/AsbCloudWebApi/Controllers/WellContactController.cs +++ b/AsbCloudWebApi/Controllers/WellContactController.cs @@ -39,6 +39,8 @@ namespace AsbCloudWebApi.Controllers /// /// [HttpGet("api/well/{idWell}/contacts/types")] + [ProducesResponseType(StatusCodes.Status204NoContent)] + [ProducesResponseType(StatusCodes.Status403Forbidden)] [ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)] public async Task GetTypesAsync(int idWell, CancellationToken token) { @@ -54,6 +56,8 @@ namespace AsbCloudWebApi.Controllers /// /// [HttpGet("api/well/{idWell}/contactType/{contactTypeId}")] + [ProducesResponseType(StatusCodes.Status204NoContent)] + [ProducesResponseType(StatusCodes.Status403Forbidden)] [ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)] public async Task GetAllAsync(int idWell, int contactTypeId, CancellationToken token) { @@ -72,6 +76,8 @@ namespace AsbCloudWebApi.Controllers /// /// [HttpGet("api/well/{idWell}/contact/{id}")] + [ProducesResponseType(StatusCodes.Status204NoContent)] + [ProducesResponseType(StatusCodes.Status403Forbidden)] [ProducesResponseType(typeof(IEnumerable), (int)System.Net.HttpStatusCode.OK)] public async Task GetAsync(int idWell, int id, CancellationToken token) { diff --git a/AsbCloudWebApi/appsettings.json b/AsbCloudWebApi/appsettings.json index c28b8530..6801ff38 100644 --- a/AsbCloudWebApi/appsettings.json +++ b/AsbCloudWebApi/appsettings.json @@ -7,10 +7,10 @@ } }, "ConnectionStrings": { - "DefaultConnection": "Host=localhost;Database=postgres2;Username=postgres;Password=q;Persist Security Info=True", - "DebugConnection": "Host=localhost;Database=postgres2;Username=postgres;Password=q;Persist Security Info=True;Include Error Detail=True", - "ServerConnection": "Host=192.168.1.70;Database=postgres2;Username=postgres;Password=q;Persist Security Info=True", - "LocalConnection": "Host=localhost;Database=postgres2;Username=postgres;Password=q;Persist Security Info=True" + "DefaultConnection": "Host=localhost;Database=postgres;Username=postgres;Password=q;Persist Security Info=True", + "DebugConnection": "Host=localhost;Database=postgres;Username=postgres;Password=q;Persist Security Info=True;Include Error Detail=True", + "ServerConnection": "Host=192.168.1.70;Database=postgres;Username=postgres;Password=q;Persist Security Info=True", + "LocalConnection": "Host=localhost;Database=postgres;Username=postgres;Password=q;Persist Security Info=True" }, "AllowedHosts": "*", //"userLimits": {