Blokkolás, feloldás
This commit is contained in:
@@ -60,6 +60,70 @@ namespace WorkFlowCheck.Web.Services
|
||||
}
|
||||
public async Task<ApiResponseDTO<CheckListHeaderDTO>> UpdateCheckListHeader(CheckListHeaderDTO checkListHeaderDTO) => throw new NotImplementedException();
|
||||
|
||||
public async Task<ApiResponseDTO<bool>> AcceptCheckListHeader(int id, int userid)
|
||||
{
|
||||
var retVal = new ApiResponseDTO<bool>();
|
||||
var endpoint = $"{_httpClient.BaseAddress}api/CheckList/AcceptCheckListHeader/{id}/{userid}";
|
||||
try
|
||||
{
|
||||
var response = await _httpClient.GetFromJsonAsync<ApiResponseDTO<bool>>(endpoint);
|
||||
if (response != null)
|
||||
{
|
||||
if (response.IsSuccess)
|
||||
{
|
||||
return response;
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Log.Error(ex.Message);
|
||||
}
|
||||
return retVal;
|
||||
}
|
||||
public async Task<ApiResponseDTO<bool>> BlockCheckListHeader(int id, int userid)
|
||||
{
|
||||
var retVal = new ApiResponseDTO<bool>();
|
||||
var endpoint = $"{_httpClient.BaseAddress}api/CheckList/BlockCheckListHeader/{id}/{userid}";
|
||||
try
|
||||
{
|
||||
var response = await _httpClient.GetFromJsonAsync<ApiResponseDTO<bool>>(endpoint);
|
||||
if (response != null)
|
||||
{
|
||||
if (response.IsSuccess)
|
||||
{
|
||||
return response;
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Log.Error(ex.Message);
|
||||
}
|
||||
return retVal;
|
||||
}
|
||||
public async Task<ApiResponseDTO<bool>> UnBlockCheckListHeader(int id, int userid)
|
||||
{
|
||||
var retVal = new ApiResponseDTO<bool>();
|
||||
var endpoint = $"{_httpClient.BaseAddress}api/CheckList/UnBlockCheckListHeader/{id}/{userid}";
|
||||
try
|
||||
{
|
||||
var response = await _httpClient.GetFromJsonAsync<ApiResponseDTO<bool>>(endpoint);
|
||||
if (response != null)
|
||||
{
|
||||
if (response.IsSuccess)
|
||||
{
|
||||
return response;
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Log.Error(ex.Message);
|
||||
}
|
||||
return retVal;
|
||||
}
|
||||
|
||||
public async Task<ApiResponseDTO<byte[]>> CreatePDF(int id)
|
||||
{
|
||||
var retVal = new ApiResponseDTO<byte[]>();
|
||||
|
||||
Reference in New Issue
Block a user