define("app/services/searchIndex",["angular","cjt/util/locale","cjt/io/uapi-request","cjt/io/api","cjt/io/uapi","cjt/services/APIService"],(function(e,n,t){var a=e.module("cpanel.searchIndex.searchIndex.service",[]);a.value("PAGE",PAGE),a.value("userEmailAccount",PAGE.emailAccount),a.factory("searchIndex",["$q","APIService","userEmailAccount","$timeout",function(n,a,r,c){var i=function(){};return i.prototype=new a,e.extend(i.prototype,{reIndexEmail:function(){var e=new t.Class;return e.initialize("Email","fts_rescan_mailbox",{account:r}),this.deferred(e).promise}}),new i}])})),define("app/views/main",["angular","cjt/util/locale","app/services/searchIndex","cjt/modules","cjt/directives/actionButtonDirective","cjt/directives/alertList"],(function(e,n){return e.module("cpanel.searchIndex").controller("main",["$scope","searchIndex","alertService","PAGE",function(e,t,a,r){e.reIndexEmail=function(){return a.clear(),t.reIndexEmail().then((function(e){a.add({message:n.maketext("The system has initiated a reindex of your email."),replace:!0,id:"reIndexStatus",type:"success"}),e.messages&&e.messages.forEach((function(e){a.add({message:e,replace:!1,type:"warning"})}))})).catch((function(e){a.add({message:n.maketext("The system encountered an error when it attempted to initiate a reindex of your email: [_1]",e),replace:!0,id:"reIndexStatus",type:"danger"})}))}}])})),define("app/index",["angular","cjt/core","cjt/modules","ngRoute","app/services/searchIndex"],(function(e){"use strict";return function(){return e.module("cpanel.searchIndex",[PAGE.CJT2_ANGULAR_MODULE_NAME,"ngRoute","cpanel.searchIndex.searchIndex.service"]),require(["cjt/bootstrap","app/views/main"],(function(n){var t=e.module("cpanel.searchIndex");t.value("PAGE",PAGE),t.config(["$routeProvider",function(e){e.when("/",{controller:"main",templateUrl:"views/main.ptt"}),e.otherwise({redirectTo:"/"})}]),n("#content","cpanel.searchIndex")}))}}));