DD.WellWorkover.Cloud/AsbCloudWebApi.IntegrationTests/Clients/ICrudWellRelatedClient.cs
2024-02-27 09:32:08 +05:00

30 lines
747 B
C#

using AsbCloudApp.Data;
using Refit;
namespace AsbCloudWebApi.IntegrationTests.Clients;
public interface ICrudWellRelatedClient<TDto>
where TDto : IId, IWellRelated
{
[Post("/")]
Task<IApiResponse<int>> InsertAsync([Body] TDto dto);
[Post("/range")]
Task<IApiResponse<int>> InsertRangeAsync([Body] IEnumerable<TDto> dtos);
[Get("/")]
Task<IApiResponse<IEnumerable<TDto>>> GetAllAsync();
[Get("/well/{idWell}")]
Task<IApiResponse<IEnumerable<TDto>>> GetByIdWellAsync(int idWell);
[Get("/{id}")]
Task<IApiResponse<TDto>> GetOrDefaultAsync(int id);
[Put("/")]
Task<IApiResponse<int>> UpdateAsync([Body] TDto dto);
[Delete("/{id}")]
Task<IApiResponse<int>> DeleteAsync(int id);
}