mirror of
https://github.com/bitwarden/mobile
synced 2025-12-19 01:33:22 +00:00
[SG-834] Mobile pending login requests management screen (#2281)
* Bootstrap new classes for settings list * [SG-834] Add new method GetActivePasswordlessLoginRequestsAsync to AuthService * [SG-834] Add generic handle exception method to BaseViewModel * [SG-834] Add request verification to settings entry * [SG-834] Add text resources * [SG-834] Update view and viewmodel * [SG-834] Remove unnecessary property assignment * [SG-834] removed logger resolve
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Bit.Core.Abstractions;
|
||||
@@ -494,6 +495,12 @@ namespace Bit.Core.Services
|
||||
return await _apiService.GetAuthRequestAsync();
|
||||
}
|
||||
|
||||
public async Task<List<PasswordlessLoginResponse>> GetActivePasswordlessLoginRequestsAsync()
|
||||
{
|
||||
var requests = await GetPasswordlessLoginRequestsAsync();
|
||||
return requests.Where(r => !r.IsAnswered && !r.IsExpired).OrderByDescending(r => r.CreationDate).ToList();
|
||||
}
|
||||
|
||||
public async Task<PasswordlessLoginResponse> GetPasswordlessLoginRequestByIdAsync(string id)
|
||||
{
|
||||
return await _apiService.GetAuthRequestAsync(id);
|
||||
|
||||
Reference in New Issue
Block a user