mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-05-13 07:25:26 +00:00
Fix support for SOGoSieveFolderEncoding defaults
Fixed the following bugs in the mail filter editor: 1. Sieve folder encoding not respecting the SOGoSieveFolderEncoding system defaults; 2. Conditions are still displayed when rule affects all messages; 3. Missing custom mail labels to "flag with" action.
This commit is contained in:
@@ -12,7 +12,8 @@
|
||||
var vm = this,
|
||||
sieveCapabilities = $window.sieveCapabilities,
|
||||
forwardEnabled = $window.forwardEnabled,
|
||||
vacationEnabled = $window.vacationEnabled;
|
||||
vacationEnabled = $window.vacationEnabled,
|
||||
sieveFolderPathAttribute = ($window.sieveFolderEncoding == "UTF-8") ? "name" : "path";
|
||||
|
||||
vm.filter = filter;
|
||||
vm.mailboxes = mailboxes;
|
||||
@@ -50,6 +51,12 @@
|
||||
//if (vacationEnabled)
|
||||
// vm.methodLabels.vacation = l("Send a vacation message");
|
||||
|
||||
vm.mailboxes = _.map(mailboxes, function(mailbox) {
|
||||
return { level: mailbox.level,
|
||||
name: mailbox.name,
|
||||
path: mailbox[sieveFolderPathAttribute] };
|
||||
});
|
||||
|
||||
if (sieveCapabilities.indexOf("reject") > -1)
|
||||
vm.methodLabels.reject = l("Send a reject message");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user