Add a create repo button in a few places
This commit is contained in:
parent
8cb177128b
commit
5175364e62
3 changed files with 17 additions and 5 deletions
|
@ -204,7 +204,7 @@ function RepoListCtrl($scope, Restangular, UserService) {
|
|||
});
|
||||
}
|
||||
|
||||
function LandingCtrl($scope, $timeout, Restangular, UserService, KeyService) {
|
||||
function LandingCtrl($scope, $timeout, $location, Restangular, UserService, KeyService) {
|
||||
$('.form-signup').popover();
|
||||
|
||||
$scope.$watch( function () { return UserService.currentUser(); }, function (currentUser) {
|
||||
|
@ -230,7 +230,11 @@ function LandingCtrl($scope, $timeout, Restangular, UserService, KeyService) {
|
|||
};
|
||||
|
||||
$scope.browseRepos = function() {
|
||||
document.location = '/repository/';
|
||||
$location.path('/repository/');
|
||||
};
|
||||
|
||||
$scope.createRepo = function() {
|
||||
$location.path('/new/');
|
||||
};
|
||||
|
||||
$scope.register = function() {
|
||||
|
@ -906,13 +910,13 @@ function ImageViewCtrl($scope, $routeParams, $rootScope, Restangular) {
|
|||
});
|
||||
}
|
||||
|
||||
function V1Ctrl($scope, UserService) {
|
||||
function V1Ctrl($scope, $location, UserService) {
|
||||
$scope.$watch( function () { return UserService.currentUser(); }, function (currentUser) {
|
||||
$scope.user = currentUser;
|
||||
}, true);
|
||||
|
||||
$scope.browseRepos = function() {
|
||||
document.location = '/repository/';
|
||||
$location.path('/repository/');
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Reference in a new issue