From 8efd01d55e333df843028a7d32417847d4e18905 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Thu, 26 Jan 2017 18:29:07 +0100 Subject: [PATCH 1/8] write using 'to', 'cc' or 'bcc' write to multiple selected contacts using 'to', 'cc' or 'bcc' Feauture Request #3548 --- .../ContactsUI/UIxContactFoldersView.wox | 27 ++++++++++++++++--- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/UI/Templates/ContactsUI/UIxContactFoldersView.wox b/UI/Templates/ContactsUI/UIxContactFoldersView.wox index a76d4de96..6f6dcf02c 100644 --- a/UI/Templates/ContactsUI/UIxContactFoldersView.wox +++ b/UI/Templates/ContactsUI/UIxContactFoldersView.wox @@ -364,10 +364,29 @@ - - - - + + + + + + + + + + + + + + + + + + + + + + + From ed62670a1aee4087064ce726ff8d503969e3c0a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Thu, 26 Jan 2017 19:27:13 +0100 Subject: [PATCH 2/8] write using 'to', 'cc' or 'bcc' write to multiple selected contacts using 'to', 'cc' or 'bcc' Feauture Request #3548 --- .../js/Contacts/AddressBookController.js | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/UI/WebServerResources/js/Contacts/AddressBookController.js b/UI/WebServerResources/js/Contacts/AddressBookController.js index dfa53e26e..46a92ff3e 100644 --- a/UI/WebServerResources/js/Contacts/AddressBookController.js +++ b/UI/WebServerResources/js/Contacts/AddressBookController.js @@ -319,7 +319,7 @@ vm.selectedFolder.$filter(''); } - function newMessage($event, recipients) { + function newMessage($event, recipients, recipientsField) { Account.$findAll().then(function(accounts) { var account = _.find(accounts, function(o) { if (o.id === 0) @@ -330,7 +330,16 @@ // list before proceeding with message's creation account.$getMailboxes().then(function(mailboxes) { account.$newMessage().then(function(message) { - angular.extend(message.editable, { to: recipients }); + switch(recipientsField) { + case 0: + angular.extend(message.editable, { to: recipients }); + break; + case 1: + angular.extend(message.editable, { cc: recipients }); + break; + case 2: + angular.extend(message.editable, { bcc: recipients }); + } $mdDialog.show({ parent: angular.element(document.body), targetEvent: $event, @@ -351,12 +360,12 @@ function newMessageWithRecipient($event, recipient, fn) { var recipients = [fn + ' <' + recipient + '>']; - vm.newMessage($event, recipients); + vm.newMessage($event, recipients, 0); $event.stopPropagation(); $event.preventDefault(); } - function newMessageWithSelectedCards($event) { + function newMessageWithSelectedCards($event, recipientsField) { var selectedCards = _.filter(vm.selectedFolder.$cards, function(card) { return card.selected; }); var promises = [], recipients = []; @@ -386,7 +395,7 @@ $q.all(promises).then(function() { recipients = _.uniq(recipients); if (recipients.length) - vm.newMessage($event, recipients); + vm.newMessage($event, recipients, recipientsField); }); } } From 621adb38c267e194c4fd817090b70c2c7432f71a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Fri, 27 Jan 2017 16:37:13 +0100 Subject: [PATCH 3/8] write using 'to', 'cc' or 'bcc' with string parameter write to multiple selected contacts using 'to', 'cc' or 'bcc' Feauture Request #3548 --- UI/Templates/ContactsUI/UIxContactFoldersView.wox | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/UI/Templates/ContactsUI/UIxContactFoldersView.wox b/UI/Templates/ContactsUI/UIxContactFoldersView.wox index 6f6dcf02c..0d9baebb9 100644 --- a/UI/Templates/ContactsUI/UIxContactFoldersView.wox +++ b/UI/Templates/ContactsUI/UIxContactFoldersView.wox @@ -370,17 +370,17 @@ - + - + - + From c9a50aa0577ebab060ab6ecef80dc1987894b315 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Fri, 27 Jan 2017 16:41:34 +0100 Subject: [PATCH 4/8] write using 'to', 'cc' or 'bcc' with string parameter write to multiple selected contacts using 'to', 'cc' or 'bcc' Feauture Request #3548 --- .../js/Contacts/AddressBookController.js | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/UI/WebServerResources/js/Contacts/AddressBookController.js b/UI/WebServerResources/js/Contacts/AddressBookController.js index 46a92ff3e..1f45b62a0 100644 --- a/UI/WebServerResources/js/Contacts/AddressBookController.js +++ b/UI/WebServerResources/js/Contacts/AddressBookController.js @@ -330,16 +330,9 @@ // list before proceeding with message's creation account.$getMailboxes().then(function(mailboxes) { account.$newMessage().then(function(message) { - switch(recipientsField) { - case 0: - angular.extend(message.editable, { to: recipients }); - break; - case 1: - angular.extend(message.editable, { cc: recipients }); - break; - case 2: - angular.extend(message.editable, { bcc: recipients }); - } + var headerField = {}; + headerField[recipientsField] = recipients; + angular.extend(message.editable, { headerField }); $mdDialog.show({ parent: angular.element(document.body), targetEvent: $event, @@ -360,7 +353,7 @@ function newMessageWithRecipient($event, recipient, fn) { var recipients = [fn + ' <' + recipient + '>']; - vm.newMessage($event, recipients, 0); + vm.newMessage($event, recipients, 'to'); $event.stopPropagation(); $event.preventDefault(); } From f90b2efadbfa698c6c0b3933d03e801e2fbbf014 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Fri, 27 Jan 2017 16:52:58 +0100 Subject: [PATCH 5/8] simpler version --- UI/WebServerResources/js/Contacts/AddressBookController.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/UI/WebServerResources/js/Contacts/AddressBookController.js b/UI/WebServerResources/js/Contacts/AddressBookController.js index 1f45b62a0..c012589c1 100644 --- a/UI/WebServerResources/js/Contacts/AddressBookController.js +++ b/UI/WebServerResources/js/Contacts/AddressBookController.js @@ -330,9 +330,7 @@ // list before proceeding with message's creation account.$getMailboxes().then(function(mailboxes) { account.$newMessage().then(function(message) { - var headerField = {}; - headerField[recipientsField] = recipients; - angular.extend(message.editable, { headerField }); + message.editable[recipientsField] = recipients; $mdDialog.show({ parent: angular.element(document.body), targetEvent: $event, From 1d8caa4297b13f1215589340080acf0880ed11f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Sat, 28 Jan 2017 17:22:14 +0100 Subject: [PATCH 6/8] Change Strings according to RFC 5322 --- UI/Contacts/English.lproj/Localizable.strings | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/UI/Contacts/English.lproj/Localizable.strings b/UI/Contacts/English.lproj/Localizable.strings index e35c7b947..67c4870ad 100644 --- a/UI/Contacts/English.lproj/Localizable.strings +++ b/UI/Contacts/English.lproj/Localizable.strings @@ -41,6 +41,9 @@ "Move To" = "Move To"; "Copy To" = "Copy To"; "Add to" = "Add to"; +"To" = "To"; +"CC" = "Carbon Copy (Cc)"; +"BCC" = "Blind Carbon Copy (Bcc)"; /* Subheader of empty addressbook */ "No contact" = "No contact"; @@ -258,4 +261,4 @@ "key_create_card" = "c"; /* Hotkey to create a new list */ -"key_create_list" = "l"; \ No newline at end of file +"key_create_list" = "l"; From ef4e311a5ac8d447087a9141b68501a11094a757 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Sat, 28 Jan 2017 17:53:05 +0100 Subject: [PATCH 7/8] Change Strings according to RFC 5322 --- UI/Templates/ContactsUI/UIxContactFoldersView.wox | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/UI/Templates/ContactsUI/UIxContactFoldersView.wox b/UI/Templates/ContactsUI/UIxContactFoldersView.wox index 0d9baebb9..6b0bad543 100644 --- a/UI/Templates/ContactsUI/UIxContactFoldersView.wox +++ b/UI/Templates/ContactsUI/UIxContactFoldersView.wox @@ -376,12 +376,12 @@ - + - + From 1b264ef6baf2582b5a335d0db9d58aced669452d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=BCller?= Date: Sat, 28 Jan 2017 17:53:14 +0100 Subject: [PATCH 8/8] Change Strings according to RFC 5322 correction: for translations the strings in English.lproj should better be equal --- UI/Contacts/English.lproj/Localizable.strings | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/UI/Contacts/English.lproj/Localizable.strings b/UI/Contacts/English.lproj/Localizable.strings index 67c4870ad..4c3ebc10a 100644 --- a/UI/Contacts/English.lproj/Localizable.strings +++ b/UI/Contacts/English.lproj/Localizable.strings @@ -42,8 +42,8 @@ "Copy To" = "Copy To"; "Add to" = "Add to"; "To" = "To"; -"CC" = "Carbon Copy (Cc)"; -"BCC" = "Blind Carbon Copy (Bcc)"; +"Carbon Copy (Cc)" = "Carbon Copy (Cc)"; +"Blind Carbon Copy (Bcc)" = "Blind Carbon Copy (Bcc)"; /* Subheader of empty addressbook */ "No contact" = "No contact";