harbor/static/ng/resources/js/layout/details/details.controller.js
2016-05-04 18:42:05 +08:00

28 lines
704 B
JavaScript

(function() {
'use strict';
angular
.module('harbor.details')
.controller('DetailsController', DetailsController);
DetailsController.$inject = ['$scope', '$location', '$routeParams'];
function DetailsController($scope, $location, $routeParams) {
var vm = this;
vm.isOpen = false;
vm.publicity = false;
vm.isProjectMember = true;
vm.closeRetrievePane = closeRetrievePane;
vm.togglePublicity = togglePublicity;
function closeRetrievePane() {
$scope.$broadcast('isOpen', false);
}
function togglePublicity(e) {
vm.publicity = e.publicity;
console.log('current project publicity:' + vm.publicity);
}
}
})();