blob: f805c1a725e492c227f652d794ebfde858a3d950 [file] [log] [blame]
(function () {
'use strict';
angular.module('xos.serviceTopology')
.directive('subscriberModal', function(){
return {
scope: {
subscribers: '=',
open: '='
},
bindToController: true,
restrict: 'E',
templateUrl: 'templates/subscriber-modal.tpl.html',
controllerAs: 'vm',
controller: function($rootScope){
this.close = () => {
this.open = false;
};
this.select = (subscriber) => {
$rootScope.$emit('subscriber.selected', subscriber);
this.close();
};
}
};
});
})();