TF-1810 Add StoreDetailedEmailToCacheInteractor to store detailed email to cache
(cherry picked from commit 60a91537f7ea1225b5ca67f6dd9ef358b33939da)
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
|
||||
import 'package:model/email/attachment.dart';
|
||||
import 'package:tmail_ui_user/features/offline_mode/model/attachment_hive_cache.dart';
|
||||
|
||||
extension AttachmentExtension on Attachment {
|
||||
AttachmentHiveCache toHiveCache() {
|
||||
return AttachmentHiveCache(
|
||||
partId: partId?.value,
|
||||
blobId: blobId?.value,
|
||||
size: size?.value.toInt(),
|
||||
name: name,
|
||||
type: type?.mimeType,
|
||||
cid: cid,
|
||||
disposition: disposition?.name
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user