fix: align backend APIs and upload flow
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
using System.Net.Http.Json;
|
||||
|
||||
namespace FileService.Application.UploadFile
|
||||
{
|
||||
public interface IGroupAccessService
|
||||
{
|
||||
Task<bool> CheckMemberAsync(Guid userId, Guid groupId);
|
||||
}
|
||||
|
||||
public class GroupAccessService(HttpClient httpClient) : IGroupAccessService
|
||||
{
|
||||
public async Task<bool> CheckMemberAsync(Guid userId, Guid groupId)
|
||||
{
|
||||
var result = await httpClient.GetFromJsonAsync<IM.Commons.Result<bool>>(
|
||||
$"api/groupmember/checkmember?userId={userId}&groupId={groupId}");
|
||||
return result?.Succeeded == true && result.Data;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user