sogo/UI/WebServerResources/js/Preferences.js

2 lines
12 KiB
JavaScript
Raw Normal View History

2017-05-13 07:24:30 +02:00
!function(){"use strict";function e(e,a){e.state("preferences",{abstract:!0,views:{preferences:{templateUrl:"preferences.html",controller:"PreferencesController",controllerAs:"app"}},resolve:{statePreferences:t}}).state("preferences.general",{url:"/general",views:{module:{templateUrl:"generalPreferences.html"}}}).state("preferences.calendars",{url:"/calendars",views:{module:{templateUrl:"calendarsPreferences.html"}}}).state("preferences.addressbooks",{url:"/addressbooks",views:{module:{templateUrl:"addressbooksPreferences.html"}}}).state("preferences.mailer",{url:"/mailer",views:{module:{templateUrl:"mailerPreferences.html"}}}),a.otherwise("/general")}function t(e){return e}function a(e){e.$on("$routeChangeError",function(e,t,a,n){console.error(e,t,a,n)})}angular.module("SOGo.PreferencesUI",["ui.router","ck","SOGo.Common","SOGo.MailerUI","SOGo.ContactsUI","SOGo.Authentication","as.sortable"]).config(e).run(a),e.$inject=["$stateProvider","$urlRouterProvider"],t.$inject=["Preferences"],a.$inject=["$rootScope"]}(),function(){"use strict";function e(e,t,a,n,r){function o(){return!(n>0)&&!r}function l(){e.cancel()}function s(){e.hide()}var i=this;i.defaultPort=143,i.defaults=t,i.account=a,i.accountId=n,i.customFromIsReadonly=o,i.cancel=l,i.save=s,i.hostnameRE=n>0?/^(?!(127\.0\.0\.1|localhost(?:\.localdomain)?)$)/:/./,i.account.encryption?"ssl"==i.account.encryption&&(i.defaultPort=993):i.account.encryption="none"}e.$inject=["$mdDialog","defaults","account","accountId","mailCustomFromEnabled"],angular.module("SOGo.PreferencesUI").controller("AccountDialogController",e)}(),function(){"use strict";function e(e,t,a,n,r,o){function s(){a.cancel()}function i(){return g.filter.rules&&g.filter.rules.length>0&&g.filter.actions&&g.filter.actions.length>0}function c(e){a.hide()}function d(e){g.filter.rules||(g.filter.rules=[]),g.filter.rules.push({field:"subject",operator:"contains"})}function f(e){g.filter.rules.splice(e,1)}function u(e){g.filter.actions||(g.filter.actions=[]),g.filter.actions.push({method:"discard"})}function m(e){g.filter.actions.splice(e,1)}var g=this,p=t.sieveCapabilities,h=t.forwardEnabled;t.vacationEnabled;g.filter=n,g.mailboxes=r,g.labels=o,g.cancel=s,g.hasRulesAndActions=i,g.save=c,g.addMailFilterRule=d,g.removeMailFilterRule=f,g.addMailFilterAction=u,g.removeMailFilterAction=m,g.fieldLabels={subject:l("Subject"),from:l("From"),to:l("To"),cc:l("Cc"),to_or_cc:l("To or Cc"),size:l("Size (Kb)"),header:l("Header")},p.indexOf("body")>-1&&(g.fieldLabels.body=l("Body")),g.methodLabels={discard:l("Discard the message"),keep:l("Keep the message"),stop:l("Stop processing filter rules")},h&&(g.methodLabels.redirect=l("Forward the message to")),p.indexOf("reject")>-1&&(g.methodLabels.reject=l("Send a reject message")),p.indexOf("fileinto")>-1&&(g.methodLabels.fileinto=l("File the message in")),(p.indexOf("imapflags")>-1||p.indexOf("imap4flags")>-1)&&(g.methodLabels.addflag=l("Flag the message with")),g.numberOperatorLabels={under:l("is under"),over:l("is over")},g.textOperatorLabels={is:l("is"),is_not:l("is not"),contains:l("contains"),contains_not:l("does not contain"),matches:l("matches"),matches_not:l("does not match")},p.indexOf("regex")>-1&&(g.textOperatorLabels.regex=l("matches regex"),g.textOperatorLabels.regex_not=l("does not match regex")),g.flagLabels={seen:l("Seen"),deleted:l("Deleted"),answered:l("Answered"),flagged:l("Flagged"),junk:l("Junk"),not_junk:l("Not Junk")}}e.$inject=["$scope","$window","$mdDialog","filter","mailboxes","labels"],angular.module("SOGo.PreferencesUI").controller("FiltersDialogController",e)}(),function(){"use strict";function e(e,t,a,n,r,o,s,i,c,d,f,u,m,g){function p(e,t){t.$valid&&(n("xs")&&r("left").close(),a.go("preferences."+e))}function h(e){d.confirm(l("Warning"),l("Save preferences and reload page now?"),{ok:l("Yes"),cancel:l("No")}).then(function(){L(e,{quick:!0}).then(function(){t.location.reload(!0)})})}function w(e){Z.preferences.defaults.SOGoCalendarCategoriesColors["New category"]="#aaa",Z.preferences.defaults.SOGoCalendarCategories.push("New category"),c("calendarCategory_
//# sourceMappingURL=Preferences.js.map