Moved the code from AlertsCtrl and the markup in the vocabulary admin body into the alerts directive in the front end.