TF-2189 Create collapsed signature when edit email in Sending Queue on iOS
Signed-off-by: dab246 <tdvu@linagora.com> (cherry picked from commit 4f5e82173c2a6070d89f3debc00bc35ffb3021db)
This commit is contained in:
@@ -291,6 +291,14 @@ class ComposerController extends BaseController {
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
void handleExceptionAction({Failure? failure, Exception? exception}) {
|
||||
super.handleExceptionAction(failure: failure, exception: exception);
|
||||
if (failure is GetAllIdentitiesFailure) {
|
||||
_handleGetAllIdentitiesFailure(failure);
|
||||
}
|
||||
}
|
||||
|
||||
void _listenStreamEvent() {
|
||||
uploadInlineImageWorker = ever(uploadController.uploadInlineViewState, (state) {
|
||||
log('ComposerController::_listenStreamEvent()::uploadInlineImageWorker: $state');
|
||||
@@ -2089,4 +2097,15 @@ class ComposerController extends BaseController {
|
||||
log('ComposerController::addAttachmentFromDropZone: $attachment');
|
||||
uploadController.initializeUploadAttachments([attachment]);
|
||||
}
|
||||
|
||||
void _handleGetAllIdentitiesFailure(GetAllIdentitiesFailure failure) async {
|
||||
log('ComposerController::_handleGetAllIdentitiesFailure:failure: $failure');
|
||||
if (composerArguments.value?.emailActionType == EmailActionType.editSendingEmail && PlatformInfo.isMobile) {
|
||||
final signatureContent = await htmlEditorApi?.getSignatureContent();
|
||||
log('ComposerController::_handleGetAllIdentitiesFailure:signatureContent: $signatureContent');
|
||||
if (signatureContent?.isNotEmpty == true) {
|
||||
await _applySignature(signatureContent!);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user