Inject RootCtrl into MemberModalCtrl to expose shared methods

This commit is contained in:
Kevin Gisi
2015-04-21 05:17:15 -04:00
parent ee7ba19ed1
commit a05714405a

View File

@@ -153,8 +153,11 @@ habitrpg.controller("GroupsCtrl", ['$scope', '$rootScope', 'Shared', 'Groups', '
};
}])
.controller("MemberModalCtrl", ['$scope', '$rootScope', 'Members', 'Shared', '$http', 'Notification', 'Groups',
function($scope, $rootScope, Members, Shared, $http, Notification, Groups) {
.controller("MemberModalCtrl", ['$scope', '$rootScope', 'Members', 'Shared', '$http', 'Notification', 'Groups', '$controller',
function($scope, $rootScope, Members, Shared, $http, Notification, Groups, $controller) {
$controller('RootCtrl', {$scope: $scope});
$scope.timestamp = function(timestamp){
return moment(timestamp).format($rootScope.User.user.preferences.dateFormat.toUpperCase());
}