TF-1604: Add requiredCapabilities support TeamMailbox for GetEmailMethod
(cherry picked from commit 3922303e63a8e910511361019a54ea13801e3f92)
This commit is contained in:
+15
-12
@@ -5,6 +5,7 @@ import 'package:dartz/dartz.dart';
|
||||
import 'package:jmap_dart_client/jmap/account_id.dart';
|
||||
import 'package:jmap_dart_client/jmap/core/filter/filter.dart';
|
||||
import 'package:jmap_dart_client/jmap/core/properties/properties.dart';
|
||||
import 'package:jmap_dart_client/jmap/core/session/session.dart';
|
||||
import 'package:jmap_dart_client/jmap/core/unsigned_int.dart';
|
||||
import 'package:jmap_dart_client/jmap/core/sort/comparator.dart';
|
||||
import 'package:model/extensions/email_extension.dart';
|
||||
@@ -18,23 +19,25 @@ class RefreshChangesSearchEmailInteractor {
|
||||
RefreshChangesSearchEmailInteractor(this.threadRepository);
|
||||
|
||||
Stream<Either<Failure, Success>> execute(
|
||||
AccountId accountId,
|
||||
{
|
||||
UnsignedInt? limit,
|
||||
Set<Comparator>? sort,
|
||||
Filter? filter,
|
||||
Properties? properties,
|
||||
}
|
||||
Session session,
|
||||
AccountId accountId,
|
||||
{
|
||||
UnsignedInt? limit,
|
||||
Set<Comparator>? sort,
|
||||
Filter? filter,
|
||||
Properties? properties,
|
||||
}
|
||||
) async* {
|
||||
try {
|
||||
yield Right(RefreshingChangeSearchEmailState());
|
||||
|
||||
final emailList = await threadRepository.searchEmails(
|
||||
accountId,
|
||||
limit: limit,
|
||||
sort: sort,
|
||||
filter: filter,
|
||||
properties: properties);
|
||||
session,
|
||||
accountId,
|
||||
limit: limit,
|
||||
sort: sort,
|
||||
filter: filter,
|
||||
properties: properties);
|
||||
|
||||
final presentationEmailList = emailList
|
||||
.map((email) => email.toPresentationEmail())
|
||||
|
||||
Reference in New Issue
Block a user