This commit is contained in:
mmrbnjd
2025-07-30 23:49:51 +03:30
parent 5731c9ff97
commit 96d6f5c004
4 changed files with 58 additions and 3 deletions

View File

@@ -73,9 +73,13 @@ namespace HushianWebApp.Service
return response.IsSuccessStatusCode;
}
public async Task<ChatItemDto> GetLastChatInCompany(int CompanyID)
public async Task<ChatItemDto?> GetLastOpenChatInCompany(int CompanyID)
{
return new();
var response = await _baseController.Get($"{BaseRoute}User/LastOpenChatInCompany/{CompanyID}");
if (response.StatusCode==System.Net.HttpStatusCode.OK)
return await response.Content.ReadFromJsonAsync<ChatItemDto>();
return null;
}
}
}